Payment methods operations

Manage payment methods.

Each operation below is reachable at POST /v1/op/{operation_id} or the resource path POST /v1/{resource}/{action}, with a Bearer token (a gpra_ API key or a session token). Back to the Operations Reference index.

payment_methods.attach

Persist a saved card (Airwallex Payment Consent) for the org.

Scopebilling:write
Side-effectcompute
HTTPPOST /v1/op/payment_methods.attach · POST /v1/payment_methods/attach
Python / TypeScriptclient.payment_methods.attach(…)
CLIgeopera payment-methods attach …

RequestAttachInput

FieldTypeRequiredDescription
payment_method_idstringyes

ResponsePaymentMethodOutput.

payment_methods.create_setup_intent

Start saving a card to the org (off-session) — returns the Airwallex client_secret + env.

Scopebilling:write
Side-effectcompute
HTTPPOST /v1/op/payment_methods.create_setup_intent · POST /v1/payment_methods/create_setup_intent
Python / TypeScriptclient.payment_methods.create_setup_intent(…)
CLIgeopera payment-methods create-setup-intent …

RequestSetupIntentInput (see the OpenAPI schema for fields).

ResponseSetupIntentOutput.

payment_methods.detach

Detach (remove) a saved payment method from the org.

Scopebilling:write
Side-effectdestructive
HTTPPOST /v1/op/payment_methods.detach · POST /v1/payment_methods/detach
Python / TypeScriptclient.payment_methods.detach(…)
CLIgeopera payment-methods detach …

RequestDetachInput

FieldTypeRequiredDescription
payment_method_row_idstringyes

ResponseDetachOutput.

payment_methods.list

List the org’s saved payment methods.

Scopebilling:read
Side-effectread
HTTPPOST /v1/op/payment_methods.list · POST /v1/payment_methods/list
Python / TypeScriptclient.payment_methods.list(…)
CLIgeopera payment-methods list …

Request_Empty (see the OpenAPI schema for fields).

Response — a streaming or binary payload (NDJSON / file / tile). Call the HTTP endpoint directly; the JSON SDK return does not apply.

payment_methods.set_default

Make a saved payment method the org’s default (used by off-session charges).

Scopebilling:write
Side-effectcompute
HTTPPOST /v1/op/payment_methods.set_default · POST /v1/payment_methods/set_default
Python / TypeScriptclient.payment_methods.set_default(…)
CLIgeopera payment-methods set-default …

RequestSetDefaultInput

FieldTypeRequiredDescription
payment_method_row_idstringyes

ResponsePaymentMethodOutput.