Method: echo
Stay organized with collections
Save and categorize content based on your preferences.
Echos back a string sent from the client.
If the endpoint encounters an error while processing the request, the response body from this endpoint should be of type ErrorResponse
.
An example request looks like:
{
"requestHeader": {
"protocolVersion": {
"major": 2
},
"requestId": "G1MQ0YERJ0Q7LPM",
"requestTimestamp": {
"epochMillis": "1481899949606"
},
"paymentIntegratorAccountId": "InvisiCashUSA_USD"
},
"clientMessage": "Client echo message"
}
An example success response looks like:
{
"responseHeader": {
"responseTimestamp": {
"epochMillis":"1481899950236"
}
},
"clientMessage": "Client echo message",
"serverMessage": "Debug ID 12345"
}
HTTP request
POST https://www.integratorhost.example.com/integrator-base-path/v2/echo
Request body
The request body contains data with the following structure:
JSON representation |
{
"requestHeader": {
object (RequestHeader )
},
"clientMessage": string
} |
Fields |
requestHeader |
object (RequestHeader )
REQUIRED: Common header for all requests.
|
clientMessage |
string
REQUIRED: Message to echo in the response.
|
Response body
This method supports multiple return types. For additional information about what 4XX or 5XX HTTP status code to return with an ErrorResponse
, consult the ErrorResponse
object and HTTP status codes documentation.
Possible response messages |
HTTP 200 Status |
object (EchoResponse )
|
HTTP 4XX / 5XX Status |
object (ErrorResponse )
|
EchoResponse
Response object for the echo method.
JSON representation |
{
"responseHeader": {
object (ResponseHeader )
},
"clientMessage": string,
"serverMessage": string
} |
Fields |
clientMessage |
string
REQUIRED: Message received in the request.
|
serverMessage |
string
OPTIONAL: Server message, independent of the clientMessage being echoed.
|
All rights reserved. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-02-28 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-02-28 UTC."],[[["\u003cp\u003eThis endpoint echos back a string sent from the client in the request body.\u003c/p\u003e\n"],["\u003cp\u003eThe request body must include a \u003ccode\u003erequestHeader\u003c/code\u003e object and a \u003ccode\u003eclientMessage\u003c/code\u003e string.\u003c/p\u003e\n"],["\u003cp\u003eThe response body, upon success, will contain a \u003ccode\u003eresponseHeader\u003c/code\u003e object, the echoed \u003ccode\u003eclientMessage\u003c/code\u003e, and an optional \u003ccode\u003eserverMessage\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eIn case of errors, the response will be of type \u003ccode\u003eErrorResponse\u003c/code\u003e with a corresponding 4XX or 5XX HTTP status code.\u003c/p\u003e\n"],["\u003cp\u003eThe HTTP method used for this endpoint is \u003ccode\u003ePOST\u003c/code\u003e and the URL is \u003ccode\u003ehttps://www.integratorhost.example.com/integrator-base-path/v2/echo\u003c/code\u003e.\u003c/p\u003e\n"]]],["The core functionality involves an echo service that receives a string message from a client via a `POST` request to the `/v2/echo` endpoint. The request must include a `requestHeader` and a `clientMessage` within the request body. A successful response (HTTP 200) mirrors the `clientMessage` back and may contain a `serverMessage` within an `EchoResponse`, including a `responseHeader`. Errors result in an `ErrorResponse` with a 4XX or 5XX status code.\n"],null,["# Method: echo\n\n- [HTTP request](#body.HTTP_TEMPLATE)\n- [Request body](#body.request_body)\n - [JSON representation](#body.request_body.SCHEMA_REPRESENTATION)\n- [Response body](#body.response_body)\n- [EchoResponse](#EchoResponse)\n - [JSON representation](#EchoResponse.SCHEMA_REPRESENTATION)\n\nEchos back a string sent from the client.\n\nIf the endpoint encounters an error while processing the request, the response body from this endpoint should be of type [`ErrorResponse`](/pay/banking-fop-v2/payment-integrator-banking-fop-api/ErrorResponse).\n\nAn example request looks like: \n\n\n {\n \"requestHeader\": {\n \"protocolVersion\": {\n \"major\": 2\n },\n \"requestId\": \"G1MQ0YERJ0Q7LPM\",\n \"requestTimestamp\": {\n \"epochMillis\": \"1481899949606\"\n },\n \"paymentIntegratorAccountId\": \"InvisiCashUSA_USD\"\n },\n \"clientMessage\": \"Client echo message\"\n }\n\nAn example success response looks like: \n\n\n {\n \"responseHeader\": {\n \"responseTimestamp\": {\n \"epochMillis\":\"1481899950236\"\n }\n },\n \"clientMessage\": \"Client echo message\",\n \"serverMessage\": \"Debug ID 12345\"\n }\n\n### HTTP request\n\n`POST https://www.integratorhost.example.com/integrator-base-path/v2/echo`\n\n### Request body\n\nThe request body contains data with the following structure:\n\n| JSON representation |\n|-----------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"requestHeader\": { object (/pay/banking-fop-v2/payment-integrator-banking-fop-api/RequestHeader) }, \"clientMessage\": string } ``` |\n\n| Fields ||\n|-----------------|--------------------------------------------------------------------------------------------------------------------------------------------------|\n| `requestHeader` | `object (`[RequestHeader](/pay/banking-fop-v2/payment-integrator-banking-fop-api/RequestHeader)`)` **REQUIRED**: Common header for all requests. |\n| `clientMessage` | `string` **REQUIRED**: Message to echo in the response. |\n\n### Response body\n\nThis method supports multiple return types. For additional information about what 4XX or 5XX HTTP status code to return with an `ErrorResponse`, consult the `ErrorResponse` object and [HTTP status codes documentation](/pay/banking-fop-v2/guides/connectivity/protocol-standards#http_status_codes).\n\n| Possible response messages ||\n|-----------------------|-------------------------------------------------------------------------------------------------------|\n| HTTP 200 Status | `object (`[EchoResponse](/pay/banking-fop-v2/payment-integrator-banking-fop-api/echo#EchoResponse)`)` |\n| HTTP 4XX / 5XX Status | `object (`[ErrorResponse](/pay/banking-fop-v2/payment-integrator-banking-fop-api/ErrorResponse)`)` |\n\nEchoResponse\n------------\n\nResponse object for the echo method.\n\n| JSON representation |\n|--------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"responseHeader\": { object (/pay/banking-fop-v2/payment-integrator-banking-fop-api/ResponseHeader) }, \"clientMessage\": string, \"serverMessage\": string } ``` |\n\n| Fields ||\n|------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------|\n| `responseHeader` | `object (`[ResponseHeader](/pay/banking-fop-v2/payment-integrator-banking-fop-api/ResponseHeader)`)` **REQUIRED**: Common header for all responses. |\n| `clientMessage` | `string` **REQUIRED**: Message received in the request. |\n| `serverMessage` | `string` **OPTIONAL** : Server message, independent of the `clientMessage` being echoed. |"]]