Deleting a Player's Data
When a player deletes their account in your game or platform, tell INVO to erase the same player. One call from your server deletes the personal data INVO holds for your game, releases the player's phone number, and (if you ask) files a refund of the player's unspent coins to the card they paid with. This page covers the calls, what INVO deletes and what it must keep, the refund of unspent coins, the webhooks, and a checklist for app store account deletion rules.
Who decides, and when it runs
- • You instruct, INVO carries it out. For the data INVO processes for your game, you decide and INVO acts on your instruction. The erasure runs as soon as you call: the response tells you it is done.
- • There is no cancellation window at INVO. An erasure cannot be undone. If you give players a grace period to change their mind (for example 30 days), run it on your side first and call INVO only when it ends.
- • Only your game is affected. If the same person also plays another game or uses another platform on INVO, their account there is untouched.
- • Server only. Every call on this page authenticates with your game secret key in the
X-Game-Secret-Keyheader. Never call it from a browser or a client app.
Erase a player
POST /api/sdk/players/erasure
curl -X POST https://invo.network/api/sdk/players/erasure \
-H "X-Game-Secret-Key: $INVO_GAME_SECRET" \
-H "Content-Type: application/json" \
-d '{
"player_email": "fan@example.com",
"refund_unspent_coins": true,
"reference": "account-8812"
}'| Field | Required | Meaning |
|---|---|---|
player_email | yes | The player's email in your game. |
refund_unspent_coins | no | true or false (default false). When true, INVO files a refund request for the player's unspent coins before erasing them. See unspent coins. |
reference | no | Your own id for this deletion (an account id or a ticket number), up to 255 characters. It is echoed on the response and on the webhooks. |
201 when the player was erased by this call, 200 when this player was already erased (you get the same erasure back). Both mean the player is erased.
{
"erasure_id": "era_5f2c0d9b7a4e11f0c3a1b2d4",
"status": "completed",
"reference": "account-8812",
"game_id": "457716685480",
"identity_id": "9b1e6c0f2a...",
"wallet_identity_erased": false,
"balances_retained": [
{
"balance_id": 812,
"currency_id": 44,
"available_balance": "120.00",
"reserved_balance": "0.00"
}
],
"refund_requested": true,
"refund_request_id": "prr_81c0a7e3d2f9",
"refund_request_status": "pending",
"created_at": "2026-11-18T15:02:11+00:00",
"completed_at": "2026-11-18T15:02:11+00:00"
}| Field | Meaning |
|---|---|
erasure_id | INVO's id for this erasure. Keep it with your deletion record. |
status | Always "completed" on a success: the erasure ran before the response was sent. |
reference | Your reference, or null. |
identity_id | The player's opaque INVO identity id, the same id other INVO events carry. Use it to match your own records; it is not personal data on its own. |
wallet_identity_erased | true when the player's INVO wallet identity was deleted too, because no other game or platform uses it. false when another game or platform still uses it: then only your game's link to it is removed. |
balances_retained | The coins the player still held when they were erased, per currency. INVO keeps these on record so they can still be refunded. Amounts are two-place decimal strings. |
refund_requested | true when a refund request is attached to this erasure. |
refund_request_id | The attached refund request, or null. Read it with GET /api/sdk/refund-requests/{id}. |
refund_request_status | That request's status when you read the erasure, or null. See refund statuses. |
created_at, completed_at | ISO 8601 timestamps. |
The response never contains the player's email or phone number.
Repeat calls are safe
- • Calling again for a player who is already erased returns 200 with the same
erasure_id. Nothing runs twice. You do not need an idempotency key. - • A player who signs up again. If someone registers again with the same email after an erasure, that is a new player. The next erase call erases the new player and returns a new
erasure_id(201). - • If a call times out or you get a
503(ERASURE_FAILED,ERASURE_UNAVAILABLEorFEATURE_UNAVAILABLE), call again later with the same body. A503means nothing was changed. - • Asking for the refund later. If you erased a player without
refund_unspent_coins, repeat the same call with"refund_unspent_coins": true: INVO files the refund request against the erasure and returns it withrefund_request_idfilled in.
Read an erasure
GET /api/sdk/erasures/{erasure_id} returns the same body as the erase call, with refund_request_status as it is now. An erasure made by another game, or an unknown id, answers 404 ERASURE_NOT_FOUND.
curl https://invo.network/api/sdk/erasures/era_5f2c0d9b7a4e11f0c3a1b2d4 \
-H "X-Game-Secret-Key: $INVO_GAME_SECRET"What INVO deletes, and what it must keep
Deleted or anonymised now, for your game
- • The player's name, username, email, phone number and avatar on the player record, and any customer ids you stored on it.
- • Devices your game registered for the player.
- • Short-lived records for your game, such as pending verification and claim attempts and phone change requests.
- • The player's INVO wallet identity (phone and email), when no other game or platform uses it (
wallet_identity_erased: true).
Kept, sealed and access-restricted, for 10 years
- • Transactions, orders, payments and receipts.
- • Tax records.
- • Identity and verification records.
- • The player's coin balance (
balances_retained).
Why some records are kept. For its own payment, tax, anti-fraud and verification records, INVO is an independent controller with legal duties to keep them, so they cannot be deleted on request. The personal details are removed from the records INVO uses day to day and kept sealed, with access restricted to what the law requires, until the retention period of 10 years ends. They are then deleted.
The phone number is released. After an erasure the player's phone number no longer matches this player. A send or transfer addressed to that number afterwards does not reach the erased account.
Unspent coins
Players cannot withdraw coins as money. The only way unspent coins go back is a refund by INVO to the card they were bought with. Nothing is lost silently: whatever the player still holds is listed on the erasure (balances_retained) and kept, so it can still be refunded.
- • With
refund_unspent_coins: true, INVO files a refund request before it erases the player. INVO reviews the request and refunds, for each card purchase, the coins of that purchase that were not spent, back to the original card. - • Coins already spent are never refunded.
- • Coins that cannot go back to a card (for example coins bought through a third-party storefront or payment rail, or credited by a subscription renewal) are listed on the request with the reason. Refunds for those go through the store or flow they were bought through.
- • You can also ask for a refund without erasing the player, below.
Recommendation: when the player still holds coins, pass refund_unspent_coins: true on the erase call, so the request is filed while INVO can still match the player to their purchases.
Ask for a refund of unspent coins
POST /api/sdk/players/refund-request files a refund request without erasing the player. Nothing is refunded by this call: INVO reviews the request and decides.
curl -X POST https://invo.network/api/sdk/players/refund-request \
-H "X-Game-Secret-Key: $INVO_GAME_SECRET" \
-H "Content-Type: application/json" \
-d '{"player_email": "fan@example.com", "reference": "ticket-3391"}'201 when the request was filed, 200 when a request for this player is already open (you get that one back, so repeat calls are safe). 409 NOTHING_TO_REFUND when the player holds no coins in your game.
{
"refund_request_id": "prr_81c0a7e3d2f9",
"status": "pending",
"source": "partner",
"game_id": "457716685480",
"erasure_id": null,
"reference": "ticket-3391",
"identity_id": "9b1e6c0f2a...",
"balances": [
{"balance_id": 812, "currency_id": 44, "available_balance": "120.00", "reserved_balance": "0.00"}
],
"orders": [
{
"order_id": "ORD_20261102_7Q2M",
"rail": "card",
"order_type": "currency_purchase",
"purchased_at": "2026-11-02T18:40:05+00:00",
"usd_amount": "10.00",
"coins_purchased": "100.00",
"unspent_coins": "100.00",
"spent_coins": "0.00",
"estimated_refund_usd_gross": "10.00",
"card_refundable": true,
"reason": null,
"reason_text": null
},
{
"order_id": "ORD_20261015_K8P1",
"rail": "card",
"order_type": "currency_purchase",
"purchased_at": "2026-10-15T09:12:44+00:00",
"usd_amount": "5.00",
"coins_purchased": "50.00",
"unspent_coins": "0.00",
"spent_coins": "50.00",
"estimated_refund_usd_gross": "0.00",
"card_refundable": false,
"reason": "COINS_ALREADY_SPENT",
"reason_text": "Every coin this purchase credited has been spent or refunded."
}
],
"results": null,
"requested_at": "2026-11-18T15:02:11+00:00",
"decided_at": null
}orders lists every completed coin purchase of the player in your game, newest first, with what a refund could return. estimated_refund_usd_gross is an estimate: INVO sizes each refund again when it approves the request (coins spent in the meantime are not refunded), and the card processing fee may be deducted as for any refund. rail says how the coins were bought: card (by card through INVO), platform_store (through a platform's own store) or other. Only card purchases can be refunded by INVO. Orders may carry further fields; ignore the ones you do not use.
reason on an order | Why this order cannot go back to a card |
|---|---|
COINS_ALREADY_SPENT | Every coin the purchase credited has been spent or already refunded. |
NOT_REFUNDABLE_RAIL | Not bought by card through INVO (for example through a platform's own store). The refund goes through that store. |
NOT_REFUNDABLE_SUBSCRIPTION_MINT | Coins credited by a subscription renewal. Refund it through the subscription refund flow. |
NOT_CREDITED | The purchase never credited coins, so there is nothing to take back. |
NO_PAYMENT_REFERENCE | The order has no card payment to refund. |
GET /api/sdk/refund-requests/{refund_request_id} returns the same body. A request made by another game, or an unknown id, answers 404 REFUND_REQUEST_NOT_FOUND.
Refund request statuses
| Status | Meaning | Final? |
|---|---|---|
pending | Filed, waiting for INVO's review. | no (open) |
processing | Approved; INVO is refunding the orders. | no (open) |
partially_completed | Some orders could not be refunded yet. results says which; INVO retries the open ones, so this can later become completed or rejected_remaining. | no (open) |
completed | Every order that could go back to a card was refunded. Orders that could not are listed with their reason. | yes |
rejected | INVO declined the request. Nothing was refunded. | yes |
rejected_remaining | INVO closed a partially completed request. Orders already refunded stay refunded; every order still open is listed with outcome rejected and reason REJECTED. | yes |
A player has at most one open request (pending, processing or partially_completed): a new refund request for the same player returns the open one. Once INVO has run a request, results holds one entry per order, each with an outcome and, unless it was refunded, a reason and a reason_text you can show:
outcome | Meaning |
|---|---|
refunded | Refunded to the card, with refunded_coins, amount_usd_gross and amount_usd_net. |
not_refunded | Nothing to refund: one of the order reasons above, or ALREADY_REFUNDED. |
failed | The refund did not go through this time (for example PROCESSOR_ERROR). INVO retries it. |
not_attempted | Not reached in this run (reason NOT_ATTEMPTED). INVO retries it. |
needs_manual_review | INVO is checking this refund by hand before anything else happens to it. |
rejected | Closed by INVO on a rejected_remaining request (reason REJECTED). |
reason on a result | Meaning |
|---|---|
PROCESSOR_ERROR | The card processor did not answer; INVO retries this order. |
PROCESSOR_REJECTED | The card processor refused the refund. |
PROCESSOR_UNAVAILABLE | Card refunds are not available right now. |
ALREADY_REFUNDED | This purchase has already been refunded. |
REFUND_BELOW_MINIMUM | The unspent coins are worth less than the smallest card refund. |
NOT_ATTEMPTED | Not reached yet; INVO retries this order. |
REJECTED | INVO declined to refund this order. |
IDEMPOTENCY_CONFLICT, PROCESSOR_READ_FAILED, SETTLEMENT_FAILED, SETTLEMENT_UNCONFIRMED | INVO is checking this refund by hand (outcome needs_manual_review). |
Any other code reads "The refund could not be completed." Show reason_text rather than building your own sentence from the code, and treat a code you do not know as not refunded yet.
Webhooks
Opt in by name. These two events are not delivered to a * subscription. Add player.erasure_completed and player.refund_completed to your webhook endpoint's events by name (see webhook management).
player.erasure_completed
Sent when an erasure your game asked for has run.
{
"erasure_id": "era_5f2c0d9b7a4e11f0c3a1b2d4",
"reference": "account-8812",
"status": "completed",
"identity_id": "9b1e6c0f2a...",
"wallet_identity_erased": false,
"balances_retained": [
{"balance_id": 812, "currency_id": 44, "available_balance": "120.00", "reserved_balance": "0.00"}
],
"refund_request_id": "prr_81c0a7e3d2f9",
"completed_at": "2026-11-18T15:02:11+00:00"
}player.refund_completed
Sent each time INVO finishes a run of a refund request, whether it was filed on its own or by an erasure. status is completed, partially_completed, rejected or rejected_remaining. One request can send it more than once: a partially_completed event can be followed by completed or rejected_remaining for the same refund_request_id. Treat the latest one as the current state.
{
"refund_request_id": "prr_81c0a7e3d2f9",
"erasure_id": "era_5f2c0d9b7a4e11f0c3a1b2d4",
"reference": "account-8812",
"identity_id": "9b1e6c0f2a...",
"status": "completed",
"refunds": [
{"order_id": "ORD_20261102_7Q2M", "refunded_coins": "100.00", "amount_usd_net": "9.41", "amount_usd_gross": "10.00"}
],
"not_refunded": [
{"order_id": "ORD_20261015_K8P1", "reason": "COINS_ALREADY_SPENT"}
],
"decided_at": "2026-11-19T10:30:00+00:00"
}Neither event carries an email address or a phone number. Match them to your records with reference, erasure_id or refund_request_id. Both use the same signature and delivery rules as every other INVO webhook.
Errors
Errors carry {"error": "<message>", "code": "<CODE>"}.
| HTTP | Code | When | What to do |
|---|---|---|---|
| 400 | INVALID_INPUT | player_email missing, refund_unspent_coins not a boolean, or reference not a string of at most 255 characters. | Fix the body. |
| 401 | INVALID_GAME_SECRET | The X-Game-Secret-Key header is missing or wrong. | Check the key for this environment. |
| 404 | PLAYER_NOT_FOUND | No player with this email in your game (also for a player of another game). | Nothing to erase at INVO. Record it and carry on. |
| 404 | ERASURE_NOT_FOUND, REFUND_REQUEST_NOT_FOUND | Unknown id, or an id of another game. | Check the id. |
| 409 | ERASURE_BLOCKED | Something must stop first. The body's blockers list says what: ACTIVE_SUBSCRIPTIONS (the player has running subscriptions, with their count in subscriptions) or CHECK_UNAVAILABLE (INVO could not confirm nothing is running). | Cancel the player's subscriptions (see managing subscriptions), then call again. For CHECK_UNAVAILABLE, call again shortly. |
| 409 | NOTHING_TO_REFUND | Refund request for a player who holds no coins in your game. | Nothing to refund. |
| 429 | Too many requests. | Back off and retry. | |
| 500 | REFUND_REQUEST_FAILED | The refund request could not be filed. | Call again; a repeat returns the open request if the first one was filed. |
| 503 | ERASURE_FAILED, ERASURE_UNAVAILABLE, FEATURE_UNAVAILABLE | The erasure could not run, erasure is temporarily unavailable, or the feature is not available yet. Nothing was changed. | Call again later. |
{
"error": "This player cannot be erased yet. 1 subscription(s) of this player are still running. Cancel them first.",
"code": "ERASURE_BLOCKED",
"blockers": [
{
"code": "ACTIVE_SUBSCRIPTIONS",
"message": "1 subscription(s) of this player are still running. Cancel them first.",
"subscriptions": 1
}
]
}With the SDKs
The server entry points of both SDKs wrap these four calls. They hold your game secret, so use them only on your server. The browser SDK has no erasure calls.
import { InvoServer, InvoError } from "@invonetwork/web-sdk/server";
const invo = new InvoServer({ gameSecret: process.env.INVO_GAME_SECRET! });
try {
const erasure = await invo.erasePlayer({
playerEmail: "fan@example.com",
refundUnspentCoins: true,
reference: "account-8812",
});
// erasure.erasureId, erasure.refundRequestId, erasure.balancesRetained
} catch (err) {
if (err instanceof InvoError && err.isErasureBlocked) {
// err.erasureBlockers: cancel the player's subscriptions, then call again
} else if (err instanceof InvoError && err.isPlayerNotFound) {
// nothing to erase at INVO
} else {
throw err;
}
}
const request = await invo.getRefundRequest("prr_81c0a7e3d2f9");import os
from invonetwork import InvoServer, InvoError
invo = InvoServer(game_secret=os.environ["INVO_GAME_SECRET"])
try:
erasure = invo.erase_player(
player_email="fan@example.com",
refund_unspent_coins=True,
reference="account-8812",
)
except InvoError as err:
if err.is_erasure_blocked:
... # err.erasure_blockers: cancel subscriptions, then call again
elif err.is_player_not_found:
... # nothing to erase at INVO
else:
raise
request = invo.get_refund_request("prr_81c0a7e3d2f9")Also getErasure / get_erasure and requestPlayerRefund / request_player_refund. See the Web SDK and Python SDK pages for installation.
Checklist: account deletion in your app
App stores require an app that lets people create an account to also let them delete it from inside the app. A typical flow with INVO:
- Offer "Delete account" where people can find it in the app, not only through support.
- Tell the player what happens: their account and personal data are deleted, and some payment and tax records are kept for the period the law requires, sealed and used for nothing else.
- If the player still holds coins, tell them unspent coins bought by card will be refunded to that card, and that spent coins are not refunded.
- Cancel any running subscriptions for the player.
- Run your own grace period if you offer one. INVO has none: an erasure is final.
- Call
POST /api/sdk/players/erasurewith yourreference, and withrefund_unspent_coins: trueif the player holds coins. Store theerasure_id. - Delete the player's data in your own systems.
- Subscribe to
player.erasure_completedandplayer.refund_completedby name, and confirm the deletion (and later the refund) to the player through your own channel.
Common mistakes
- • Calling at the start of your grace period. INVO erases at once. Call when your grace period ends.
- • Subscribing with
*only. The two player events are opt-in by name and never arrive through*. - • Treating
200as an error. It means the player was already erased. - • Treating
partially_completedas final. INVO retries the open orders; wait for a laterplayer.refund_completed. - • Promising a refund of every coin. Only unspent coins bought by card through INVO go back to the card.
- • Calling from a client app. These calls use your game secret and belong on your server.