Skip to main content
Aria Knowledge Central

get_unapplied_credits_payments_m Sample Call and Response

This example retrieves the payments that are unapplied for a given account, based on the get_unapplied_credits_payments_m method defined in plsql_m_r73.yml.

This example includes every required field for a straightforward lookup by account number. It does not cover every optional field the method accepts, and it does not show cash-credit-specific fields, for reasons explained below.

Sample call

{
  "rest_call": "get_unapplied_credits_payments_m",
  "output_format": "json",
  "client_no": 1275,
  "auth_key": "a1b2c3d4e5f6a7b8c9d0e1f2a3b4c5d6",
  "acct_no": 900412233
}

The rest_call and output_format fields form the envelope that the REST layer adds to every call; they are not part of the method's own documented arguments. The acct_no field identifies the account and is one of two alternative fields for this purpose; this example uses the Aria-assigned acct_no rather than the client-defined client_acct_id.

Sample response

{
  "error_code": 0,
  "error_msg": "OK",
  "unapplied_payments": [
    {
      "payment_transaction_id": 4402188,
      "payment_amount": 150.00,
      "unapplied_amount": 45.00
    },
    {
      "payment_transaction_id": 4402312,
      "payment_amount": 75.00,
      "unapplied_amount": 75.00
    }
  ]
}

An error_code of zero, together with an error_msg of "OK," indicates that Aria located the account and returned its unapplied payment records successfully. The unapplied_payments array is shown here with two entries to illustrate that an account can have more than one unapplied payment; an actual response could contain additional entries beyond what is shown here. Although this method's own description mentions both payments and cash credits, and its yml definition still lists cash_credit_transaction_id, cash_credit_amount, and unapplied_cash_credit fields within this same array, those three fields are marked as unused in this release, so they are never actually populated and are left out of this example entirely; the array in this release effectively returns only unapplied payment records. This example also leaves out the separate unapplied_payments_internal structure, which the yml marks as both nonpublic and internal.

TOP
  • Was this article helpful?