webapp/src/graphql/query/chats-load.ts
2022-11-24 09:52:31 +03:00

29 lines
450 B
TypeScript

import { gql } from '@urql/core'
export default gql`
query GetChatsQuery($limit: Int, $offset: Int) {
loadChats(limit: $limit, offset: $offset) {
error
chats {
id
messages {
id
body
author
}
admins {
slug
name
}
users {
slug
name
}
unread
description
updatedAt
}
}
}
`