import gql from 'graphql-tag';

export const NOTIFICATIONS = gql`
  query Notifications($input: NotificationsInput!) {
    notifications(input: $input) {
      notifications {
        created
        deliveries {
          channelType
          created
          id
          notificationChannelId
          resultMessage
          sentTo
          status
          updated
        }
        id
        message
        recipientId
        regardingType
        subject
        type
        updated
      }
      pageInfo {
        hasNextPage
        nextPage
        totalCount
      }
    }
  }
`;

export const NOTIFICATION_DETAILS = gql`
  query NotificationDetails($input: DetailInput!) {
    notificationDetails(input: $input) {
      htmlBody
    }
  }
`;
