getUserInput

The getUserInput method prompts the user for a numeric or alphanumeric input on the payment terminal. This is typically used to collect an ID, amount, or any free-form entry required for the transaction or flow.

See also the abortGetUserInput method to cancel a pending input request.

Request

📘

JSON-RPC 2.0

All methods in TweezerComm follow a JSON-RPC 2.0 structure. See Get Startedfor more details on how the requests are structured and sent.

To invoke this method, set the method field to getUserInput, and include the service name and parameters as shown below.

{
    "jsonrpc":"2.0",
    "method":"getUserInput",
    "id":"1234567890",
    "params": [
            "device",{
                "title": "Main-Title",
                "subtitle": "Sub-Ttitle",
                "type": "numeric",
                "minLength": 2,
                "maxLength": 10,
                "timeout": 5
            }
        ]
}

Request Parameters

The table below describes the parameters of the request:

ParameterTypeDescription
titlestringThe main title is displayed to the user.
subtitlestringSubtitle is displayed below the title.
typestringType of input (numeric or alphanumeric).
minLengthintMinimum number of characters allowed.
maxLengthintMaximum number of characters allowed.
timeoutintTimeout in seconds before the request expires.

Response

A successful request will return the following response:

{
    "jsonrpc": "2.0",
    "id": "1234567890",
    "result": {
        "statusCode": 0,
        "data": "12456"
    }
}

Response Parameters

The table below describes the response parameters for this method:

ParameterTypeDescription
retailerNumberstringRetailer identifier.
nayaxSNstringNayax serial number.
isActiveDesstringActivation status.
emvConfigFileIdintEMV configuration file ID.
emvProviderintEMV provider ID.
paymentMethodsstringEnabled payment method codes.
cibusEnabledstringCibus support status.
cibusRestaurantIdintCibus restaurant ID.
cibusPosIdintCibus POS ID.
multipassEnabledstringMultipass support status.
multipassPosIdintMultipass POS ID.