Returns a list of payments for the specified order
import { createSpreeClient } from '@spree/sdk'
const client = createSpreeClient({
baseUrl: 'https://your-store.com',
publishableKey: '<api-key>',
})
const payments = await client.store.orders.payments.list('or_abc123', {
bearerToken: '<token>',
}){
"data": [
{
"id": "py_UkLWZg9DAJ",
"payment_method_id": "pm_UkLWZg9DAJ",
"state": "checkout",
"response_code": "12345",
"number": "PJZATDCN",
"amount": "110.0",
"display_amount": "$110.00",
"created_at": "2026-03-05T20:52:34.525Z",
"updated_at": "2026-03-05T20:52:34.525Z",
"source_type": "credit_card",
"source_id": "card_UkLWZg9DAJ",
"source": {
"id": "card_UkLWZg9DAJ",
"cc_type": "visa",
"last_digits": "1111",
"month": 12,
"year": 2027,
"name": "Spree Commerce",
"default": false,
"gateway_payment_profile_id": null
},
"payment_method": {
"id": "pm_UkLWZg9DAJ",
"name": "Credit Card",
"description": null,
"type": "Spree::Gateway::Bogus",
"session_required": true
}
}
],
"meta": {}
}Publishable API key for store access
JWT token for authenticated customers
Order prefix ID
Was this page helpful?
import { createSpreeClient } from '@spree/sdk'
const client = createSpreeClient({
baseUrl: 'https://your-store.com',
publishableKey: '<api-key>',
})
const payments = await client.store.orders.payments.list('or_abc123', {
bearerToken: '<token>',
}){
"data": [
{
"id": "py_UkLWZg9DAJ",
"payment_method_id": "pm_UkLWZg9DAJ",
"state": "checkout",
"response_code": "12345",
"number": "PJZATDCN",
"amount": "110.0",
"display_amount": "$110.00",
"created_at": "2026-03-05T20:52:34.525Z",
"updated_at": "2026-03-05T20:52:34.525Z",
"source_type": "credit_card",
"source_id": "card_UkLWZg9DAJ",
"source": {
"id": "card_UkLWZg9DAJ",
"cc_type": "visa",
"last_digits": "1111",
"month": 12,
"year": 2027,
"name": "Spree Commerce",
"default": false,
"gateway_payment_profile_id": null
},
"payment_method": {
"id": "pm_UkLWZg9DAJ",
"name": "Credit Card",
"description": null,
"type": "Spree::Gateway::Bogus",
"session_required": true
}
}
],
"meta": {}
}