Manage virtual currency with API methods

Use the Metaframe API to manage a user’s virtual currency: retrieve balance information, top up the balance, and charge virtual currency from the user’s balance.

To work with the Metaframe API generate JWT.

To generate a token and work with API methods, use the data provided by the integration team:

Implement user balance management using the Metaframe API:

TaskMethod
Charges virtual currency from user’s balance using tokenCharges virtual currency from user’s balance
Charges virtual currency from user’s balance using Xsolla Wallet IDCharges virtual currency from user’s balance by Xsolla account ID
Get a list of virtual currency packagesGet package list
Create an orderCreate manual purchase
Retrieve balance information in multiple virtual currenciesGet multi virtual currencies balance
Top up the user’s balanceTop up user’s multicurrency balance
Note

In the API methods, shards are used to top up and deduct virtual currency from a user’s balance.

One unit of virtual currency is equivalent to 6 shards, so the amount of virtual currency needs to be multiplied by 6. For example, to top up the balance with 10 units of virtual currency, call the Top up user multicurrency balance method and specify 60 in the shards parameter.

Was this article helpful?
Thank you!
Is there anything we can improve? Message
We’re sorry to hear that
Please explain why this article wasn’t helpful to you. Message
Thank you for your feedback!
We’ll review your message and use it to help us improve your experience.
Last updated: October 10, 2024

Found a typo or other text error? Select the text and press Ctrl+Enter.

Report a problem
We always review our content. Your feedback helps us improve it.
Provide an email so we can follow up
Thank you for your feedback!