Update a merchant's failed payment handling

Changed on

Update the settings that control automatic payment retry when a customer failed payment occurs.

put/billing/merchant/failedpaymenthandling

Request

  • Base URL
    https://api-sandbox.ezypay.com/v2
  • URL
    https://api-sandbox.ezypay.com/v2/billing/merchant/failedpaymenthandling
  • Auth
    OAuth 2
    Client credentials
    Token URL: https://identity-sandbox.ezypay.com/token

Headers

merchantstring required

Merchant ID

Request body

initialActionstring

The initial action taken when a failed payment occurs. Supported values are: stop - Do not attempt any further payment processing for the failed invoice. continue - Continue to attempt payment recovery for the failed invoice.

autoRetryboolean

Determines if automatic payment retry will occur on the failed invoice. Supported values are true and false.

retryInDaysinteger

Specifies the number of days to wait before next retry for payment. Supported values are between 2 - 14. Default value is 7.

maximumFailedAttemptsinteger

Specifies the maximum number of failed attempts allowed before stopping payment retries. Supported values are between 2 - 5. Default value is 2.

applyTostring

Specifies the scope when updating the failed payment settings. Supported values are: merchant - Apply updated settings to all new plans and on-demand invoices created. Existing plans, subscriptions, and invoices are not affected.

Response

200

idstring
numberstring
legalNamestring
namestring
addressunknown
countryCodestring
emailstring
phoneNumberunknown
billingboolean
settlementboolean
statusstring
businessRegistrationNumberunknown
taxIdunknown
categoryCodeunknown
websiteunknown
descriptionunknown
referenceCodeunknown
acceptedPaymentMethodsstring[]
paymentReactivationHandlingstring
typestring
feePricingIdstring

Example response

{
  "id": "c556d40f-87b5-49f9-90e8-07a610dac1a7",
  "number": "57899",
  "legalName": "high_st LegalNameNZ",
  "name": "high_st NameNZ",
  "countryCode": "NZ",
  "email": "success+NZ+merchant+bf905c27-b03b-4529-a5d1-3beef14a03e3@simulator.amazonses.com",
  "billing": true,
  "settlement": true,
  "status": "ACTIVE",
  "settlementSchedule": {
    "intervalUnit": "DAY",
    "interval": 1,
    "nextSettlementDate": "2019-05-19",
    "intervalDayType": "calendar"
  },
  "settlementPayoutMethod": {
    "id": "c556d40f-87b5-49f9-90e8-07a610dac1a7",
    "paymentMethodToken": "cc0101ef-4bed-468a-8f0e-97449bba0edc",
    "bank": {
      "accountHolderName": "Automation Test NEW_ZEALAND",
      "last4": "0000",
      "bankNumber": "03",
      "branchNumber": "1587",
      "suffixNumber": "00"
    }
  },
  "acceptedPaymentMethods": [
    "BANK"
  ],
  "failedPaymentHandling": {
    "initialAction": "CONTINUE",
    "autoRetry": true,
    "retryInDays": 2,
    "maximumFailedAttempts": 4
  },
  "paymentReactivationHandling": "activate_payments_across_customer",
  "notifications": {
    "customerEmail": {
      "subscriptionCreation": true,
      "paymentMethodCreation": true,
      "pastDueInvoice": true
    }
  },
  "metadata": {
    "ezypay_internal_payment_simulator": "false"
  },
  "type": "business",
  "feePricingId": "a67eca1d-0c37-4fc9-b9c5-03b2dc8aefc7",
  "documentNumberSettings": [
    {
      "documentType": "invoice",
      "prefix": "IN"
    }
  ]
}

Changes