AffiniPay

Link a merchant's existing Affinipay account with its account ID and API secret key to process credit card transactions through Preczn.

Overview

Preczn routes card and ACH payments to each merchant's own AffiniPay account, and can import a linked merchant's past AffiniPay transactions. Each merchant brings its own AffiniPay credentials, and Preczn doesn't board merchants to AffiniPay.

Merchant onboarding

CapabilitySupportedDetails
Merchant onboarding✗ No
Onboarding through the API✗ No
Merchant import✗ No

Transactions

CapabilitySupportedDetails
Card transactions✓ YesJump to Processing transactions
Apple Pay transactions✗ No
Google Pay transactions✗ No
ACH transactions✓ YesJump to ACH payments
Transaction import✓ YesJump to Transaction import

Tokens and lending

CapabilitySupportedDetails
Token migration✗ No
Lending✗ No

Configuring the platform connection

In the Dashboard, go to Connections → Add Connection and select AffiniPay. AffiniPay takes no platform credentials, so you add credentials to each merchant instead. For the general steps, see Add a connection to your platform.

Dashboard fieldRequiredDescription
Import Merchant Transaction HistoryNoImports a linked merchant's past transactions. See the Transaction import section.

Click Add Connection to save. Preczn doesn't check anything with AffiniPay at this step.


Linking existing credentials

Each merchant processes with its own AffiniPay account, so you link that account's credentials to the merchant's AffiniPay connection. A merchant has one connection for each processor. For a business with two AffiniPay accounts, see Use two accounts at one provider.

You need the following values from the merchant's AffiniPay account:

  • Secret key: the API secret key. It's required.
  • Account ID: the AffiniPay account that processes card payments. The account also sets whether the merchant transacts in US or Canadian dollars.
  • ACH account ID: the AffiniPay account that processes ACH payments. Add it only if the merchant accepts ACH. See the ACH payments section.

Choose how you'll link the account. Select the Dashboard tab or the API tab.

  1. In Merchant Vault, open the merchant.
  2. Under Connections, select AffiniPay.
  3. Click Edit, and enter the values in Account ID, ACH Account ID, and Secret Key.
  4. Click Verify connection. The drawer shows Credentials successfully verified if AffiniPay accepts them, and Verification failed otherwise.
  5. Click Save changes.

Preczn checks the secret key with AffiniPay, and checks that the account ID and the ACH account ID belong to that secret key. When you save the credentials, Preczn also subscribes to transaction webhooks on the merchant's AffiniPay account. See the Synchronous and asynchronous outcomes section.

To link many merchants at once, fill in the AffiniPay_account_id, AffiniPay_ach_account_id, and AffiniPay_secret_key columns of the merchant import CSV file. See Import merchants.


Processing transactions

Preczn processes the following transaction types through AffiniPay. For each type, see Choose a transaction type.

  • Cards: sale, auth, capture, refund, void, and verify. A verify sends a $1.00 authorization, and Preczn voids it when AffiniPay approves it. Captures and refunds can be partial.
  • ACH: sales. See the ACH payments section.

AffiniPay doesn't process Apple Pay or Google Pay payments through Preczn.

Synchronous and asynchronous outcomes

Results arrive as follows:

  • Card sale, auth, capture, and verify return Approved or Declined right away.
  • Voids return Approved when AffiniPay voids the transaction.
  • Refunds return Pending when AffiniPay accepts them.
  • ACH sales return Pending when AffiniPay accepts them.

AffiniPay reports the final result of each refund and ACH sale through the webhooks Preczn subscribed to when you linked the merchant. Preczn then sets the transaction to Approved or Declined and sends you the change as a transaction webhook. See Handle synchronous and asynchronous results.

If AffiniPay rejects a request for a reason other than a decline, Preczn returns Error with AffiniPay's message.

ACH payments

AffiniPay processes ACH payments through a separate account. Preczn sends each ACH payment to the merchant's ACH account ID, and rejects an ACH sale with a 422 error when the merchant's AffiniPay connection has no ACH account ID. For the shared ACH rules, see ACH payments.

Data sent to AffiniPay

AffiniPay shows custom fields on its payment receipts. Preczn sends the following values:

  • Invoice and description. Preczn sends invoice as the Invoice custom field and description as the Notes custom field, on a sale, auth, verify, refund, or void.
  • Metadata. Preczn sends each metadata key and value as its own custom field, on the same transaction types.
  • Order. Preczn sends order as the AffiniPay reference, cut to 128 characters.
  • Not sent. Preczn doesn't send dynamic descriptors, card-on-file flags, or Level II and Level III tax and line items to AffiniPay.

AVS and CVV

A card sale, auth, verify, or capture returns AVS and CVV results when AffiniPay includes them. Send the billing address and cvv to get a meaningful result. See Card verification results.

AffiniPay can require a CVV on every charge, depending on the merchant account's settings. See the FAQ section.

Transaction import

Preczn imports a merchant's past AffiniPay transactions when you link the merchant's credentials while Import Merchant Transaction History is on. For how import works, see Import transactions from a connection.

The import covers the last six months. Card and ACH transactions arrive as sales, refunds, and voids. Preczn skips AffiniPay credit transactions. Preczn sets each imported transaction's status from its AffiniPay status:

AffiniPay statusPreczn status
Completed, Authorized, or VoidedApproved
FailedDeclined
PendingPending
Any other statusError

Testing in test mode

In Test mode, Preczn sends payments to the AffiniPay sandbox. Link each test merchant with credentials from an AffiniPay test account. Use the Preczn test cards and bank accounts, which Preczn maps to the values AffiniPay expects. See Test data and Live vs. test mode.


FAQ

Why do recurring card payments fail with "Card code cannot be blank"?

The merchant's AffiniPay account requires a CVV on every charge, and a payment on a stored card has no CVV. AffiniPay sends the message, and Preczn returns it with an Error status. A Preczn token doesn't bypass the requirement, and no Preczn field turns the check off.

Ask AffiniPay support to change two settings on the merchant's AffiniPay account: remove cvv from required_payment_fields, and set cvv_policy to OPTIONAL. AffiniPay then still checks the CVV on payments that include one. These settings belong to each merchant account, so confirm them for every merchant you link.

Why does a payment fail with "A payment token is required for this operation"?

AffiniPay sends this message, and Preczn returns it with an Error status. It doesn't refer to the Preczn token in your request. The most common cause is a secret key that no longer authorizes the merchant's account ID, such as a key from a different AffiniPay application. Get both values from AffiniPay again and link them. See the Linking existing credentials section. If the credentials are current, ask AffiniPay whether the account can accept card data through its API.

Can one AffiniPay connection process both US and Canadian dollars?

No. The AffiniPay account ID sets the currency. To process in the other currency, link the merchant with the account ID that AffiniPay set up for that currency.

Why did an ACH payment fail with a 422 error?

The merchant's AffiniPay connection has no ACH account ID. Add it, as described in the Linking existing credentials section.

What do I give AffiniPay support when a rejected charge has no transaction ID?

AffiniPay creates no transaction when it rejects a charge, so there's no AffiniPay transaction ID. Contact Preczn support with the Preczn transaction ID. Preczn keeps AffiniPay's response, including its request ID, for AffiniPay support.


Did this page help you?