@jsb188/graphql 1.1.8 → 1.1.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (122) hide show
  1. package/cache/config.ts +66 -42
  2. package/cache/index.test.ts +881 -0
  3. package/cache/index.ts +1815 -979
  4. package/cache/persist.ts +721 -0
  5. package/cache/store.ts +437 -0
  6. package/client/data-table-realtime-subscriptions.test.ts +740 -0
  7. package/client/data-table-realtime-subscriptions.ts +955 -0
  8. package/client/data-table-realtime.test.ts +792 -0
  9. package/client/data-table-realtime.ts +1218 -0
  10. package/client/fragment-realtime-sequence.ts +52 -0
  11. package/client/index.ts +4 -2
  12. package/client/open-sheet.ts +137 -0
  13. package/client/request-managed-session.test.ts +574 -0
  14. package/client/request-no-store.test.ts +157 -0
  15. package/client/request.ts +973 -143
  16. package/client/sse-ticket.test.ts +26 -0
  17. package/deno.lock +170 -0
  18. package/deno.test.json +10 -0
  19. package/drafts/index.ts +149 -0
  20. package/drafts/store.ts +397 -0
  21. package/gql/eagerQueryMap.ts +12 -0
  22. package/gql/fragments/accountAuthFragments.ts +5 -0
  23. package/gql/fragments/accountFragments.ts +1 -3
  24. package/gql/fragments/accountSessionFragments.ts +16 -0
  25. package/gql/fragments/agentDocFragments.ts +46 -0
  26. package/gql/fragments/agentMemoryFragments.ts +19 -0
  27. package/gql/fragments/aiChatFragments.ts +17 -0
  28. package/gql/fragments/billingFragments.ts +0 -11
  29. package/gql/fragments/campaignFragments.ts +277 -0
  30. package/gql/fragments/dataTableFragments.ts +102 -0
  31. package/gql/fragments/emailFragments.ts +36 -0
  32. package/gql/fragments/fieldDocFragments.ts +82 -0
  33. package/gql/fragments/inboundContactFragments.ts +15 -0
  34. package/gql/fragments/integrationFragments.ts +22 -0
  35. package/gql/fragments/logFragments.ts +33 -64
  36. package/gql/fragments/organizationFragments.ts +94 -21
  37. package/gql/fragments/scheduleFragments.ts +155 -0
  38. package/gql/fragments/sheetFragments.ts +675 -0
  39. package/gql/fragments/storageFragments.ts +21 -1
  40. package/gql/fragments/workflowFragments.ts +67 -0
  41. package/gql/mutations/accountMutations.ts +24 -4
  42. package/gql/mutations/agentDocMutations.ts +177 -0
  43. package/gql/mutations/agentMemoryMutations.ts +36 -0
  44. package/gql/mutations/aiChatMutations.ts +43 -3
  45. package/gql/mutations/authMutations.ts +160 -19
  46. package/gql/mutations/campaignMutations.ts +215 -0
  47. package/gql/mutations/dataTableMutations.ts +106 -0
  48. package/gql/mutations/fieldDocMutations.ts +24 -0
  49. package/gql/mutations/inboundContactMutations.ts +24 -0
  50. package/gql/mutations/index.ts +17 -8
  51. package/gql/mutations/integrationMutations.ts +25 -0
  52. package/gql/mutations/logMutations.ts +10 -19
  53. package/gql/mutations/organizationMutations.ts +160 -2
  54. package/gql/mutations/scheduleMutations.ts +423 -0
  55. package/gql/mutations/sheetMutations.ts +385 -0
  56. package/gql/mutations/storageMutations.ts +21 -2
  57. package/gql/mutations/workflowMutations.ts +42 -0
  58. package/gql/queries/agentDocQueries.ts +120 -0
  59. package/gql/queries/agentMemoryQueries.ts +22 -0
  60. package/gql/queries/aiChatQueries.ts +18 -2
  61. package/gql/queries/authQueries.ts +41 -0
  62. package/gql/queries/billingQueries.ts +24 -1
  63. package/gql/queries/campaignQueries.ts +127 -0
  64. package/gql/queries/dataTableQueries.ts +134 -0
  65. package/gql/queries/emailQueries.ts +96 -0
  66. package/gql/queries/fieldDocQueries.ts +158 -0
  67. package/gql/queries/inboundContactQueries.ts +40 -0
  68. package/gql/queries/index.ts +17 -6
  69. package/gql/queries/logQueries.ts +42 -32
  70. package/gql/queries/organizationQueries.ts +113 -8
  71. package/gql/queries/scheduleQueries.ts +315 -0
  72. package/gql/queries/sheetQueries.ts +383 -0
  73. package/gql/queries/storageQueries.ts +38 -0
  74. package/gql/queries/workflowQueries.ts +99 -0
  75. package/hooks/index.ts +2104 -860
  76. package/hooks/use-account-mtn.ts +91 -48
  77. package/hooks/use-agentDoc-mtn.ts +285 -0
  78. package/hooks/use-agentDoc-qry.ts +208 -0
  79. package/hooks/use-agentMemory-mtn.ts +73 -0
  80. package/hooks/use-agentMemory-qry.ts +44 -0
  81. package/hooks/use-aiChat-mtn.ts +248 -97
  82. package/hooks/use-aiChat-qry.ts +501 -191
  83. package/hooks/use-app-qry.ts +14 -11
  84. package/hooks/use-auth-mtn.ts +410 -256
  85. package/hooks/use-auth-qry.ts +51 -0
  86. package/hooks/use-campaign-mtn.ts +377 -0
  87. package/hooks/use-campaign-qry.ts +257 -0
  88. package/hooks/use-dataTable-mtn.ts +170 -0
  89. package/hooks/use-dataTable-qry.ts +996 -0
  90. package/hooks/use-email-qry.ts +227 -0
  91. package/hooks/use-fieldDoc-mtn.ts +50 -0
  92. package/hooks/use-fieldDoc-qry.ts +180 -0
  93. package/hooks/use-inboundContact-mtn.ts +34 -0
  94. package/hooks/use-inboundContact-qry.ts +96 -0
  95. package/hooks/use-integration-mtn.ts +77 -0
  96. package/hooks/use-integration-qry.ts +30 -0
  97. package/hooks/use-log-mtn.ts +77 -61
  98. package/hooks/use-log-qry.ts +99 -72
  99. package/hooks/use-organization-mtn.ts +409 -80
  100. package/hooks/use-organization-qry.ts +211 -92
  101. package/hooks/use-schedule-mtn.ts +416 -0
  102. package/hooks/use-schedule-qry.ts +157 -0
  103. package/hooks/use-sheet-mtn.ts +367 -0
  104. package/hooks/use-sheet-qry.ts +440 -0
  105. package/hooks/use-storage-mtn.ts +83 -42
  106. package/hooks/use-storage-qry.ts +104 -13
  107. package/hooks/use-workflow-mtn.ts +55 -0
  108. package/hooks/use-workflow-qry.ts +230 -0
  109. package/loaders/campaign.ts +137 -0
  110. package/package.json +94 -52
  111. package/sse.ts +158 -105
  112. package/tsconfig.json +13 -0
  113. package/types.d.ts +60 -29
  114. package/utils.ts +77 -50
  115. package/gql/fragments/actionFragments.ts +0 -16
  116. package/gql/fragments/productFragments.ts +0 -63
  117. package/gql/fragments/reportFragments.ts +0 -48
  118. package/gql/mutations/billingMutations.ts +0 -34
  119. package/gql/queries/productQueries.ts +0 -70
  120. package/gql/queries/reportQueries.ts +0 -66
  121. package/hooks/use-product-qry.ts +0 -109
  122. package/hooks/use-report-qry.ts +0 -69
@@ -0,0 +1,67 @@
1
+ export const workflowFragment = `fragment workflowFragment on Workflow {
2
+ id
3
+ organizationId
4
+ fieldDocId
5
+
6
+ kind
7
+ triggerType
8
+ logTypes
9
+
10
+ accountId
11
+ recipients {
12
+ accountId
13
+ name
14
+ phone
15
+ email
16
+ channels
17
+ }
18
+ cursor
19
+
20
+ title
21
+
22
+ steps {
23
+ iconName
24
+ label
25
+ value
26
+ }
27
+
28
+ schedule
29
+ scheduleInterval
30
+ active
31
+ status
32
+
33
+ startedAt
34
+ nextAt
35
+
36
+ createdAt
37
+ updatedAt
38
+ }`;
39
+
40
+ export const workflowRunFragment = `fragment workflowRunFragment on WorkflowRun {
41
+ id
42
+ workflowId
43
+ logId
44
+ cursor
45
+
46
+ runKey
47
+ iterations
48
+ progressReport
49
+ message
50
+ status
51
+
52
+ activeWait {
53
+ id
54
+ workflowRunId
55
+ name
56
+ phone
57
+ email
58
+ channel
59
+ expiresAt
60
+ resolvedAt
61
+ createdAt
62
+ }
63
+
64
+ scheduledDate
65
+ followUpAt
66
+ activityAt
67
+ }`;
@@ -1,15 +1,13 @@
1
1
  import { gql } from 'graphql-tag';
2
- import { accountFragment } from '../fragments/accountFragments';
2
+ import { accountFragment } from '../fragments/accountFragments.ts';
3
3
 
4
4
  export const editAccountMtn = gql`
5
5
  mutation editAccount (
6
- $accountId: GenericID
7
6
  $photoId: GenericID
8
7
  $profile: AccountProfileInput
9
8
  $settings: AccountSettingsInput
10
9
  ) {
11
10
  editAccount (
12
- accountId: $accountId
13
11
  photoId: $photoId
14
12
  profile: $profile
15
13
  settings: $settings
@@ -28,4 +26,26 @@ mutation requestChangeEmail (
28
26
  emailAddress: $emailAddress
29
27
  )
30
28
  }
31
- `;
29
+ `;
30
+
31
+ export const requestChangePhoneMtn = gql`
32
+ mutation requestChangePhone (
33
+ $phone: String!
34
+ ) {
35
+ requestChangePhone (
36
+ phone: $phone
37
+ )
38
+ }
39
+ `;
40
+
41
+ export const changePhoneMtn = gql`
42
+ mutation changePhone (
43
+ $code: String!
44
+ $phone: String!
45
+ ) {
46
+ changePhone (
47
+ code: $code
48
+ phone: $phone
49
+ )
50
+ }
51
+ `;
@@ -0,0 +1,177 @@
1
+ import { gql } from 'graphql-tag';
2
+ import { agentDocFragment } from '../fragments/agentDocFragments.ts';
3
+
4
+ export const createAgentDocMtn = gql`
5
+ mutation createAgentDoc (
6
+ $organizationId: GenericID!
7
+ $title: String
8
+ $folderId: GenericID
9
+ $position: Float
10
+ ) {
11
+ createAgentDoc (
12
+ organizationId: $organizationId
13
+ title: $title
14
+ folderId: $folderId
15
+ position: $position
16
+ )
17
+ }
18
+ `;
19
+
20
+ // NOTE: content is the noteDoc document serialized as JSON text (the caller
21
+ // must JSON.stringify the sanitized doc), and imageStorageIds carries every
22
+ // image storageId still present in the doc so the server can reconcile
23
+ // agent_doc_storage_rels against it.
24
+
25
+ export const updateAgentDocMtn = gql`
26
+ mutation updateAgentDoc (
27
+ $organizationId: GenericID!
28
+ $agentDocId: GenericID!
29
+ $title: String
30
+ $content: String
31
+ $folderId: GenericID
32
+ $imageStorageIds: [GenericID!]
33
+ ) {
34
+ updateAgentDoc (
35
+ organizationId: $organizationId
36
+ agentDocId: $agentDocId
37
+ title: $title
38
+ content: $content
39
+ folderId: $folderId
40
+ imageStorageIds: $imageStorageIds
41
+ ) {
42
+ ...agentDocFragment
43
+ }
44
+ }
45
+
46
+ ${agentDocFragment}
47
+ `;
48
+
49
+ export const deleteAgentDocMtn = gql`
50
+ mutation deleteAgentDoc (
51
+ $organizationId: GenericID!
52
+ $agentDocId: GenericID!
53
+ ) {
54
+ deleteAgentDoc (
55
+ organizationId: $organizationId
56
+ agentDocId: $agentDocId
57
+ )
58
+ }
59
+ `;
60
+
61
+ // NOTE: The selection is intentionally NOT agentDocFragment: the access
62
+ // record update returns the bare row (no rels attached), so selecting
63
+ // content/files here would merge rel-unfiltered content and an empty files
64
+ // list over the issuer's cached agentDoc fragment. Only the access-relevant
65
+ // fields update.
66
+
67
+ export const updateAgentDocAccessMtn = gql`
68
+ mutation updateAgentDocAccess (
69
+ $organizationId: GenericID!
70
+ $agentDocId: GenericID!
71
+ $access: DocAccessInput!
72
+ ) {
73
+ updateAgentDocAccess (
74
+ organizationId: $organizationId
75
+ agentDocId: $agentDocId
76
+ access: $access
77
+ ) {
78
+ id
79
+ organizationId
80
+
81
+ access {
82
+ team
83
+ public
84
+ network
85
+ }
86
+
87
+ updatedAt
88
+ }
89
+ }
90
+ `;
91
+
92
+ // NOTE: Same bare-row rule as updateAgentDocAccess: the settings update
93
+ // returns the row without rels attached, so only the settings-relevant
94
+ // fields are selected to keep the issuer's cached content/files intact.
95
+
96
+ export const updateAgentDocSettingsMtn = gql`
97
+ mutation updateAgentDocSettings (
98
+ $organizationId: GenericID!
99
+ $agentDocId: GenericID!
100
+ $settings: AgentDocSettingsInput!
101
+ ) {
102
+ updateAgentDocSettings (
103
+ organizationId: $organizationId
104
+ agentDocId: $agentDocId
105
+ settings: $settings
106
+ ) {
107
+ id
108
+ organizationId
109
+
110
+ settings {
111
+ aiCannotEdit
112
+ aiCannotRead
113
+ pinned
114
+ hiddenSurfaces
115
+ reviewBy
116
+ }
117
+
118
+ updatedAt
119
+ }
120
+ }
121
+ `;
122
+
123
+ export const createAgentDocFolderMtn = gql`
124
+ mutation createAgentDocFolder (
125
+ $organizationId: GenericID!
126
+ $name: String!
127
+ $position: Float
128
+ ) {
129
+ createAgentDocFolder (
130
+ organizationId: $organizationId
131
+ name: $name
132
+ position: $position
133
+ ) {
134
+ id
135
+ organizationId
136
+ name
137
+ position
138
+ createdAt
139
+ updatedAt
140
+ }
141
+ }
142
+ `;
143
+
144
+ export const updateAgentDocFolderMtn = gql`
145
+ mutation updateAgentDocFolder (
146
+ $organizationId: GenericID!
147
+ $folderId: GenericID!
148
+ $name: String
149
+ $position: Float
150
+ ) {
151
+ updateAgentDocFolder (
152
+ organizationId: $organizationId
153
+ folderId: $folderId
154
+ name: $name
155
+ position: $position
156
+ ) {
157
+ id
158
+ organizationId
159
+ name
160
+ position
161
+ createdAt
162
+ updatedAt
163
+ }
164
+ }
165
+ `;
166
+
167
+ export const deleteAgentDocFolderMtn = gql`
168
+ mutation deleteAgentDocFolder (
169
+ $organizationId: GenericID!
170
+ $folderId: GenericID!
171
+ ) {
172
+ deleteAgentDocFolder (
173
+ organizationId: $organizationId
174
+ folderId: $folderId
175
+ )
176
+ }
177
+ `;
@@ -0,0 +1,36 @@
1
+ import { gql } from 'graphql-tag';
2
+ import { agentMemoryFragment } from '../fragments/agentMemoryFragments.ts';
3
+
4
+ export const editAgentMemoryMtn = gql`
5
+ mutation editAgentMemory (
6
+ $organizationId: GenericID!
7
+ $agentMemoryId: GenericID!
8
+ $content: String
9
+ $permanent: Boolean
10
+ $status: AgentMemoryStatus
11
+ ) {
12
+ editAgentMemory (
13
+ organizationId: $organizationId
14
+ agentMemoryId: $agentMemoryId
15
+ content: $content
16
+ permanent: $permanent
17
+ status: $status
18
+ ) {
19
+ ...agentMemoryFragment
20
+ }
21
+ }
22
+
23
+ ${agentMemoryFragment}
24
+ `;
25
+
26
+ export const deleteAgentMemoryMtn = gql`
27
+ mutation deleteAgentMemory (
28
+ $organizationId: GenericID!
29
+ $agentMemoryId: GenericID!
30
+ ) {
31
+ deleteAgentMemory (
32
+ organizationId: $organizationId
33
+ agentMemoryId: $agentMemoryId
34
+ )
35
+ }
36
+ `;
@@ -1,14 +1,21 @@
1
1
  import { gql } from 'graphql-tag';
2
- import { aiChatFragment, aiChatMessageFragment } from '../fragments/aiChatFragments';
2
+ import {
3
+ aiChatFragment,
4
+ aiChatMessageFragment,
5
+ } from '../fragments/aiChatFragments.ts';
3
6
 
4
7
  export const startAIChatMtn = gql`
5
8
  mutation startAIChat (
6
9
  $organizationId: GenericID!
7
- $text: String!
10
+ $text: String
11
+ $attachments: [String!]
12
+ $clientRequestId: String
8
13
  ) {
9
14
  startAIChat (
10
15
  organizationId: $organizationId
11
16
  text: $text
17
+ attachments: $attachments
18
+ clientRequestId: $clientRequestId
12
19
  ) {
13
20
  sessionKey
14
21
  node {
@@ -21,18 +28,41 @@ mutation startAIChat (
21
28
  ${aiChatFragment}
22
29
  `;
23
30
 
31
+ export const editAIChatMtn = gql`
32
+ mutation editAIChat (
33
+ $aiChatId: GenericID!
34
+ $archived: Boolean
35
+ $summary: String
36
+ ) {
37
+ editAIChat (
38
+ aiChatId: $aiChatId
39
+ archived: $archived
40
+ summary: $summary
41
+ ) {
42
+ cursor
43
+ ...aiChatFragment
44
+ }
45
+ }
46
+
47
+ ${aiChatFragment}
48
+ `;
49
+
24
50
  export const sendAIChatMessageMtn = gql`
25
51
  mutation sendAIChatMessage (
26
52
  $aiChatId: GenericID!
27
53
  $organizationId: GenericID
28
54
  $variablesKey: String
29
- $text: String!
55
+ $text: String
56
+ $attachments: [String!]
57
+ $clientRequestId: String
30
58
  ) {
31
59
  sendAIChatMessage (
32
60
  aiChatId: $aiChatId
33
61
  organizationId: $organizationId
34
62
  variablesKey: $variablesKey
35
63
  text: $text
64
+ attachments: $attachments
65
+ clientRequestId: $clientRequestId
36
66
  ) {
37
67
  sessionKey
38
68
  node {
@@ -53,3 +83,13 @@ mutation stopAIChatMessage (
53
83
  )
54
84
  }
55
85
  `;
86
+
87
+ export const deleteAIChatMtn = gql`
88
+ mutation deleteAIChat (
89
+ $aiChatId: GenericID!
90
+ ) {
91
+ deleteAIChat (
92
+ aiChatId: $aiChatId
93
+ )
94
+ }
95
+ `;
@@ -1,10 +1,18 @@
1
1
  import { gql } from 'graphql-tag';
2
- import { accountAuthFragment } from '../fragments/accountAuthFragments';
3
- import { emailFragment, phoneFragment } from '../fragments/otherFragments';
4
- import { accountFragment } from '../fragments/accountFragments';
2
+ import { accountAuthFragment } from '../fragments/accountAuthFragments.ts';
3
+ import { accountFragment } from '../fragments/accountFragments.ts';
4
+ import { emailFragment, phoneFragment } from '../fragments/otherFragments.ts';
5
5
 
6
6
  const authenticateResultText = `...accountAuthFragment
7
7
 
8
+ managedSessionCredential {
9
+ accessToken
10
+ accessTokenExpiresAt
11
+ refreshToken
12
+ refreshTokenExpiresAt
13
+ sessionId
14
+ }
15
+
8
16
  account {
9
17
  ...accountFragment
10
18
 
@@ -34,7 +42,6 @@ mutation confirmPassword (
34
42
  }
35
43
  `;
36
44
 
37
-
38
45
  export const authenticateWithPasswordMtn = gql`
39
46
  mutation authenticateWithPassword (
40
47
  $identifier: String!
@@ -63,12 +70,126 @@ mutation authenticateWithToken (
63
70
  ${authenticateFragments}
64
71
  `;
65
72
 
73
+ export const authenticateManagedSessionMtn = gql`
74
+ mutation authenticateManagedSession (
75
+ $accessToken: Token!
76
+ $refreshToken: String!
77
+ $refreshAttemptId: String!
78
+ ) {
79
+ authenticateManagedSession (
80
+ accessToken: $accessToken
81
+ refreshToken: $refreshToken
82
+ refreshAttemptId: $refreshAttemptId
83
+ ) {
84
+ auth {
85
+ ${authenticateResultText}
86
+ }
87
+
88
+ credential {
89
+ accessToken
90
+ accessTokenExpiresAt
91
+ refreshToken
92
+ refreshTokenExpiresAt
93
+ sessionId
94
+ }
95
+ }
96
+ }
97
+ ${authenticateFragments}
98
+ `;
99
+
100
+ export const exchangeSessionBootstrapMtn = gql`
101
+ mutation exchangeSessionBootstrap (
102
+ $bootstrapToken: String!
103
+ ) {
104
+ exchangeSessionBootstrap (
105
+ bootstrapToken: $bootstrapToken
106
+ ) {
107
+ accessToken
108
+ accessTokenExpiresAt
109
+ refreshToken
110
+ refreshTokenExpiresAt
111
+ sessionId
112
+ }
113
+ }`;
114
+
115
+ export const refreshManagedSessionMtn = gql`
116
+ mutation refreshManagedSession (
117
+ $refreshToken: String!
118
+ $refreshAttemptId: String
119
+ ) {
120
+ refreshManagedSession (
121
+ refreshToken: $refreshToken
122
+ refreshAttemptId: $refreshAttemptId
123
+ ) {
124
+ accessToken
125
+ accessTokenExpiresAt
126
+ refreshToken
127
+ refreshTokenExpiresAt
128
+ sessionId
129
+ }
130
+ }`;
131
+
132
+ export const revokeManagedSessionMtn = gql`
133
+ mutation revokeManagedSession (
134
+ $refreshToken: String!
135
+ $accessToken: Token
136
+ ) {
137
+ revokeManagedSession (
138
+ refreshToken: $refreshToken
139
+ accessToken: $accessToken
140
+ )
141
+ }`;
142
+
143
+ export const revokeMyAccountSessionMtn = gql`
144
+ mutation revokeMyAccountSession (
145
+ $sessionId: GenericID!
146
+ ) {
147
+ revokeMyAccountSession (
148
+ sessionId: $sessionId
149
+ )
150
+ }`;
151
+
152
+ export const revokeMyOtherAccountSessionsMtn = gql`
153
+ mutation revokeMyOtherAccountSessions {
154
+ revokeMyOtherAccountSessions
155
+ }`;
156
+
157
+ export const revokeOrganizationMemberSessionMtn = gql`
158
+ mutation revokeOrganizationMemberSession (
159
+ $organizationId: GenericID!
160
+ $accountId: GenericID!
161
+ $sessionId: GenericID!
162
+ ) {
163
+ revokeOrganizationMemberSession (
164
+ organizationId: $organizationId
165
+ accountId: $accountId
166
+ sessionId: $sessionId
167
+ )
168
+ }`;
169
+
170
+ export const revokeOrganizationMemberSessionsMtn = gql`
171
+ mutation revokeOrganizationMemberSessions (
172
+ $organizationId: GenericID!
173
+ $accountId: GenericID!
174
+ ) {
175
+ revokeOrganizationMemberSessions (
176
+ organizationId: $organizationId
177
+ accountId: $accountId
178
+ )
179
+ }`;
180
+
66
181
  export const continueWithGoogleMtn = gql`
67
182
  mutation continueWithGoogle (
68
183
  $oauthToken: String!
184
+ $ssoConnectionId: GenericID
185
+ $formPublicId: String
186
+ $authenticateOnly: Boolean
69
187
  ) {
70
188
  continueWithGoogle (
71
189
  oauthToken: $oauthToken
190
+ ssoConnectionId: $ssoConnectionId
191
+ formPublicId: $formPublicId
192
+ authenticateOnly: $authenticateOnly
72
193
  ) {
73
194
  ${authenticateResultText}
74
195
  }
@@ -76,6 +197,41 @@ mutation continueWithGoogle (
76
197
  ${authenticateFragments}
77
198
  `;
78
199
 
200
+ export const continueWithMicrosoftMtn = gql`
201
+ mutation continueWithMicrosoft (
202
+ $idToken: String!
203
+ $ssoConnectionId: GenericID
204
+ $formPublicId: String
205
+ $authenticateOnly: Boolean
206
+ ) {
207
+ continueWithMicrosoft (
208
+ idToken: $idToken
209
+ ssoConnectionId: $ssoConnectionId
210
+ formPublicId: $formPublicId
211
+ authenticateOnly: $authenticateOnly
212
+ ) {
213
+ ${authenticateResultText}
214
+ }
215
+ }
216
+ ${authenticateFragments}
217
+ `;
218
+
219
+ export const getSsoLoginOptionsMtn = gql`
220
+ mutation getSsoLoginOptions (
221
+ $email: String!
222
+ ) {
223
+ getSsoLoginOptions (
224
+ email: $email
225
+ ) {
226
+ id
227
+ provider
228
+ organizationId
229
+ organizationName
230
+ microsoftTenantId
231
+ googleHostedDomain
232
+ }
233
+ }`;
234
+
79
235
  export const checkUsernameOrEmailMtn = gql`
80
236
  mutation checkUsernameOrEmail (
81
237
  $usernameOrEmail: String!
@@ -149,18 +305,3 @@ mutation signUpWithEmail (
149
305
  password: $password
150
306
  )
151
307
  }`;
152
-
153
- export const signInWithAppleMtn = gql`
154
- mutation signInWithApple (
155
- $code: String!
156
- $idToken: String!
157
- ) {
158
- signInWithApple (
159
- code: $code
160
- idToken: $idToken
161
- ) {
162
- ${authenticateResultText}
163
- }
164
- }
165
- ${authenticateFragments}
166
- `;