PayFacto API - v1.0 - Response Parameters

PayFacto API - v1.0 - Response Parameters

PayFacto API - v1.0 - Response Parameters

Complete reference for all fields returned in PayFacto API v1.0 responses. Parameters are grouped by functional category. Not every field is returned on every endpoint — refer to individual endpoint articles for which fields are always returned vs conditionally returned.

ℹ️

All PayFacto API responses are returned as JSON key-value pairs. Always check returnCode (or recurReturnCode for recurring endpoints) first to determine whether the operation succeeded before reading other fields. A value of 00 indicates success.

  Result Codes & Messages

Always check these fields first. A returnCode of 00 indicates success. Any other value means the operation failed or was declined.

ParameterType / LengthExampleDescription
returnCodeAlphanumeric / 400Transaction result code. 00=approved/success. All other values indicate a failure or decline. Refer to the Return Code Index for the complete list. Always check this field first.
recurReturnCodeAlphanumeric / 400Return code specific to recurring billing endpoints (/v1/recur/*). 00=operation completed successfully. Check this instead of returnCode on all recurring endpoints.
transactionReturnCodeAlphanumeric / 400Return code of a transaction triggered as part of a recurring billing operation, if applicable.
receiptDispAlphanumeric / 32APPROVED-THANK-YOUPayFacto-generated receipt message. Can be used to produce a customer receipt. Example: APPROVED-THANK-YOU.
terminalDispAlphanumeric / 24APPROVEDTransaction message displayed on the terminal, POS system, or payment page.
errorDescriptionAlphanumeric / 50CARD DECLINEDHuman-readable description of the failure reason. Only present on non-approved transactions.
📋

  Transaction Identifiers

Store transactionNumber and invoiceNumber from every successful transaction response — they are required for Void and Refund operations. Display authorizationNumber on every customer receipt.

ParameterType / LengthExampleDescription
transactionNumberNumeric / 12000111222333Unique PayFacto gateway transaction identifier. Store this value — it is required for Void and Refund operations.
authorizationNumberAlphanumeric / 8APPROV99Authorization code issued on successful approval. Mandatory to display on all customer receipts.
referenceNumberAlphanumeric / 100000000001Reference number issued on successful transaction completion.
sequenceNumberAlphanumeric / 12000011112222Sequence number generated by the banking acquirer.
batchNumberNumeric / 40001Batch number used by the terminal when the transaction was processed. Can be used when generating client receipts.
terminalInvoiceNumberNumeric / 12Zero-paddedTerminal-assigned invoice number. Only returned for terminal (Semi-Integrated) transactions.
bankTerminalNumberAlphanumeric / 800000001Terminal identifier at the banking acquirer that processed the transaction.
serverNumberAlphanumeric / 40001Identifies the PayFacto Network server that processed the transaction.
terminalNumberNumeric / 500001Identifies the terminal in the PayFacto Network used to process the transaction.
invoiceNumberAlphanumeric / 12INV000000001Echo of the request InvoiceNumber.
TUIDNumeric / 24212400667337208477009882PayFacto switch (EPOS) unique transaction number. Store this value — it can be used with the Refund with TUID endpoint.
secureIDAlphanumeric / 35Alphanumeric tokenSecure session identifier for redirect or PayFacto Objects sessions. Used when retrieving the transaction result via Get Response.
🕐

  Timing

Three separate date/time fields are returned. timeStamp reflects the PayFacto server clock; trxDate and trxTime reflect the banking acquirer clock and may differ.

ParameterType / LengthExampleDescription
timeStampAlphanumeric / 1720240515-14300100Date and time the transaction was processed on the PayFacto payment server. Format: YYYYMMDD-HHMMSSCC. May differ from acquirer date/time fields.
trxDateNumeric / 805152024Transaction date at the banking acquirer. Format: MMDDYYYY. May differ from timeStamp.
trxTimeNumeric / 6143001Transaction time at the banking acquirer. Format: HHMMSS. May differ from timeStamp.
🔄

  Transaction Type

These fields identify what kind of transaction was processed and how the card was read.

ParameterType / LengthExampleDescription
trxCodeAlphanumeric / 200Transaction type code. 00=Purchase, 01=Pre-Authorization, 02=Completion, 03=Refund, 04=Void Purchase, 05=Void Refund, 06=Void Completion, 07=Force Post, 08=Verify Account, 50=Refund Without Card, 51=Standalone Completion, 52=Purchase with Token, 53=Refund with Token, 54=Pre-Authorization with Token, 98=Recover, 99=Cash.
trxTypeAlphanumeric / 1C, D, FCard type used by the customer. C=Credit card, D=Debit card, F=Fidelity/Gift card.
trxMethodAlphanumeric / 3D@1Summarizes the overall transaction method. First character describes how card was read: D=Dipped (chip), S=Swiped, T=Tap (contactless), M=Manual entry. Third character: 1=System authorized. Example: D@1=chip card, authorized. T@1=contactless, authorized.
accountTypeAlphanumeric / 1C, SAccount type used for the transaction. C=Chequing, S=Savings.
💳

  Card Data

Card data is always returned masked for PCI compliance. The token field is only present when tokenization is enabled on the merchant account.

ParameterType / LengthExampleDescription
cardNumberAlphanumeric / 40MaskedEcho of the request CardNumber, returned masked (e.g. 411111XXXXXX1111).
cardTypeAlphanumeric / 1V, M, A, etc.Card brand determined by the network. A=Amex, D=Debit, F=Datacandy, I=Diners, J=JCB, M=Mastercard, O=Discover, V=Visa.
expirationDateNumeric / 41226Echo of the request ExpirationDate. Format: MMYY.
holderNameAlphanumeric / 50Free textCardholder name entered on a hosted payment page. Only returned when captured via a hosted session.
tokenAlphanumeric / 35Alphanumeric tokenToken representing the cardholder's card for future token-based transactions. Only returned when tokenization is enabled for the merchant.
💵

  Amounts

All monetary amounts are returned as integers in the smallest currency unit, zero-padded left to 11 digits. Optional amount fields (tip, tax, cashback, surcharge) are only present when applicable.

ParameterType / LengthExampleDescription
amountNumeric / 1100000010000Echo of the transaction amount. Zero-padded left.
tipAmountNumeric / 1100000000200Tip amount added at the terminal. Zero-padded left. Only returned when a tip was captured.
taxAmountNumeric / 1100000000374Tax amount of the financial transaction. Zero-padded left. Only returned when taxAmount was provided in the request.
cashbackAmountNumeric / 1100000002000Cash-back amount of the financial transaction. Zero-padded left. Only returned when cash-back was applied.
surchargeAmountNumeric / 1100000000050Surcharge amount applied to the transaction. Zero-padded left. Only returned when a surcharge was applied.
🔒

  Verification Results

Verification result fields are only returned when the corresponding data was sent in the request. Your application is responsible for evaluating these results and deciding whether to proceed with the transaction.

ParameterType / LengthExampleDescription
avsStatusAlphanumeric / 1M, N, Z, A, UAddress Verification Service result. Only returned when CardHolderAddress or CardHolderPostalCode were sent. M=Address and ZIP/Postal match, N=Neither match, Z=ZIP/Postal matches only, A=Address matches only, U=AVS unavailable or not supported.
cvv2Cvc2StatusAlphanumeric / 1M, N, blankCVD verification result. Only returned when Cvv2Cvc2Number was sent. M=Matches, N=Does not match, blank=Unknown.
threeDSStatusAlphanumeric / 1P, F, N3-D Secure verification result. Only returned when 3-D Secure data was sent. P=Passed validation, F=Failed validation, N=Not validated or not supported.
cvmResultsAlphanumeric / 6030000Cardholder Verification Method result from chip transactions. Print a signature line on the receipt if the first 2 digits are 03, 05, 43, 45, 1E, or 5E.
💰

  EMV Chip

EMV fields are only returned for chip card transactions. They contain the raw EMV data required for receipt printing and chargeback documentation.

ParameterType / LengthExampleDescription
emvAIDAlphanumeric / 32AID: A000000277EMV Application Identifier. Only returned for chip (EMV) transactions.
emvLabelAlphanumeric / 16Visa, InteracEMV application label. Human-readable name of the chip application used. Only returned for chip (EMV) transactions.
emvTCAlphanumeric / 40TC: A2E51243D4C7E551EMV Transaction Cryptogram. Only returned for chip (EMV) transactions.
emvTSIAlphanumeric / 4F800EMV Transaction Status Information. Only returned for chip (EMV) transactions.
emvTVRAlphanumeric / 10Hex stringEMV Terminal Verification Result. Only returned for chip (EMV) transactions.
🔁

  Echo Fields

These fields echo back values sent in the request. They are useful for correlating responses to requests in asynchronous or high-volume environments.

ParameterType / LengthExampleDescription
companyNumberNumeric / 512345Echo of the request CompanyNumber.
merchantNumberNumeric / 853400000Echo of the request MerchantNumber.
customerNumberAlphanumeric / 8CLIENT12Echo of the request CustomerNumber. Only returned when provided in the request.
operatorIdAlphanumeric / 8USER0001Echo of the request OperatorID.
languageCodeAlphanumeric / 1F, EEcho of the request LanguageCode.
emailAlphanumeric / 250test@test.comEmail address entered on a hosted payment page. Only returned when captured via a hosted session.
demoModeAlphanumeric / 4trueIndicates the terminal is operating in demo mode. Value is true when active. Only returned when the terminal is in demo mode.
🏠

  Interac Online (IOP)

These fields are returned only when the payment was guaranteed via Interac Online. Both fields must be displayed on the merchant's confirmation page.

ParameterType / LengthExampleDescription
iopIssuerConfirmationNumberAlphanumeric / 1–15AlphanumericIssuer Confirmation Number from Interac Online (Acxsys). Only returned when payment was guaranteed. Must be displayed on the merchant's confirmation screen.
iopIssuerNameAlphanumeric / 1–30Free textIssuer's name from Interac Online. Should be in the language the customer used for online banking. Only returned when payment was guaranteed. Display on the merchant's confirmation screen.

  Signature Capture

The captured signature image is returned Base64-encoded. Decode and render it on the merchant receipt when the cvmResults field indicates a signature is required.

ParameterType / LengthExampleDescription
signatureBase64PngAlphanumeric (Base64) / ~700 bytesBase64-encoded PNGThe captured customer signature as a Base64-encoded PNG image (310×100 px). Since PNG is compressed, the exact size varies — typically around 700 bytes encoded. Only returned when a signature was captured at the terminal.
🔄

  Recurring Billing

These fields are returned by recurring billing endpoints (/v1/recur/*). Use recurReturnCode (not returnCode) to determine success on these endpoints.

ParameterType / LengthExampleDescription
idNumeric / 12Zero-paddedUnique identifier of the subscriber, subscription, or session returned by recurring operations.
subscriptionIdNumeric / 12Zero-paddedIdentifier of the subscription associated with the operation.
clientAlphanumeric / 8CLIENT12Subscriber (customer) number associated with the recurring record.
nameAlphanumeric / 50Free textSubscriber name on file.
emailAlphanumeric / 240test@test.comSubscriber email address on file.
accountNumberAlphanumeric / 50ACC00012345Merchant reference number for the subscriber account.
descriptionAlphanumeric / 50Free textMerchant reference description for the subscription.
currencyCodeAlphanumeric / 3CAD, USDCurrency of the subscription.
frequencyNumeric / 203Frequency code of the subscription. See the Frequency field in the Request Parameters reference for all codes.
numberOfPaymentsNumeric / 3012Number of payments scheduled or remaining for the subscription.
startDateNumeric / 820240101Start date of the subscription. Format: YYYYMMDD.
endDateNumeric / 820251231End date of the subscription, or 8 spaces if open-ended. Format: YYYYMMDD.
lastInvoiceDateNumeric / 820240501Date the last invoice was processed. Format: YYYYMMDD.
nextInvoiceDateNumeric / 820240601Date the next invoice is scheduled. Format: YYYYMMDD.
statusNumeric / 201, 50Current status of the subscriber, subscription, or invoice. Client: 01=Active, 02=Expired, 03=No card set. Invoice: 01=Active, 02=In process, 03=Processed, 04=Completed, 05=Error, 06=Suspended, 07=Expired, 08=Without card. Subscription: 01=Active, 50=Pause.
tokenAlphanumeric / 35Alphanumeric tokenToken linked to the subscriber's card. Used for future recurring charges, token-based purchases, and refunds.
recurReturnCodeAlphanumeric / 400Return code of the recurring billing operation. 00=success. Check this before inspecting other response fields on recurring endpoints.
transactionReturnCodeAlphanumeric / 400Return code of any transaction triggered as part of the recurring billing operation.
🎁

  DataCandy (Gift / Loyalty)

These fields are returned by DataCandy gift and loyalty card endpoints. Store transactionConfirmationNumber from every DataCandy response — it is required for commit, cancel, and unlock operations.

ParameterType / LengthExampleDescription
balanceAmountNumeric / 12000000001000Balance in dollars available on the DataCandy card. Example: 000000001000 = $10.00
remainingAmountNumeric / 12000000000500Amount remaining on the transaction after a partial redemption.
totalBalanceAmountNumeric / 12000000002000Total balance on the card including all locked amounts.
transactionConfirmationNumberNumeric / VariableAnyDataCandy transaction confirmation number. Must be stored — required for committing, cancelling, or unlocking the card.
accountTypeNumberNumeric / 1NumericDataCandy account type number. Refer to DataCandy documentation for possible values.
startDateAlphanumeric / 102019-12-31DataCandy card start date (if later than activation date). Format: YYYY-MM-DD. Only returned when the card has a future start date.
picNumeric / 11 or 0DataCandy card profile completeness. {c('1')}=Complete, {c('0')}=Incomplete.
ctmString / 155Pipe-separatedConsumer-targeted message to print on the receipt. Each line separated by a pipe character. Example: Test123.