Get Message

Get
/api/v1/chat.getMessage

Get a single chat message. You must have permission to access the room where the message resides.

Changelog

Version Description
0.47.0 Added
Header parameters
X-Auth-Token
stringRequired

The authToken of the authenticated user.

ExampleRScctEHSmLGZGywfIhWyRpyofhKOiMoUIpimhvheU3f
X-User-Id
stringRequired

The userId of the authenticated user.

ExamplerbAXPnMktTFbNpwtJ
Query parameters
msgId
stringRequired

The message ID.

Example7aDSXtjMA3KPLxLjt
Responses
200

OK

Success
{
  "message": {
    "_id": "CeXwh5eBbdrtvnqG6",
    "rid": "agh2Sucgb54RQ8dDo",
    "msg": "s",
    "ts": "2018-10-05T13:48:21.616Z",
    "u": {
      "_id": "KPkEYwKKBKZnEEPpt",
      "username": "marc.pow",
      "name": "Marc Pow"
    },
    "_updatedAt": "2018-10-05T13:48:49.535Z",
    "reactions": {
      ":frowning2:": {
        "usernames": [
          "marcos.defendi"
        ]
      }
    },
    "mentions": [],
    "channels": [],
    "starred": {
      "_id": "KPkEYwKKBKZnEEPpt"
    }
  },
  "count": 2,
  "offset": 0,
  "total": 2,
  "success": true
}
Expand All
object
message
object
_id
string
rid
string
msg
string
alias
string
ts
string
u
object
_id
string
username
string
name
string
_updatedAt
string
reactions
object
:frowning2:
object
usernames
Array of string
string
mentions
Array of object
object
channels
Array of object
object
starred
object
_id
string
t
string
groupable
boolean
success
boolean
400

Bad Request

Example 1
{
  "success": false,
  "error": "The \"msgId\" query parameter must be provided."
}
object
success
boolean
error
string
401

Unauthorized

Authorization Error
{
  "status": "error",
  "message": "You must be logged in to do this."
}
object
status
string
message
string