Skip to main content
Aria Knowledge Central

get_usage_history_m Guide

This API returns usage records for an account, and can be filtered by date range, usage type, invoice, exclude status, and qualifiers. Using limit and offset inputs, results can be paginated. The fields "locale_no" and "locale_name" can be specified to translate output fields for which translations have been assigned to Locales configured in Aria.

API Specification: get_usage_history_m
Required Fields:
  • <client_no>
  • <auth_key>
  • <acct_no> or <client_acct_id>
  • <master_plan_instance_no>
 

Additional Guidance

Input Fields
 
Field Name: Notes:
<master_plan_instance_no>

You can:

  1. Pass in the Aria-assigned unique identifier for the master plan instance (MPI) to get the usage history of only that MPI; or
  2. Pass in -1 to get the usage history of all MPIs for the specified account.
<specified_usage_type_no>

You can pass in:

  • a <specified_usage_type_no> or <specified_usage_type_code> without a <date_range_start> or  <invoice_no>; or
  • a combination of (<specified_usage_type_no> or <specified_usage_type_code>) and/or (<date_range_start> and <date_range_end>) and (<invoice_no>).
<specified_usage_type_code>

You can pass in:

  • a <specified_usage_type_no> or <specified_usage_type_code> without a <date_range_start> or  <invoice_no>; or
  • a combination of (<specified_usage_type_no> or <specified_usage_type_code>) and/or (<date_range_start> and <date_range_end>) and (<invoice_no>).
<date_range_start> A date_range_start is required if an invoice_no is not specified.
<invoice_no>

You can pass in:

  • a <specified_usage_type_no> or <specified_usage_type_code> without a <date_range_start> or  <invoice_no>; or
  • a combination of (<specified_usage_type_no> or <specified_usage_type_code>) and/or (<date_range_start> and <date_range_end>) and (<invoice_no>).

An invoice number is required if  date_range_start is not specified or if you are entering an invoice_line_item.

<invoice_line_item> The invoice_no input is required if you are entering an invoice_line_item.
<retrieve_excluded_usage>
Allowable Values
Values Description
true Discarded usage records will be included
false Discarded usage records will not be included
<billed_filter>
Allowable Values
Values Description
0 Return both billed and unbilled usage records. (Default)
1 Billed usage records only
2 Unbilled usage records only

Output Fields

 
Field Name Notes
<is_excluded>
Allowable Values
Values Description
true Usage record has been excluded from billing.
false Usage record has not been excluded from billing.
<exclude_reason_cd>
Allowable Values
Values Description
1 No reason provided when discarding.
Any Random reason number given by client when discarding.

Error Codes

Error Code/Description Associated Inputs
 
<auth_key>, <client_no>
<acct_no>, <client_acct_id>
<specified_usage_type_no>
<specified_usage_type_code>
<limit>
<offset>
<master_plan_instance_no>, <client_master_plan_instance_id>, <invoice_no>, <limit>, <offset>, <acct_no>
<invoice_line_item>
<retrieve_excluded_usage>
<master_plan_instance_no>, <client_master_plan_instance_id> 
<master_plan_instance_no>
<client_master_plan_instance_id> 
<date_range_start>, <date_range_end>
<locale_no>
<locale_name>
  • Was this article helpful?