@mica/sdk (SDK contract v1)
    Preparing search index...

    Interface Invoice

    A bill a resource presented to a player through the phone (MICA-240).

    Created only by the server, through the SendInvoice export — no generic action on the invoices service is registered, so nothing a client sends can mint, edit or delete one. status is active while it can still be paid or declined; paid, declined and expired are terminal, and expires_at is when an open one stops being payable, set from mica_invoice_expiry_days at creation. Exactly one of society and payee names where the money goes: a job's society account through the banking bridge, or a character's bank.

    interface Invoice {
        amount: number;
        citizenid: string;
        created_at: string | Date;
        expires_at: number;
        from_label: string;
        id: number;
        memo: string | null;
        paid_at: number | null;
        payee: string | null;
        resource: string;
        society: string | null;
        status: "active" | "deleted" | "paid" | "declined" | "expired";
        updated_at: string | Date;
    }
    Index
    amount: number

    Whole currency units.

    citizenid: string

    Who is billed.

    created_at: string | Date
    expires_at: number

    Epoch seconds.

    from_label: string

    What the player reads as the biller: a business or a job name.

    id: number
    memo: string | null
    paid_at: number | null

    Epoch seconds, once paid; null otherwise.

    payee: string | null

    The character paid, or null when a society is.

    resource: string

    The resource that sent it, so a payment can be reported back to it.

    society: string | null

    The job whose society account is paid, or null when a character is.

    status: "active" | "deleted" | "paid" | "declined" | "expired"
    updated_at: string | Date