/ frontend / graphql / notifications.gql
notifications.gql
 1  query UserNotifications($maxItems: Int = 20) {
 2    notifications(pagination: {limit: $maxItems}, sort: "createdAt:DESC") {
 3      data {
 4        id
 5        attributes {
 6          type
 7          read
 8          createdAt
 9          event {
10            data {
11              id
12              attributes {
13                name
14                uuid
15              }
16            }
17          }
18        }
19      }
20    }
21  }
22  
23  mutation readNotifications($id: ID) {
24    readNotifications(id: $id) {
25      data {
26        id
27        attributes {
28          type
29          read
30        }
31      }
32    }
33  }