Skip to content

Initiate a POS transaction (legacy)

Request

The /pos-transactions endpoint enables the initiation of instore transactions, supporting various transaction methods, including card and alternative payments.

Bodyapplication/json

Initiate a transaction

credentialsobject

Credentials used for authentication. This is only to be used when processing transactions to the PXP ANYpay platform.

merchantstring, <= 20 charactersrequired

A unique identifier assigned by PXP to represent a merchant entity, such as a store, hotel, or website, within the payment processing system. This identifier is crucial for routing transactions to the correct merchant account, ensuring accurate processing, settlement, and reporting. Merchants receive this value upon registration or integration with PXP, and it must be included in transaction requests to identify the merchant for whom the transaction is being processed.

Example:"MERCHANT-1"
sitestring, <= 20 charactersrequired

The unique site identifier associated with the transaction. This could represent a physical location, website, or any other distinct entity where the transaction occurs. The value for this field is generated by PXP.

Example:"SITE-1"
pointOfInteractionobject

The pointOfInteraction object captures detailed information about the device and environment where a card present transaction takes place. It includes various attributes that help identify and describe the capabilities and configurations of the point of sale (POS) device.

merchantTransactionIdstring, <= 50 charactersrequired

Represents a unique transaction reference assigned by you, the merchant, to identify individual transactions. This identifier serves as a primary means of communication regarding the transaction status between you and PXP. It is essential to maintain uniqueness for each transaction, ensuring accurate tracking and communication throughout the transaction lifecycle.

Example:"This_is_my_merchant_transaction_id"
merchantTransactionDatestring, (date-time)required

Specifies the date and time when the transaction was initiated by the merchant. This timestamp is crucial for tracking the transaction throughout its lifecycle and for chronological order analysis. The date and time format follows the ISO 8601 standard, ensuring consistency and ease of interpretation in global contexts. It facilitates the accurate and precise logging of transaction initiation times, aiding in transaction management and reconciliation processes between the merchant and PXP.

Example:"2021-10-27 08:51:02.826445+00:00"
amountsobjectrequired

Details of the amount including transaction, gratuity, and service charge values and its associated currency. Note that gratuity and serviceCharge cannot be sent together.

transactionMethodobjectrequired

The transaction method provides comprehensive details about the intent, capture method, and origin of a transaction.

curl -i -X POST \
  https://api-services.pxp.io/api/v1/pos-transactions/legacy \
  -H 'Content-Type: application/json' \
  -d '{
    "pointOfInteraction": {
      "pointOfSaleId": "POS-1",
      "language": "EN",
      "storeAndForwardType": "None",
      "invokeKeyed": false
    },
    "merchant": "MERCHANT-1",
    "site": "SITE-1",
    "merchantTransactionId": "This_is_my_merchant_transaction_id",
    "merchantTransactionDate": "2024-01-27 08:51:02.826445+00:00",
    "amounts": {
      "transaction": 30.32,
      "currencyCode": "EUR"
    },
    "transactionMethod": {
      "intent": "Purchase",
      "entryType": "Instore",
      "fundingType": "Card"
    }
  }'

Responses

Successful Response

Bodyapplication/json
statestring

The current state of the transaction.

Enum:"Authorised""Captured""Cancelled""Error""Refused"
Example:"Authorised"
stateDataobject(stateData)

Key value pair for various state data. Learn more about how this works.

Example:
{ "code": "CRD000", "message": "Approved" }
approvalCodestring^[A-Z]

A unique identifier code provided by the authorizing entity, indicating approval or reference for the transaction. This code typically consists of alphanumeric characters, starting with an uppercase letter, and serves as a key reference for authorisation verification.

Example:"A123456"
merchantTransactionDatestring, (date-time)

Specifies the date and time when the transaction was initiated by the merchant. This timestamp is crucial for tracking the transaction throughout its lifecycle and for chronological order analysis. The date and time format follows the ISO 8601 standard, ensuring consistency and ease of interpretation in global contexts. It facilitates the accurate and precise logging of transaction initiation times, aiding in transaction management and reconciliation processes between the merchant and PXP.

Example:"2021-10-27 08:51:02.826445+00:00"
merchantTransactionIdstring, <= 50 characters

Represents a unique transaction reference assigned by you, the merchant, to identify individual transactions. This identifier serves as a primary means of communication regarding the transaction status between you and PXP. It is essential to maintain uniqueness for each transaction, ensuring accurate tracking and communication throughout the transaction lifecycle.

Example:"This_is_my_merchant_transaction_id"
systemTransactionIdstring, [ 36 .. 36 ]^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]...

The system transaction Id is a unique identifier generated by PXP for each transaction. It serves as a reference for tracking and querying transactions within the PXP system. This Id is crucial for performing modifications or querying transaction details.

Example:"1ed768bb-e88a-4636-91ae-67927ccbb02b"
providerTransactionIdstring

A unique identifier assigned by the financial service provider for the transaction. It facilitates tracking, reconciliation, and support processes.

fundingDataobject

Funding data specifying the payment method used for the transaction. It includes essential information about a card involved in a transaction, such as its scheme, payment account reference, and token IDs. Additionally, it provides verification results for enhanced security, such as CVC and AVS checks, enabling you to ensure transaction integrity and mitigate fraud risks efficiently. This object is returned if the transactionMethod.fundingType is card or schemeToken.

Response
{ "state": "Authorised", "approvalCode": "123456", "merchantTransactionDate": "2024-01-27 08:51:02.826445+00:00", "merchantTransactionId": "This_is_my_merchant_transaction_id", "systemTransactionId": "1ed768bb-e88a-4636-91ae-67927ccbb02b", "providerTransactionId": "1ed768bb-e88a-4636-91ae-67927ccbb02b", "fundingData": { "cardScheme": "Visa", "gatewayTokenId": "1ed768bb-e88a-4636-91ae-67927ccbb02b", "providerResponse": {} }, "amounts": { "gratuity": 0 } }