# API: Get invoices

# getInvoices

Get list of invoices.

TIP

This API call uses pagination for results.

# Optional parameters

Parameter Description
page Which page to return
list Status of invoices to list, possible values: all, paid, unpaid, cancelled
filter[lastname] Filter by client lastname
filter[firstname] Filter by client firstname
filter[companyname] Filter by client companyname
filter[total] Filter by invoice total
filter[date] Filter by invoice date
filter[duedate] Filter by invoice duedate
filter[payment_module] Filter by payment module id
filter[status] Filter by invoice status
filter[recurring_id] Filter by recurring invoice id
filter[currency_id] Filter by currency id
filter[country] Filter by customer country
filter[type] Filter by item type, ie:: Hosting, Domain
filter[item_id] Filter by related item id, ie: Account id, or Domain id - use with filter[type]

# Request

GET /admin/api.php?api_id=API_ID&api_key=API_KEY&call=getInvoices

# PHP Samples

# Response

{
    "success": true,
    "invoices": [
        {
            "id": "62",
            "currency_id": "0",
            "date": "2011-12-09",
            "duedate": "2011-12-09",
            "subtotal2": "178.00",
            "credit": "0.00",
            "total": "178.00",
            "paid_id": "",
            "status": "Paid",
            "firstname": "Jack",
            "client_id": "8",
            "lastname": "Black",
            "module": "AlertPay",
            "recid": "0"
        },
        {
            "id": "61",
            "currency_id": "0",
            "date": "2011-12-07",
            "duedate": "2011-12-07",
            "subtotal2": "295.00",
            "credit": "0.00",
            "total": "295.00",
            "paid_id": "",
            "status": "Unpaid",
            "firstname": "Jack",
            "client_id": "8",
            "lastname": "Black",
            "module": "AlertPay",
            "recid": "0"
        },
        {
            "id": "58",
            "currency_id": "0",
            "date": "2011-11-22",
            "duedate": "2011-11-22",
            "subtotal2": "11.94",
            "credit": "0.00",
            "total": "11.94",
            "paid_id": "",
            "status": "Unpaid",
            "firstname": "Mike",
            "client_id": "6",
            "lastname": "Blue",
            "module": "AlertPay",
            "recid": "0"
        },
        {
            "id": "53",
            "currency_id": "0",
            "date": "2011-11-15",
            "duedate": "2011-11-15",
            "subtotal2": "50.00",
            "credit": "0.00",
            "total": "50.00",
            "paid_id": "",
            "status": "Unpaid",
            "firstname": "Mike",
            "client_id": "6",
            "lastname": "Blue",
            "module": "AlertPay",
            "recid": "0"
        },
        {
            "id": "46",
            "currency_id": "0",
            "date": "2011-11-02",
            "duedate": "2011-11-02",
            "subtotal2": "20.00",
            "credit": "20.00",
            "total": "0.00",
            "paid_id": "",
            "status": "Paid",
            "firstname": "Random",
            "client_id": "2",
            "lastname": "Customer",
            "module": "AlertPay",
            "recid": "0"
        },
        {
            "id": "43",
            "currency_id": "0",
            "date": "2011-10-31",
            "duedate": "2011-10-31",
            "subtotal2": "30.00",
            "credit": "0.00",
            "total": "30.00",
            "paid_id": "",
            "status": "Paid",
            "firstname": "John",
            "client_id": "1",
            "lastname": "Doe",
            "module": "AlertPay",
            "recid": "0"
        },
        {
            "id": "6",
            "currency_id": "0",
            "date": "2011-10-07",
            "duedate": "2012-01-05",
            "subtotal2": "1.00",
            "credit": "0.00",
            "total": "1.00",
            "paid_id": "",
            "status": "Unpaid",
            "firstname": "Random",
            "client_id": "2",
            "lastname": "Customer",
            "module": null,
            "recid": "0"
        },
        {
            "id": "1",
            "currency_id": "0",
            "date": "2011-09-24",
            "duedate": "2011-09-24",
            "subtotal2": "11.94",
            "credit": "0.00",
            "total": "11.94",
            "paid_id": "",
            "status": "Paid",
            "firstname": "John",
            "client_id": "1",
            "lastname": "Doe",
            "module": null,
            "recid": "0"
        }
    ],
    "call": "getInvoices",
    "server_time": 1323444951
}
Last Updated: 9/30/2024, 2:47:06 PM