v1

latestOpenAPI 3.0.2Apache 2.02026-07-17292234.0 KB
Message

Submit a new message to the system.

Push a new message to the systems outbound message queue. The system will continuously attempt to send the message until it is either fully transmitted, or the send deadline is expired.

post/api/v1/messages

Query parameters

reply_timeoutinteger

Amount of seconds to wait for a reply to this message to come in. If not set, the system won't wait for a reply and return the ID of the message, which can be used later. If set, the system will wait for at most the given amount of seconds for a reply to come in. If a reply arrives, it is returned to the client. If not, the message ID is returned for later use.

Request body

topicstring byte

An optional message topic

payloadstring byte

The message to send, base64 encoded

Example request

{
  "dst": {
    "ip": "449:abcd:0123:defa::1"
  },
  "topic": "hpV+",
  "payload": "xuV+"
}

Response

We received a reply within the specified timeout

idstring hex

Id of the message, hex encoded

srcIpstring ipv6

Sender overlay IP address

srcPkstring hex

Sender public key, hex encoded

dstIpstring ipv6

Receiver overlay IP address

dstPkstring hex

Receiver public key, hex encoded. This is the public key of the system

topicstring byte

An optional message topic

payloadstring byte

The message payload, encoded in standard alphabet base64

Example response

{
  "id": "0123456789abcdef",
  "srcIp": "449:abcd:0123:defa::1",
  "srcPk": "fedbca9876543210fedbca9876543210fedbca9876543210fedbca9876543210",
  "dstIp": "34f:b680:ba6e:7ced:355f:346f:d97b:eecb",
  "dstPk": "02468ace13579bdf02468ace13579bdf02468ace13579bdf02468ace13579bdf",
  "topic": "hpV+",
  "payload": "xuV+"
}