Skip to main content

Create a payment method

API operation: Open the endpoint in Scalar

Use POST /paymethods to create a project-level payment-method definition. The operation documented here is Paymethod.register.

The documented schema requires name and a unique gateway; optional fields include enabled, allow_with_zero_balance, and data_template.

The documented operation uses super-administrator middleware. Creating a definition does not by itself implement a working payment integration or associate the payment method with a business. Gateway libraries, business credentials, product support, and payment flows are separate concerns.

See the payment method model and Business payment-method credential model for the identity boundary.

OpenAPI reference​

Operation: POST /paymethods

Request body fields

NameTypeRequired
allow_with_zero_balancebooleanNo
data_templatearray | nullNo
enabledbooleanNo
gatewayanyYes
nameanyYes

Responses

CodeDescription
200OK
400Bad Request (ErrorResponse)
401Unauthorized
404Not Found
429Too Many Requests (ErrorResponse)
500Internal Server Error (ErrorResponse)
503Service Unavailable (ErrorResponse)
Open this operation in the API reference