update_payment_method_m Sample Call and Response
This example shows a call that updates a payment method on an account’s billing group, based on the update_payment_method_m method defined in plsql_m_r73.yml.
The example replaces the card number and expiration date on an existing credit card payment method because the card was reissued, disabling the prior payment method as part of the update. It does not cover switching from one payment type to another, disabling a payment method outright, updating the display name or description of a payment method, or attempting a collection as part of the same call.
Sample call
{
"rest_call": "update_payment_method_m",
"output_format": "json",
"client_no": 1073,
"auth_key": "b19b2b3a4c5d6e7f8091a2b3c4d5e6f7",
"acct_no": 3300521,
"billing_group_no": 550214,
"payment_method_no": 990456,
"pay_method_type": 1,
"cc_num": "4111111111111111",
"cc_expire_mm": 9,
"cc_expire_yyyy": 2029,
"cvv": "456",
"bill_first_name": "Priya",
"bill_last_name": "Natarajan",
"bill_address1": "48 Harborview Lane",
"bill_city": "Portland",
"bill_state_prov": "OR",
"bill_postal_cd": "97201",
"bill_country": "US",
"disable_existing_on_update": "true"
}
rest_call and output_format are envelope fields added by the REST layer. auth_key is required for this method. acct_no is one side of an alternative pair with client_acct_id; this example uses the Aria-assigned account number. billing_group_no identifies the billing group whose payment method is being changed, and is one of a group of alternatives that also includes client_billing_group_id, master_plan_instance_no, and client_master_plan_instance_id; this example uses the Aria-assigned billing group number. payment_method_no identifies the existing payment method being updated; omitting it would instead create a new payment method on the billing group. pay_method_type uses the enumerated value one, meaning credit card. cc_num is clearly a fake, non-real card number used only to illustrate the request shape. disable_existing_on_update is set to “true,” its default, so the prior payment method is disabled once the new one is saved; setting it to “false” would leave the original payment method enabled alongside the new one. Left out of this example: disabled_ind, bill_contact_no (an alternative to supplying billing contact fields inline), pay_method_name, pay_method_description, the bank account and Direct Debit fields (bank_acct_num, bank_routing_num, iban, bank_check_digit, bank_swift_cd, bank_country_cd, mandate_id, bank_id_cd, bank_branch_cd, bank_name, bank_city, bank_acct_type, bank_acct_holder_type, mandate_signature_date), do_collect, change_status_after_coll, reset_dates_after_status, cc_id, cc_auth_amount, and new_client_payment_method_id.
Sample response
{
"error_code": 0,
"error_msg": "OK",
"seq_no": 990457
}
An error_code of zero together with an error_msg of “OK” indicates that Aria saved the new payment method successfully. seq_no is the sequence number of the new payment method as it appears on the account. Because this example did not set do_collect to true, no collection was attempted, so collection_info, the multidimensional array of collection results, is left out of this response along with its nested processor response fields (proc_cvv_response, proc_avs_response, proc_cavv_response, proc_status_code, proc_status_text, proc_payment_id, proc_auth_code, proc_merch_comments). If a collection had been requested and attempted, collection_info would contain one entry per billing group collected against.