refactor(webapi)!: avoid u64/i64 usage in types except timestamp

We do not need that many big numbers yet. This should simplify client
implementation without native u64 (eg. JavaScript).

Also put a hard limit on `unseen_cnt` query.
This commit is contained in:
oxalica 2024-09-21 15:12:17 -04:00
parent ad3e422902
commit a7f31e5fad
3 changed files with 19 additions and 18 deletions

View file

@ -506,7 +506,7 @@ components:
attrs:
description: Room attributes bitset, see `RoomAttrs`.
type: integer
format: int64
format: int32
last_msg:
$ref: '#/components/schemas/WithMsgId-Signed-Chat'
last_seen_cid:
@ -517,10 +517,10 @@ components:
The number of unseen messages. Only available for
GET `/room?filter=unseen`.
type: integer
format: uint64
format: uint32
member_permission:
type: integer
format: int64
format: int32
peer_user:
type: string
description: |
@ -536,7 +536,7 @@ components:
type: string
attrs:
type: integer
format: int64
format: int32
RoomMsgs:
type: object
@ -644,7 +644,7 @@ components:
type: string
permission:
type: integer
format: uint64
format: int32
user:
type: string