Knowledge Base / API
עברית

Ask AI

✦ AI answer

Thinking…

Sources

    Processing a Card Replacement File for Tokens in APIs (Get Muhlafim Tokens)

    When should this function be used?

    Businesses that use the Muhlafim model service can use this function to view tokens that have received an update or a new status regarding the associated charge, such as a chargeback or cancellation of a recurring payment. This allows them to determine the current status of their customers’ recurring payments and new credit cards.

    What does this function return?

    The tokens and their identifiers are updated with the new credit card details.

    Required models, actions, and settings

    Token model.

    Muhlafim model.

    A terminal that does not require a CVV or ID number and uses the recurring payment charge type. This must be requested from the acquirer.

    After creating a token, it must be charged using the Do Transaction function with the IsAutoRecurringPayment parameter.

    JSON API documentation

    Get Muhlafim Tokens

    POST - https://secure.cardcom.solutions/api/v11/RecuringPayments/GetMuhlafimByDate

    The following parameters must be passed to the Get Muhlafim Tokens function.

    Legend:

    Red parameter – required

    Bold parameter – recommended

    A parameter that is neither red nor bold is optional.

     

    No.
     

    Parameter

    Example values

    Description

    1

    apiUserName

    "test2025"

    API username.

    2

    apiPassword

    "test5000$"

    API user password.

    3

    fromDate

    "2019-08-24T14:15:22Z"

    Start date of the received file.

    4

    toDate

    "2019-08-24T14:15:22Z"

    End date, up to the date of the next received file.

     

    Get Muhlafim Tokens response

    No.
     

    Parameter

    Example values

    Description

    1

    ResponseCode

    0

    Response code. If the value is zero, the function was executed successfully. Any other value indicates that the operation failed.

    2

    Description

    "OK"

    Response description. "OK" indicates success.

    3

    UpdateList

    Array of objects.

    ID - INT

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

    UpdatedTokenList - Array of objects

    ID - Muhlafim file identifier

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

    UpdatedTokenList - List of updated tokens.

     

    UpdatedTokenList values

    Array of objects.

    No.
     

    Parameter

    Example values

    Description

    1

    ID

    INT

    File identifier, identical to the parent object’s identifier.

    2

    ExcelRow

    INT

    Row number in the Excel file.

    3

    OriginalStatus

    Depends on the acquirer

    Original status received from the acquirer.

    4

    Status

    Status in the Cardcom system.

    1 - A replacement card number was received
    2 - Credit card canceled without a replacement
    3 - Transaction chargeback
    4 - The customer requested cancellation of the recurring payment
    5 - Credit card unblocked

    5

    Token

     AA-BB-CC

    Token. If the returned token is empty, no token was found to update. The business most likely updated the credit card details manually. The token remains unchanged; we update the credit card details associated with it on the server side.

    6

    NewExpirationDateYYYY

    2022

    New card expiration year.

    7

    NewExpirationDateMM

     10

    New card expiration month.

    8

    Last4Digits

    1234

    Last four digits of the new credit card number.

     

    Sample function code

    POST request to retrieve replacement card updates for tokens:

    {
      "apiUserName": "test2025",
      "apiPassword": "test5000$",
      "fromDate": "2019-08-24T14:15:22Z",
      "toDate": "2019-08-24T14:15:22Z"
    }

    Example response:

    {
      "ResponseCode": 0,
      "Description": "string",
      "UpdateList": [
        {
          "ID": 0,
          "UpdatedTokenList": [
            {
              "ID": 0,
              "ExcelRow": 0,
              "OriginalStatus": "string",
              "Status": 0,
              "Token": "string",
              "NewExpirationDateYYYY": "string",
              "NewExpirationDateMM": "string",
              "Last4Digits": "string"
            }
          ]
        }
      ]
    }

    Was this article helpful?