TriggerTransaction

The TriggerTransaction endpoint is used to initiate user interaction with the physical terminal. It sends a wake-up signal to the specified device. The request should contain a value that Nayax will use to authorize (Pre-Authorization) or charge (Pre-Selection) the consumer’s payment card.

  • If the Pre-Authorization flow is implemented, the authorization value can be managed and retrieved from Nayax Core.
  • In case the Pre-Selection flow is implemented, a request with a missing amount will return an error.

Request

The integrator sends a POST request to the /spark/TriggerTransaction endpoint. The body parameters need to be as the ones in the example below:

{
  "SparkTransactionId": "12c7cec2-c690-4425-9a1f-db0db60e2d8c",
  "TerminalId": "0434334921100366",
  "TerminalIdType": 1,
  "Amount": 15.00,
  "PosDisplay": ";Charging Station:3;Day:30.52p;Night:9p;Standing charge:52.18p/day; Off-peak:12:30-04:30;",
  "TransactionId": "external-session-id-001"
}

Request Parameters

The table below describes the parameters of the request:

FieldTypeRequiredDescription
SparkTransactionIdStringYesUnique session ID received from Spark during authentication
TerminalIdStringYesID of the target terminal
TerminalIdTypeIntegerYesDefines the ID type used. 1 for HW Serial, 2 for Nayax Machine ID
AmountNumberYesThe amount to be pre-authorized (e.g., 15.00)
PosDisplayStringNoCustom message to show on the terminal display (semicolon-delimited format). See PosDisplay Format to learn how to format your message.
TransactionIdStringYesA unique external transaction/session ID used by the integrator

Response

A successful response will return the following body:


{
 "SparkTransactionId": "12c7cec2-c690-4425-9a1f-db0db60e2d8c",
 "Status": {
 "Verdict": "Approved",
 "ErrorDescription": " No Errors "
 }
}

Response Parameters

The table below describes the parameters of the response:

FieldTypeDescription
SparkTransactionIdStringEchoes the transaction ID from the request
StatusObjectContains the resulting verdict and an optional error description
Status.VerdictStringResult of the request (Approved, Rejected, etc.)
Status.ErrorDescriptionStringProvides a human-readable description of any errors that occurred, or indicates No Errors for a successful request.