v1

latestOpenAPI 3.0.1GPL v3.02026-07-175524.4 KB
Batch

Utility endpoint to allow submitting multiple independent requests at once.

This is used, for example, to poll multiple rooms on the same server for updates in a single query rather than needing to make multiple requests for each room. No guarantee is made as to the order in which sub-requests are processed; use the /sequence instead if you need that. For contained subrequests that specify a body (i.e. POST or PUT requests) exactly one of json, b64, or bytes must be provided with the request body.

post/batch

Request body

methodstring required

The request method, typically GET for batched requests, though other methods are also permitted.

pathstring required

The request path, e.g. /room/123/messages/since/45678

headersobject

Dict of HTTP headers for the subrequest. Optional.

jsonobject

Nested json structure containing a json body for a POST/PUT request. Exclusive of b64 and bytes.

b64string byte

Byte data for the body for a POST/PUT request. Exclusive of json and bytes

bytesstring binary

Optional binary body, as raw octets. Exclusive of b64 and json. Not recommended when using json unless the data happens to be mostly safe ascii

Response

Batch jobs completed. Note that 200 only means the batch was processed; for individual sub-requests see the relevant sub-response code. The returned array returns responses in exactly the same order as the request's list of sub-requests (regardless of the actual order jobs were processed).

codeinteger required

HTTP response code for the subrequest (e.g. 200, 404, etc.)

content-typestring required

HTTP content-type of the subrequest response (e.g. application/json)