A payment method is a stored instrument (credit card, bank account, direct debit mandate) that a customer uses to pay invoices. Payment methods are tokenized through the configured payment gateway - Kontorion never stores raw card numbers or bank details.
Each customer can have multiple payment methods. One is marked as is_default and is used automatically when invoices are finalized.
List payment methods
Returns payment methods for the org. Pass ?customer_id=
query Parameters
customer_idFilter by customer UUID
Filter by customer UUID
include_removedInclude soft-deleted methods (default false)
Include soft-deleted methods (default false)
limitPage size. Values above the server-side cap are clamped (standard default 50, cap 200; a few document-heavy lists use larger windows). Invalid values fall back to the default.
cursorOpaque continuation token from the previous response's pagination.cursor. Omit for the first page. Cursors are stateless and do not expire, but are only valid for the list and filters that produced them.
Headers
X-Workspace-IdSelects the workspace this request operates in, by workspace UUID or slug (e.g. a sandbox workspace for test integrations). Omitted: the organization's default live workspace. Unknown workspace: 404; workspace outside your organization: 403. Discover workspaces via GET /workspaces.
Workspace UUID or slug.
List payment methods › Responses
OK
Create a payment method
Creates a new payment method. customer_id is supplied in the request body.
Headers
Idempotency-KeyUnique key that makes this POST safe to retry: repeats with the same key replay the first response instead of re-executing. Replays are scoped to the retrying principal (same API key / user) and kept for 24 hours. Required on every POST.
Client-generated idempotency key (e.g. a UUID).
X-Workspace-IdSelects the workspace this request operates in, by workspace UUID or slug (e.g. a sandbox workspace for test integrations). Omitted: the organization's default live workspace. Unknown workspace: 404; workspace outside your organization: 403. Discover workspaces via GET /workspaces.
Workspace UUID or slug.
Create a payment method › Request Body
customer_idCustomer to attach the payment method to. Required.
is_defaultWhen true, make this the customer's default payment method, demoting any prior default.
Free-form key/value metadata for caller use; not interpreted by billing.
providerPayment provider holding this method, e.g. "stripe" or "gocardless". Required.
provider_idProvider's own identifier for the stored method; omit when not tracked externally.
typeMethod type: CREDIT_CARD, BANK_ACCOUNT, SEPA_DIRECT_DEBIT, SEPA_DIRECT_DEBIT_B2B, ACH_BUSINESS, PAYPAL, or EXTERNAL. Required; the B2B/ACH types require a BUSINESS customer.
Create a payment method › Responses
Created
Get a payment method
Returns a single payment method. Soft-deleted (removed) methods are not served and respond 404.
path Parameters
idPayment method UUID
Payment method UUID
Headers
X-Workspace-IdSelects the workspace this request operates in, by workspace UUID or slug (e.g. a sandbox workspace for test integrations). Omitted: the organization's default live workspace. Unknown workspace: 404; workspace outside your organization: 403. Discover workspaces via GET /workspaces.
Workspace UUID or slug.
Get a payment method › Responses
OK
Delete a payment method
Soft-deletes a payment method by ID.
path Parameters
idPayment method UUID
Payment method UUID
Headers
X-Workspace-IdSelects the workspace this request operates in, by workspace UUID or slug (e.g. a sandbox workspace for test integrations). Omitted: the organization's default live workspace. Unknown workspace: 404; workspace outside your organization: 403. Discover workspaces via GET /workspaces.
Workspace UUID or slug.
Delete a payment method › Responses
No Content
Update a payment method
Merge-patch update: only supplied fields (provider, provider_id, is_default, status, metadata) change. Setting is_default=true atomically demotes the customer's previous default method.
path Parameters
idPayment method UUID
Payment method UUID
Headers
X-Workspace-IdSelects the workspace this request operates in, by workspace UUID or slug (e.g. a sandbox workspace for test integrations). Omitted: the organization's default live workspace. Unknown workspace: 404; workspace outside your organization: 403. Discover workspaces via GET /workspaces.
Workspace UUID or slug.
Update a payment method › Request Body
is_defaultWhen true, promote this method to the customer's default; omit to leave unchanged.
Replacement free-form key/value metadata; omit to leave unchanged.
providerNew payment provider; omit to leave unchanged.
provider_idNew provider-side identifier; omit to leave unchanged.
statusNew lifecycle status: active, expired, or removed; omit to leave unchanged.
Update a payment method › Responses
OK