Skip to content

armgit / macro

Public Imported from GitHub
0

Macro is a unified workspace for teams: email, chat, docs, tasks, agents, calls, and CRM — @-linked together with shared AI memory.

817 B
Raw Blame
# The badge can gain a channel that was absent from its unread-filtered page.
# Select only identity so inserting it never replays other notification states.
query ChannelUnreadMembershipCacheWrite($input: SoupInput!) {
	user {
		id
		soup(input: $input) {
			items { __typename id }
		}
	}
}

# Local cache entrypoint only: subscription roots are not persisted as query
# membership. Write the channel relationship without rewriting its other fields.
subscription ChannelUnreadCacheWrite {
	soupUpdates {
		__typename
		... on SoupUpdated {
			item {
				__typename
				id
				... on GraphqlSoupChannel {
					unreadNotifications: notifications(
						filter: {
							states: [UNSEEN]
							topLevelMessagesOnly: true
						}
						limit: 1
					) {
						id
						state
						createdAt
					}
				}
			}
		}
	}
}