@hatang/sdk
    Preparing search index...

    Interface CreateOrderOptions

    POST /payments for one of your orders; see payments.createOrder.

    interface CreateOrderOptions {
        amount: number;
        code?: string;
        connection_id?: string;
        customer?: { email?: string; name?: string; phone?: string };
        description?: string;
        expires_in?: number;
        invoice?: InvoiceRequest;
        ipn_url?: string;
        metadata?: Record<string, string | number | boolean | null>;
        order_id: string;
        return_url?: string;
    }

    Hierarchy (View Summary)

    Index
    amount: number
    code?: string

    Your own transfer description — your order number, say — instead of a generated HT… code. Letters and digits, 6 to 20, upper-cased; unused on that bank account, or the call is a 409. Longer is safer: it is matched by looking for it inside the transfer description.

    connection_id?: string
    customer?: { email?: string; name?: string; phone?: string }
    description?: string
    expires_in?: number
    invoice?: InvoiceRequest

    Issue an e-invoice once the payment succeeds.

    ipn_url?: string

    Your endpoint for this payment's IPN calls (signed with HMAC-SHA256; see verifyIpn).

    metadata?: Record<string, string | number | boolean | null>
    order_id: string

    Your order id: the payment's idempotency key and metadata.order_id.

    return_url?: string