get_pending_invoice_no_m Sample Call and Response
This example retrieves the pending invoice number or numbers associated with an account, based on the get_pending_invoice_no_m method defined in plsql_m_r73.yml. When only the account identifier is passed, the method returns an array of pending invoices covering every master plan instance on the account.
This example passes only the account identifier, rather than also narrowing the request to one master plan instance, so the response shows the array behavior with two pending invoices, one per master plan instance on the account.
Sample call
{
"rest_call": "get_pending_invoice_no_m",
"output_format": "json",
"client_no": 100848,
"auth_key": "8cfb51c1c9110f4152c",
"acct_no": 5017732
}
The account is identified by acct_no, the Aria-assigned account identifier, rather than by its alternative, client_acct_id. The optional master_plan_instance_no field, or its alternative client_master_plan_instance_id, is left out here; supplying either one narrows the response to the single pending invoice for that specific master plan instance instead of returning the full array shown below.
Sample response
{
"error_code": 0,
"error_msg": "OK",
"pending_invoice": [
{
"invoice_no": 7723501,
"acct_no": 5017732,
"client_master_plan_instance_id": "MPI-77210",
"billing_group_no": 3312,
"client_billing_group_id": "BG-4471"
},
{
"invoice_no": 7723502,
"acct_no": 5017732,
"client_master_plan_instance_id": "MPI-77215",
"billing_group_no": 3315,
"client_billing_group_id": "BG-4480"
}
]
}
An error_code of zero and an error_msg of "OK" indicate the request completed successfully. The pending_invoice array contains one entry per master plan instance on the account that currently has a pending invoice; this example shows two entries to illustrate the array, but an account with more master plan instances would return more entries. This example omits the error_details field, since it is marked nonpublic in the method definition.