Create message
Messages
POST message
Endpoint
POST /api/v1/chats/:chat_id/messages
Parameters
Name | Description |
---|---|
message[text] | Message text |
message[files] | Array of files signed ids |
Request
Route
POST /api/v1/chats/770/messages
Headers
Accept: application/json
Content-Type: application/json
Authorization: Bearer eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiIxNDgzIiwic2NwIjoidXNlciIsImF1ZCI6bnVsbCwiaWF0IjoxNzYwOTUwNDY4LCJleHAiOjE3NjM1NDI0NjgsImp0aSI6ImE5MTBiMzdhLTRlOWEtNDg0Yi1iZmY1LTMyOTJhZmNjNGJjOCJ9.vvLFhfahuaZhg0z7cyxF__gcLfURfJ5tyMUdSnQmK8k
Host: example.org
Cookie:
Body
{
"chat_id": 770,
"message": {
"text": "Recusandae doloremque accusantium expedita.",
"files": [
"eyJfcmFpbHMiOnsiZGF0YSI6MjUsInB1ciI6ImJsb2JfaWQifX0=--701f03b91322c932fe58855a3e15e5ecbc2b1c88"
]
}
}
Response
Simulated Response
Status
403
Headers
x-frame-options: SAMEORIGIN
x-xss-protection: 0
x-content-type-options: nosniff
x-permitted-cross-domain-policies: none
referrer-policy: strict-origin-when-cross-origin
content-type: application/json; charset=utf-8
vary: Accept, Origin
cache-control: no-cache
x-request-id: e0c7e9cc-597c-48c7-9cb7-e8cfd6464c8d
x-runtime: 0.010276
content-length: 94
Body
{
"status": "Forbidden",
"message": "not allowed to message? this Chat",
"code": 403,
"backtrace": ""
}