Use the Ripple Payments Direct 1.0 API to get quotes, create and manage payments, and manage originator and beneficiary identities.
Payments Direct 1.0 API ( )
The Ripple Payments Direct 1.0 API offers the following environments:
| <div style="width:90px">Environment</div> | Base URL |
|---|---|
| Test | https://{customer-name}.test.rnc.ripplenet.com/v4 |
| Production | https://{customer-name}.rnc.ripplenet.com/v4 |
The base URL for the Ripple Payments Direct 1.0 API follows the {domainprefix}.{domain} pattern. For the test environment, the {domainprefix} is {customername}.test. For the production environment, the {domainprefix} is {customername}.
Note: The following examples use aperture as the customer name, your customer name will be different.
This is the URL format for the Ripple Payments Direct 1.0 API.
https://{domainprefix}.{domain}/v4
This is an example base URL for the Ripple Payments Direct 1.0 API.
https://aperture.test.rnc.ripplenet.com/v4/{path}?{parameters}
This connects to the test environment and requests a list of payments with 100 results per page.
https://aperture.test.rnc.ripplenet.com/v4/payments?page=0&size=100
| Environment | <div style="width:120px;">Domain Prefix</div> | Domain | Base URL |
|---|---|---|---|
| Test | aperture.test.rnc | ripplenet.com | https://aperture.test.rnc.ripplenet.com/v4 |
| Production | aperture.rnc | ripplenet.com | https://aperture.rnc.ripplenet.com/v4 |
All Ripple Payments Direct 1.0 API operations require a Bearer access token specific to the environment you're using. Ripple provides a secure model for authentication and authorization by providing access tokens scoped for a set of credentials.
You will need your client ID and client secret to obtain an access token.
If you do not already have your client ID and client secret, do the following:
- Log into the Ripple Payments UI.
- In the left navigation menu, click Settings.
- Under Administration, click API Credentials.
- In the dropdown list next to the page title, select the access environment. For example, to provision credentials for the test environment, select Test from the dropdown list.
- In the upper right corner of the page, click New Credential.
- Click Save and Generate Key.
Caution: The client secret is displayed only once when you are creating new credentials. You cannot retrieve the secret after exiting this page. Copy and store the client secret securely and share it with authorized individuals in accordance with your organization's security policy.
You can now use the client ID and client secret to generate access tokens using the Request an access token operation.
To get an access token, use the Request an access token operation with your client_id and client_secret. The response contains a token in the access_token field.
We recommend rotating your API credentials at regular intervals according to your organization's security policy.
Note: Authentication tokens are not a fixed length and can vary, avoid validating tokens based on character length.
https://docs.ripple.com/_mock/products/payments-direct/api-docs/payments-direct-swagger/reference/payments-direct-swagger-external/
https://{{customer-name}}.test.rnc.ripplenet.com/v4/
https://{{customer-name}}.rnc.ripplenet.com/v4/
Authentication
Use these API operations to manage your authentication tokens.
| Operation | Method | Description |
|---|---|---|
| Request an access token | POST | Request an access token for authentication with Ripple APIs. |
| Test access token | GET | Test if an access token can be used for authentication. |
Identities
Use these API operations to manage your identities.
| Operation | Method | Description |
|---|---|---|
| List identities | GET | Get a list of existing identities. |
| Create an identity | POST | Create a new identity. |
| Get an identity by ID | GET | Get an identity by its unique ID. |
| Delete an identity | DELETE | Delete an identity. |
Payments
Use these API operations to manage your payments.
| Operation | Method | Description |
|---|---|---|
| Get payments | GET | Get a list of existing payments. |
| Get payment by payment ID | GET | Get a specific payment by payment ID. |
Quotes
Use these API operations to manage your quotes.
| Operation | Method | Description |
|---|---|---|
| Accept quote | POST | Accepts a quote ID to start the payment process. |
| Create quote collection | POST | Create a collection of quotes. |
Routing
Use this API operation to look up a payout method.
| Operation | Method | Description |
|---|---|---|
| Get payout method | GET | Look up a payout method. |
Data requirements
Use this API operation to get the data required for making a payout using a specific currency.
| Operation | Method | Description |
|---|---|---|
| Get data requirements | GET | Retrieve data requirements. |
Balances
Use this API operation to get your account balance information.
| Operation | Method | Description |
|---|---|---|
| Get spendable balance | GET | Retrieve account balances. |
Request
Retrieves your spendable balance.
Note: The response contains either the funded_balance or the credit_usage object depending on your funding method. <br/><br/> If you're using the Funded Payments method, the response contains only the funded_balance object. If you're using the T+1 Invoicing method, the response contains only the credit_usage object.
- Mock server
https://docs.ripple.com/_mock/products/payments-direct/api-docs/payments-direct-swagger/reference/payments-direct-swagger-external/spendable_balance
- Development environment
https://{{customer-name}}.test.rnc.ripplenet.com/v4/spendable_balance
- Production environment
https://{{customer-name}}.rnc.ripplenet.com/v4/spendable_balance
- curl
- Python
- JavaScript
curl -i -X GET \
https://docs.ripple.com/_mock/products/payments-direct/api-docs/payments-direct-swagger/reference/payments-direct-swagger-external/spendable_balance \
-H 'Authorization: Bearer <YOUR_JWT_HERE>'Successfully returned spendable balance information.
Array of spendable balance information for all applicable currencies.
Information about your credit limit and use.
Information about your net balance.
The amount for which Ripple has invoiced you but hasn't received payment yet. Note that this amount may be in a different currency from your statement_currency.
The amount of credit you've used since the last invoice was issued, shown in USD.
The total credit you've used, which is the sum of your net_balance and unbilled_used_credit shown in USD.
Your spendable credit amount, calculated as difference of your credit limit and current credit consumption shown in USD.