PayFacto API - v1.0 - Solution : DataCandy

PayFacto API - v1.0 - Solution : DataCandy

PayFacto API - v1.0 - Solution : DataCandy

Enable gift and loyalty program support via DataCandy alongside credit and debit in semi-integrated setups β€” how to activate a gift card account, the full set of DataCandy transaction endpoints, and the complete acquirer return code list.

πŸ”’

  Account Activation Linked to the Gift Card

ℹ️

Make sure your payment terminal is properly configured before processing DataCandy gift card transactions.

DataCandy provides the terminal configuration information directly to the merchant. This information includes:

πŸ”‘

DataCandy Merchant Number

Identifies the merchant within the DataCandy platform.

πŸ”‘

DataCandy Access Key

Used to authenticate API requests to DataCandy.

πŸ”‘

DataCandy Merchant Password

Required for merchant-level authentication.

ℹ️

For complete application information, refer to the DataCandy User Guide.

To activate an account linked to a gift card, you must complete the Activation transaction using the payment terminal. To activate an account, the merchant must call the Payment API using the following function:

DataCandy - Activate

The amount sent in the Activation call is automatically credited on the DataCandy gift card account. Using this endpoint, the account status of the card in the DataCandy dashboard is updated from Activable to Active.

APIEndpoint
DataCandy - Activatehttps://developer.payfacto.com/docs/datacandy-activate
❗

Activation Makes All Other Transactions Possible

This step is required before performing other types of DataCandy transactions: Increment, Purchase (Redemption), Balance, Partial Cancel, and Complete Cancel.

βž•

  DataCandy Increment

This transaction is used to increment (add funds to) a DataCandy gift card. The initial amount is credited to the gift card during the Activation transaction.

To process an Increment transaction, the merchant must call the Payment API using the following function:

DataCandy - Increment

Adds funds to an already-activated DataCandy gift card.

APIEndpoint
DataCandy - Incrementhttps://test.api.payfacto.cloud/v1/datacandy/increment
πŸ’³

  DataCandy Purchase (Redemption)

This transaction is used to redeem a DataCandy gift card.

To process a Purchase transaction, the merchant must call the Payment API using the following function:

DataCandy - Purchase

Redeems balance from a DataCandy gift card.

APIEndpoint
DataCandy - Purchasehttps://test.api.payfacto.cloud/v1/datacandy/redemption
πŸ’°

  DataCandy Balance

This transaction is used to get the balance remaining on a DataCandy gift card.

To process a Balance transaction, the merchant must call the Payment API using the following function:

DataCandy - Balance

Retrieves the current balance on a DataCandy gift card.

APIEndpoint
DataCandy - Balancehttps://test.api.payfacto.cloud/v1/datacandy/balance
⏳

  DataCandy Partial Cancel

This transaction is used to perform a partial cancel of a previous DataCandy transaction.

To process a partial cancel, the merchant must call the Payment API using the following function:

DataCandy - Partial Cancel

Reverses part of the amount of a previous DataCandy transaction.

APIEndpoint
DataCandy - Partial Cancelhttps://test.api.payfacto.cloud/v1/datacandy/partialCancel
❌

  DataCandy Complete Cancel

This transaction is used to fully cancel a previous DataCandy transaction.

To process a complete cancel transaction, the merchant must call the Payment API using the following function:

DataCandy - Complete Cancel

Fully reverses a previous DataCandy transaction.

APIEndpoint
DataCandy - Complete Cancelhttps://test.api.payfacto.cloud/v1/datacandy/completeCancel
πŸ“‹

  DataCandy Return Codes

The following table lists the acquirer return codes returned by DataCandy.

CodeDescription
1Transaction is valid and was accepted.
101The card specified by the CID parameter is invalid or does not exist.
102The amount specified by the AMT parameter is invalid or not properly formatted.
103The card you are trying to activate is already active.
104The card specified by the CID parameter is expired and no longer active.
105The account's balance is insufficient.
106A value used for authentication could not be validated, such as MID or MPW.
107The transaction specified by the TCR parameter could not be found.
108The transaction is invalid.
109The transaction could not be processed because the actual date/time is outside the allowed transaction processing window.
111The transaction specified by the TCR parameter is not a lock transaction or is the wrong lock transaction.
140The program specified by the PRG parameter is invalid.
141The API version specified by the VER parameter isn't supported.
142Your request did not include the mandatory VER parameter.
143The API version specified by the VER parameter is in an invalid format. It should be in the YYYY-MM-DD form. For example: 2010-01-06.
144The language specified by the LNG parameter isn't supported.
146The language you specified in the LNG parameter is in an invalid format.
216The invoice number specified in the INV parameter has already been used for this merchant in the current year. This error is only triggered when the client requires this configuration.
222The invoice number specified in the INV parameter is invalid.
223Card locked due to repeated failed PIN attempts.
225Invalid action/transaction type.
228Invalid workstation number.
229Invalid waiter/employee number.
233Invalid PIN number. The PIN number was sent but does not match.
234Empty PIN. A PIN number was required but none was sent.
235Invalid DB PIN value. The server-side PIN value is invalid (e.g. non-numerical PIN).
260Sample error message: card is valid from 2016-06-01 to 2016-12-31. This error is triggered when the start date of the card is in the future.
262Too many attached accounts found. Unable to determine which one to use.
264The account is inactive.
265The account is expired.
268The target account's balance exceeds the maximum possible balance.
270The card can't be activated due to invalid expiry setting.
277The source account does not support balance transfers.
279The amount specified in the AMT parameter is lower than the minimum increment amount.
280The amount specified in the AMT parameter is lower than the minimum activation amount.
281Emptying cards is not supported at the specified location.
282The source account's balance exceeds the maximum amount supported at the specified location.
283The account does not support locking.
284The account is currently locked.
285The account is not currently locked.
286The amount specified in the AMT parameter is higher than the maximum increment amount.
287The amount specified in the AMT parameter is higher than the maximum activation amount.
288Emptying cards is not supported for the account type of the given card.
322The maximum number of redemptions allowed at this merchant has been met.
500There is an internal problem with the DataCandy API, which you cannot resolve. Retry the request. If the problem persists, contact us.