Create quote collection request
Payments Direct API (0.0.3)
Use the Payments Direct API to get quotes, create and manage payments, and manage originator and beneficiary identities.
The Payments Direct API offers the following environments:
Environment | Base URL | Description |
|---|---|---|
| UAT | https://api.test.ripple.com | UAT environment with simulated currency. |
| Production | https://api.ripple.com | Production environment |
All {{process.env.VAR_RPD}} 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 UAT 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-2/api-docs/payments-direct-api/payments-direct-2-api/
https://api.test.ripple.com/
https://api.ripple.com/
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 (v3)
Use these API operations to manage your identities with Identity Management v3 (recommended for all new integrations).
| Operation | Method | Description |
|---|---|---|
| Create an identity (v3) | POST | Create a new identity (INDIVIDUAL/BUSINESS; ORIGINATOR/BENEFICIARY). |
| Get a list of identies (v3) | GET | Retrieve a list of identities with optional filters (e.g., paymentRole, identityType). |
| Get an identity by ID (v3) | GET | Retrieve a specific identity by identityId (latest version by default). |
| Update an identity (v3) | PUT | Update one or more fields; creates a new version. |
| Deactivate an identity (v3) | DELETE | Set the identity state to DEACTIVATED (cannot be used for new payments). |
| Add a financial instrument (v3) | POST | Add a financial instrument to an identity. |
| Get a list of financial instruments (v3) | GET | Get a list of financial instruments for an identity. |
| Get a financial instrument by ID (v3) | GET | Get a specific financial instrument by financialInstrumentId. |
| Update a financial instrument (v3) | PUT | Update a financial instrument by financialInstrumentId. |
| Deactivate a financial instrument (v3) | DELETE | Deactivate a financial instrument by financialInstrumentId. |
Identities (v2) — Legacy
Use these API operations to manage your identities for existing integrations built on Identity Management v2.
Versioning notes
- v2 identities remain fully supported for ongoing operations.
- New integrations should use v3.
| Operation | Method | Description |
|---|---|---|
| Create a new identity (v2) - Legacy | POST | Create a new v2 legacy identity. |
| Get a list of identities (v2) - Legacy | GET | Get a list of existing v2 legacy identities. |
| Get an identity by ID (v2) - Legacy | GET | Get a v2 legacy identity by its unique ID. |
| Delete an identity (v2) - Legacy | DELETE | Deactivate a v2 legacy identity. |
Quotes
Use these API operations to manage your quotes.
| Operation | Method | Description |
|---|---|---|
| Create quote collection | POST | Create a collection of quotes. |
| Get quote collection | GET | Get a quote collection by ID. |
| Get a quote | GET | Get a specific quote by ID. |
The amount for which you wish to receive a collection of quotes.
The type of amount for which you want to get a quote.
| Enum Value | Description |
|---|---|
| SOURCE_AMOUNT | Specify this value to get a quote for the amount that you want to send. |
| DESTINATION_AMOUNT | Specify this value to get a quote for the amount that the beneficiary should receive. |
The currency code of the currency that you are sending.
The currency code of the currency in which your beneficiary will receive this payment.
The country code of the country from where you are sending the funds. This is an ISO 3166-1 alpha-2 code.
The country where the beneficiary is located specified in Alpha-2 Code format as defined in the ISO CountryCode ISO 3166-1 list. If the beneficiary is an individual, then this value is their country of residence. If the beneficiary is an institution, then this value is their the country of incorporation.
The name of the payout category.
| Enum Value | Description |
|---|---|
| BANK | Indicates that the payout will be made in fiat currency to a recipient’s bank account through local banking rails. |
| CRYPTO | Indicates that the payout will be made in stablecoin to a recipient’s crypto wallet address. |
The name of the pay in category indicating how this payment will be funded.
| Enum Value | Description |
|---|---|
| FUNDED | Indicates that the payment is being made from funds you've deposited with Ripple. |
| T_PLUS_ONE | Indicates the payment is being made and you will pay the outstanding invoice. |
- Mock server
https://docs.ripple.com/_mock/products/payments-direct-2/api-docs/payments-direct-api/payments-direct-2-api/v2/quotes/quote-collection
- UAT environment with simulated currency
https://api.test.ripple.com/v2/quotes/quote-collection
- Production environment
https://api.ripple.com/v2/quotes/quote-collection
- curl
- Python
curl -i -X POST \
https://docs.ripple.com/_mock/products/payments-direct-2/api-docs/payments-direct-api/payments-direct-2-api/v2/quotes/quote-collection \
-H 'Authorization: Bearer <YOUR_JWT_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"quoteAmount": 123.45,
"quoteAmountType": "SOURCE_AMOUNT",
"sourceCurrency": "USD",
"destinationCurrency": "MXN",
"sourceCountry": "US",
"destinationCountry": "PH",
"payoutCategory": "BANK",
"payinCategory": "FUNDED",
"destinationBlockchainNetwork": "Ethereum"
}'Creates a collection of quotes
Unique ID that represents this quote collection.
List of quotes
Unique ID that represents this quote.
| Enum Value | Description |
|---|---|
| EXPIRED | Expired quote |
| ACTIVE | Quote that you can accept to create a payment. |
The type of amount for which you want to get a quote.
| Enum Value | Description |
|---|---|
| SOURCE_AMOUNT | Specify this value to get a quote for the amount that you want to send. |
| DESTINATION_AMOUNT | Specify this value to get a quote for the amount that the beneficiary should receive. |
Amount to be received by destination
The currency code of the currency that you are sending.
The currency code of the currency in which your beneficiary will receive this payment.
The country where the payment originator is located or incorporated, specified in Alpha-2 Code format as defined in the ISO CountryCode ISO 3166-1 list.
The country code to which you wish to send the funds. It follows ISO 3166-1 alpha-2 code
Name of the payout category specified in the quote request.
The name of payin category specified in the quote request.
Foreign Exchange (FX) rate used to calculate the quote.
A summary of fees included in this quote.
An array of fees that provides a breakdown of how the total fees is calculated for this quote.
Value of the fee when the configured fee unit is applied against the value.
A summary of taxes included in this quote.
An array of taxes with details such as tax description, rate, name and tax amount.
GST service fee tax .
The time when this quote was created, specified in UTC.
The time when this quote expires, specified in UTC.
{ "quoteCollectionId": "11111111-aaaa-2222-bbbb-222222222222", "quotes": [ { … } ] }
- Mock server
https://docs.ripple.com/_mock/products/payments-direct-2/api-docs/payments-direct-api/payments-direct-2-api/v2/quotes/quote-collection/{quote-collection-id}
- UAT environment with simulated currency
https://api.test.ripple.com/v2/quotes/quote-collection/{quote-collection-id}
- Production environment
https://api.ripple.com/v2/quotes/quote-collection/{quote-collection-id}
- curl
- Python
curl -i -X GET \
https://docs.ripple.com/_mock/products/payments-direct-2/api-docs/payments-direct-api/payments-direct-2-api/v2/quotes/quote-collection/11111111-aaaa-2222-bbbb-222222222222 \
-H 'Authorization: Bearer <YOUR_JWT_HERE>'Valid quote collection found
Unique ID that represents this quote collection.
List of quotes
Unique ID that represents this quote.
| Enum Value | Description |
|---|---|
| EXPIRED | Expired quote |
| ACTIVE | Quote that you can accept to create a payment. |
The type of amount for which you want to get a quote.
| Enum Value | Description |
|---|---|
| SOURCE_AMOUNT | Specify this value to get a quote for the amount that you want to send. |
| DESTINATION_AMOUNT | Specify this value to get a quote for the amount that the beneficiary should receive. |
Amount to be received by destination
The currency code of the currency that you are sending.
The currency code of the currency in which your beneficiary will receive this payment.
The country where the payment originator is located or incorporated, specified in Alpha-2 Code format as defined in the ISO CountryCode ISO 3166-1 list.
The country code to which you wish to send the funds. It follows ISO 3166-1 alpha-2 code
Name of the payout category specified in the quote request.
The name of payin category specified in the quote request.
Foreign Exchange (FX) rate used to calculate the quote.
A summary of fees included in this quote.
An array of fees that provides a breakdown of how the total fees is calculated for this quote.
Value of the fee when the configured fee unit is applied against the value.
A summary of taxes included in this quote.
An array of taxes with details such as tax description, rate, name and tax amount.
GST service fee tax .
The time when this quote was created, specified in UTC.
The time when this quote expires, specified in UTC.
{ "quoteCollectionId": "11111111-aaaa-2222-bbbb-222222222222", "quotes": [ { … } ] }
- Mock server
https://docs.ripple.com/_mock/products/payments-direct-2/api-docs/payments-direct-api/payments-direct-2-api/v2/quotes/{quote-id}
- UAT environment with simulated currency
https://api.test.ripple.com/v2/quotes/{quote-id}
- Production environment
https://api.ripple.com/v2/quotes/{quote-id}
- curl
- Python
curl -i -X GET \
https://docs.ripple.com/_mock/products/payments-direct-2/api-docs/payments-direct-api/payments-direct-2-api/v2/quotes/22222222-aaaa-2222-bbbb-222222222222 \
-H 'Authorization: Bearer <YOUR_JWT_HERE>'Valid quote found
Unique ID that represents this quote.
| Enum Value | Description |
|---|---|
| EXPIRED | Expired quote |
| ACTIVE | Quote that you can accept to create a payment. |
The type of amount for which you want to get a quote.
| Enum Value | Description |
|---|---|
| SOURCE_AMOUNT | Specify this value to get a quote for the amount that you want to send. |
| DESTINATION_AMOUNT | Specify this value to get a quote for the amount that the beneficiary should receive. |
Amount to be received by destination
The currency code of the currency that you are sending.
The currency code of the currency in which your beneficiary will receive this payment.
The country where the payment originator is located or incorporated, specified in Alpha-2 Code format as defined in the ISO CountryCode ISO 3166-1 list.
The country code to which you wish to send the funds. It follows ISO 3166-1 alpha-2 code
Name of the payout category specified in the quote request.
The name of payin category specified in the quote request.
Foreign Exchange (FX) rate used to calculate the quote.
A summary of fees included in this quote.
An array of fees that provides a breakdown of how the total fees is calculated for this quote.
Value of the fee when the configured fee unit is applied against the value.
A summary of taxes included in this quote.
An array of taxes with details such as tax description, rate, name and tax amount.
GST service fee tax .
The time when this quote was created, specified in UTC.
The time when this quote expires, specified in UTC.
{ "quoteId": "7ea3399c-1234-5678-8d8f-d320ea406630", "quoteStatus": "ACTIVE", "quoteAmountType": "SOURCE_AMOUNT", "sourceAmount": 123.45, "destinationAmount": 2438.19, "sourceCurrency": "USD", "destinationCurrency": "MXN", "sourceCountry": "US", "destinationCountry": "MX", "payoutCategory": "BANK", "payinCategory": "FUNDED", "adjustedExchangeRate": { "adjustedRate": 2 }, "fees": [ { … } ], "taxes": [ { … } ], "createdAt": "2023-11-02T18:26:00.000123Z", "expiresAt": "2023-11-02T18:26:00.000123Z", "destinationBlockchainNetwork": "Ethereum" }
Payments (v3)
Use these API operations to manage your payments with Payment Management v3 (recommended for all new integrations).
| Operation | Method | Description |
|---|---|---|
| Search payments (v3) | POST | Search for v3 payments based on filtering criteria. |
| Create a payment (v3) | POST | Create a v3payment by accepting a quote. |
| Get payment by payment ID (v3) | GET | Get a specific v3 payment by payment ID. |
| Get state transitions by payment ID (v3) | GET | Get the state transitions for a specific v3 payment by payment ID. |
| Update payment labels (v3) | PATCH | Update the labels for a specific v3 payment by payment ID. |
Payments (v2) - Legacy
Use these API operations to manage your v2 legacy payments.
| Operation | Method | Description |
|---|---|---|
| Search payments (v2) - Legacy) | POST | Search for legacy v2 payments based on filtering criteria. |
| Create a payment (v2) - Legacy) | POST | Create a legacy v2 payment by accepting a quote. |
| Get a payment by payment ID (v2) - Legacy | GET | Get a specific legacy v2 payment by payment ID. |
| Get state transitions by payment ID (v2) - Legacy | GET | Get the state transitions for a specific legacy v2 payment by payment ID. |
| Update payment labels (v2) - Legacy | PATCH | Update the labels for a specific legacy v2 payment by payment ID. |
Ledger
Use these API operation to fetch ledger transactions and check balances.
| Operation | Method | Description |
|---|---|---|
| Get balances | GET | View your existing balances |
| Get ledger transactions | GET | View your ledger transactions. |