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.
| Scope | billing:write |
| Side-effect | compute |
| HTTP | POST /v1/op/payment_methods.attach · POST /v1/payment_methods/attach |
| Python / TypeScript | client.payment_methods.attach(…) |
| CLI | geopera payment-methods attach … |
Request — AttachInput
| Field | Type | Required | Description |
|---|---|---|---|
payment_method_id | string | yes |
Response — PaymentMethodOutput.
payment_methods.create_setup_intent
Start saving a card to the org (off-session) — returns the Airwallex client_secret + env.
| Scope | billing:write |
| Side-effect | compute |
| HTTP | POST /v1/op/payment_methods.create_setup_intent · POST /v1/payment_methods/create_setup_intent |
| Python / TypeScript | client.payment_methods.create_setup_intent(…) |
| CLI | geopera payment-methods create-setup-intent … |
Request — SetupIntentInput (see the OpenAPI schema for fields).
Response — SetupIntentOutput.
payment_methods.detach
Detach (remove) a saved payment method from the org.
| Scope | billing:write |
| Side-effect | destructive |
| HTTP | POST /v1/op/payment_methods.detach · POST /v1/payment_methods/detach |
| Python / TypeScript | client.payment_methods.detach(…) |
| CLI | geopera payment-methods detach … |
Request — DetachInput
| Field | Type | Required | Description |
|---|---|---|---|
payment_method_row_id | string | yes |
Response — DetachOutput.
payment_methods.list
List the org’s saved payment methods.
| Scope | billing:read |
| Side-effect | read |
| HTTP | POST /v1/op/payment_methods.list · POST /v1/payment_methods/list |
| Python / TypeScript | client.payment_methods.list(…) |
| CLI | geopera 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).
| Scope | billing:write |
| Side-effect | compute |
| HTTP | POST /v1/op/payment_methods.set_default · POST /v1/payment_methods/set_default |
| Python / TypeScript | client.payment_methods.set_default(…) |
| CLI | geopera payment-methods set-default … |
Request — SetDefaultInput
| Field | Type | Required | Description |
|---|---|---|---|
payment_method_row_id | string | yes |
Response — PaymentMethodOutput.