Create a project
Create a new project.
/projects
Parameters
| Name | Description |
|---|---|
| body * |
Cloud Wallet is an API that cover asset management and asset accounting at scale. We encourage you to integrate our APIs to your existing product or build a new one.
Authenticate your calls with a token that can be obtained from RapidApi.
Our API expects that you already have your customer database integrated with your app or service. There is no need to copy all the information about your customers into our system. All we need is a unique ID for your customer that matches the information listed in your database. You may supply additional information, such as the customer’s name or a description, but that is only for your convenience.
Please ensure that if you send us customer's personal information, you have obtained a permission.
Note on consistency guarantees. Due to the distributed nature of our platform, some parts of it are following the eventual consistency model. Transactions themselves internally are running with a strict consistency model, so there is no need to worry about the issues like double-spends or lost transfers. However, you may experience short (1-3 seconds) delays between the successful transaction call and seeing the result in List Transactions call.
A *project* is the first entity you create. Projects store customer records and wallets that are linked to one application or focus on one idea. *Transactions are available only for wallets within one project.*
Create a new project.
/projects
| Name | Description |
|---|---|
| body * |
Obtain a name and a list of assets for a project.
/projects/{projectId}
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
Obtain a list of your projects.
/projects
Updates the name of a project.
/projects/{projectId}/name
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
| Name | Description |
|---|---|
| body |
An *asset* can be anything of value owned by someone, such as virtual or real currencies, bonus points, or metro rides. Inventory items like water bottles, bags of coffee beans, or packets of sugar can also be assets. Asset amounts are stored in wallets.
Create a new asset type.
/projects/{projectId}/assets
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
| Name | Description |
|---|---|
| body * |
Deletes an unused asset type. Used assets cannot be removed. Asset types are marked as used when the first wallet using this asset is created.
/projects/{projectId}/assets/{assetId}
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
| assetId* |
String
Asset ID
Required
|
Obtain a list of assets for a project.
/projects/{projectId}/assets
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
Obtain the details of an asset with provided id.
/projects/{projectId}/assets/{assetId}
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
| assetId* |
String
Asset ID
Required
|
Update asset's name.
/projects/{projectId}/assets/{assetId}/name
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
| assetId* |
String
Asset ID
Required
|
| Name | Description |
|---|---|
| body * |
A *customer* is a record that reflects your existing users and enables you to create wallets for them. Basically, customers own wallets. You decide how you map customers into your system. People, devices, vehicles, or appliances that contain value can act as customers. We respect your users' privacy and only ask you to provide an ID that you can later identify and map back to the user in your system.
Creates a new customer record or updates existing record if a customer with provided id already exists.
/projects/{projectId}/customers
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
| Name | Description |
|---|---|
| body * |
Call this endpoint to obtain a record for a customer with provided ID.
/projects/{projectId}/customers/{customerId}
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
| customerId* |
String
Customer ID
Required
|
Retrieve a list of your customers with pagination. Specify current page and page size as query parameters.
/projects/{projectId}/customers
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
| Name | Description |
|---|---|
| page* |
Integer
(int32)
Page number query parameter
Required
|
| pageSize |
Integer
(int32)
Page size query parameter
|
Call this endpoint to create or update a record for a customer with provided customer ID.
/projects/{projectId}/customers/{customerId}
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
| customerId* |
String
Customer ID
Required
|
| Name | Description |
|---|---|
| body |
Suspend customer and all their wallets.
/projects/{projectId}/customers/{customerId}/suspend
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
| customerId* |
String
Customer ID
Required
|
Unsuspend a customer. Please note that customer's wallets will not be reactivated. You must reactivate wallets either via separate calls or by providing wallet IDs in the request body.
/projects/{projectId}/customers/{customerId}/resume
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
| customerId* |
String
Customer ID
Required
|
| Name | Description |
|---|---|
| body * |
Call this endpoint to delete a customer record. All wallets belonging to this customer must be closed before this call. **Deleted data cannot be restored. Closed wallets will not be deleted.**
/projects/{projectId}/customers/{customerId}
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
| customerId* |
String
Customer ID
Required
|
A *wallet* stores value, as well as the user’s balance history. Each wallet belongs either to a customer or to you (then it is called a *system wallet*). Assign as many wallets to your users or devices as you’d like. The wallet balance can’t dip below zero. A *wallet entry* is a record in a wallet ledger about an event. There are several types of events: - *Issue* records the effect of an issue operation - *Redeem* records redeem operations - *Debit* is posted to the wallet that is on the debit side of a transfer - *Credit* will appear on the credit side of the transfer
Create a wallet for a customer with a provided customer ID. Make a call to receive the opened wallet details.
/projects/{projectId}/wallets
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
| Name | Description |
|---|---|
| body * |
Open a new system wallet for the current project. System wallets belong to you, not to your customers. They are linked to a project and usually are created to collect commissions or accept fees, among other reasons.
/projects/{projectId}/system-wallets
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
| Name | Description |
|---|---|
| body * |
Obtain wallet balance and details.
/projects/{projectId}/wallets/{walletId}
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
| walletId* |
String
Wallet ID
Required
|
List customer's wallets
/projects/{projectId}/customers/{customerId}/wallets
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
| customerId* |
String
Customer ID
Required
|
Obtain a list of system wallets for this project.
/projects/{projectId}/system-wallets
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
Updates wallet name.
/projects/{projectId}/wallets/{walletId}/name
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
| walletId* |
String
Wallet ID
Required
|
| Name | Description |
|---|---|
| body * |
Updates wallet description.
/projects/{projectId}/wallets/{walletId}/description
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
| walletId* |
String
Wallet ID
Required
|
| Name | Description |
|---|---|
| body * |
Every wallet is created as Open. Then it is possible to change the status (mode) to one of the following: - *Open* wallets can hold a balance and participate in transactions. May switch to Suspended or Closed. - *Suspended* wallets keep holding their balance, but you’re unable to perform transactions with them. May change back to Active or to Closed. - *Closed* permanently stop transactions with a wallet. Only empty wallets can be closed, and you can't reopen wallets once you’ve closed them.
/projects/{projectId}/wallets/{walletId}/status
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
| walletId* |
String
Wallet ID
Required
|
| Name | Description |
|---|---|
| body * |
Obtain a pageable list of operations that were posted to a wallet within a specified time period.
/projects/{projectId}/wallets/{walletId}/entries
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
| walletId* |
String
Wallet ID
Required
|
| Name | Description |
|---|---|
| page* |
Integer
(int32)
Page number query parameter
Required
|
| pageSize |
Integer
(int32)
Page size query parameter
|
| from* |
Long
(int64)
Date from
Required
|
| to* |
Long
(int64)
Date to
Required
|
A transaction is a set of operations (one or more) that must be performed together. When a transaction is performed, operations are performed in the order in which they’re listed. An operation is a basic atomic action which updates one or two wallet balances. Each operation posts an entry to the ledger of each wallet it affects. An operation can be performed only within a transaction. There are three types of operations: - A *Transfer* moves some value from one wallet to another within the same project. - An *Issue* operation increases a user’s wallet balance by creating value. - *Redeem* decreases one wallet's balance by eliminating some amount of value. When all the operations in a set can be performed successfully, the whole transaction will be completed. If any single operation fails, all the other operations will be reverted back and the transaction will fail.
This call initiates a new transaction. A transaction is a set of operations (one or more) that must be performed together. When a transaction is performed, operations are applied in the order in which they’re listed. When all the operations in a set can be performed successfully, the whole transaction will be completed. If any single operation fails, all the other operations will be reverted back and the transaction will fail.
/projects/{projectId}/transactions
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
| Name | Description |
|---|---|
| body * |
Call this endpoint to obtain a transaction's current state.
/projects/{projectId}/transactions/{txId}
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
| txId* |
String
Transaction ID
Required
|
Retrieve a pageable list of transactions for a time period.
/projects/{projectId}/transactions
| Name | Description |
|---|---|
| projectId* |
String
Project ID
Required
|
| Name | Description |
|---|---|
| page* |
Integer
(int32)
Page number query parameter
Required
|
| pageSize |
Integer
(int32)
Page size query parameter
|
| from* |
Long
(int64)
Date from
Required
|
| to* |
Long
(int64)
Date to
Required
|