Attach a payment method
POST
/api/v1/organizations/{orgID}/billing/payment-methods
const url = 'https://api.aetherplatform.cloud/api/v1/organizations/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/billing/payment-methods';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"stripe_pm_id":"example","is_default":true}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.aetherplatform.cloud/api/v1/organizations/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/billing/payment-methods \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "stripe_pm_id": "example", "is_default": true }'Attaches a Stripe payment method (referenced by its Stripe payment-method ID) to the organization.
Authorizations
Section titled “Authorizations ”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters ” orgID
required
string format: uuid
Organization UUID.
Request Body required
Section titled “Request Body required ” Media type application/json
object
stripe_pm_id
required
The Stripe payment method ID to attach.
string
is_default
boolean
Example generated
{ "stripe_pm_id": "example", "is_default": true}Responses
Section titled “ Responses ”Payment method attached.
Media type application/json
object
id
required
string format: uuid
org_id
required
string format: uuid
card_brand
string | null
card_last4
string | null
card_exp_month
integer | null
card_exp_year
integer | null
is_default
required
boolean
created_at
required
string format: date-time
Example generated
{ "id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "org_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "card_brand": "example", "card_last4": "example", "card_exp_month": 1, "card_exp_year": 1, "is_default": true, "created_at": "2026-04-15T12:00:00Z"}Missing or invalid credentials.
Media type application/json
object
error
required
object
code
required
A stable, machine-readable error code.
string
message
required
string
details
Array<object>
object
field
required
string
code
required
string
message
required
string
Example generated
{ "error": { "code": "example", "message": "example", "details": [ { "field": "example", "code": "example", "message": "example" } ] }}Request validation failed.
Media type application/json
object
error
required
object
code
required
A stable, machine-readable error code.
string
message
required
string
details
Array<object>
object
field
required
string
code
required
string
message
required
string
Example generated
{ "error": { "code": "example", "message": "example", "details": [ { "field": "example", "code": "example", "message": "example" } ] }}