Merge pull request #2560 from matrix-org/travis/clarify-txn-send

Fix the response format of the `/send` endpoint
This commit is contained in:
Travis Ralston 2020-05-21 07:46:08 -06:00 committed by GitHub
commit ab62b6293c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 28 additions and 37 deletions

View file

@ -77,14 +77,7 @@ paths:
The result of processing the transaction. The server is to use this response even in The result of processing the transaction. The server is to use this response even in
the event of one or more PDUs failing to be processed. the event of one or more PDUs failing to be processed.
schema: schema:
type: array type: object
minItems: 2
maxItems: 2
items:
- type: integer
description: The value ``200``.
example: 200
- type: object
title: PDU Processing Results title: PDU Processing Results
description: The results for the processing of each PDU in the transaction. description: The results for the processing of each PDU in the transaction.
properties: properties:
@ -106,9 +99,7 @@ paths:
example: "You are not allowed to send a message to this room." example: "You are not allowed to send a message to this room."
required: ['pdus'] required: ['pdus']
examples: examples:
application/json: [ application/json: {
200,
{
"pdus": { "pdus": {
"$successful_event:example.org": {}, "$successful_event:example.org": {},
"$failed_event:example.org": { "$failed_event:example.org": {
@ -116,4 +107,3 @@ paths:
} }
} }
} }
]

View file

@ -0,0 +1 @@
Fix the response format of the ``/send`` endpoint.