Make a payment for a specific invoice. You need to provide the ID of the invoice to be paid, which you can retrieve from the GET /api/billing/invoice/{id} endpoint. You can also specify a particular payment method (e.g., a credit card) by providing its ID, which you can retrieve from GET /api/billing/cards.
/billing/pay/[uuid] /billing/pay/[uuid]/success /billing invoiceId from GET /api/billing/invoice/{id} cardId from GET /api/billing/cards Accept Example Content-Type Example cardId string required
· Example: primary invoiceId string required
· Example: 49332 data object required data.message string required
· Example: Function has been scheduled for execution Human-readable message.
data.success boolean required
· Example: true True for successful responses.
requestId string required
· Example: 2121ae20-bd9d-41e9-aeeb-5dd1dd1a24ba Unique request identifier (UUID).
success boolean required
· Example: true True for successful responses.
timestamp string required
· Example: 2026-02-10T00:00:00.000Z ISO 8601 timestamp (UTC).
code string required
· Example: BAD_REQUEST Machine-readable error code.
error string required
· Example: Bad Request HTTP status title (e.g. 'Bad Request').
message string required
· Example: Your card does not support this type of purchase. Human-readable message.
requestId string required
· Example: 2121ae20-bd9d-41e9-aeeb-5dd1dd1a24ba Unique request identifier (UUID).
timestamp string required
· Example: 2026-02-10T00:00:00.000Z ISO 8601 timestamp (UTC).
https://cloud.hostup.se/api/billing/pay curl -X POST "https://cloud.hostup.se/api/billing/pay" \
-H "X-API-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"invoiceId": "49332",
"cardId": "primary"
}' {
"success": true,
"timestamp": "2026-02-10T00:00:00.000Z",
"requestId": "2121ae20-bd9d-41e9-aeeb-5dd1dd1a24ba",
"data": {
"success": true,
"message": "Function has been scheduled for execution"
}
} {
"invoiceId": "49332",
"cardId": "primary"
}