Knowledge Base / API
עברית

Ask AI

✦ AI answer

Thinking…

Sources

    Update debit order history item to irrevocable status

    Use this API function to update the status of a recurring payment debt without changing the previous status. This is useful when a recurring charge fails, allowing the debt to be marked for tracking, paid through another method, or as bad debt.

    When should this function be used?

    This function is intended for merchants who want to update the status of a customer’s recurring payment history item to a new status without changing the previous status.

    Typically, this function is used when a debt is created because the customer’s credit card charge failed.

    In these cases, the merchant can change the debt status. For example:

    • Change it to bad debt so that the system will not attempt to charge the card again.
    • Change it to debt paid through another method, such as cash or bank transfer.
    • Change it to debt for tracking so that the system will not make another charge, while the debt remains open and can be monitored.

    How can a debt created by a recurring payment be identified in the API?

    There are two main ways to identify a debt created by a recurring card payment.

    The first is by using a webhook (automatic notification) for recurring payments. When a charge fails, the system immediately sends a notification that the charge was unsuccessful, indicating that a debt was created.

    The second way is to use the Get recurring payment history function. This function allows you to check the status of charges in the recurring payment history. If the status DEBTAUTOBILLING (debt for automatic collection) is returned, it means that a debt was created for that specific charge.

    Get recurring payment history

    Here is the link to the JSON function:

    Request method: POST.

    Update debit order history item to irrevocable status

    https://secure.cardcom.solutions/api/v11/RecuringPayments/ChangeStatusForHistoryRecurringToIrrevocable

    The following parameters must be passed to the Update debit order history item to irrevocable status function.

    Key:

    Red parameter – required

    Bold parameter – recommended

    Parameter that is neither red nor bold – optional

    Number Parameter Example values Description
    1 ApiUserName "test2025" API username.
    2 ApiPassword "test5000$" API user password.
    3 RowID int Internal charge row number for the customer’s card.
    4 AccountId 37452 Customer card number.
    5 ChangeTo

    "DebtForTracking"

    ----------------------------

    "NoOtherPaymentMethod"

    ----------------------------

    "BadDebt"

    ChangeTo – the status to which the debt should be changed.

    --------------------------

    DebtForTracking – debt for tracking. Cardcom will no longer attempt to charge the debt, but the debt can still be viewed and an attempt can be made to charge it.

    --------------------------

    NoOtherPaymentMethod – paid through another method. If the customer paid in cash, by recurring payment, or through another method that does not go through Cardcom, this status can be selected. The system will stop attempting to charge the debt automatically.

    --------------------------

    BadDebt – bad debt. The system will stop attempting to charge the debt automatically.

    Response from Update debit order history item to irrevocable status

    Number Parameter Example values Description
    1 ResponseCode 0 Response code. If it equals zero, the function was executed successfully. Any other response indicates that the operation was unsuccessful.
    2 Description "Successful operation" Response description. "OK" indicates a successful result.

    Below is an example of the function call and its response.

    POST request to change the charge status

    {
      "ApiUserName": "test2025",
      "ApiPassword": "test5000$",
      "AccountId": 37452,
      "RowID": "340642",
      "ChangeTo": "BadDebt"
    }

    Response:

    {
      "ResponseCode": 0,
      "Description": "Successful operation"
    }

    Was this article helpful?