Hello team can we update trialOccurrences and trialAmount update subscription using ARBUpdateSubscriptionRequest, if so please suggest valid json format.
12-11-2023 02:15 AM
To update trialOccurrences and trialAmount in a subscription using the ARBUpdateSubscriptionRequest with Authorize.Net, you can send a JSON request including these fields under the paymentSchedule section of the subscription. Make sure to include your merchant authentication details, subscription ID, and the new values for trialOccurrences and trialAmount. For exact field names and format, refer to Authorize.Net's API documentation.
12-11-2023 03:57 AM
Thanks For your response AreejAnjum i have tried it but am getting error -Your payment could not be processed because of error E00003: The element 'subscription' in namespace 'AnetApi/xml/v1/schema/AnetApiSchema.xsd' has invalid child element 'paymentSchedule' in namespace 'AnetApi/xml/v1/schema/AnetApiSchema.xsd'. List of possible elements expected: 'order, customer, billTo, shipTo, profile' in namespace 'AnetApi/xml/v1/schema/AnetApiSchema.xsd'.
12-11-2023 04:04 AM
Hi @navya
Here is the json request/response example of success updating trial data:
request
{
"ARBUpdateSubscriptionRequest": {
"merchantAuthentication": {
"name": "${your_api_login_id}",
"transactionKey": "${you_transaction_key}"
},
"refId": "123456",
"subscriptionId": "9052227",
"subscription": {
"paymentSchedule": {
"trialOccurrences": 1
},
"trialAmount": 1.00
}
}
}
response:
{
"profile": {
"customerProfileId": "515619158",
"customerPaymentProfileId": "523840874"
},
"refId": "123456",
"messages": {
"resultCode": "Ok",
"message": [
{
"code": "I00001",
"text": "Successful."
}
]
}
}
12-14-2023 01:30 PM