public void OnInputRequest(InputRequestData requestData, IInputReceiver inputReceiver) { Console.WriteLine($"TransactionListener OnInputRequest InputRequestData: {requestData} , IInputReceiver: {inputReceiver}"); // Get information about the request for input from the terminal InputRequestType inputType = requestData.InputType; DeviceType inputDevice = requestData.DeviceType; string inputDefault = requestData.DefaultInputString; int? inputTimeout = requestData.TimeoutInSeconds; int? inputMinLength = requestData.MinLength; int? inputMaxLength = requestData.MaxLength; DisplayOutput output = requestData.DisplayOutput; DeviceType outputDevice = output.DeviceType; DisplayContent outputContent = output.Content; if (outputContent.Format == DisplayFormatType.Text) { ContentText contentText = outputContent.Text; string plainTextDisplayMessage = contentText.PlainText; } // Return user input inputReceiver.InputText("1234"); //see chapter "Input requests" for details }