Skip to main content
An order is one financial event. A subscription describes an ongoing commercial relationship; each initial payment, renewal, or billed change inside that relationship becomes a separate order.

Identify why it exists

The billing_reason places an order in its business context: Every order ties money, discount, tax, customer, product, optional subscription, custom checkout fields, and the resulting invoice together.

Track collection state

Charge a saved method without checkout

Off-session charges are a paid-plan preview feature.
Use this flow for a manual service fee, top-up, or other amount that should be charged to an existing customer’s saved payment method. It requires orders:write and organization sales-management permission.
1

Create a draft

Send POST /v1/orders/ with an existing customer and a one-time fixed-price or free product. The customer must have a complete billing address and at least one saved payment method.
This creates order.created, but assigns no invoice number and sends no customer email.
2

Finalize the draft

Send POST /v1/orders/{id}/finalize. Ruba uses the default saved method unless payment_method_id selects another.
Success changes the order to paid, assigns the invoice number, grants product benefits, emails confirmation, and emits order.paid. A failed charge returns the order to draft without consuming an invoice number: 402 covers declines, missing methods, or an off-session 3DS/SCA requirement; 403 means the feature or account cannot accept the charge; 412 means the order is no longer a draft.

Invoice and receipt are different

The invoice describes what was sold, including line items, billing identity, tax, and totals. Ruba creates a PDF invoice for every paid order. Generate or retrieve it with the invoice endpoints, or let the customer edit billing identity and download it from the portal. Once generated, merchant-side billing details are frozen; a customer correction regenerates it through the portal. The receipt proves collection. It includes payment method, date, paid amount, applied customer balance, later refunds, and the linked invoice number. Receipt numbers follow RCPT-{customer-id}-{NNNN}. Retrieve one through the merchant endpoint or portal endpoint. The first request may return 202 Accepted while the PDF renders; retry for the presigned URL.

React to state changes

Full and partial refunds use a separate resource linked to the order. Review refund rules →