List Payments
Retrieve a list of all payments that you have created.
You can filter the list with query parameters.
created_after
The ID of the payment created before the first payment you want to retrieve. String starting with payment_..
created_before
The ID of the payment created after the last payment you want to retrieve. String starting with payment_..
customer
Filters the list for payments related to the specified customer.
destination_card
Filters the list for payments related to the specified destination card.
ending_before
The ID of the payment created after the last payment you want to retrieve. String starting with payment_. Deprecated.
ewallet
Filters the list for payments related to the specified wallet.
group
Indicates whether the response includes group payments.
true - Includes only group payments in the response.
false - Excludes group payments from the response.
false
invoice
Filters the list for payments related to the specified invoice.
order
Filters the list for payments related to the specified order.
payment_method
Filters the list for payments related to the specified payment method.
starting_after
The ID of the payment created before the first payment you want to retrieve. String starting with payment_. Deprecated.
subscription
Filters the list for payments related to the specified subscription.
Code Samples
.NET
using System; namespace RapydApiRequestSample { class Program { static void Main(string[] args) { try { int limit = 2; string result = RapydApiRequestSample.Utilities.MakeRequest("GET", $"/v1/payments?limit={limit}"); Console.WriteLine(result); } catch (Exception e) { Console.WriteLine("Error completing request: " + e.Message); } } } }
JavaScript
const makeRequest = require('<path-to-your-utility-file>/utilities').makeRequest; async function main() { try { const result = await makeRequest( 'GET', '/v1/payments?limit=2' ); console.log(result); } catch (error) { console.error('Error completing request', error); } }
PHP
<?php $path = $_SERVER['DOCUMENT_ROOT']; $path .= "/<path-to-your-utility-file>/utilities.php"; include($path); try { $object = make_request('get', '/v1/payments?limit=2'); var_dump($object); } catch(Exception $e) { echo "Error: $e"; } ?>
Python
from pprint import pprint from utilities import make_request response = make_request(method='get', path=f'/v1/payments?limit=2')
/v1/payments
List Payments
curl -X get https://sandboxapi.rapyd.net/v1/payments?limit=2 -H 'access_key: your-access-key-here' -H 'Content-Type: application/json' -H 'salt: your-random-string-here' -H 'signature: your-calculated-signature-here' -H 'timestamp: your-unix-timestamp-here'
{ "status": { "error_code": "", "status": "SUCCESS", "message": "", "response_code": "", "operation_id": "d570fe15-f19a-46ce-a2ec-309b7a797cf4" }, "data": [ { "id": "payment_cc8c029e086acbd6d34eb0eb696c9804", "amount": 279, "original_amount": 279, "is_partial": false, "currency_code": "USD", "country_code": "US", "status": "CLO", "description": "", "merchant_reference_id": "", "customer_token": "cus_91be5f1b0f2dbb70c1d0509a1ae2351e", "payment_method": "card_8cc9838d5d1bf3b3843cd1b8aa585e19", "payment_method_data": { "id": "card_8cc9838d5d1bf3b3843cd1b8aa585e19", "type": "us_mastercard_card", "category": "card", "metadata": null, "image": "", "authentication_url": "", "webhook_url": "", "supporting_documentation": "", "name": "John Doe", "last4": "0414", "acs_check": "unchecked", "cvv_check": "unchecked", "bin_details": { "brand": null, "bin_number": "554672" }, "expiration_year": "23", "expiration_month": "11", "fingerprint_token": "ocfp_5f5a0376b98d8238064a232cc51f6f4e" }, "expiration": 1622553335, "captured": false, "refunded": false, "refunded_amount": 0, "receipt_email": "", "redirect_url": "", "complete_payment_url": "", "error_payment_url": "", "receipt_number": "", "flow_type": "", "address": null, "statement_descriptor": "Rapyd", "transaction_id": "", "created_at": 1621948535, "metadata": { "merchant_defined": true }, "failure_code": "", "failure_message": "", "paid": true, "paid_at": 1621948562, "dispute": null, "refunds": null, "order": null, "outcome": null, "visual_codes": {}, "textual_codes": {}, "instructions": [], "ewallet_id": "ewallet_c67c44ec60d5c2e62480aa7c76b3f8b4", "ewallets": [ { "ewallet_id": "ewallet_c67c44ec60d5c2e62480aa7c76b3f8b4", "amount": 279, "percent": 100, "refunded_amount": 0 } ], "payment_method_options": {}, "payment_method_type": "us_mastercard_card", "payment_method_type_category": "card", "fx_rate": 1, "merchant_requested_currency": null, "merchant_requested_amount": null, "fixed_side": "", "payment_fees": null, "invoice": "", "escrow": null, "group_payment": "", "cancel_reason": null, "initiation_type": "customer_present", "mid": "", "next_action": "not_applicable" }, { "id": "payment_6cc10a51cbc9e84e49e3bc55350bbb8c", "amount": 12, "original_amount": 279, "is_partial": true, "currency_code": "USD", "country_code": "US", "status": "CLO", "description": "", "merchant_reference_id": "", "customer_token": "cus_482125ea7824229596380a2d3b50a7cd", "payment_method": "card_7aa04cdf8e165917c082779aff029785", "payment_method_data": { "id": "card_7aa04cdf8e165917c082779aff029785", "type": "us_mastercard_card", "category": "card", "metadata": null, "image": "", "authentication_url": "", "webhook_url": "", "supporting_documentation": "", "name": "John Doe", "last4": "0414", "acs_check": "unchecked", "cvv_check": "unchecked", "bin_details": { "brand": null, "bin_number": "554672" }, "expiration_year": "23", "expiration_month": "11", "fingerprint_token": "ocfp_5f5a0376b98d8238064a232cc51f6f4e" }, "expiration": 1622549964, "captured": true, "refunded": false, "refunded_amount": 0, "receipt_email": "", "redirect_url": "", "complete_payment_url": "", "error_payment_url": "", "receipt_number": "", "flow_type": "", "address": null, "statement_descriptor": "Rapyd", "transaction_id": "", "created_at": 1621945164, "metadata": { "merchant_defined": true }, "failure_code": "", "failure_message": "", "paid": true, "paid_at": 1621945205, "dispute": null, "refunds": null, "order": null, "outcome": null, "visual_codes": {}, "textual_codes": {}, "instructions": [], "ewallet_id": "ewallet_c67c44ec60d5c2e62480aa7c76b3f8b4", "ewallets": [ { "ewallet_id": "ewallet_c67c44ec60d5c2e62480aa7c76b3f8b4", "amount": 279, "percent": 100, "refunded_amount": 0 } ], "payment_method_options": {}, "payment_method_type": "us_mastercard_card", "payment_method_type_category": "card", "fx_rate": 1, "merchant_requested_currency": null, "merchant_requested_amount": null, "fixed_side": "", "payment_fees": null, "invoice": "", "escrow": null, "group_payment": "", "cancel_reason": null, "initiation_type": "customer_present", "mid": "", "next_action": "not_applicable" } ] }
List Group Payments and Limit of Two
curl -X get https://sandboxapi.rapyd.net/v1/payments?group=true&limit=2 -H 'access_key: your-access-key-here' -H 'Content-Type: application/json' -H 'salt: your-random-string-here' -H 'signature: your-calculated-signature-here' -H 'timestamp: your-unix-timestamp-here'
{ "status": { "error_code": "", "status": "SUCCESS", "message": "", "response_code": "", "operation_id": "bb216c05-069f-45e7-b22d-25fb4e6e4b7a" }, "data": [ { "id": "payment_d272bf57ccb88741cf9732270516b526", "amount": 200, "original_amount": 200, "is_partial": false, "currency_code": "USD", "country_code": "fr", "status": "CLO", "description": "", "merchant_reference_id": "", "customer_token": "cus_3cd0d059b51936a0487634b456a8e9c3", "payment_method": "card_c60d4678a8bfbad42b495b3c3dcd0810", "payment_method_data": { "id": "card_c60d4678a8bfbad42b495b3c3dcd0810", "type": "fr_mastercard_card", "category": "card", "metadata": null, "image": "", "authentication_url": "", "webhook_url": "", "supporting_documentation": "", "name": "John Doe", "last4": "1111", "acs_check": "unchecked", "cvv_check": "unchecked", "bin_details": { "brand": null, "bin_number": "411111" }, "expiration_year": "23", "expiration_month": "11", "fingerprint_token": "ocfp_e599f990674473ce6283b245e9ad2467" }, "expiration": 1622554328, "captured": true, "refunded": false, "refunded_amount": 0, "receipt_email": "", "redirect_url": "", "complete_payment_url": "", "error_payment_url": "", "receipt_number": "", "flow_type": "", "address": null, "statement_descriptor": "Rapyd", "transaction_id": "", "created_at": 1621949528, "metadata": {}, "failure_code": "", "failure_message": "", "paid": true, "paid_at": 1621949528, "dispute": null, "refunds": null, "order": null, "outcome": null, "visual_codes": {}, "textual_codes": {}, "instructions": {}, "ewallet_id": "ewallet_c67c44ec60d5c2e62480aa7c76b3f8b4", "ewallets": [ { "ewallet_id": "ewallet_c67c44ec60d5c2e62480aa7c76b3f8b4", "amount": 200, "percent": 100, "refunded_amount": 0 } ], "payment_method_options": {}, "payment_method_type": "fr_mastercard_card", "payment_method_type_category": "card", "fx_rate": 1, "merchant_requested_currency": null, "merchant_requested_amount": null, "fixed_side": "", "payment_fees": null, "invoice": "", "escrow": null, "group_payment": "gp_119896e86cedd72e8bafbcf26968ea08", "cancel_reason": null, "initiation_type": "customer_present", "mid": "", "next_action": "not_applicable" }, { "id": "payment_5dbe58b16fd1f611f5de4015b7cf6bba", "amount": 50, "original_amount": 50, "is_partial": false, "currency_code": "USD", "country_code": "fr", "status": "CLO", "description": "", "merchant_reference_id": "", "customer_token": "cus_ab5b66edc938dbd09764eb4974247e41", "payment_method": "card_6d85d4898377ce80959584034fe91cc5", "payment_method_data": { "id": "card_6d85d4898377ce80959584034fe91cc5", "type": "fr_visa_card", "category": "card", "metadata": null, "image": "", "authentication_url": "", "webhook_url": "", "supporting_documentation": "", "name": "Jane Doe", "last4": "1111", "acs_check": "unchecked", "cvv_check": "unchecked", "bin_details": { "brand": null, "bin_number": "411111" }, "expiration_year": "23", "expiration_month": "11", "fingerprint_token": "ocfp_e599f990674473ce6283b245e9ad2467" }, "expiration": 1622554328, "captured": true, "refunded": false, "refunded_amount": 0, "receipt_email": "", "redirect_url": "", "complete_payment_url": "", "error_payment_url": "", "receipt_number": "", "flow_type": "", "address": null, "statement_descriptor": "Rapyd", "transaction_id": "", "created_at": 1621949528, "metadata": {}, "failure_code": "", "failure_message": "", "paid": true, "paid_at": 1621949528, "dispute": null, "refunds": null, "order": null, "outcome": null, "visual_codes": {}, "textual_codes": {}, "instructions": {}, "ewallet_id": "ewallet_3801e782955b29955445586a2405a5db", "ewallets": [ { "ewallet_id": "ewallet_3801e782955b29955445586a2405a5db", "amount": 50, "percent": 100, "refunded_amount": 0 } ], "payment_method_options": {}, "payment_method_type": "fr_visa_card", "payment_method_type_category": "card", "fx_rate": 1, "merchant_requested_currency": null, "merchant_requested_amount": null, "fixed_side": "", "payment_fees": null, "invoice": "", "escrow": null, "group_payment": "gp_119896e86cedd72e8bafbcf26968ea08", "cancel_reason": null, "initiation_type": "customer_present", "mid": "", "next_action": "not_applicable" } ] }
List Payments by Wallet ID
curl -X get https://sandboxapi.rapyd.net/v1/payments?ewallet=ewallet_c67c44ec60d5c2e62480aa7c76b3f8b4 -H 'access_key: your-access-key-here' -H 'Content-Type: application/json' -H 'salt: your-random-string-here' -H 'signature: your-calculated-signature-here' -H 'timestamp: your-unix-timestamp-here'
{ "status": { "error_code": "", "status": "SUCCESS", "message": "", "response_code": "", "operation_id": "4d9bd095-9ca4-4b03-b26d-3e1044a7201d" }, "data": [ { "id": "payment_d272bf57ccb88741cf9732270516b526", "amount": 200, "original_amount": 200, "is_partial": false, "currency_code": "USD", "country_code": "fr", "status": "CLO", "description": "", "merchant_reference_id": "", "customer_token": "cus_3cd0d059b51936a0487634b456a8e9c3", "payment_method": "card_c60d4678a8bfbad42b495b3c3dcd0810", "payment_method_data": { "id": "card_c60d4678a8bfbad42b495b3c3dcd0810", "type": "fr_mastercard_card", "category": "card", "metadata": null, "image": "", "authentication_url": "", "webhook_url": "", "supporting_documentation": "", "name": "John Doe", "last4": "1111", "acs_check": "unchecked", "cvv_check": "unchecked", "bin_details": { "brand": null, "bin_number": "411111" }, "expiration_year": "23", "expiration_month": "11", "fingerprint_token": "ocfp_e599f990674473ce6283b245e9ad2467" }, "expiration": 1622554328, "captured": true, "refunded": false, "refunded_amount": 0, "receipt_email": "", "redirect_url": "", "complete_payment_url": "", "error_payment_url": "", "receipt_number": "", "flow_type": "", "address": null, "statement_descriptor": "Rapyd", "transaction_id": "", "created_at": 1621949528, "metadata": {}, "failure_code": "", "failure_message": "", "paid": true, "paid_at": 1621949528, "dispute": null, "refunds": null, "order": null, "outcome": null, "visual_codes": {}, "textual_codes": {}, "instructions": {}, "ewallet_id": "ewallet_c67c44ec60d5c2e62480aa7c76b3f8b4", "ewallets": [ { "ewallet_id": "ewallet_c67c44ec60d5c2e62480aa7c76b3f8b4", "amount": 200, "percent": 100, "refunded_amount": 0 } ], "payment_method_options": {}, "payment_method_type": "fr_mastercard_card", "payment_method_type_category": "card", "fx_rate": 1, "merchant_requested_currency": null, "merchant_requested_amount": null, "fixed_side": "", "payment_fees": null, "invoice": "", "escrow": null, "group_payment": "gp_119896e86cedd72e8bafbcf26968ea08", "cancel_reason": null, "initiation_type": "customer_present", "mid": "", "next_action": "not_applicable" }, { "id": "payment_cc8c029e086acbd6d34eb0eb696c9804", "amount": 279, "original_amount": 279, "is_partial": false, "currency_code": "USD", "country_code": "US", "status": "CLO", "description": "", "merchant_reference_id": "", "customer_token": "cus_91be5f1b0f2dbb70c1d0509a1ae2351e", "payment_method": "card_8cc9838d5d1bf3b3843cd1b8aa585e19", "payment_method_data": { "id": "card_8cc9838d5d1bf3b3843cd1b8aa585e19", "type": "us_mastercard_card", "category": "card", "metadata": null, "image": "", "authentication_url": "", "webhook_url": "", "supporting_documentation": "", "name": "John Doe", "last4": "0414", "acs_check": "unchecked", "cvv_check": "unchecked", "bin_details": { "brand": null, "bin_number": "554672" }, "expiration_year": "23", "expiration_month": "11", "fingerprint_token": "ocfp_5f5a0376b98d8238064a232cc51f6f4e" }, "expiration": 1622553335, "captured": false, "refunded": false, "refunded_amount": 0, "receipt_email": "", "redirect_url": "", "complete_payment_url": "", "error_payment_url": "", "receipt_number": "", "flow_type": "", "address": null, "statement_descriptor": "Rapyd", "transaction_id": "", "created_at": 1621948535, "metadata": { "merchant_defined": true }, "failure_code": "", "failure_message": "", "paid": true, "paid_at": 1621948562, "dispute": null, "refunds": null, "order": null, "outcome": null, "visual_codes": {}, "textual_codes": {}, "instructions": [], "ewallet_id": "ewallet_c67c44ec60d5c2e62480aa7c76b3f8b4", "ewallets": [ { "ewallet_id": "ewallet_c67c44ec60d5c2e62480aa7c76b3f8b4", "amount": 279, "percent": 100, "refunded_amount": 0 } ], "payment_method_options": {}, "payment_method_type": "us_mastercard_card", "payment_method_type_category": "card", "fx_rate": 1, "merchant_requested_currency": null, "merchant_requested_amount": null, "fixed_side": "", "payment_fees": null, "invoice": "", "escrow": null, "group_payment": "", "cancel_reason": null, "initiation_type": "customer_present", "mid": "", "next_action": "not_applicable" } ] }