@zeroin.earth/appwrite-graphql 0.15.12 → 0.16.0
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.
- package/README.md +12 -1
- package/dist/index.d.mts +43 -22
- package/dist/index.d.ts +43 -22
- package/dist/index.js +108 -104
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +54 -53
- package/dist/index.mjs.map +1 -1
- package/package.json +7 -5
package/dist/index.mjs
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { Client, Account, Databases, Functions, Graphql, ID } from 'appwrite';
|
|
1
|
+
import { atom, useAtomValue, useAtom } from 'jotai';
|
|
3
2
|
import { print } from 'graphql';
|
|
3
|
+
import { Client, Account, Databases, Graphql, ID } from 'appwrite';
|
|
4
4
|
import { QueryClient, useMutation, useQuery, useSuspenseQuery } from '@tanstack/react-query';
|
|
5
|
-
import {
|
|
5
|
+
import { useHydrateAtoms } from 'jotai/utils';
|
|
6
|
+
import { useEffect, useState } from 'react';
|
|
6
7
|
import { produce, castDraft } from 'immer';
|
|
7
8
|
|
|
8
|
-
function Qe(e,i){return i}var h={kind:"Document",definitions:[{kind:"FragmentDefinition",name:{kind:"Name",value:"Account_User"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"User"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"_id"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"email"}},{kind:"Field",name:{kind:"Name",value:"prefs"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"data"}}]}}]}}]},T={kind:"Document",definitions:[{kind:"FragmentDefinition",name:{kind:"Name",value:"Identity_Provider"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"Identity"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"_id"}},{kind:"Field",name:{kind:"Name",value:"userId"}},{kind:"Field",name:{kind:"Name",value:"provider"}}]}}]},V={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"AccountGet"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountGet"},selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"Account_User"}}]}}]}},{kind:"FragmentDefinition",name:{kind:"Name",value:"Account_User"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"User"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"_id"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"email"}},{kind:"Field",name:{kind:"Name",value:"prefs"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"data"}}]}}]}}]},q={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateAnonymousSession"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreateAnonymousSession"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"_id"}},{kind:"Field",name:{kind:"Name",value:"expire"}},{kind:"Field",name:{kind:"Name",value:"current"}}]}}]}}]},_={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateEmailToken"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"userId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"email"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"phrase"}},type:{kind:"NamedType",name:{kind:"Name",value:"Boolean"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreateEmailToken"},arguments:[{kind:"Argument",name:{kind:"Name",value:"userId"},value:{kind:"Variable",name:{kind:"Name",value:"userId"}}},{kind:"Argument",name:{kind:"Name",value:"email"},value:{kind:"Variable",name:{kind:"Name",value:"email"}}},{kind:"Argument",name:{kind:"Name",value:"phrase"},value:{kind:"Variable",name:{kind:"Name",value:"phrase"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"expire"}}]}}]}}]},F={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateJWT"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreateJWT"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"jwt"}}]}}]}}]},E={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateMagicURLToken"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"userId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"email"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"url"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"phrase"}},type:{kind:"NamedType",name:{kind:"Name",value:"Boolean"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreateMagicURLToken"},arguments:[{kind:"Argument",name:{kind:"Name",value:"userId"},value:{kind:"Variable",name:{kind:"Name",value:"userId"}}},{kind:"Argument",name:{kind:"Name",value:"email"},value:{kind:"Variable",name:{kind:"Name",value:"email"}}},{kind:"Argument",name:{kind:"Name",value:"url"},value:{kind:"Variable",name:{kind:"Name",value:"url"}}},{kind:"Argument",name:{kind:"Name",value:"phrase"},value:{kind:"Variable",name:{kind:"Name",value:"phrase"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"expire"}}]}}]}}]},P={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateMfaAuthenticator"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"type"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreateMfaAuthenticator"},arguments:[{kind:"Argument",name:{kind:"Name",value:"type"},value:{kind:"Variable",name:{kind:"Name",value:"type"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"secret"}},{kind:"Field",name:{kind:"Name",value:"uri"}}]}}]}}]},R={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateMfaChallenge"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"factor"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreateMfaChallenge"},arguments:[{kind:"Argument",name:{kind:"Name",value:"factor"},value:{kind:"Variable",name:{kind:"Name",value:"factor"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"userId"}},{kind:"Field",name:{kind:"Name",value:"expire"}}]}}]}}]},L={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateMfaRecoveryCodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreateMfaRecoveryCodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"recoveryCodes"}}]}}]}}]},Q={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreatePhoneToken"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"userId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"phone"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreatePhoneToken"},arguments:[{kind:"Argument",name:{kind:"Name",value:"userId"},value:{kind:"Variable",name:{kind:"Name",value:"userId"}}},{kind:"Argument",name:{kind:"Name",value:"phone"},value:{kind:"Variable",name:{kind:"Name",value:"phone"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"expire"}}]}}]}}]},G={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreatePhoneVerification"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreatePhoneVerification"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"expire"}}]}}]}}]},O={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateSession"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"userId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"secret"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreateSession"},arguments:[{kind:"Argument",name:{kind:"Name",value:"userId"},value:{kind:"Variable",name:{kind:"Name",value:"userId"}}},{kind:"Argument",name:{kind:"Name",value:"secret"},value:{kind:"Variable",name:{kind:"Name",value:"secret"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"userId"}},{kind:"Field",name:{kind:"Name",value:"expire"}},{kind:"Field",name:{kind:"Name",value:"current"}}]}}]}}]},J={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"DeleteIdentity"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"identityId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountDeleteIdentity"},arguments:[{kind:"Argument",name:{kind:"Name",value:"identityId"},value:{kind:"Variable",name:{kind:"Name",value:"identityId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"status"}}]}}]}}]},K={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"DeleteMfaAuthenticator"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"type"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"otp"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountDeleteMfaAuthenticator"},arguments:[{kind:"Argument",name:{kind:"Name",value:"type"},value:{kind:"Variable",name:{kind:"Name",value:"type"}}},{kind:"Argument",name:{kind:"Name",value:"otp"},value:{kind:"Variable",name:{kind:"Name",value:"otp"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"mfa"}}]}}]}}]},B={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"DeleteSession"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"sessionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountDeleteSession"},arguments:[{kind:"Argument",name:{kind:"Name",value:"sessionId"},value:{kind:"Variable",name:{kind:"Name",value:"sessionId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"status"}}]}}]}}]},W={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"DeleteSessions"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountDeleteSessions"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"status"}}]}}]}}]},j={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"GetMfaRecoveryCodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountGetMfaRecoveryCodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"recoveryCodes"}}]}}]}}]},z={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"GetPrefs"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountGetPrefs"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"data"}}]}}]}}]},X={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"GetSession"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"sessionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountGetSession"},arguments:[{kind:"Argument",name:{kind:"Name",value:"sessionId"},value:{kind:"Variable",name:{kind:"Name",value:"sessionId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"userId"}},{kind:"Field",name:{kind:"Name",value:"expire"}},{kind:"Field",name:{kind:"Name",value:"current"}}]}}]}}]},H={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"ListIdentities"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountListIdentities"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"total"}},{kind:"Field",name:{kind:"Name",value:"identities"},selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"Identity_Provider"}}]}}]}}]}},{kind:"FragmentDefinition",name:{kind:"Name",value:"Identity_Provider"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"Identity"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"_id"}},{kind:"Field",name:{kind:"Name",value:"userId"}},{kind:"Field",name:{kind:"Name",value:"provider"}}]}}]},Y={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"ListMfaFactors"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountListMfaFactors"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"totp"}},{kind:"Field",name:{kind:"Name",value:"phone"}},{kind:"Field",name:{kind:"Name",value:"email"}}]}}]}}]},Z={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"ListSessions"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountListSessions"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"sessions"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"_id"}},{kind:"Field",name:{kind:"Name",value:"_createdAt"}},{kind:"Field",name:{kind:"Name",value:"osName"}},{kind:"Field",name:{kind:"Name",value:"clientName"}}]}}]}}]}}]},ee={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateEmailPasswordSession"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"email"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"password"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreateEmailPasswordSession"},arguments:[{kind:"Argument",name:{kind:"Name",value:"email"},value:{kind:"Variable",name:{kind:"Name",value:"email"}}},{kind:"Argument",name:{kind:"Name",value:"password"},value:{kind:"Variable",name:{kind:"Name",value:"password"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"userId"}},{kind:"Field",name:{kind:"Name",value:"expire"}},{kind:"Field",name:{kind:"Name",value:"current"}}]}}]}}]},ne={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"ListLogs"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"queries"}},type:{kind:"ListType",type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountListLogs"},arguments:[{kind:"Argument",name:{kind:"Name",value:"queries"},value:{kind:"Variable",name:{kind:"Name",value:"queries"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"total"}},{kind:"Field",name:{kind:"Name",value:"logs"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"event"}},{kind:"Field",name:{kind:"Name",value:"userId"}},{kind:"Field",name:{kind:"Name",value:"userEmail"}},{kind:"Field",name:{kind:"Name",value:"userName"}},{kind:"Field",name:{kind:"Name",value:"mode"}},{kind:"Field",name:{kind:"Name",value:"ip"}},{kind:"Field",name:{kind:"Name",value:"time"}},{kind:"Field",name:{kind:"Name",value:"osCode"}},{kind:"Field",name:{kind:"Name",value:"osName"}},{kind:"Field",name:{kind:"Name",value:"osVersion"}},{kind:"Field",name:{kind:"Name",value:"clientType"}},{kind:"Field",name:{kind:"Name",value:"clientCode"}},{kind:"Field",name:{kind:"Name",value:"clientName"}},{kind:"Field",name:{kind:"Name",value:"clientVersion"}},{kind:"Field",name:{kind:"Name",value:"clientEngine"}},{kind:"Field",name:{kind:"Name",value:"clientEngineVersion"}},{kind:"Field",name:{kind:"Name",value:"deviceName"}},{kind:"Field",name:{kind:"Name",value:"deviceBrand"}},{kind:"Field",name:{kind:"Name",value:"deviceModel"}},{kind:"Field",name:{kind:"Name",value:"countryCode"}},{kind:"Field",name:{kind:"Name",value:"countryName"}}]}}]}}]}}]},te={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateRecovery"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"email"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"url"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreateRecovery"},arguments:[{kind:"Argument",name:{kind:"Name",value:"email"},value:{kind:"Variable",name:{kind:"Name",value:"email"}}},{kind:"Argument",name:{kind:"Name",value:"url"},value:{kind:"Variable",name:{kind:"Name",value:"url"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"expire"}}]}}]}}]},ae={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdateRecovery"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"userId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"secret"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"password"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdateRecovery"},arguments:[{kind:"Argument",name:{kind:"Name",value:"userId"},value:{kind:"Variable",name:{kind:"Name",value:"userId"}}},{kind:"Argument",name:{kind:"Name",value:"secret"},value:{kind:"Variable",name:{kind:"Name",value:"secret"}}},{kind:"Argument",name:{kind:"Name",value:"password"},value:{kind:"Variable",name:{kind:"Name",value:"password"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"expire"}}]}}]}}]},ie={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateAccount"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"userId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"name"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"email"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"password"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreate"},arguments:[{kind:"Argument",name:{kind:"Name",value:"userId"},value:{kind:"Variable",name:{kind:"Name",value:"userId"}}},{kind:"Argument",name:{kind:"Name",value:"name"},value:{kind:"Variable",name:{kind:"Name",value:"name"}}},{kind:"Argument",name:{kind:"Name",value:"email"},value:{kind:"Variable",name:{kind:"Name",value:"email"}}},{kind:"Argument",name:{kind:"Name",value:"password"},value:{kind:"Variable",name:{kind:"Name",value:"password"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"email"}}]}}]}}]},oe={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"VerifyEmail"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"url"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreateVerification"},arguments:[{kind:"Argument",name:{kind:"Name",value:"url"},value:{kind:"Variable",name:{kind:"Name",value:"url"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"expire"}}]}}]}}]},re={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdateEmail"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"email"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"password"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdateEmail"},arguments:[{kind:"Argument",name:{kind:"Name",value:"email"},value:{kind:"Variable",name:{kind:"Name",value:"email"}}},{kind:"Argument",name:{kind:"Name",value:"password"},value:{kind:"Variable",name:{kind:"Name",value:"password"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"email"}}]}}]}}]},se={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdateMagicURLSession"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"userId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"secret"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdateMagicURLSession"},arguments:[{kind:"Argument",name:{kind:"Name",value:"userId"},value:{kind:"Variable",name:{kind:"Name",value:"userId"}}},{kind:"Argument",name:{kind:"Name",value:"secret"},value:{kind:"Variable",name:{kind:"Name",value:"secret"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"userId"}},{kind:"Field",name:{kind:"Name",value:"expire"}},{kind:"Field",name:{kind:"Name",value:"current"}}]}}]}}]},ue={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdateMFA"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"mfa"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"Boolean"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdateMFA"},arguments:[{kind:"Argument",name:{kind:"Name",value:"mfa"},value:{kind:"Variable",name:{kind:"Name",value:"mfa"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"mfa"}}]}}]}}]},ce={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdateMfaAuthenticator"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"type"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"otp"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdateMfaAuthenticator"},arguments:[{kind:"Argument",name:{kind:"Name",value:"type"},value:{kind:"Variable",name:{kind:"Name",value:"type"}}},{kind:"Argument",name:{kind:"Name",value:"otp"},value:{kind:"Variable",name:{kind:"Name",value:"otp"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"mfa"}}]}}]}}]},de={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdateMfaChallenge"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"challengeId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"otp"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdateMfaChallenge"},arguments:[{kind:"Argument",name:{kind:"Name",value:"challengeId"},value:{kind:"Variable",name:{kind:"Name",value:"challengeId"}}},{kind:"Argument",name:{kind:"Name",value:"otp"},value:{kind:"Variable",name:{kind:"Name",value:"otp"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"status"}}]}}]}}]},le={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdateMfaRecoveryCodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdateMfaRecoveryCodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"recoveryCodes"}}]}}]}}]},pe={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdateName"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"name"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdateName"},arguments:[{kind:"Argument",name:{kind:"Name",value:"name"},value:{kind:"Variable",name:{kind:"Name",value:"name"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"}}]}}]}}]},me={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdatePassword"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"password"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"oldPassword"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdatePassword"},arguments:[{kind:"Argument",name:{kind:"Name",value:"password"},value:{kind:"Variable",name:{kind:"Name",value:"password"}}},{kind:"Argument",name:{kind:"Name",value:"oldPassword"},value:{kind:"Variable",name:{kind:"Name",value:"oldPassword"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"status"}}]}}]}}]},ye={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdatePhone"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"phone"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"password"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdatePhone"},arguments:[{kind:"Argument",name:{kind:"Name",value:"phone"},value:{kind:"Variable",name:{kind:"Name",value:"phone"}}},{kind:"Argument",name:{kind:"Name",value:"password"},value:{kind:"Variable",name:{kind:"Name",value:"password"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"phone"}}]}}]}}]},Se={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdatePhoneSession"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"userId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"secret"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdatePhoneSession"},arguments:[{kind:"Argument",name:{kind:"Name",value:"userId"},value:{kind:"Variable",name:{kind:"Name",value:"userId"}}},{kind:"Argument",name:{kind:"Name",value:"secret"},value:{kind:"Variable",name:{kind:"Name",value:"secret"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"userId"}},{kind:"Field",name:{kind:"Name",value:"expire"}},{kind:"Field",name:{kind:"Name",value:"current"}}]}}]}}]},ke={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdatePhoneVerification"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"userId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"secret"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdatePhoneVerification"},arguments:[{kind:"Argument",name:{kind:"Name",value:"userId"},value:{kind:"Variable",name:{kind:"Name",value:"userId"}}},{kind:"Argument",name:{kind:"Name",value:"secret"},value:{kind:"Variable",name:{kind:"Name",value:"secret"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"expire"}}]}}]}}]},fe={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdatePrefs"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"prefs"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"JSON"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdatePrefs"},arguments:[{kind:"Argument",name:{kind:"Name",value:"prefs"},value:{kind:"Variable",name:{kind:"Name",value:"prefs"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"prefs"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"data"}}]}}]}}]}}]},ge={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdateSession"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"sessionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdateSession"},arguments:[{kind:"Argument",name:{kind:"Name",value:"sessionId"},value:{kind:"Variable",name:{kind:"Name",value:"sessionId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"userId"}},{kind:"Field",name:{kind:"Name",value:"expire"}},{kind:"Field",name:{kind:"Name",value:"current"}}]}}]}}]},ve={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdateVerification"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"userId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"secret"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdateVerification"},arguments:[{kind:"Argument",name:{kind:"Name",value:"userId"},value:{kind:"Variable",name:{kind:"Name",value:"userId"}}},{kind:"Argument",name:{kind:"Name",value:"secret"},value:{kind:"Variable",name:{kind:"Name",value:"secret"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"secret"}},{kind:"Field",name:{kind:"Name",value:"expire"}},{kind:"Field",name:{kind:"Name",value:"userId"}}]}}]}}]},be={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"ListDocuments"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"databaseId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"collectionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"queries"}},type:{kind:"ListType",type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"databasesListDocuments"},arguments:[{kind:"Argument",name:{kind:"Name",value:"databaseId"},value:{kind:"Variable",name:{kind:"Name",value:"databaseId"}}},{kind:"Argument",name:{kind:"Name",value:"collectionId"},value:{kind:"Variable",name:{kind:"Name",value:"collectionId"}}},{kind:"Argument",name:{kind:"Name",value:"queries"},value:{kind:"Variable",name:{kind:"Name",value:"queries"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"total"}},{kind:"Field",name:{kind:"Name",value:"documents"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"_id"}},{kind:"Field",name:{kind:"Name",value:"data"}}]}}]}}]}}]},Me={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateDocument"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"databaseId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"collectionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"documentId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"data"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"JSON"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"permissions"}},type:{kind:"ListType",type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"databasesCreateDocument"},arguments:[{kind:"Argument",name:{kind:"Name",value:"databaseId"},value:{kind:"Variable",name:{kind:"Name",value:"databaseId"}}},{kind:"Argument",name:{kind:"Name",value:"collectionId"},value:{kind:"Variable",name:{kind:"Name",value:"collectionId"}}},{kind:"Argument",name:{kind:"Name",value:"documentId"},value:{kind:"Variable",name:{kind:"Name",value:"documentId"}}},{kind:"Argument",name:{kind:"Name",value:"data"},value:{kind:"Variable",name:{kind:"Name",value:"data"}}},{kind:"Argument",name:{kind:"Name",value:"permissions"},value:{kind:"Variable",name:{kind:"Name",value:"permissions"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"_id"}}]}}]}}]},Ne={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"DeleteDocument"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"databaseId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"collectionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"documentId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"databasesDeleteDocument"},arguments:[{kind:"Argument",name:{kind:"Name",value:"databaseId"},value:{kind:"Variable",name:{kind:"Name",value:"databaseId"}}},{kind:"Argument",name:{kind:"Name",value:"collectionId"},value:{kind:"Variable",name:{kind:"Name",value:"collectionId"}}},{kind:"Argument",name:{kind:"Name",value:"documentId"},value:{kind:"Variable",name:{kind:"Name",value:"documentId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"status"}}]}}]}}]},De={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"GetDocument"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"databaseId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"collectionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"documentId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"databasesGetDocument"},arguments:[{kind:"Argument",name:{kind:"Name",value:"databaseId"},value:{kind:"Variable",name:{kind:"Name",value:"databaseId"}}},{kind:"Argument",name:{kind:"Name",value:"collectionId"},value:{kind:"Variable",name:{kind:"Name",value:"collectionId"}}},{kind:"Argument",name:{kind:"Name",value:"documentId"},value:{kind:"Variable",name:{kind:"Name",value:"documentId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"_id"}},{kind:"Field",name:{kind:"Name",value:"data"}}]}}]}}]},xe={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdateDocument"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"databaseId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"collectionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"documentId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"data"}},type:{kind:"NamedType",name:{kind:"Name",value:"JSON"}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"permissions"}},type:{kind:"ListType",type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"databasesUpdateDocument"},arguments:[{kind:"Argument",name:{kind:"Name",value:"databaseId"},value:{kind:"Variable",name:{kind:"Name",value:"databaseId"}}},{kind:"Argument",name:{kind:"Name",value:"collectionId"},value:{kind:"Variable",name:{kind:"Name",value:"collectionId"}}},{kind:"Argument",name:{kind:"Name",value:"documentId"},value:{kind:"Variable",name:{kind:"Name",value:"documentId"}}},{kind:"Argument",name:{kind:"Name",value:"data"},value:{kind:"Variable",name:{kind:"Name",value:"data"}}},{kind:"Argument",name:{kind:"Name",value:"permissions"},value:{kind:"Variable",name:{kind:"Name",value:"permissions"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"_id"}}]}}]}}]},Ie={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateExecution"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"functionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"body"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"async"}},type:{kind:"NamedType",name:{kind:"Name",value:"Boolean"}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"path"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"method"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"functionsCreateExecution"},arguments:[{kind:"Argument",name:{kind:"Name",value:"functionId"},value:{kind:"Variable",name:{kind:"Name",value:"functionId"}}},{kind:"Argument",name:{kind:"Name",value:"body"},value:{kind:"Variable",name:{kind:"Name",value:"body"}}},{kind:"Argument",name:{kind:"Name",value:"async"},value:{kind:"Variable",name:{kind:"Name",value:"async"}}},{kind:"Argument",name:{kind:"Name",value:"path"},value:{kind:"Variable",name:{kind:"Name",value:"path"}}},{kind:"Argument",name:{kind:"Name",value:"method"},value:{kind:"Variable",name:{kind:"Name",value:"method"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"_id"}},{kind:"Field",name:{kind:"Name",value:"status"}},{kind:"Field",name:{kind:"Name",value:"responseStatusCode"}},{kind:"Field",name:{kind:"Name",value:"responseBody"}},{kind:"Field",name:{kind:"Name",value:"errors"}},{kind:"Field",name:{kind:"Name",value:"duration"}}]}}]}}]},$e={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"GetFunctionExecution"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"functionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"executionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"functionsGetExecution"},arguments:[{kind:"Argument",name:{kind:"Name",value:"functionId"},value:{kind:"Variable",name:{kind:"Name",value:"functionId"}}},{kind:"Argument",name:{kind:"Name",value:"executionId"},value:{kind:"Variable",name:{kind:"Name",value:"executionId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"status"}},{kind:"Field",name:{kind:"Name",value:"errors"}},{kind:"Field",name:{kind:"Name",value:"duration"}}]}}]}}]};var Oe={"\n fragment Account_User on User {\n _id\n name\n email\n prefs {\n data\n }\n }\n":h,"\n fragment Identity_Provider on Identity {\n _id\n userId\n provider\n }\n":T,"\n query AccountGet {\n accountGet {\n ...Account_User\n }\n }\n":V,"\n mutation CreateAnonymousSession {\n accountCreateAnonymousSession {\n _id\n expire\n current\n }\n }\n":q,"\n mutation CreateEmailToken($userId: String!, $email: String!, $phrase: Boolean) {\n accountCreateEmailToken(userId: $userId, email: $email, phrase: $phrase) {\n expire\n }\n }\n":_,"\n mutation CreateJWT {\n accountCreateJWT {\n jwt\n }\n }\n":F,"\n mutation CreateMagicURLToken($userId: String!, $email: String!, $url: String, $phrase: Boolean) {\n accountCreateMagicURLToken(userId: $userId, email: $email, url: $url, phrase: $phrase) {\n expire\n }\n }\n":E,"\n mutation CreateMfaAuthenticator($type: String!) {\n accountCreateMfaAuthenticator(type: $type) {\n secret\n uri\n }\n }\n":P,"\n mutation CreateMfaChallenge($factor: String!) {\n accountCreateMfaChallenge(factor: $factor) {\n userId\n expire\n }\n }\n":R,"\n mutation CreateMfaRecoveryCodes {\n accountCreateMfaRecoveryCodes {\n recoveryCodes\n }\n }\n":L,"\n mutation CreatePhoneToken($userId: String!, $phone: String!) {\n accountCreatePhoneToken(userId: $userId, phone: $phone) {\n expire\n }\n }\n":Q,"\n mutation CreatePhoneVerification {\n accountCreatePhoneVerification {\n expire\n }\n }\n":G,"\n mutation CreateSession($userId: String!, $secret: String!) {\n accountCreateSession(userId: $userId, secret: $secret) {\n userId\n expire\n current\n }\n }\n":O,"\n mutation DeleteIdentity($identityId: String!) {\n accountDeleteIdentity(identityId: $identityId) {\n status\n }\n }\n":J,"\n mutation DeleteMfaAuthenticator($type: String!, $otp: String!) {\n accountDeleteMfaAuthenticator(type: $type, otp: $otp) {\n mfa\n }\n }\n":K,"\n mutation DeleteSession($sessionId: String!) {\n accountDeleteSession(sessionId: $sessionId) {\n status\n }\n }\n":B,"\n mutation DeleteSessions {\n accountDeleteSessions {\n status\n }\n }\n":W,"\n query GetMfaRecoveryCodes {\n accountGetMfaRecoveryCodes {\n recoveryCodes\n }\n }\n":j,"\n query GetPrefs {\n accountGetPrefs {\n data\n }\n }\n":z,"\n query GetSession($sessionId: String!) {\n accountGetSession(sessionId: $sessionId) {\n userId\n expire\n current\n }\n }\n":X,"\n query ListIdentities {\n accountListIdentities {\n total\n identities {\n ...Identity_Provider\n }\n }\n }\n":H,"\n query ListMfaFactors {\n accountListMfaFactors {\n totp\n phone\n email\n }\n }\n":Y,"\n query ListSessions {\n accountListSessions {\n sessions {\n _id\n _createdAt\n osName\n clientName\n }\n }\n }\n":Z,"\n mutation CreateEmailPasswordSession($email: String!, $password: String!) {\n accountCreateEmailPasswordSession(email: $email, password: $password) {\n userId\n expire\n current\n }\n }\n":ee,"\n query ListLogs($queries: [String!]) {\n accountListLogs(queries: $queries) {\n total\n logs {\n event\n userId\n userEmail\n userName\n mode\n ip\n time\n osCode\n osName\n osVersion\n clientType\n clientCode\n clientName\n clientVersion\n clientEngine\n clientEngineVersion\n deviceName\n deviceBrand\n deviceModel\n countryCode\n countryName\n }\n }\n }\n":ne,"\n mutation CreateRecovery($email: String!, $url: String!) {\n accountCreateRecovery(email: $email, url: $url) {\n expire\n }\n }\n":te,"\n mutation UpdateRecovery($userId: String!, $secret: String!, $password: String!) {\n accountUpdateRecovery(userId: $userId, secret: $secret, password: $password) {\n expire\n }\n }\n":ae,"\n mutation CreateAccount($userId: String!, $name: String, $email: String!, $password: String!) {\n accountCreate(userId: $userId, name: $name, email: $email, password: $password) {\n name\n email\n }\n }\n":ie,"\n mutation VerifyEmail($url: String!) {\n accountCreateVerification(url: $url) {\n expire\n }\n }\n":oe,"\n mutation UpdateEmail($email: String!, $password: String!) {\n accountUpdateEmail(email: $email, password: $password) {\n name\n email\n }\n }\n":re,"\n mutation UpdateMagicURLSession($userId: String!, $secret: String!) {\n accountUpdateMagicURLSession(userId: $userId, secret: $secret) {\n userId\n expire\n current\n }\n }\n":se,"\n mutation UpdateMFA($mfa: Boolean!) {\n accountUpdateMFA(mfa: $mfa) {\n mfa\n }\n }\n":ue,"\n mutation UpdateMfaAuthenticator($type: String!, $otp: String!) {\n accountUpdateMfaAuthenticator(type: $type, otp: $otp) {\n mfa\n }\n }\n":ce,"\n mutation UpdateMfaChallenge($challengeId: String!, $otp: String!) {\n accountUpdateMfaChallenge(challengeId: $challengeId, otp: $otp) {\n status\n }\n }\n":de,"\n mutation UpdateMfaRecoveryCodes {\n accountUpdateMfaRecoveryCodes {\n recoveryCodes\n }\n }\n":le,"\n mutation UpdateName($name: String!) {\n accountUpdateName(name: $name) {\n name\n }\n }\n":pe,"\n mutation UpdatePassword($password: String!, $oldPassword: String!) {\n accountUpdatePassword(password: $password, oldPassword: $oldPassword) {\n status\n }\n }\n":me,"\n mutation UpdatePhone($phone: String!, $password: String!) {\n accountUpdatePhone(phone: $phone, password: $password) {\n phone\n }\n }\n":ye,"\n mutation UpdatePhoneSession($userId: String!, $secret: String!) {\n accountUpdatePhoneSession(userId: $userId, secret: $secret) {\n userId\n expire\n current\n }\n }\n":Se,"\n mutation UpdatePhoneVerification($userId: String!, $secret: String!) {\n accountUpdatePhoneVerification(userId: $userId, secret: $secret) {\n expire\n }\n }\n":ke,"\n mutation UpdatePrefs($prefs: JSON!) {\n accountUpdatePrefs(prefs: $prefs) {\n prefs {\n data\n }\n }\n }\n":fe,"\n mutation UpdateSession($sessionId: String!) {\n accountUpdateSession(sessionId: $sessionId) {\n userId\n expire\n current\n }\n }\n":ge,"\n mutation UpdateVerification($userId: String!, $secret: String!) {\n accountUpdateVerification(userId: $userId, secret: $secret) {\n secret\n expire\n userId\n }\n }\n":ve,"\n query ListDocuments($databaseId: String!, $collectionId: String!, $queries: [String!]) {\n databasesListDocuments(\n databaseId: $databaseId\n collectionId: $collectionId\n queries: $queries\n ) {\n total\n documents {\n _id\n data\n }\n }\n }\n":be,"\n mutation CreateDocument(\n $databaseId: String!\n $collectionId: String!\n $documentId: String!\n $data: JSON!\n $permissions: [String!]\n ) {\n databasesCreateDocument(\n databaseId: $databaseId\n collectionId: $collectionId\n documentId: $documentId\n data: $data\n permissions: $permissions\n ) {\n _id\n }\n }\n":Me,"\n mutation DeleteDocument($databaseId: String!, $collectionId: String!, $documentId: String!) {\n databasesDeleteDocument(\n databaseId: $databaseId\n collectionId: $collectionId\n documentId: $documentId\n ) {\n status\n }\n }\n":Ne,"\n query GetDocument($databaseId: String!, $collectionId: String!, $documentId: String!) {\n databasesGetDocument(\n databaseId: $databaseId\n collectionId: $collectionId\n documentId: $documentId\n ) {\n _id\n data\n }\n }\n":De,"\n mutation UpdateDocument(\n $databaseId: String!\n $collectionId: String!\n $documentId: String!\n $data: JSON\n $permissions: [String!]\n ) {\n databasesUpdateDocument(\n databaseId: $databaseId\n collectionId: $collectionId\n documentId: $documentId\n data: $data\n permissions: $permissions\n ) {\n _id\n }\n }\n":xe,"\n mutation CreateExecution(\n $functionId: String!\n $body: String\n $async: Boolean\n $path: String\n $method: String # $headers: JSON\n ) {\n functionsCreateExecution(\n functionId: $functionId\n body: $body\n async: $async\n path: $path\n method: $method # headers: $headers\n ) {\n _id\n status\n responseStatusCode\n responseBody\n errors\n duration\n }\n }\n":Ie,"\n query GetFunctionExecution($functionId: String!, $executionId: String!) {\n functionsGetExecution(functionId: $functionId, executionId: $executionId) {\n status\n errors\n duration\n }\n }\n":$e};function o(e){return Oe[e]??{}}var Ce=o(`
|
|
9
|
+
function je(e,a){return a}var F={kind:"Document",definitions:[{kind:"FragmentDefinition",name:{kind:"Name",value:"Account_User"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"User"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"_id"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"email"}},{kind:"Field",name:{kind:"Name",value:"prefs"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"data"}}]}}]}}]},E={kind:"Document",definitions:[{kind:"FragmentDefinition",name:{kind:"Name",value:"Identity_Provider"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"Identity"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"_id"}},{kind:"Field",name:{kind:"Name",value:"userId"}},{kind:"Field",name:{kind:"Name",value:"provider"}}]}}]},P={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"AccountGet"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountGet"},selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"Account_User"}}]}}]}},{kind:"FragmentDefinition",name:{kind:"Name",value:"Account_User"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"User"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"_id"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"email"}},{kind:"Field",name:{kind:"Name",value:"prefs"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"data"}}]}}]}}]},R={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateAnonymousSession"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreateAnonymousSession"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"_id"}},{kind:"Field",name:{kind:"Name",value:"expire"}},{kind:"Field",name:{kind:"Name",value:"current"}}]}}]}}]},L={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateEmailToken"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"userId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"email"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"phrase"}},type:{kind:"NamedType",name:{kind:"Name",value:"Boolean"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreateEmailToken"},arguments:[{kind:"Argument",name:{kind:"Name",value:"userId"},value:{kind:"Variable",name:{kind:"Name",value:"userId"}}},{kind:"Argument",name:{kind:"Name",value:"email"},value:{kind:"Variable",name:{kind:"Name",value:"email"}}},{kind:"Argument",name:{kind:"Name",value:"phrase"},value:{kind:"Variable",name:{kind:"Name",value:"phrase"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"expire"}}]}}]}}]},Q={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateJWT"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreateJWT"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"jwt"}}]}}]}}]},G={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateMagicURLToken"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"userId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"email"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"url"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"phrase"}},type:{kind:"NamedType",name:{kind:"Name",value:"Boolean"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreateMagicURLToken"},arguments:[{kind:"Argument",name:{kind:"Name",value:"userId"},value:{kind:"Variable",name:{kind:"Name",value:"userId"}}},{kind:"Argument",name:{kind:"Name",value:"email"},value:{kind:"Variable",name:{kind:"Name",value:"email"}}},{kind:"Argument",name:{kind:"Name",value:"url"},value:{kind:"Variable",name:{kind:"Name",value:"url"}}},{kind:"Argument",name:{kind:"Name",value:"phrase"},value:{kind:"Variable",name:{kind:"Name",value:"phrase"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"expire"}}]}}]}}]},O={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateMfaAuthenticator"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"type"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreateMfaAuthenticator"},arguments:[{kind:"Argument",name:{kind:"Name",value:"type"},value:{kind:"Variable",name:{kind:"Name",value:"type"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"secret"}},{kind:"Field",name:{kind:"Name",value:"uri"}}]}}]}}]},J={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateMfaChallenge"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"factor"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreateMfaChallenge"},arguments:[{kind:"Argument",name:{kind:"Name",value:"factor"},value:{kind:"Variable",name:{kind:"Name",value:"factor"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"userId"}},{kind:"Field",name:{kind:"Name",value:"expire"}}]}}]}}]},K={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateMfaRecoveryCodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreateMfaRecoveryCodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"recoveryCodes"}}]}}]}}]},B={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreatePhoneToken"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"userId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"phone"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreatePhoneToken"},arguments:[{kind:"Argument",name:{kind:"Name",value:"userId"},value:{kind:"Variable",name:{kind:"Name",value:"userId"}}},{kind:"Argument",name:{kind:"Name",value:"phone"},value:{kind:"Variable",name:{kind:"Name",value:"phone"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"expire"}}]}}]}}]},W={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreatePhoneVerification"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreatePhoneVerification"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"expire"}}]}}]}}]},j={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateSession"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"userId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"secret"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreateSession"},arguments:[{kind:"Argument",name:{kind:"Name",value:"userId"},value:{kind:"Variable",name:{kind:"Name",value:"userId"}}},{kind:"Argument",name:{kind:"Name",value:"secret"},value:{kind:"Variable",name:{kind:"Name",value:"secret"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"userId"}},{kind:"Field",name:{kind:"Name",value:"expire"}},{kind:"Field",name:{kind:"Name",value:"current"}}]}}]}}]},z={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"DeleteIdentity"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"identityId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountDeleteIdentity"},arguments:[{kind:"Argument",name:{kind:"Name",value:"identityId"},value:{kind:"Variable",name:{kind:"Name",value:"identityId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"status"}}]}}]}}]},X={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"DeleteMfaAuthenticator"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"type"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"otp"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountDeleteMfaAuthenticator"},arguments:[{kind:"Argument",name:{kind:"Name",value:"type"},value:{kind:"Variable",name:{kind:"Name",value:"type"}}},{kind:"Argument",name:{kind:"Name",value:"otp"},value:{kind:"Variable",name:{kind:"Name",value:"otp"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"mfa"}}]}}]}}]},H={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"DeleteSession"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"sessionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountDeleteSession"},arguments:[{kind:"Argument",name:{kind:"Name",value:"sessionId"},value:{kind:"Variable",name:{kind:"Name",value:"sessionId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"status"}}]}}]}}]},Y={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"DeleteSessions"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountDeleteSessions"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"status"}}]}}]}}]},Z={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"GetMfaRecoveryCodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountGetMfaRecoveryCodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"recoveryCodes"}}]}}]}}]},ee={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"GetPrefs"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountGetPrefs"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"data"}}]}}]}}]},ne={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"GetSession"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"sessionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountGetSession"},arguments:[{kind:"Argument",name:{kind:"Name",value:"sessionId"},value:{kind:"Variable",name:{kind:"Name",value:"sessionId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"userId"}},{kind:"Field",name:{kind:"Name",value:"expire"}},{kind:"Field",name:{kind:"Name",value:"current"}}]}}]}}]},te={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"ListIdentities"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountListIdentities"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"total"}},{kind:"Field",name:{kind:"Name",value:"identities"},selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"Identity_Provider"}}]}}]}}]}},{kind:"FragmentDefinition",name:{kind:"Name",value:"Identity_Provider"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"Identity"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"_id"}},{kind:"Field",name:{kind:"Name",value:"userId"}},{kind:"Field",name:{kind:"Name",value:"provider"}}]}}]},ae={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"ListMfaFactors"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountListMfaFactors"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"totp"}},{kind:"Field",name:{kind:"Name",value:"phone"}},{kind:"Field",name:{kind:"Name",value:"email"}}]}}]}}]},ie={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"ListSessions"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountListSessions"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"sessions"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"_id"}},{kind:"Field",name:{kind:"Name",value:"_createdAt"}},{kind:"Field",name:{kind:"Name",value:"osName"}},{kind:"Field",name:{kind:"Name",value:"clientName"}}]}}]}}]}}]},oe={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateEmailPasswordSession"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"email"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"password"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreateEmailPasswordSession"},arguments:[{kind:"Argument",name:{kind:"Name",value:"email"},value:{kind:"Variable",name:{kind:"Name",value:"email"}}},{kind:"Argument",name:{kind:"Name",value:"password"},value:{kind:"Variable",name:{kind:"Name",value:"password"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"userId"}},{kind:"Field",name:{kind:"Name",value:"expire"}},{kind:"Field",name:{kind:"Name",value:"current"}}]}}]}}]},re={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"ListLogs"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"queries"}},type:{kind:"ListType",type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountListLogs"},arguments:[{kind:"Argument",name:{kind:"Name",value:"queries"},value:{kind:"Variable",name:{kind:"Name",value:"queries"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"total"}},{kind:"Field",name:{kind:"Name",value:"logs"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"event"}},{kind:"Field",name:{kind:"Name",value:"userId"}},{kind:"Field",name:{kind:"Name",value:"userEmail"}},{kind:"Field",name:{kind:"Name",value:"userName"}},{kind:"Field",name:{kind:"Name",value:"mode"}},{kind:"Field",name:{kind:"Name",value:"ip"}},{kind:"Field",name:{kind:"Name",value:"time"}},{kind:"Field",name:{kind:"Name",value:"osCode"}},{kind:"Field",name:{kind:"Name",value:"osName"}},{kind:"Field",name:{kind:"Name",value:"osVersion"}},{kind:"Field",name:{kind:"Name",value:"clientType"}},{kind:"Field",name:{kind:"Name",value:"clientCode"}},{kind:"Field",name:{kind:"Name",value:"clientName"}},{kind:"Field",name:{kind:"Name",value:"clientVersion"}},{kind:"Field",name:{kind:"Name",value:"clientEngine"}},{kind:"Field",name:{kind:"Name",value:"clientEngineVersion"}},{kind:"Field",name:{kind:"Name",value:"deviceName"}},{kind:"Field",name:{kind:"Name",value:"deviceBrand"}},{kind:"Field",name:{kind:"Name",value:"deviceModel"}},{kind:"Field",name:{kind:"Name",value:"countryCode"}},{kind:"Field",name:{kind:"Name",value:"countryName"}}]}}]}}]}}]},se={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateRecovery"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"email"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"url"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreateRecovery"},arguments:[{kind:"Argument",name:{kind:"Name",value:"email"},value:{kind:"Variable",name:{kind:"Name",value:"email"}}},{kind:"Argument",name:{kind:"Name",value:"url"},value:{kind:"Variable",name:{kind:"Name",value:"url"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"expire"}}]}}]}}]},ue={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdateRecovery"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"userId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"secret"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"password"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdateRecovery"},arguments:[{kind:"Argument",name:{kind:"Name",value:"userId"},value:{kind:"Variable",name:{kind:"Name",value:"userId"}}},{kind:"Argument",name:{kind:"Name",value:"secret"},value:{kind:"Variable",name:{kind:"Name",value:"secret"}}},{kind:"Argument",name:{kind:"Name",value:"password"},value:{kind:"Variable",name:{kind:"Name",value:"password"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"expire"}}]}}]}}]},ce={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateAccount"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"userId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"name"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"email"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"password"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreate"},arguments:[{kind:"Argument",name:{kind:"Name",value:"userId"},value:{kind:"Variable",name:{kind:"Name",value:"userId"}}},{kind:"Argument",name:{kind:"Name",value:"name"},value:{kind:"Variable",name:{kind:"Name",value:"name"}}},{kind:"Argument",name:{kind:"Name",value:"email"},value:{kind:"Variable",name:{kind:"Name",value:"email"}}},{kind:"Argument",name:{kind:"Name",value:"password"},value:{kind:"Variable",name:{kind:"Name",value:"password"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"email"}}]}}]}}]},de={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"VerifyEmail"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"url"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountCreateVerification"},arguments:[{kind:"Argument",name:{kind:"Name",value:"url"},value:{kind:"Variable",name:{kind:"Name",value:"url"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"expire"}}]}}]}}]},le={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdateEmail"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"email"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"password"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdateEmail"},arguments:[{kind:"Argument",name:{kind:"Name",value:"email"},value:{kind:"Variable",name:{kind:"Name",value:"email"}}},{kind:"Argument",name:{kind:"Name",value:"password"},value:{kind:"Variable",name:{kind:"Name",value:"password"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"email"}}]}}]}}]},pe={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdateMagicURLSession"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"userId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"secret"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdateMagicURLSession"},arguments:[{kind:"Argument",name:{kind:"Name",value:"userId"},value:{kind:"Variable",name:{kind:"Name",value:"userId"}}},{kind:"Argument",name:{kind:"Name",value:"secret"},value:{kind:"Variable",name:{kind:"Name",value:"secret"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"userId"}},{kind:"Field",name:{kind:"Name",value:"expire"}},{kind:"Field",name:{kind:"Name",value:"current"}}]}}]}}]},me={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdateMFA"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"mfa"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"Boolean"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdateMFA"},arguments:[{kind:"Argument",name:{kind:"Name",value:"mfa"},value:{kind:"Variable",name:{kind:"Name",value:"mfa"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"mfa"}}]}}]}}]},ye={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdateMfaAuthenticator"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"type"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"otp"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdateMfaAuthenticator"},arguments:[{kind:"Argument",name:{kind:"Name",value:"type"},value:{kind:"Variable",name:{kind:"Name",value:"type"}}},{kind:"Argument",name:{kind:"Name",value:"otp"},value:{kind:"Variable",name:{kind:"Name",value:"otp"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"mfa"}}]}}]}}]},Se={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdateMfaChallenge"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"challengeId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"otp"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdateMfaChallenge"},arguments:[{kind:"Argument",name:{kind:"Name",value:"challengeId"},value:{kind:"Variable",name:{kind:"Name",value:"challengeId"}}},{kind:"Argument",name:{kind:"Name",value:"otp"},value:{kind:"Variable",name:{kind:"Name",value:"otp"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"status"}}]}}]}}]},ke={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdateMfaRecoveryCodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdateMfaRecoveryCodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"recoveryCodes"}}]}}]}}]},fe={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdateName"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"name"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdateName"},arguments:[{kind:"Argument",name:{kind:"Name",value:"name"},value:{kind:"Variable",name:{kind:"Name",value:"name"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"}}]}}]}}]},ge={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdatePassword"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"password"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"oldPassword"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdatePassword"},arguments:[{kind:"Argument",name:{kind:"Name",value:"password"},value:{kind:"Variable",name:{kind:"Name",value:"password"}}},{kind:"Argument",name:{kind:"Name",value:"oldPassword"},value:{kind:"Variable",name:{kind:"Name",value:"oldPassword"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"status"}}]}}]}}]},ve={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdatePhone"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"phone"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"password"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdatePhone"},arguments:[{kind:"Argument",name:{kind:"Name",value:"phone"},value:{kind:"Variable",name:{kind:"Name",value:"phone"}}},{kind:"Argument",name:{kind:"Name",value:"password"},value:{kind:"Variable",name:{kind:"Name",value:"password"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"phone"}}]}}]}}]},be={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdatePhoneSession"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"userId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"secret"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdatePhoneSession"},arguments:[{kind:"Argument",name:{kind:"Name",value:"userId"},value:{kind:"Variable",name:{kind:"Name",value:"userId"}}},{kind:"Argument",name:{kind:"Name",value:"secret"},value:{kind:"Variable",name:{kind:"Name",value:"secret"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"userId"}},{kind:"Field",name:{kind:"Name",value:"expire"}},{kind:"Field",name:{kind:"Name",value:"current"}}]}}]}}]},Me={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdatePhoneVerification"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"userId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"secret"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdatePhoneVerification"},arguments:[{kind:"Argument",name:{kind:"Name",value:"userId"},value:{kind:"Variable",name:{kind:"Name",value:"userId"}}},{kind:"Argument",name:{kind:"Name",value:"secret"},value:{kind:"Variable",name:{kind:"Name",value:"secret"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"expire"}}]}}]}}]},Ne={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdatePrefs"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"prefs"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"JSON"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdatePrefs"},arguments:[{kind:"Argument",name:{kind:"Name",value:"prefs"},value:{kind:"Variable",name:{kind:"Name",value:"prefs"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"prefs"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"data"}}]}}]}}]}}]},De={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdateSession"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"sessionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdateSession"},arguments:[{kind:"Argument",name:{kind:"Name",value:"sessionId"},value:{kind:"Variable",name:{kind:"Name",value:"sessionId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"userId"}},{kind:"Field",name:{kind:"Name",value:"expire"}},{kind:"Field",name:{kind:"Name",value:"current"}}]}}]}}]},xe={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdateVerification"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"userId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"secret"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"accountUpdateVerification"},arguments:[{kind:"Argument",name:{kind:"Name",value:"userId"},value:{kind:"Variable",name:{kind:"Name",value:"userId"}}},{kind:"Argument",name:{kind:"Name",value:"secret"},value:{kind:"Variable",name:{kind:"Name",value:"secret"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"secret"}},{kind:"Field",name:{kind:"Name",value:"expire"}},{kind:"Field",name:{kind:"Name",value:"userId"}}]}}]}}]},Ie={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"ListDocuments"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"databaseId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"collectionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"queries"}},type:{kind:"ListType",type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"databasesListDocuments"},arguments:[{kind:"Argument",name:{kind:"Name",value:"databaseId"},value:{kind:"Variable",name:{kind:"Name",value:"databaseId"}}},{kind:"Argument",name:{kind:"Name",value:"collectionId"},value:{kind:"Variable",name:{kind:"Name",value:"collectionId"}}},{kind:"Argument",name:{kind:"Name",value:"queries"},value:{kind:"Variable",name:{kind:"Name",value:"queries"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"total"}},{kind:"Field",name:{kind:"Name",value:"documents"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"_id"}},{kind:"Field",name:{kind:"Name",value:"data"}}]}}]}}]}}]},$e={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateDocument"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"databaseId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"collectionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"documentId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"data"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"JSON"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"permissions"}},type:{kind:"ListType",type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"databasesCreateDocument"},arguments:[{kind:"Argument",name:{kind:"Name",value:"databaseId"},value:{kind:"Variable",name:{kind:"Name",value:"databaseId"}}},{kind:"Argument",name:{kind:"Name",value:"collectionId"},value:{kind:"Variable",name:{kind:"Name",value:"collectionId"}}},{kind:"Argument",name:{kind:"Name",value:"documentId"},value:{kind:"Variable",name:{kind:"Name",value:"documentId"}}},{kind:"Argument",name:{kind:"Name",value:"data"},value:{kind:"Variable",name:{kind:"Name",value:"data"}}},{kind:"Argument",name:{kind:"Name",value:"permissions"},value:{kind:"Variable",name:{kind:"Name",value:"permissions"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"_id"}}]}}]}}]},Ce={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"DeleteDocument"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"databaseId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"collectionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"documentId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"databasesDeleteDocument"},arguments:[{kind:"Argument",name:{kind:"Name",value:"databaseId"},value:{kind:"Variable",name:{kind:"Name",value:"databaseId"}}},{kind:"Argument",name:{kind:"Name",value:"collectionId"},value:{kind:"Variable",name:{kind:"Name",value:"collectionId"}}},{kind:"Argument",name:{kind:"Name",value:"documentId"},value:{kind:"Variable",name:{kind:"Name",value:"documentId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"status"}}]}}]}}]},Ae={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"GetDocument"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"databaseId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"collectionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"documentId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"databasesGetDocument"},arguments:[{kind:"Argument",name:{kind:"Name",value:"databaseId"},value:{kind:"Variable",name:{kind:"Name",value:"databaseId"}}},{kind:"Argument",name:{kind:"Name",value:"collectionId"},value:{kind:"Variable",name:{kind:"Name",value:"collectionId"}}},{kind:"Argument",name:{kind:"Name",value:"documentId"},value:{kind:"Variable",name:{kind:"Name",value:"documentId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"_id"}},{kind:"Field",name:{kind:"Name",value:"data"}}]}}]}}]},we={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"UpdateDocument"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"databaseId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"collectionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"documentId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"data"}},type:{kind:"NamedType",name:{kind:"Name",value:"JSON"}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"permissions"}},type:{kind:"ListType",type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"databasesUpdateDocument"},arguments:[{kind:"Argument",name:{kind:"Name",value:"databaseId"},value:{kind:"Variable",name:{kind:"Name",value:"databaseId"}}},{kind:"Argument",name:{kind:"Name",value:"collectionId"},value:{kind:"Variable",name:{kind:"Name",value:"collectionId"}}},{kind:"Argument",name:{kind:"Name",value:"documentId"},value:{kind:"Variable",name:{kind:"Name",value:"documentId"}}},{kind:"Argument",name:{kind:"Name",value:"data"},value:{kind:"Variable",name:{kind:"Name",value:"data"}}},{kind:"Argument",name:{kind:"Name",value:"permissions"},value:{kind:"Variable",name:{kind:"Name",value:"permissions"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"_id"}}]}}]}}]},Te={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateExecution"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"functionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"body"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"async"}},type:{kind:"NamedType",name:{kind:"Name",value:"Boolean"}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"path"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"method"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"functionsCreateExecution"},arguments:[{kind:"Argument",name:{kind:"Name",value:"functionId"},value:{kind:"Variable",name:{kind:"Name",value:"functionId"}}},{kind:"Argument",name:{kind:"Name",value:"body"},value:{kind:"Variable",name:{kind:"Name",value:"body"}}},{kind:"Argument",name:{kind:"Name",value:"async"},value:{kind:"Variable",name:{kind:"Name",value:"async"}}},{kind:"Argument",name:{kind:"Name",value:"path"},value:{kind:"Variable",name:{kind:"Name",value:"path"}}},{kind:"Argument",name:{kind:"Name",value:"method"},value:{kind:"Variable",name:{kind:"Name",value:"method"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"_id"}},{kind:"Field",name:{kind:"Name",value:"status"}},{kind:"Field",name:{kind:"Name",value:"responseStatusCode"}},{kind:"Field",name:{kind:"Name",value:"responseBody"}},{kind:"Field",name:{kind:"Name",value:"errors"}},{kind:"Field",name:{kind:"Name",value:"duration"}}]}}]}}]},Ue={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"GetFunctionExecution"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"functionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"executionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"functionsGetExecution"},arguments:[{kind:"Argument",name:{kind:"Name",value:"functionId"},value:{kind:"Variable",name:{kind:"Name",value:"functionId"}}},{kind:"Argument",name:{kind:"Name",value:"executionId"},value:{kind:"Variable",name:{kind:"Name",value:"executionId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"status"}},{kind:"Field",name:{kind:"Name",value:"errors"}},{kind:"Field",name:{kind:"Name",value:"duration"}}]}}]}}]};var Xe={"\n fragment Account_User on User {\n _id\n name\n email\n prefs {\n data\n }\n }\n":F,"\n fragment Identity_Provider on Identity {\n _id\n userId\n provider\n }\n":E,"\n query AccountGet {\n accountGet {\n ...Account_User\n }\n }\n":P,"\n mutation CreateAnonymousSession {\n accountCreateAnonymousSession {\n _id\n expire\n current\n }\n }\n":R,"\n mutation CreateEmailToken($userId: String!, $email: String!, $phrase: Boolean) {\n accountCreateEmailToken(userId: $userId, email: $email, phrase: $phrase) {\n expire\n }\n }\n":L,"\n mutation CreateJWT {\n accountCreateJWT {\n jwt\n }\n }\n":Q,"\n mutation CreateMagicURLToken($userId: String!, $email: String!, $url: String, $phrase: Boolean) {\n accountCreateMagicURLToken(userId: $userId, email: $email, url: $url, phrase: $phrase) {\n expire\n }\n }\n":G,"\n mutation CreateMfaAuthenticator($type: String!) {\n accountCreateMfaAuthenticator(type: $type) {\n secret\n uri\n }\n }\n":O,"\n mutation CreateMfaChallenge($factor: String!) {\n accountCreateMfaChallenge(factor: $factor) {\n userId\n expire\n }\n }\n":J,"\n mutation CreateMfaRecoveryCodes {\n accountCreateMfaRecoveryCodes {\n recoveryCodes\n }\n }\n":K,"\n mutation CreatePhoneToken($userId: String!, $phone: String!) {\n accountCreatePhoneToken(userId: $userId, phone: $phone) {\n expire\n }\n }\n":B,"\n mutation CreatePhoneVerification {\n accountCreatePhoneVerification {\n expire\n }\n }\n":W,"\n mutation CreateSession($userId: String!, $secret: String!) {\n accountCreateSession(userId: $userId, secret: $secret) {\n userId\n expire\n current\n }\n }\n":j,"\n mutation DeleteIdentity($identityId: String!) {\n accountDeleteIdentity(identityId: $identityId) {\n status\n }\n }\n":z,"\n mutation DeleteMfaAuthenticator($type: String!, $otp: String!) {\n accountDeleteMfaAuthenticator(type: $type, otp: $otp) {\n mfa\n }\n }\n":X,"\n mutation DeleteSession($sessionId: String!) {\n accountDeleteSession(sessionId: $sessionId) {\n status\n }\n }\n":H,"\n mutation DeleteSessions {\n accountDeleteSessions {\n status\n }\n }\n":Y,"\n query GetMfaRecoveryCodes {\n accountGetMfaRecoveryCodes {\n recoveryCodes\n }\n }\n":Z,"\n query GetPrefs {\n accountGetPrefs {\n data\n }\n }\n":ee,"\n query GetSession($sessionId: String!) {\n accountGetSession(sessionId: $sessionId) {\n userId\n expire\n current\n }\n }\n":ne,"\n query ListIdentities {\n accountListIdentities {\n total\n identities {\n ...Identity_Provider\n }\n }\n }\n":te,"\n query ListMfaFactors {\n accountListMfaFactors {\n totp\n phone\n email\n }\n }\n":ae,"\n query ListSessions {\n accountListSessions {\n sessions {\n _id\n _createdAt\n osName\n clientName\n }\n }\n }\n":ie,"\n mutation CreateEmailPasswordSession($email: String!, $password: String!) {\n accountCreateEmailPasswordSession(email: $email, password: $password) {\n userId\n expire\n current\n }\n }\n":oe,"\n query ListLogs($queries: [String!]) {\n accountListLogs(queries: $queries) {\n total\n logs {\n event\n userId\n userEmail\n userName\n mode\n ip\n time\n osCode\n osName\n osVersion\n clientType\n clientCode\n clientName\n clientVersion\n clientEngine\n clientEngineVersion\n deviceName\n deviceBrand\n deviceModel\n countryCode\n countryName\n }\n }\n }\n":re,"\n mutation CreateRecovery($email: String!, $url: String!) {\n accountCreateRecovery(email: $email, url: $url) {\n expire\n }\n }\n":se,"\n mutation UpdateRecovery($userId: String!, $secret: String!, $password: String!) {\n accountUpdateRecovery(userId: $userId, secret: $secret, password: $password) {\n expire\n }\n }\n":ue,"\n mutation CreateAccount($userId: String!, $name: String, $email: String!, $password: String!) {\n accountCreate(userId: $userId, name: $name, email: $email, password: $password) {\n name\n email\n }\n }\n":ce,"\n mutation VerifyEmail($url: String!) {\n accountCreateVerification(url: $url) {\n expire\n }\n }\n":de,"\n mutation UpdateEmail($email: String!, $password: String!) {\n accountUpdateEmail(email: $email, password: $password) {\n name\n email\n }\n }\n":le,"\n mutation UpdateMagicURLSession($userId: String!, $secret: String!) {\n accountUpdateMagicURLSession(userId: $userId, secret: $secret) {\n userId\n expire\n current\n }\n }\n":pe,"\n mutation UpdateMFA($mfa: Boolean!) {\n accountUpdateMFA(mfa: $mfa) {\n mfa\n }\n }\n":me,"\n mutation UpdateMfaAuthenticator($type: String!, $otp: String!) {\n accountUpdateMfaAuthenticator(type: $type, otp: $otp) {\n mfa\n }\n }\n":ye,"\n mutation UpdateMfaChallenge($challengeId: String!, $otp: String!) {\n accountUpdateMfaChallenge(challengeId: $challengeId, otp: $otp) {\n status\n }\n }\n":Se,"\n mutation UpdateMfaRecoveryCodes {\n accountUpdateMfaRecoveryCodes {\n recoveryCodes\n }\n }\n":ke,"\n mutation UpdateName($name: String!) {\n accountUpdateName(name: $name) {\n name\n }\n }\n":fe,"\n mutation UpdatePassword($password: String!, $oldPassword: String!) {\n accountUpdatePassword(password: $password, oldPassword: $oldPassword) {\n status\n }\n }\n":ge,"\n mutation UpdatePhone($phone: String!, $password: String!) {\n accountUpdatePhone(phone: $phone, password: $password) {\n phone\n }\n }\n":ve,"\n mutation UpdatePhoneSession($userId: String!, $secret: String!) {\n accountUpdatePhoneSession(userId: $userId, secret: $secret) {\n userId\n expire\n current\n }\n }\n":be,"\n mutation UpdatePhoneVerification($userId: String!, $secret: String!) {\n accountUpdatePhoneVerification(userId: $userId, secret: $secret) {\n expire\n }\n }\n":Me,"\n mutation UpdatePrefs($prefs: JSON!) {\n accountUpdatePrefs(prefs: $prefs) {\n prefs {\n data\n }\n }\n }\n":Ne,"\n mutation UpdateSession($sessionId: String!) {\n accountUpdateSession(sessionId: $sessionId) {\n userId\n expire\n current\n }\n }\n":De,"\n mutation UpdateVerification($userId: String!, $secret: String!) {\n accountUpdateVerification(userId: $userId, secret: $secret) {\n secret\n expire\n userId\n }\n }\n":xe,"\n query ListDocuments($databaseId: String!, $collectionId: String!, $queries: [String!]) {\n databasesListDocuments(\n databaseId: $databaseId\n collectionId: $collectionId\n queries: $queries\n ) {\n total\n documents {\n _id\n data\n }\n }\n }\n":Ie,"\n mutation CreateDocument(\n $databaseId: String!\n $collectionId: String!\n $documentId: String!\n $data: JSON!\n $permissions: [String!]\n ) {\n databasesCreateDocument(\n databaseId: $databaseId\n collectionId: $collectionId\n documentId: $documentId\n data: $data\n permissions: $permissions\n ) {\n _id\n }\n }\n":$e,"\n mutation DeleteDocument($databaseId: String!, $collectionId: String!, $documentId: String!) {\n databasesDeleteDocument(\n databaseId: $databaseId\n collectionId: $collectionId\n documentId: $documentId\n ) {\n status\n }\n }\n":Ce,"\n query GetDocument($databaseId: String!, $collectionId: String!, $documentId: String!) {\n databasesGetDocument(\n databaseId: $databaseId\n collectionId: $collectionId\n documentId: $documentId\n ) {\n _id\n data\n }\n }\n":Ae,"\n mutation UpdateDocument(\n $databaseId: String!\n $collectionId: String!\n $documentId: String!\n $data: JSON\n $permissions: [String!]\n ) {\n databasesUpdateDocument(\n databaseId: $databaseId\n collectionId: $collectionId\n documentId: $documentId\n data: $data\n permissions: $permissions\n ) {\n _id\n }\n }\n":we,"\n mutation CreateExecution(\n $functionId: String!\n $body: String\n $async: Boolean\n $path: String\n $method: String # $headers: JSON\n ) {\n functionsCreateExecution(\n functionId: $functionId\n body: $body\n async: $async\n path: $path\n method: $method # headers: $headers\n ) {\n _id\n status\n responseStatusCode\n responseBody\n errors\n duration\n }\n }\n":Te,"\n query GetFunctionExecution($functionId: String!, $executionId: String!) {\n functionsGetExecution(functionId: $functionId, executionId: $executionId) {\n status\n errors\n duration\n }\n }\n":Ue};function o(e){return Xe[e]??{}}var he=o(`
|
|
9
10
|
fragment Account_User on User {
|
|
10
11
|
_id
|
|
11
12
|
name
|
|
@@ -14,19 +15,19 @@ function Qe(e,i){return i}var h={kind:"Document",definitions:[{kind:"FragmentDef
|
|
|
14
15
|
data
|
|
15
16
|
}
|
|
16
17
|
}
|
|
17
|
-
`),
|
|
18
|
+
`),Ve=o(`
|
|
18
19
|
fragment Identity_Provider on Identity {
|
|
19
20
|
_id
|
|
20
21
|
userId
|
|
21
22
|
provider
|
|
22
23
|
}
|
|
23
|
-
`);var
|
|
24
|
+
`);var Ye=process.env.APPWRITE_ENDPOINT??process.env.EXPO_PUBLIC_APPWRITE_URL??process.env.NEXT_PUBLIC_APPWRITE_URL??"http://localhost/v1",Ze=process.env.APPWRITE_PROJECT_ID??process.env.EXPO_PUBLIC_APPWRITE_PROJECT_ID??process.env.NEXT_PUBLIC_APPWRITE_PROJECT_ID??"[PROJECT_ID]",D=new Client;D.setEndpoint(Ye).setProject(Ze);var Pe=e=>({client:e.client,query:async({query:a,variables:n})=>{let{data:t,errors:i}=await e.query({query:print(a),variables:n});return {data:t,errors:i}},mutation:async({query:a,variables:n})=>{let{data:t,errors:i}=await e.mutation({query:print(a),variables:n});return {data:t,errors:i}}}),Fe=atom({account:new Account(D),databases:new Databases(D),graphql:Pe(new Graphql(D))}),x=atom(e=>e(Fe),(e,a,{endpoint:n,projectId:t})=>{let i=new Client;i.setEndpoint(n).setProject(t);let s=new Account(i),c=new Databases(i),d=new Graphql(i);a(Fe,{account:s,databases:c,graphql:Pe(d)});});function r(){let{account:e,databases:a,graphql:n}=useAtomValue(x);return {account:e,databases:a,graphql:n}}var an=new QueryClient,Re=atom(an);function p(){let[e]=useAtom(Re);return e}function u(e){let a=p();return useMutation(e,a)}function m(e){let a=p();return useQuery(e,a)}function _(e){let a=p(),n=useQuery({...e,enabled:!1},a);return {run:n.refetch,query:n}}function f(e){let a=p();return useSuspenseQuery(e,a)}function ln({endpoint:e,projectId:a,children:n}){return useHydrateAtoms([[x,{endpoint:e,projectId:a}]]),n}var yn=o(`
|
|
24
25
|
query AccountGet {
|
|
25
26
|
accountGet {
|
|
26
27
|
...Account_User
|
|
27
28
|
}
|
|
28
29
|
}
|
|
29
|
-
`);function
|
|
30
|
+
`);function Sn(){let{graphql:e}=r(),a=p(),n=_(Qe(e));return useEffect(()=>Ge(e,a),[e.client,a]),n}function kn(){let{graphql:e}=r(),a=p(),n=m(Qe(e));return useEffect(()=>Ge(e,a),[e.client,a]),n}function Qe(e){return {queryKey:["appwrite","account"],queryFn:async()=>{let{data:a,errors:n}=await e.query({query:yn});if(n)throw n;return a.accountGet},retry:!1}}function Ge(e,a){return e.client.subscribe("account",n=>{if(n.events.some(i=>i.endsWith("prefs"))){a.setQueryData(["appwrite","account"],i=>produce(i,s=>{s&&(s.prefs=castDraft(n.payload.prefs));}));return}a.setQueryData(["appwrite","account"],n.payload);})}var fn=o(`
|
|
30
31
|
mutation CreateAnonymousSession {
|
|
31
32
|
accountCreateAnonymousSession {
|
|
32
33
|
_id
|
|
@@ -34,57 +35,57 @@ function Qe(e,i){return i}var h={kind:"Document",definitions:[{kind:"FragmentDef
|
|
|
34
35
|
current
|
|
35
36
|
}
|
|
36
37
|
}
|
|
37
|
-
`);function
|
|
38
|
+
`);function gn(){let{graphql:e}=r();return {...u({mutationFn:async()=>{let{data:n,errors:t}=await e.mutation({query:fn});if(t)throw t;return n.accountCreateAnonymousSession}})}}var vn=o(`
|
|
38
39
|
mutation CreateEmailToken($userId: String!, $email: String!, $phrase: Boolean) {
|
|
39
40
|
accountCreateEmailToken(userId: $userId, email: $email, phrase: $phrase) {
|
|
40
41
|
expire
|
|
41
42
|
}
|
|
42
43
|
}
|
|
43
|
-
`);function
|
|
44
|
+
`);function bn(){let{graphql:e}=r();return {...u({mutationFn:async({userId:n,email:t,phrase:i})=>{let{data:s,errors:c}=await e.mutation({query:vn,variables:{userId:n,email:t,phrase:i}});if(c)throw c;return s.accountCreateEmailToken}})}}var Oe=o(`
|
|
44
45
|
mutation CreateJWT {
|
|
45
46
|
accountCreateJWT {
|
|
46
47
|
jwt
|
|
47
48
|
}
|
|
48
49
|
}
|
|
49
|
-
`);function
|
|
50
|
+
`);function Mn({gcTime:e=6e5}={}){let{graphql:a}=r(),n=p();return {...u({gcTime:e,mutationKey:["appwrite","jwt"],mutationFn:async()=>{let{data:i,errors:s}=await a.mutation({query:Oe});if(s)throw s;return i.accountCreateJWT},onSuccess:i=>{a.client.setJWT(i.jwt),n.setQueryData(["appwrite","jwt"],i.jwt,{updatedAt:Date.now()});}})}}function Nn({gcTime:e=6e5}={}){let{graphql:a}=r();return {...f({gcTime:e,queryKey:["appwrite","jwt"],queryFn:async()=>{let{data:t,errors:i}=await a.mutation({query:Oe});if(i)throw i;return a.client.setJWT(t.accountCreateJWT.jwt),t.accountCreateJWT}})}}var Dn=o(`
|
|
50
51
|
mutation CreateMagicURLToken($userId: String!, $email: String!, $url: String, $phrase: Boolean) {
|
|
51
52
|
accountCreateMagicURLToken(userId: $userId, email: $email, url: $url, phrase: $phrase) {
|
|
52
53
|
expire
|
|
53
54
|
}
|
|
54
55
|
}
|
|
55
|
-
`);function
|
|
56
|
+
`);function xn(){let{graphql:e}=r();return {...u({mutationFn:async({userId:n,email:t,url:i,phrase:s})=>{let{data:c,errors:d}=await e.mutation({query:Dn,variables:{userId:n,email:t,url:i,phrase:s}});if(d)throw d;return c.accountCreateMagicURLToken}})}}var In=o(`
|
|
56
57
|
mutation CreateMfaAuthenticator($type: String!) {
|
|
57
58
|
accountCreateMfaAuthenticator(type: $type) {
|
|
58
59
|
secret
|
|
59
60
|
uri
|
|
60
61
|
}
|
|
61
62
|
}
|
|
62
|
-
`);function
|
|
63
|
+
`);function $n(){let{graphql:e}=r();return {...u({mutationFn:async({type:n="totp"})=>{let{data:t,errors:i}=await e.mutation({query:In,variables:{type:n}});if(i)throw i;return t.accountCreateMfaAuthenticator}})}}var Cn=o(`
|
|
63
64
|
mutation CreateMfaChallenge($factor: String!) {
|
|
64
65
|
accountCreateMfaChallenge(factor: $factor) {
|
|
65
66
|
userId
|
|
66
67
|
expire
|
|
67
68
|
}
|
|
68
69
|
}
|
|
69
|
-
`);function
|
|
70
|
+
`);function An(){let{graphql:e}=r();return {...u({mutationFn:async({factor:n})=>{let{data:t,errors:i}=await e.mutation({query:Cn,variables:{factor:n}});if(i)throw i;return t.accountCreateMfaChallenge}})}}var wn=o(`
|
|
70
71
|
mutation CreateMfaRecoveryCodes {
|
|
71
72
|
accountCreateMfaRecoveryCodes {
|
|
72
73
|
recoveryCodes
|
|
73
74
|
}
|
|
74
75
|
}
|
|
75
|
-
`);function
|
|
76
|
+
`);function Tn(){let{graphql:e}=r();return {...u({mutationFn:async()=>{let{data:n,errors:t}=await e.mutation({query:wn});if(t)throw t;return n.accountCreateMfaRecoveryCodes}})}}var Un=o(`
|
|
76
77
|
mutation CreatePhoneToken($userId: String!, $phone: String!) {
|
|
77
78
|
accountCreatePhoneToken(userId: $userId, phone: $phone) {
|
|
78
79
|
expire
|
|
79
80
|
}
|
|
80
81
|
}
|
|
81
|
-
`);function
|
|
82
|
+
`);function hn(){let{graphql:e}=r();return {...u({mutationFn:async({userId:n,phone:t})=>{let{data:i,errors:s}=await e.mutation({query:Un,variables:{userId:n,phone:t}});if(s)throw s;return i.accountCreatePhoneToken}})}}var Vn=o(`
|
|
82
83
|
mutation CreatePhoneVerification {
|
|
83
84
|
accountCreatePhoneVerification {
|
|
84
85
|
expire
|
|
85
86
|
}
|
|
86
87
|
}
|
|
87
|
-
`);function
|
|
88
|
+
`);function qn(){let{graphql:e}=r();return {...u({mutationFn:async()=>{let{data:n,errors:t}=await e.mutation({query:Vn});if(t)throw t;return n.accountCreatePhoneVerification}})}}var _n=o(`
|
|
88
89
|
mutation CreateSession($userId: String!, $secret: String!) {
|
|
89
90
|
accountCreateSession(userId: $userId, secret: $secret) {
|
|
90
91
|
userId
|
|
@@ -92,43 +93,43 @@ function Qe(e,i){return i}var h={kind:"Document",definitions:[{kind:"FragmentDef
|
|
|
92
93
|
current
|
|
93
94
|
}
|
|
94
95
|
}
|
|
95
|
-
`);function
|
|
96
|
+
`);function Fn(){let{graphql:e}=r();return {...u({mutationFn:async({userId:n,secret:t})=>{let{data:i,errors:s}=await e.mutation({query:_n,variables:{userId:n,secret:t}});if(s)throw s;return i.accountCreateSession}})}}var En=o(`
|
|
96
97
|
mutation DeleteIdentity($identityId: String!) {
|
|
97
98
|
accountDeleteIdentity(identityId: $identityId) {
|
|
98
99
|
status
|
|
99
100
|
}
|
|
100
101
|
}
|
|
101
|
-
`);function
|
|
102
|
+
`);function Pn(){let{graphql:e}=r();return {...u({mutationFn:async({identityId:n})=>{let{data:t,errors:i}=await e.mutation({query:En,variables:{identityId:n}});if(i)throw i;return t?.accountDeleteIdentity??{status:!1}}})}}var Rn=o(`
|
|
102
103
|
mutation DeleteMfaAuthenticator($type: String!, $otp: String!) {
|
|
103
104
|
accountDeleteMfaAuthenticator(type: $type, otp: $otp) {
|
|
104
105
|
mfa
|
|
105
106
|
}
|
|
106
107
|
}
|
|
107
|
-
`);function
|
|
108
|
+
`);function Ln(){let{graphql:e}=r();return {...u({mutationFn:async({type:n="totp",otp:t})=>{let{data:i,errors:s}=await e.mutation({query:Rn,variables:{type:n,otp:t}});if(s)throw s;return i.accountDeleteMfaAuthenticator}})}}var Qn=o(`
|
|
108
109
|
mutation DeleteSession($sessionId: String!) {
|
|
109
110
|
accountDeleteSession(sessionId: $sessionId) {
|
|
110
111
|
status
|
|
111
112
|
}
|
|
112
113
|
}
|
|
113
|
-
`);function
|
|
114
|
+
`);function Gn(){let{graphql:e}=r();return {...u({mutationFn:async({sessionId:n})=>{let{data:t,errors:i}=await e.mutation({query:Qn,variables:{sessionId:n}});if(i)throw i;return t?.accountDeleteSession??{status:!1}}})}}var On=o(`
|
|
114
115
|
mutation DeleteSessions {
|
|
115
116
|
accountDeleteSessions {
|
|
116
117
|
status
|
|
117
118
|
}
|
|
118
119
|
}
|
|
119
|
-
`);function
|
|
120
|
+
`);function Jn(){let{graphql:e}=r();return {...u({mutationFn:async()=>{let{data:n,errors:t}=await e.mutation({query:On});if(t)throw t;return n?.accountDeleteSessions??{status:!1}}})}}var Kn=o(`
|
|
120
121
|
query GetMfaRecoveryCodes {
|
|
121
122
|
accountGetMfaRecoveryCodes {
|
|
122
123
|
recoveryCodes
|
|
123
124
|
}
|
|
124
125
|
}
|
|
125
|
-
`);function
|
|
126
|
+
`);function Bn(){let{graphql:e}=r();return {...m({queryKey:["appwrite","account","mfa","recovery-codes"],queryFn:async()=>{let{data:n,errors:t}=await e.query({query:Kn});if(t)throw t;return n.accountGetMfaRecoveryCodes}})}}var Wn=o(`
|
|
126
127
|
query GetPrefs {
|
|
127
128
|
accountGetPrefs {
|
|
128
129
|
data
|
|
129
130
|
}
|
|
130
131
|
}
|
|
131
|
-
`);function
|
|
132
|
+
`);function jn(){let{graphql:e}=r();return {...m({queryKey:["appwrite","account","prefs"],queryFn:async()=>{let{data:n,errors:t}=await e.query({query:Wn});if(t)throw t;return n.accountGetPrefs}})}}var zn=o(`
|
|
132
133
|
query GetSession($sessionId: String!) {
|
|
133
134
|
accountGetSession(sessionId: $sessionId) {
|
|
134
135
|
userId
|
|
@@ -136,7 +137,7 @@ function Qe(e,i){return i}var h={kind:"Document",definitions:[{kind:"FragmentDef
|
|
|
136
137
|
current
|
|
137
138
|
}
|
|
138
139
|
}
|
|
139
|
-
`);function
|
|
140
|
+
`);function Xn({sessionId:e}){let{graphql:a}=r();return m({queryKey:["appwrite","account","session",e],queryFn:async()=>{let{data:t,errors:i}=await a.query({query:zn,variables:{sessionId:e}});if(i)throw i;return t.accountGetSession}})}var Hn=o(`
|
|
140
141
|
query ListIdentities {
|
|
141
142
|
accountListIdentities {
|
|
142
143
|
total
|
|
@@ -145,7 +146,7 @@ function Qe(e,i){return i}var h={kind:"Document",definitions:[{kind:"FragmentDef
|
|
|
145
146
|
}
|
|
146
147
|
}
|
|
147
148
|
}
|
|
148
|
-
`);function
|
|
149
|
+
`);function Yn(){let{graphql:e}=r();return {...m({queryKey:["appwrite","account","identities"],queryFn:async()=>{let{data:n,errors:t}=await e.query({query:Hn});if(t)throw t;return n.accountListIdentities}})}}var Zn=o(`
|
|
149
150
|
query ListMfaFactors {
|
|
150
151
|
accountListMfaFactors {
|
|
151
152
|
totp
|
|
@@ -153,7 +154,7 @@ function Qe(e,i){return i}var h={kind:"Document",definitions:[{kind:"FragmentDef
|
|
|
153
154
|
email
|
|
154
155
|
}
|
|
155
156
|
}
|
|
156
|
-
`);function
|
|
157
|
+
`);function et(){let{graphql:e}=r();return {...m({queryKey:["appwrite","account","mfa","factors"],queryFn:async()=>{let{data:n,errors:t}=await e.query({query:Zn});if(t)throw t;return n.accountListMfaFactors}})}}var nt=o(`
|
|
157
158
|
query ListSessions {
|
|
158
159
|
accountListSessions {
|
|
159
160
|
sessions {
|
|
@@ -164,7 +165,7 @@ function Qe(e,i){return i}var h={kind:"Document",definitions:[{kind:"FragmentDef
|
|
|
164
165
|
}
|
|
165
166
|
}
|
|
166
167
|
}
|
|
167
|
-
`);function
|
|
168
|
+
`);function tt(){let{graphql:e}=r();return {...m({queryKey:["appwrite","account","sessions"],queryFn:async()=>{let{data:n,errors:t}=await e.query({query:nt});if(t)throw t;return n.accountListSessions}})}}var at=o(`
|
|
168
169
|
mutation CreateEmailPasswordSession($email: String!, $password: String!) {
|
|
169
170
|
accountCreateEmailPasswordSession(email: $email, password: $password) {
|
|
170
171
|
userId
|
|
@@ -172,13 +173,13 @@ function Qe(e,i){return i}var h={kind:"Document",definitions:[{kind:"FragmentDef
|
|
|
172
173
|
current
|
|
173
174
|
}
|
|
174
175
|
}
|
|
175
|
-
`);function
|
|
176
|
+
`);function it(){let{account:e,graphql:a}=r(),n=u({mutationFn:async({email:i,password:s})=>{let{data:c,errors:d}=await a.mutation({query:at,variables:{email:i,password:s}});if(d)throw d;return c.accountCreateEmailPasswordSession}}),t=u({mutationFn:async({provider:i,success:s,failure:c})=>e.createOAuth2Session(i,s,c)});return {login:n,oAuthLogin:t}}var ot=o(`
|
|
176
177
|
mutation DeleteSession($sessionId: String!) {
|
|
177
178
|
accountDeleteSession(sessionId: $sessionId) {
|
|
178
179
|
status
|
|
179
180
|
}
|
|
180
181
|
}
|
|
181
|
-
`);function
|
|
182
|
+
`);function rt(){let{graphql:e}=r(),a=p(),n=u({mutationFn:async({sessionId:t})=>{let{data:i,errors:s}=await e.mutation({query:ot,variables:{sessionId:t}});if(s)throw s;return i?.accountDeleteSession??{status:!1}},onSuccess:async()=>{a.setQueryData(["appwrite"],null),a.setQueryData(["appwrite","account"],null),a.invalidateQueries({queryKey:["appwrite"]}),a.invalidateQueries({queryKey:["appwrite","account"]}),a.removeQueries({queryKey:["appwrite"]}),a.removeQueries({queryKey:["appwrite","account"]}),a.clear();}});return {...n,mutate:n.mutate}}var st=o(`
|
|
182
183
|
query ListLogs($queries: [String!]) {
|
|
183
184
|
accountListLogs(queries: $queries) {
|
|
184
185
|
total
|
|
@@ -207,39 +208,39 @@ function Qe(e,i){return i}var h={kind:"Document",definitions:[{kind:"FragmentDef
|
|
|
207
208
|
}
|
|
208
209
|
}
|
|
209
210
|
}
|
|
210
|
-
`);function
|
|
211
|
+
`);function ut({queries:e}){let{graphql:a}=r();return {...m({queryKey:["appwrite","account","logs",e],queryFn:async()=>{let{data:t,errors:i}=await a.query({query:st,variables:{queries:e}});if(i)throw i;return t.accountListLogs}})}}var ct=o(`
|
|
211
212
|
mutation CreateRecovery($email: String!, $url: String!) {
|
|
212
213
|
accountCreateRecovery(email: $email, url: $url) {
|
|
213
214
|
expire
|
|
214
215
|
}
|
|
215
216
|
}
|
|
216
|
-
`);function
|
|
217
|
+
`);function dt(){let{graphql:e}=r();return {...u({mutationFn:async({email:n,url:t})=>{let{data:i,errors:s}=await e.mutation({query:ct,variables:{email:n,url:t}});if(s)throw s;return i.accountCreateRecovery},onSuccess:async(n,t)=>{localStorage.setItem("email",t.email);}})}}var lt=o(`
|
|
217
218
|
mutation UpdateRecovery($userId: String!, $secret: String!, $password: String!) {
|
|
218
219
|
accountUpdateRecovery(userId: $userId, secret: $secret, password: $password) {
|
|
219
220
|
expire
|
|
220
221
|
}
|
|
221
222
|
}
|
|
222
|
-
`);function
|
|
223
|
+
`);function pt(){let{graphql:e}=r();return {...u({mutationFn:async({userId:n,secret:t,password:i})=>{let{data:s,errors:c}=await e.mutation({query:lt,variables:{userId:n,secret:t,password:i}});if(c)throw c;return s.accountUpdateRecovery??{}}})}}var mt=o(`
|
|
223
224
|
mutation CreateAccount($userId: String!, $name: String, $email: String!, $password: String!) {
|
|
224
225
|
accountCreate(userId: $userId, name: $name, email: $email, password: $password) {
|
|
225
226
|
name
|
|
226
227
|
email
|
|
227
228
|
}
|
|
228
229
|
}
|
|
229
|
-
`),
|
|
230
|
+
`),yt=o(`
|
|
230
231
|
mutation VerifyEmail($url: String!) {
|
|
231
232
|
accountCreateVerification(url: $url) {
|
|
232
233
|
expire
|
|
233
234
|
}
|
|
234
235
|
}
|
|
235
|
-
`);function
|
|
236
|
+
`);function St(){let{graphql:e}=r(),a=u({mutationFn:async({userId:t,email:i,password:s,name:c})=>{let{data:d,errors:l}=await e.mutation({query:mt,variables:{userId:t??ID.unique(),name:c,email:i,password:s}});if(l)throw l;return d.accountCreate}}),n=u({mutationFn:async({verifyUrl:t})=>{let{data:i,errors:s}=await e.mutation({query:yt,variables:{url:t}});if(s)throw s;return i.accountCreateVerification}});return {signUp:a,verifyEmail:n}}var kt=o(`
|
|
236
237
|
mutation UpdateEmail($email: String!, $password: String!) {
|
|
237
238
|
accountUpdateEmail(email: $email, password: $password) {
|
|
238
239
|
name
|
|
239
240
|
email
|
|
240
241
|
}
|
|
241
242
|
}
|
|
242
|
-
`);function
|
|
243
|
+
`);function ft(){let{graphql:e}=r();return {...u({mutationFn:async({email:n,password:t})=>{let{data:i,errors:s}=await e.mutation({query:kt,variables:{email:n,password:t}});if(s)throw s;return i.accountUpdateEmail}})}}var gt=o(`
|
|
243
244
|
mutation UpdateMagicURLSession($userId: String!, $secret: String!) {
|
|
244
245
|
accountUpdateMagicURLSession(userId: $userId, secret: $secret) {
|
|
245
246
|
userId
|
|
@@ -247,49 +248,49 @@ function Qe(e,i){return i}var h={kind:"Document",definitions:[{kind:"FragmentDef
|
|
|
247
248
|
current
|
|
248
249
|
}
|
|
249
250
|
}
|
|
250
|
-
`);function
|
|
251
|
+
`);function vt(){let{graphql:e}=r();return {...u({mutationFn:async({userId:n,secret:t})=>{let{data:i,errors:s}=await e.mutation({query:gt,variables:{userId:n,secret:t}});if(s)throw s;return i.accountUpdateMagicURLSession}})}}var bt=o(`
|
|
251
252
|
mutation UpdateMFA($mfa: Boolean!) {
|
|
252
253
|
accountUpdateMFA(mfa: $mfa) {
|
|
253
254
|
mfa
|
|
254
255
|
}
|
|
255
256
|
}
|
|
256
|
-
`);function
|
|
257
|
+
`);function Mt(){let{graphql:e}=r();return {...u({mutationFn:async({mfa:n})=>{let{data:t,errors:i}=await e.mutation({query:bt,variables:{mfa:n}});if(i)throw i;return t.accountUpdateMFA}})}}var Nt=o(`
|
|
257
258
|
mutation UpdateMfaAuthenticator($type: String!, $otp: String!) {
|
|
258
259
|
accountUpdateMfaAuthenticator(type: $type, otp: $otp) {
|
|
259
260
|
mfa
|
|
260
261
|
}
|
|
261
262
|
}
|
|
262
|
-
`);function
|
|
263
|
+
`);function Dt(){let{graphql:e}=r();return {...u({mutationFn:async({type:n="totp",otp:t})=>{let{data:i,errors:s}=await e.mutation({query:Nt,variables:{type:n,otp:t}});if(s)throw s;return i.accountUpdateMfaAuthenticator}})}}var xt=o(`
|
|
263
264
|
mutation UpdateMfaChallenge($challengeId: String!, $otp: String!) {
|
|
264
265
|
accountUpdateMfaChallenge(challengeId: $challengeId, otp: $otp) {
|
|
265
266
|
status
|
|
266
267
|
}
|
|
267
268
|
}
|
|
268
|
-
`);function
|
|
269
|
+
`);function It(){let{graphql:e}=r();return {...u({mutationFn:async({challengeId:n,otp:t})=>{let{data:i,errors:s}=await e.mutation({query:xt,variables:{challengeId:n,otp:t}});if(s)throw s;return i?.accountUpdateMfaChallenge??{status:!1}}})}}var $t=o(`
|
|
269
270
|
mutation UpdateMfaRecoveryCodes {
|
|
270
271
|
accountUpdateMfaRecoveryCodes {
|
|
271
272
|
recoveryCodes
|
|
272
273
|
}
|
|
273
274
|
}
|
|
274
|
-
`);function
|
|
275
|
+
`);function Ct(){let{graphql:e}=r();return {...u({mutationFn:async()=>{let{data:n,errors:t}=await e.mutation({query:$t});if(t)throw t;return n.accountUpdateMfaRecoveryCodes}})}}var At=o(`
|
|
275
276
|
mutation UpdateName($name: String!) {
|
|
276
277
|
accountUpdateName(name: $name) {
|
|
277
278
|
name
|
|
278
279
|
}
|
|
279
280
|
}
|
|
280
|
-
`);function
|
|
281
|
+
`);function wt(){let{graphql:e}=r();return {...u({mutationFn:async({name:n})=>{let{data:t,errors:i}=await e.mutation({query:At,variables:{name:n}});if(i)throw i;return t.accountUpdateName}})}}var Tt=o(`
|
|
281
282
|
mutation UpdatePassword($password: String!, $oldPassword: String!) {
|
|
282
283
|
accountUpdatePassword(password: $password, oldPassword: $oldPassword) {
|
|
283
284
|
status
|
|
284
285
|
}
|
|
285
286
|
}
|
|
286
|
-
`);function
|
|
287
|
+
`);function Ut(){let{graphql:e}=r();return {...u({mutationFn:async({password:n,oldPassword:t})=>{let{data:i,errors:s}=await e.mutation({query:Tt,variables:{password:n,oldPassword:t}});if(s)throw s;return i?.accountUpdatePassword}})}}var ht=o(`
|
|
287
288
|
mutation UpdatePhone($phone: String!, $password: String!) {
|
|
288
289
|
accountUpdatePhone(phone: $phone, password: $password) {
|
|
289
290
|
phone
|
|
290
291
|
}
|
|
291
292
|
}
|
|
292
|
-
`);function
|
|
293
|
+
`);function Vt(){let{graphql:e}=r();return {...u({mutationFn:async({phone:n,password:t})=>{let{data:i,errors:s}=await e.mutation({query:ht,variables:{phone:n,password:t}});if(s)throw s;return i.accountUpdatePhone}})}}var qt=o(`
|
|
293
294
|
mutation UpdatePhoneSession($userId: String!, $secret: String!) {
|
|
294
295
|
accountUpdatePhoneSession(userId: $userId, secret: $secret) {
|
|
295
296
|
userId
|
|
@@ -297,13 +298,13 @@ function Qe(e,i){return i}var h={kind:"Document",definitions:[{kind:"FragmentDef
|
|
|
297
298
|
current
|
|
298
299
|
}
|
|
299
300
|
}
|
|
300
|
-
`);function
|
|
301
|
+
`);function _t(){let{graphql:e}=r();return {...u({mutationFn:async({userId:n,secret:t})=>{let{data:i,errors:s}=await e.mutation({query:qt,variables:{userId:n,secret:t}});if(s)throw s;return i.accountUpdatePhoneSession}})}}var Ft=o(`
|
|
301
302
|
mutation UpdatePhoneVerification($userId: String!, $secret: String!) {
|
|
302
303
|
accountUpdatePhoneVerification(userId: $userId, secret: $secret) {
|
|
303
304
|
expire
|
|
304
305
|
}
|
|
305
306
|
}
|
|
306
|
-
`);function
|
|
307
|
+
`);function Et(){let{graphql:e}=r();return {...u({mutationFn:async({userId:n,secret:t})=>{let{data:i,errors:s}=await e.mutation({query:Ft,variables:{userId:n,secret:t}});if(s)throw s;return i.accountUpdatePhoneVerification}})}}function Pt(){let{account:e}=r();return {...u({mutationFn:async({prefs:n})=>await e.updatePrefs(n)})}}var Rt=o(`
|
|
307
308
|
mutation UpdateSession($sessionId: String!) {
|
|
308
309
|
accountUpdateSession(sessionId: $sessionId) {
|
|
309
310
|
userId
|
|
@@ -311,7 +312,7 @@ function Qe(e,i){return i}var h={kind:"Document",definitions:[{kind:"FragmentDef
|
|
|
311
312
|
current
|
|
312
313
|
}
|
|
313
314
|
}
|
|
314
|
-
`);function
|
|
315
|
+
`);function Lt(){let{graphql:e}=r();return {...u({mutationFn:async({sessionId:n})=>{let{data:t,errors:i}=await e.mutation({query:Rt,variables:{sessionId:n}});if(i)throw i;return t.accountUpdateSession}})}}var Qt=o(`
|
|
315
316
|
mutation UpdateVerification($userId: String!, $secret: String!) {
|
|
316
317
|
accountUpdateVerification(userId: $userId, secret: $secret) {
|
|
317
318
|
secret
|
|
@@ -319,7 +320,7 @@ function Qe(e,i){return i}var h={kind:"Document",definitions:[{kind:"FragmentDef
|
|
|
319
320
|
userId
|
|
320
321
|
}
|
|
321
322
|
}
|
|
322
|
-
`);function
|
|
323
|
+
`);function Gt(){let{graphql:e}=r(),a=p();return {...u({mutationFn:async({userId:t,secret:i})=>{if(!t||!i)throw new Error("Missing userId or secret");let{data:s,errors:c}=await e.mutation({query:Qt,variables:{userId:t,secret:i}});if(c)throw c;return s.accountUpdateVerification??{}},onSuccess:async()=>{a.setQueryData(["appwrite","account"],null);}})}}var Ke=o(`
|
|
323
324
|
query ListDocuments($databaseId: String!, $collectionId: String!, $queries: [String!]) {
|
|
324
325
|
databasesListDocuments(
|
|
325
326
|
databaseId: $databaseId
|
|
@@ -333,7 +334,7 @@ function Qe(e,i){return i}var h={kind:"Document",definitions:[{kind:"FragmentDef
|
|
|
333
334
|
}
|
|
334
335
|
}
|
|
335
336
|
}
|
|
336
|
-
`);function
|
|
337
|
+
`);function Ot({databaseId:e,collectionId:a,queries:n,subscribe:t=!0}){let{graphql:i}=r(),s=p(),c=m({queryKey:["appwrite","databases",e,a,{queries:n}],queryFn:async()=>{let{data:d,errors:l}=await i.query({query:Ke,variables:{databaseId:e,collectionId:a,queries:n}});if(l)throw l;let S=d.databasesListDocuments?.documents?.map(y=>({...y,...y?JSON.parse(y.data):{}}))??[];return {total:d.databasesListDocuments?.total??0,documents:S}}});return useEffect(()=>t?i.client.subscribe(`databases.${e}.collections.${a}.documents`,l=>{let[,S]=l.events[0].match(/\.(\w+)$/),y=l.payload;switch(S){case"create":case"update":case"delete":s.setQueryData(["appwrite","databases",e,a,"documents",y.$id],y),s.invalidateQueries({queryKey:["appwrite","databases",e,a,{queries:n}],exact:!0});break}}):void 0,[e,a,i.client,s,n,t]),{...c,documents:c.data?.documents,total:c.data?.total}}function Jt({databaseId:e,collectionId:a,queries:n,subscribe:t=!0}){let{graphql:i}=r(),s=p(),c=f({queryKey:["appwrite","databases",e,a,{queries:n}],queryFn:async()=>{let{data:d,errors:l}=await i.query({query:Ke,variables:{databaseId:e,collectionId:a,queries:n}});if(l)throw l;let S=d.databasesListDocuments?.documents?.map(y=>({...y,...y?JSON.parse(y.data):{}}))??[];return {total:d.databasesListDocuments?.total??0,documents:S}}});return useEffect(()=>t?i.client.subscribe(`databases.${e}.collections.${a}.documents`,l=>{let[,S]=l.events[0].match(/\.(\w+)$/),y=l.payload;switch(S){case"create":case"update":case"delete":s.setQueryData(["appwrite","databases",e,a,"documents",y.$id],y),s.invalidateQueries({queryKey:["appwrite","databases",e,a,{queries:n}],exact:!0});break}}):void 0,[e,a,i.client,s,n]),{...c,documents:c.data?.documents,total:c.data?.total}}function Kt(){let{databases:e}=r();return u({mutationFn:async({databaseId:n,collectionId:t,documentId:i,data:s,permissions:c})=>{let{data:d,errors:l}=await e.createDocument(n,t,i,s,c);if(l)throw l;return d}})}var Bt=o(`
|
|
337
338
|
mutation DeleteDocument($databaseId: String!, $collectionId: String!, $documentId: String!) {
|
|
338
339
|
databasesDeleteDocument(
|
|
339
340
|
databaseId: $databaseId
|
|
@@ -343,7 +344,7 @@ function Qe(e,i){return i}var h={kind:"Document",definitions:[{kind:"FragmentDef
|
|
|
343
344
|
status
|
|
344
345
|
}
|
|
345
346
|
}
|
|
346
|
-
`);function
|
|
347
|
+
`);function Wt(){let{graphql:e}=r(),a=p();return {...u({mutationFn:async({databaseId:t,collectionId:i,documentId:s})=>{let{data:c,errors:d}=await e.mutation({query:Bt,variables:{databaseId:t,collectionId:i,documentId:s}});if(d)throw d;return c.databasesDeleteDocument},onSuccess:async(t,i)=>{a.setQueryData(["appwrite","databases",i.databaseId,i.collectionId,"documents",i.documentId],null),a.removeQueries({queryKey:["appwrite","databases",i.databaseId,i.collectionId,"documents",i.documentId]});}})}}var zt=o(`
|
|
347
348
|
query GetDocument($databaseId: String!, $collectionId: String!, $documentId: String!) {
|
|
348
349
|
databasesGetDocument(
|
|
349
350
|
databaseId: $databaseId
|
|
@@ -354,7 +355,7 @@ function Qe(e,i){return i}var h={kind:"Document",definitions:[{kind:"FragmentDef
|
|
|
354
355
|
data
|
|
355
356
|
}
|
|
356
357
|
}
|
|
357
|
-
`);function
|
|
358
|
+
`);function Xt({databaseId:e,collectionId:a,documentId:n}){let{graphql:t}=r(),i=p(),s=m({queryKey:["appwrite","databases",e,a,"documents",n],queryFn:async()=>{let{data:c,errors:d}=await t.query({query:zt,variables:{databaseId:e,collectionId:a,documentId:n}});if(d)throw d;return {...c.databasesGetDocument,...c.databasesGetDocument?JSON.parse(c.databasesGetDocument.data):{}}}});return useEffect(()=>t.client.subscribe(`databases.${e}.collections.${a}.documents.${n}`,d=>{i.setQueryData(["appwrite","databases",e,a,"documents",n],d.payload);}),[e,a,n,t.client,i]),{...s}}function Ht(){let{databases:e}=r();return {...u({mutationFn:async({databaseId:n,collectionId:t,documentId:i,data:s,permissions:c})=>{let{data:d,errors:l}=await e.updateDocument(n,t,i,s,c);if(l)throw l;return d}})}}var Be=o(`
|
|
358
359
|
mutation CreateExecution(
|
|
359
360
|
$functionId: String!
|
|
360
361
|
$body: String
|
|
@@ -377,7 +378,7 @@ function Qe(e,i){return i}var h={kind:"Document",definitions:[{kind:"FragmentDef
|
|
|
377
378
|
duration
|
|
378
379
|
}
|
|
379
380
|
}
|
|
380
|
-
`),
|
|
381
|
+
`),We=o(`
|
|
381
382
|
query GetFunctionExecution($functionId: String!, $executionId: String!) {
|
|
382
383
|
functionsGetExecution(functionId: $functionId, executionId: $executionId) {
|
|
383
384
|
status
|
|
@@ -385,8 +386,8 @@ function Qe(e,i){return i}var h={kind:"Document",definitions:[{kind:"FragmentDef
|
|
|
385
386
|
duration
|
|
386
387
|
}
|
|
387
388
|
}
|
|
388
|
-
`);function
|
|
389
|
+
`);function Lu(){let{graphql:e}=r(),[a,n]=useState(null),[t,i]=useState(null),s=u({mutationFn:async({functionId:d,body:l={},async:S=!1,path:y="/",method:$="POST"})=>{i(d);let{data:g}=await e.mutation({query:Be,variables:{functionId:d,body:JSON.stringify(l),async:S,path:y,method:$}}),v=null,{_id:b,status:M,responseBody:C,errors:N}=g.functionsCreateExecution??{};if(M==="completed")return JSON.parse(C??"{}");if(M==="failed"&&N)throw new Error(N);n(b??null);let A=await new Promise((w,T)=>{v=e.client.subscribe(`executions.${b}`,k=>{switch(k.payload.status){case"completed":n(null),w(JSON.parse(k.payload.responseBody));break;case"failed":n(null),T(k.payload.errors);break}return 1});});return v?.(),A}}),c=m({queryKey:["appwrite","functions",t,a],queryFn:async()=>{if(!a||!t)return null;let{data:d}=await e.query({query:We,variables:{functionId:t,executionId:a}});return d.functionsGetExecution??{}}});return {executeFunction:s,currentExecution:c}}function Qu({functionId:e,body:a={},async:n=!1,path:t="/",method:i="POST"}){let{graphql:s}=r(),[c,d]=useState(null),[l,S]=useState(null),y=f({queryKey:["appwrite","functions",e,t],queryFn:async()=>{S(e);let{data:g}=await s.mutation({query:Be,variables:{functionId:e,body:JSON.stringify(a),async:n,path:t,method:i}}),v=null,{_id:b,status:M,responseBody:C,errors:N}=g.functionsCreateExecution??{};if(M==="completed")return JSON.parse(C??"{}");if(M==="failed"&&N)throw new Error(N);d(b??null);let A=await new Promise((w,T)=>{v=s.client.subscribe(`executions.${b}`,k=>{switch(k.payload.status){case"completed":d(null),w(JSON.parse(k.payload.responseBody));break;case"failed":d(null),T(k.payload.errors);break}return 1});});return v?.(),A}}),$=m({queryKey:["appwrite","functions",l,c],queryFn:async()=>{if(!c||!l)return null;let{data:g}=await s.query({query:We,variables:{functionId:l,executionId:c}});return g.functionsGetExecution??{}}});return {executeFunction:y,currentExecution:$}}var Yt;(n=>(n.Account_UserFragment=he,n.Identity_ProviderFragment=Ve))(Yt||={});
|
|
389
390
|
|
|
390
|
-
export {
|
|
391
|
+
export { ln as AppwriteProvider, Yt as fragments, je as getFragmentData, kn as useAccount, r as useAppwrite, Ot as useCollection, gn as useCreateAnonymousSession, Kt as useCreateDocument, bn as useCreateEmailToken, Mn as useCreateJWT, xn as useCreateMagicURLToken, $n as useCreateMfaAuthenticator, An as useCreateMfaChallenge, Tn as useCreateMfaRecoveryCodes, hn as useCreatePhoneToken, qn as useCreatePhoneVerification, Fn as useCreateSession, Wt as useDeleteDocument, Pn as useDeleteIdentity, Ln as useDeleteMfaAuthenticator, Gn as useDeleteSession, Jn as useDeleteSessions, Xt as useDocument, Lu as useFunction, Bn as useGetMfaRecoveryCodes, jn as useGetPrefs, Xn as useGetSession, Sn as useLazyAccount, _ as useLazyQuery, Yn as useListIdentities, et as useListMfaFactors, tt as useListSessions, it as useLogin, rt as useLogout, ut as useLogs, u as useMutation, dt as usePasswordRecovery, m as useQuery, p as useQueryClient, pt as useResetPassword, St as useSignUp, Jt as useSuspenseCollection, Nn as useSuspenseCreateJWT, Qu as useSuspenseFunction, f as useSuspenseQuery, Ht as useUpdateDocument, ft as useUpdateEmail, vt as useUpdateMagicURLSession, Mt as useUpdateMfa, Dt as useUpdateMfaAuthenticator, It as useUpdateMfaChallenge, Ct as useUpdateMfaRecoveryCodes, wt as useUpdateName, Ut as useUpdatePassword, Vt as useUpdatePhone, _t as useUpdatePhoneSession, Et as useUpdatePhoneVerification, Pt as useUpdatePrefs, Lt as useUpdateSession, Gt as useVerification };
|
|
391
392
|
//# sourceMappingURL=out.js.map
|
|
392
393
|
//# sourceMappingURL=index.mjs.map
|