Xfers Intents API
**For user case 1:**When a user is performing a top-up via [GET /transfer_info](http://docs.xfers.io/#get-transfer-info), they might forget to enter their contact number which is needed for our system to identify them.The Intents API solves this issue by requiring the user to transfer a unique amount to Xfers which will be used to identify them. The difference between the `unique_amount` and the actual `amount` will be very small, and Xfers provides the difference for free to the user.Note that this only acts as a backup, and the user should enter his contact number in the comments section when doing a bank transfer whenever possible.Example: Jane wishes to transfer 5000 Indonesian Rupiah via `/intents`.1. She makes a HTTP GET request to `/user/transfer_info` to get the correct Xfers bank to transfer to (we have many banks!). The response tells her to transfer to Bank Central Asia (BCA).2. She makes a HTTP POST request to create an intent. The response tells her to make a bank transfer of 4999 to Xfers.3. Jane makes a transfer of 4999 to Xfers BCA. Within a few minutes, Xfers detects the transfer and tops up Jane’s Xfers account with 5000. Xfers absorbs the difference for free.4. If `notify_url` is given, Xfers will send a callback to this url.Note the above scenario is only valid when disable_va is set to True**For user case 2:**Intent can also be use a means to get callback notifications from Xfers when a user successfully fund their virtual account on Xfers.Example: Jane wishes to transfer 5000 Indonesian Rupiah via `/intents` to her virtual Xfers account and get a callback notification when it successful1. She makes a HTTP POST request to create an intent with disable_va set to false(default) and provide a `notify_url`. The response will provide a list of virtual account nos she can fund her account with from a list of bank that Xfers support.2. Jane makes a transfer of 500 to the Xfers BCA Virtual account that the intent api provide. Within a few minutes, Xfers detects the transfer and tops up Jane’s Xfers account with 5000.3. Since `notify_url` is provided, Xfers will send a callback to this url.
Xfers Intents API is one of 20 APIs that Xfers publishes on the APIs.io network, described by a machine-readable OpenAPI specification.
Tagged areas include Intents. The published artifact set on APIs.io includes an OpenAPI specification and API documentation.
This API exposes 4 operations across 3 paths, and defines 1 schema. It is described by OpenAPI 3.0.0, at version 3.
Requests are made against 2 base URLs: https://id.xfers.com/api, https://sandbox-id.xfers.com/api.
Metadata
The identity and technical contract details declared by the specification.
Authentication & Security 1
Xfers Intents API declares
1 security scheme
for authenticating requests.
An API key is passed in the header as X-XFERS-USER-API-KEY (X-XFERS-USER-API-KEY).
X-XFERS-USER-API-KEY— You can retrieve this by using [gettoken API](../sg/api/cutting-edgeoperation/getToken)
Paths & Operations 4
Across 3 paths, the API surfaces 4 operations — 1 GET, 3 POST. Each is listed below with its method, path, parameters, and response codes.
For user case 1: When a user is performing a top-up via [GET /transferinfo](http://docs.xfers.io/get-transfer-info), they might forget to enter their contact number which is neede…
Schemas 1
The contract defines 1 schema that model the data the API accepts and returns. The most detailed is error_response (3 properties). Each schema is shown below with its type and property counts.
Specification
The full machine-readable OpenAPI contract behind this narrative.
Source
More from Xfers 12
Other APIs Xfers publishes across the network.