Skip to content
Niu DocsNiu 牛元文档
Dashboard控制台

Read company checkout availability

Generated from the checked-in source. Do not edit this reference by hand.

GET /api/v1/organizations/{organization}/billing/payment-methods

Organization-wide owner/admin with read access or installation administrator only. Returns enabled merchant method codes for the requested currency when configured and an account exists. Omitted currency preserves the configured default. No merchant credentials, account identifiers or upstream queries. Availability does not guarantee collection or grant write permission. No FX or account provisioning is implied.

Operation: getCustomerPaymentMethods.

Use the credential and permission scope described above. Each object below is an alternative; schemes within one object are required together.

JSON
[
{
"bearerAuth": []
}
]

Set NIU_ORIGIN to your installation origin (without /v1). Replace path, query and header placeholders with the required values. Query examples use curl 7.87 or newer to encode values with --url-query. Use the credential scope described above; a bearer token must have the authority required by this operation.

Shell
curl --fail-with-body -X GET "$NIU_ORIGIN/api/v1/organizations/{organization}/billing/payment-methods" \
-H "Authorization: Bearer $NIU_BEARER_TOKEN"

Location: path. Required.

JSON
{
"type": "string",
"format": "uuid"
}

Location: query. Optional.

JSON
{
"type": "string",
"pattern": "^[A-Z]{3}$"
}

Location: query. Optional. Select one configured integration without falling through to another.

JSON
{
"type": "string",
"enum": [
"epay",
"stripe",
"zhifux"
]
}

No request body is declared.

Configured checkout methods or explicit unavailable state

Content type: application/json.

JSON
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"type": "object",
"additionalProperties": false,
"required": [
"currency",
"payment_gateway",
"available",
"payment_methods",
"unavailable_reason"
],
"properties": {
"currency": {
"type": "string",
"pattern": "^[A-Z]{3}$"
},
"available": {
"type": "boolean"
},
"payment_methods": {
"type": "array",
"items": {
"type": "string"
},
"description": "Empty when unavailable; exact configured codes otherwise."
},
"payment_gateway": {
"type": [
"string",
"null"
],
"enum": [
"epay",
"stripe",
"zhifux",
null
],
"description": "Selected configured integration for these methods. Forward this value with currency when creating a top-up; null means no matching integration. This is adapter identity, not merchant credentials or a payment-method display label."
},
"unavailable_reason": {
"type": [
"string",
"null"
],
"enum": [
"integration_unavailable",
"currency_account_missing",
null
]
}
}
}
}
}

Invalid company identifier or currency query

Authentication required

Company billing access not granted

Durable account storage unavailable

Organization-wide owner/admin with read access or installation administrator only. Returns enabled merchant method codes for the requested currency when configured and an account exists. Omitted currency preserves the configured default. No merchant credentials, account identifiers or upstream queries. Availability does not guarantee collection or grant write permission. No FX or account provisioning is implied.

Supported scope: implemented