Payment methods
List payment methods for a buyer
List all stored payment methods for a customer record.
To list all the vaulted payment methods for a buyer, call the
GET /buyers/payment-methods
API with the buyer_id
and/or
buyer_external_identifier
as a query parameter.
List by buyer ID
curl -i -X GET "https://api.example.gr4vy.app/buyers/payment-methods?buyer_id=fe26475d-ec3e-4884-9553-f7356683f7f9" \
-H "Authorization: Bearer [JWT_TOKEN]"
List by external ID
curl -i -X GET "https://api.example.gr4vy.app/buyers/payment-methods?buyer_external_identifier=user-1234" \
-H "Authorization: Bearer [JWT_TOKEN]"
Response
The response is a list of all the previously stored payment methods for that buyer in a mini format.
GET /buyers/payment-methods?buyer_id=fe26475d-ec3e-4884-9553-f7356683f7f9
{
"items": [
{
"type": "payment-method",
"id": "77a76f7e-d2de-4bbc-ada9-d6a0015e6bd5",
"method": "card",
"details": {
"suffix": "1111",
"scheme": "visa",
"expiration_date": "11/25"
}
}
],
"limit": 20,
"next_cursor": null,
"previous_cursor": null
}