Send a Message
Use this request to send a message to the system.
This request sends a message to the service where it is stored in the message queue. This does not guarantee that the message will be processed, only that it has been added to the queue.
The response returns a unique message ID and the location header for the sent message.
To send a message, use a POST operation and the following URL, specifying the Message ID in the body:
{service_uri}/api/v1/messages
where {service_uri} is the service's URI.
For example:
curl --request POST \
--url https://e-invoicing-message.vertexcloud.com/api/v1/messages \
--header 'accept: application/json' \
--header 'content-type: application/json' \
--data '
{
"message": "dGhpcyBpcyBhIGJhc2UgNjQgY29kZWQgbWVzc2FnZSAtIENVIERvcmlzIEJ1cmRh"
}
'
Details
| Type | Value |
|---|---|
| Endpoint | /api/v1/messages |
| Method | POST |
| API Reference Topic | Send a message |
Body Parameter
The following field is required:
| Parameter | Detail | Description |
|---|---|---|
message | String | Message content, specified in Base64 format. |
Example
Request
The following is a request for the "dGhpcyBpcyBhIGJhc2UgNjQgY29kZWQgbWVzc2FnZSAtIENVIERvcmlzIEJ1cmRh" message:
curl --request POST \
--url https://e-invoicing-message.example.net/api/v1/messages \
--header 'accept: application/json' \
--header 'content-type: application/json' \
--data '
{
"message": "dGhpcyBpcyBhIGJhc2UgNjQgY29kZWQgbWVzc2FnZSAtIENVIERvcmlzIEJ1cmRh"
}
'
Response
200
A successful request returns a Message ID:
{
"messageId": "70d4ec9d-33f9-47c1-94fc-91938dad7612"
}
Updated about 19 hours ago
