You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

54 lines
1.7 KiB
YAML

get:
tags:
- chats
summary: get chat room messages
description: This operation retrieves the messages in a chat room, with pagination options accepted
parameters:
- in: path
name: roomId
schema:
type: number
required: true
description: a valid chat room id
example: 1
- in: query
name: uid
schema:
type: number
description: a valid user id
example: 1
- in: query
name: start
schema:
type: number
description: At which chat message index to start returning messages from
example: 0
responses:
'200':
description: Messages successfully retrieved
content:
application/json:
schema:
type: object
properties:
status:
$ref: ../../../components/schemas/Status.yaml#/Status
response:
type: object
properties:
messages:
type: array
items:
allOf:
- $ref: ../../../components/schemas/Chats.yaml#/MessageObject
- type: object
description: Optional properties that may or may not be present (except for `messageId`, which is always present, and is only here as a hack to pass validation)
properties:
messageId:
type: number
index:
type: number
isOwner:
type: boolean
required:
- messageId