C# SDK Simulator

The Nayax Marshall SDK includes a simulator to help developers test and debug their device integration with the Nayax payment system. The simulator replicates the behaviour of the actual hardware and software interactions, allowing you to validate the vending process without needing physical hardware.

Simulator

When the C# SDK simulator is started on a terminal, its menu will look like this:

[0]: Start session 0
[1]: Cancel Session
[2]: Close Session 0
[3]: query sessions
[4]: reader state
[5]: cash sale
[6]: alert
[7]: ftp socket test
[8]: screen control
[9]: link stats
[10]: quit

Where:

CommandDescription
Start session 0Starts a session (a transaction).
Cancel SessionCancels the transaction as if you pressed Nayax's device X button.
Close Session 0Only relevant in multisession. Closes the session at the end of a transaction.
Query sessionsGives information about which sessions are currently open. This option is relevant from 4.0.0.22 and above.
Reader stateGives information about whether the reader is enabled (1)/disabled (0). This option is relevant from 4.0.0.22 and above.
Cash saleSimulates cash sale.
AlertSends an alert to the DCS. It can be seen in Last Alerts.
FTP socket testAllows the peripheral to use Nayax's modem for its own needs.
Screen controlTests the Display Control feature. Needs configurations in the DCS.
Link statsProvides information about the number of CRC errors, packet retransmissions, and communication losses.
QuitQuits the simulator program.

Transaction Flow Examples

Below are examples of the flow for each transaction type:

  1. Regular Transaction (Single Session):
    1. Start a session: with [0]: Start session.
    2. Present card, wait for authorization and "Thank you" screen.
  2. Multi-Session Transaction:
    1. Start a session with [0]: Start session 0.
    2. Start another session with [2]: Start session 1.
    3. Present card, wait for authorization and "Thank you" screen for each session.
    4. Close sessions individually using [1]: Close Session 0 and [4]: Close Session 1.
  3. Unsuccessful Transaction:
    1. Start a session with [0]: Start session.
    2. Present card, wait for authorization.
    3. Close the session with an error status: [1]: Close Session 0.

See Also