diff --git a/app/definitions/rest/v1/chat.ts b/app/definitions/rest/v1/chat.ts index 4a224c475..6b4253966 100644 --- a/app/definitions/rest/v1/chat.ts +++ b/app/definitions/rest/v1/chat.ts @@ -32,4 +32,11 @@ export type ChatEndpoints = { total: number; }>; }; + 'chat.delete': { + POST: (params: { msgId: string; roomId: string }) => { + _id: string; + ts: string; + message: Pick; + }; + }; }; diff --git a/app/lib/rocketchat/services/restApi.ts b/app/lib/rocketchat/services/restApi.ts index c15970cd6..5b27f610b 100644 --- a/app/lib/rocketchat/services/restApi.ts +++ b/app/lib/rocketchat/services/restApi.ts @@ -243,10 +243,8 @@ export const joinRoom = (roomId: string, joinCode: string | null, type: 'c' | 'p return sdk.post('channels.join', { roomId, joinCode }); }; -export const deleteMessage = (messageId: string, rid: string): any => +export const deleteMessage = (messageId: string, rid: string) => // RC 0.48.0 - // TODO: missing definitions from server - // @ts-ignore sdk.post('chat.delete', { msgId: messageId, roomId: rid }); export const markAsUnread = ({ messageId }: { messageId: string }) =>