get_acct_surcharges_m Sample Call and Response
This example retrieves the surcharges assigned to an account for a specific master plan instance (subscription). It is based on the get_acct_surcharges_m method definition in plsql_m_r73.yml.
This example includes every required field, plus master_plan_instance_no to scope the results to one subscription. It leaves out include_detail_ind, since that field is currently unused by this method, and locale_no and locale_name, since this example does not need locale-specific formatting.
Sample call
{
"rest_call": "get_acct_surcharges_m",
"output_format": "json",
"client_no": 6423,
"auth_key": "a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4",
"acct_no": 8842001,
"master_plan_instance_no": 500213
}
The acct_no field identifies the account, using the Aria-assigned numeric identifier rather than its alternative, client_acct_id. The master_plan_instance_no field scopes the results to one subscription rather than its alternative, client_master_plan_instance_id; leaving it null would return surcharges across the account as a whole.
Sample response
{
"error_code": 0,
"error_msg": "OK",
"all_surcharges": [
{
"surcharge_no": 4021,
"surcharge_name": "E-911 Regulatory Surcharge",
"client_surcharge_id": "SURCHG-E911",
"description": "Emergency service regulatory surcharge",
"ext_description": "Applied per FCC E-911 regulatory requirements",
"surcharge_type": "Regulatory",
"currency": "usd",
"tax_group": "TG-STANDARD",
"invoice_app_method": "Per Invoice",
"rev_gl_code": "4210",
"ar_gl_code": "1210",
"tax_inclusive_ind": 0,
"assignment_level": 3,
"master_plan_instance_no": 500213,
"plan_no": 70011,
"plan_name": "Business Pro Monthly"
},
{
"surcharge_no": 4055,
"surcharge_name": "Credit Card Processing Surcharge",
"client_surcharge_id": "SURCHG-CCPROC",
"description": "Surcharge for credit card payment processing costs",
"ext_description": "Applied when the account's primary payment method is a credit card",
"surcharge_type": "Payment Method",
"currency": "usd",
"invoice_app_method": "Per Transaction",
"rev_gl_code": "4225",
"ar_gl_code": "1210",
"tax_inclusive_ind": 1,
"assignment_level": 4,
"pay_method_type": 1,
"pay_method_type_name": "Credit Card"
}
]
}
An error_code value of zero and an error_msg value of "OK" together indicate that Aria retrieved the surcharges successfully. The all_surcharges array shows two surcharges for illustration; an account with more assigned surcharges would return additional entries. The assignment_level field indicates the level at which each surcharge applies: a value of three, on the first entry, indicates a plan-level surcharge, so that entry includes master_plan_instance_no, plan_no, and plan_name; a value of four, on the second entry, indicates a payment-methods-level surcharge, so that entry instead includes pay_method_type and pay_method_type_name and omits the plan-level fields. The second entry also omits tax_group, since that surcharge is not assigned to a tax group. This example leaves out surcharge_plan, surcharge_rate, and surcharge_rate_schedule_details, all of which this method's definition marks as currently unused, and surcharge_rate is additionally deprecated as of update version 71. It also leaves out acct_locale_no, acct_locale_name, and acct_locale_no_2, since this client does not use locale-specific account formatting; acct_locale_no is itself deprecated as of update version 19.