Create virtual currency transaction
Credits or debits one or more virtual currencies for a profile in a single atomic transaction. Use a positive amount to credit (grant) and a negative amount to debit (spend). All items are applied together — if any item fails, none are applied.
Each currency code may appear only once per request. A credit through this endpoint always creates a non-expiring balance.
Headers
The unique ID of the customer in your system. Either adapty-customer-user-id or adapty-profile-id is required.
The unique ID of the profile in your system. Your best option if you are working with anonymous profiles. Either adapty-customer-user-id or adapty-profile-id is required.
A UUID v4 that makes the request idempotent. If you retry a request with the same key, Adapty returns the result of the original transaction without changing balances again. Must be a valid UUID v4.
Keys are remembered for up to an hour, scoped to a single profile. After that window, a request with the same key is applied as a new transaction — so use the key to retry a call safely, not to deduplicate a grant over the long term.
Request body
Response
Transaction applied successfully