Skip to content
QaydTech Beta launch

Receipts

Record a receipt

post https://your-business.qaydtech.com/api/v1/receipts

Records money received from a customer: it settles the invoices named in invoices, or their open invoices oldest first with allocate: auto. Whatever settles no invoice stays to the customer’s credit. Entered in the books at once; a test key never records one.

Permission: receipts.write Supports Idempotency-Key to prevent duplicates.

Request

Headers

  • Authorization string required

    Bearer followed by the API key.

    Example: Bearer qayd_…

  • Accept-Language string optional

    en for English error messages. Arabic by default.

    Example: en

  • Content-Type string required

    application/json with every request that has a body.

    Example: application/json

  • Idempotency-Key string optional

    A unique value so a request sent again creates nothing twice.

    Example: order-10045

Request body application/json

  • customer_id integer required

    The customer’s number.

    Example: 42

  • amount number required

    The amount in riyals, up to 2 decimals.

    Example: 500.00

  • method string required

    How it was paid: cash, bank_transfer, card or cheque.

    Example: bank_transfer

  • account_id integer optional

    For payments and refunds: the cash box or bank account from GET /payment-accounts, defaulting to the method’s account. For stock documents: the offset account, defaulting to stock adjustments.

  • date date optional

    The date; today when not sent.

    Example: 2026-11-10

  • reference string optional

    Your reference, such as your store’s order number, up to 60 characters. Searchable later.

    Example: TRX-55102

  • notes string optional

    Notes, up to 500 characters.

  • allocate string optional

    auto to settle the customer’s open invoices oldest first; none to keep it to their credit. Not sent with invoices.

    Example: auto

  • invoices array[] optional

    The invoices the receipt settles, each with an amount.

  • id integer required

    The invoice number.

    Example: 318

  • amount number required

    How much of it is settled, never more than is left on it.

    Example: 258.75

Responses

  • 201 Created
  • 403 Not allowed
  • Errors · 401 · 403 · 429