Payment Cards

Payment cards represent distinct card numbers seen on receipts and expense documents for a client account. Each card record includes the card number (typically the last four digits), the associated payor (employee or business partner), and the date the card was last used. This is a read-only resource derived from document data.

Endpoints

Method Endpoint Description
GET /payment-cards List payment cards for a client account

List Payment Cards

GET /api/v2/payment-cards

Returns a list of distinct payment cards that have appeared on documents for the specified client account. Each entry includes the resolved payor name from the linked business partner.

Query Parameters

Parameter Type Required Description
client_account_id integer Yes The client account ID

Response

{
  "data": [
    {
      "card_number": "4242",
      "payor_id": 56,
      "payor_name": "Ola Nordmann",
      "last_used": "2026-04-10"
    },
    {
      "card_number": "1234",
      "payor_id": null,
      "payor_name": null,
      "last_used": "2026-03-28"
    }
  ]
}

Attributes

Attribute Type Description
card_number string The payment card number (typically the last four digits as printed on receipts)
payor_id integer or null The business partner ID of the card holder. null indicates a company card with no assigned payor
payor_name string or null The resolved name of the payor business partner. null when payor_id is null
last_used date The most recent document date where this card number appeared

Error Responses

Status Description
403 Missing or invalid client_account_id, or no access to the client account

Business Rules

  1. Payment cards are derived from the payment_card_number field on commercial documents — they are not stored as a separate entity
  2. Cards are scoped to a client account
  3. A card with payor_id: null is a company card; a card with a payor_id is an employee or personal card
  4. The payor_name is resolved from the business partner record at query time
  5. This resource is read-only — card data is populated when documents are created or updated