Sale End Notification

Cortina uses the SaleEndNotificationcommand to notify the integrator about the completion of the transaction request with the Cortina payment provider.

Request

Nayax's servers send a POST request to your configured SaleEndNotificationendpoint, which would be of the following format:

(customer's URL)/Cortina/SaleEndNotification

The payload includes the following details:

{
  "BasicInfo": {
    "TransactionId": "N99O4XURDQYJZIK4OTCAWF1RHHA40TZWVCRB",
    "NayaxTransactionId": 3584697384,
    "Amount": 5,
    "CurrencyCode": "ILS",
    "CurrencyNumeric": "376",
    "SiteId": 1,
    "MachineAuTime": "071221132914",
    "TimeoutMS": 15000,
    "IsProductSelected": true,
    "PaymentMethodID": 1,
    "BillingProviderId": 1,
    "AuditNumber": 342,
    "NayaxRRN": "111111",
    "IsDeferredAuthorization": true,
    "AgeLimitation": 18,
    "IsSoftDeclineCompletion": true,
    "TransitElement": {
      "TransitTransactionType": 1,
      "DenyListIndication": 0
    }
  },
  "PaymentInfo": {
    "SrvTranId": "3584697388",
    "AuthCode": "333333",
    "AuthAmount": 5.5,
    "SettAmount": 5.5,
    "RRN": "111111",
    "Token": "string",
    "AuthDateTime": "071221133300",
    "SettDateTime": "071221133330",
    "TraceNumber": "4444",
    "AuthSource": "string",
    "AdditionalData": "string",
    "IsGatewayTimeout": false,
    "ProviderExternalData": "string",
    "InitiateTranReference": 11223344,
    "IsRevalueCard": false
  },
  "DynamicURL": "string",
  "CustomData": {
    "DirectActor": "String",
    "Operator": "String",
    "Distributor": "String",
    "Actor": "String",
    "Machine": "String",
    "SoftDecline": "String"
  }
}

Request Parameters

The table below describes all the parameters of the request:

Field

Type

Required

Description

BasicInfo

TransactionId

String(36)

Yes

The unique identifier for this transaction.

If /StartSession has been used then this will echo the transaction Id encrypted in 'TranIDCipher'.
If /StartSession was not Used - Nayax Engine shall generate this Value.

NayaxTransactionId

Int(64)

Yes

Nayax Internal Unique identifier for the transaction which will be echoed in further requests.

Amount

Double

Yes

Decimal (max 3 digits for cents)
The amount of the payment Example: 1 cent = 0.01, 20 cents = 0.20

  • Note: Currencies with no Decimal Place shall be represented as double as well.
    Example: 234 JYN = 234.0.

CurrencyCode

String(3)

Yes

Currency according to ISO4217 Attribute format: Alpha-3.

CurrencyNumeric

String(3)

Yes

Currency according to ISO4217 Attribute format: Numeric-3.

SiteId

Int(16)

No

Region of the Nayax server.

MachineAuTime

String

No

Machine Authorization Timestamp

TimeoutMS

Int(32)

No

Nayax Server T/O configuration, in milliseconds

IsProductSelected

Bool

No

indication if the product was pre-selected

PaymentMethodID

Int(32)

No

Nayax identifier of the payment provider

BillingProviderId

Int(32)

No

Nayax identifier of the billing provider

AuditNumber

Int(64)

No

For Nayax internal use only.

NayaxRRN

String

No

Reference to generate Nayax Number, Used as External Transaction Identification for external parties (Usually Card schemes, or App service providers).
From support perspective - It is highly recommended that this ID shall be the one visible to the end consumer/Card holder and the card's Issuer (e.g. Bank) or Application service provider (e.g. Alipay, WeChat).
If none of the above is applicable, the Integrator shall generate an additional String.

  • This Value shall be echoed in the /Inquiry request.

IsDeferredAuthorization

Bool

No

Further information is unavailable.

AgeLimitation

Int(16)

No

Minimum age required to allow the transaction.

IsSoftDeclineCompletion

Bool

No

Further information is unavailable.

TransitElement inside BasicInfo

TransitTransactionType

Int(32)

No

Enum: 1 2 3 7

1 - Prefunded

2 - Realtime Authorization

3 - Post-Authorization
Aggregated Transaction

7 - Debt Recovery

TransitElement inside BasicInfo

DenyListIndication

Int(32)

No

Enum: 0 1 2

0 - unknown/ no effect

1 - Decline will cause consumer
to be added to the deny list

2 - Approval shall cause the consumer to be removed from deny list.

PaymentInfo

SrvTranId

String

No

The Integrator's internal transaction id.

Conditional, only if /StartSession was not Used.

If /StartSession was used, this should be either empty or Echo the Transaction ID sent in the request.

AuthCode

String(40)

No

External (usually Card issuer's) Authorization Code

AuthAmount

Double

No

The original amount requested in /Authorization requested.

SettAmount

Double

No

The original amount requested in /Settlement or /Sale process.

RRN

String

No

Reference Retrieval Number, Used as External Transaction Identification for external parties (Usually Card schemes)
From support perspective - It is highly recommended that this ID shall be the one visible to the end consumer/Card holder.

Token

String(256)

No

A unique token for the transaction. For Internal Nayax use only

AuthDateTime

String

No

The date time string of when the /Authorization took place Format: ddMMyyHHmmss

SettDateTime

Double

No

Irrelevant for the Authorization command.

TraceNumber

String

No

Trace number. For Internal Nayax use only

AuthSource

String(5)

No

For Internal Nayax use only

AdditionalData

String

No

String in JSON format.
Contact Nayax TPOC on order define.

IsGatewayTimeout

Bool

No

Was there was a gateway timeout (valid in response)

ProviderExternalData

String

No

String in JSON format.

InitiateTranReference

Int(64)

No

Conditional, in case of re-attempt of using a prepaid loyalty card on a terminal in a given transaction, this field will reflect which transaction (Nayax Transaction ID) this attempt originally belongs to.

IsRevalueCard

Bool

No

Indication if card is allowed revalue

BasicInfo

DynamicURL

String

No

Actor level URL configuration

CustomData

DirectActor

String

No

Direct actor custom data (String in json format)

Operator

String

No

Operator custom data (String in json format)

Distributor

String

No

Distributor custom data (String in json format)

Actor

String

No

Actor custom data (String in json format)

Machine

String

No

Machine custom data (String in json format)

SoftDecline

String

No

Soft Decline custom data (String in json format)

Response

The SaleEndNotification Response that the customer's payment method would send to Nayax's servers.
The payload should look as follows:

{
  "Status": {
    "Verdict": "string",
    "Code": 0,
    "StatusMessage": "string",
    "CustomDeclineCode": "string"
  }
}

Request Parameters

The table below describes all the parameters of the request:

Field

Type

Required

Description

TranIDCipher

String(36)

Yes

The Integrator Generates transaction ID of 36 Chars (or 288 bits). The Integrator then appends the char = and RandomNumber to create the ciphertext of 64 chars Format TransactionId=RandomNumber The integrator encrypts the ciphertexts with the Secret Token in AES ECB. The AES key will be the last (right most) 256 bits (or 32 chars) of the Secret Token the matches the TokenID provided in the request. Nayax will AES ECB decrypt and extract transaction id The transaction Id value will then be used for all further requests.

Information regarding how to generate the TranIDCipher (via encrypting the token alongside the Random Number and the customer's Transaction ID can be reviewed under Start Session authentication process

Verdict inside Status

String

Yes

Const string.
Status of the request ('Approved'/'Declined')

Code inside Status

Int(32)

No

Conditional - Only if verdict value is declined.

Valid decline codes (must be a code from this list):


1 - Insufficient funds


2 - Transaction ID unknown


3 - Cardholder exceeded daily / weekly / monthly transaction count limit


4 - Cardholder exceeded transaction amount limit


5 - Suspected Fraud


6 - General system failure


7 - Invalid amount


8 - Request cannot be parsed (format error)


9 - Transaction not allowed to cardholder


40 - For Nayax internal use only.


990 - CertificateFileName not found


991 - Failed to decipher message body


992 - Timeout exception


994 - Card Brand not supported


996 - Transaction ID Unknown / Duplicate Transaction ID (Start Session Error)


997 - Missing mandatory parameters


998 - Validation / request cannot be parsed


999 - General exception


1010 - Public Key Certificate not found


1011 - Method not Implemented

StatusMessage inside Status

String(255)

No

Transaction status message free text field / additional varying data

CustomDeclineCode inside Status

String

No

This field is used for specifying a custom decline code (i.e. Soft Decline or Switch Interface). The value might be the same as the acquirer's response code or composed by other data.