react-native-appwrite 0.4.0 → 0.5.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.
Files changed (111) hide show
  1. package/.github/workflows/autoclose.yml +11 -0
  2. package/README.md +2 -2
  3. package/dist/cjs/sdk.js +19 -16
  4. package/dist/cjs/sdk.js.map +1 -1
  5. package/dist/esm/sdk.js +19 -16
  6. package/dist/esm/sdk.js.map +1 -1
  7. package/docs/examples/account/create-anonymous-session.md +2 -2
  8. package/docs/examples/account/create-email-password-session.md +2 -2
  9. package/docs/examples/account/create-email-token.md +2 -2
  10. package/docs/examples/account/create-j-w-t.md +2 -2
  11. package/docs/examples/account/create-magic-u-r-l-token.md +2 -2
  12. package/docs/examples/account/create-mfa-authenticator.md +2 -2
  13. package/docs/examples/account/create-mfa-challenge.md +2 -2
  14. package/docs/examples/account/create-mfa-recovery-codes.md +2 -2
  15. package/docs/examples/account/create-o-auth2session.md +1 -1
  16. package/docs/examples/account/create-o-auth2token.md +1 -1
  17. package/docs/examples/account/create-phone-token.md +2 -2
  18. package/docs/examples/account/create-phone-verification.md +2 -2
  19. package/docs/examples/account/create-push-target.md +2 -2
  20. package/docs/examples/account/create-recovery.md +2 -2
  21. package/docs/examples/account/create-session.md +2 -2
  22. package/docs/examples/account/create-verification.md +2 -2
  23. package/docs/examples/account/create.md +2 -2
  24. package/docs/examples/account/delete-identity.md +2 -2
  25. package/docs/examples/account/delete-mfa-authenticator.md +3 -4
  26. package/docs/examples/account/delete-push-target.md +2 -2
  27. package/docs/examples/account/delete-session.md +2 -2
  28. package/docs/examples/account/delete-sessions.md +2 -2
  29. package/docs/examples/account/get-mfa-recovery-codes.md +2 -2
  30. package/docs/examples/account/get-prefs.md +2 -2
  31. package/docs/examples/account/get-session.md +2 -2
  32. package/docs/examples/account/get.md +2 -2
  33. package/docs/examples/account/list-identities.md +2 -2
  34. package/docs/examples/account/list-logs.md +2 -2
  35. package/docs/examples/account/list-mfa-factors.md +2 -2
  36. package/docs/examples/account/list-sessions.md +2 -2
  37. package/docs/examples/account/update-email.md +2 -2
  38. package/docs/examples/account/update-m-f-a.md +2 -2
  39. package/docs/examples/account/update-magic-u-r-l-session.md +2 -2
  40. package/docs/examples/account/update-mfa-authenticator.md +2 -2
  41. package/docs/examples/account/update-mfa-challenge.md +2 -2
  42. package/docs/examples/account/update-mfa-recovery-codes.md +2 -2
  43. package/docs/examples/account/update-name.md +2 -2
  44. package/docs/examples/account/update-password.md +2 -2
  45. package/docs/examples/account/update-phone-session.md +2 -2
  46. package/docs/examples/account/update-phone-verification.md +2 -2
  47. package/docs/examples/account/update-phone.md +2 -2
  48. package/docs/examples/account/update-prefs.md +2 -2
  49. package/docs/examples/account/update-push-target.md +2 -2
  50. package/docs/examples/account/update-recovery.md +2 -2
  51. package/docs/examples/account/update-session.md +2 -2
  52. package/docs/examples/account/update-status.md +2 -2
  53. package/docs/examples/account/update-verification.md +2 -2
  54. package/docs/examples/avatars/get-browser.md +1 -1
  55. package/docs/examples/avatars/get-credit-card.md +1 -1
  56. package/docs/examples/avatars/get-favicon.md +1 -1
  57. package/docs/examples/avatars/get-flag.md +1 -1
  58. package/docs/examples/avatars/get-image.md +1 -1
  59. package/docs/examples/avatars/get-initials.md +1 -1
  60. package/docs/examples/avatars/get-q-r.md +1 -1
  61. package/docs/examples/databases/create-document.md +2 -2
  62. package/docs/examples/databases/delete-document.md +2 -2
  63. package/docs/examples/databases/get-document.md +2 -2
  64. package/docs/examples/databases/list-documents.md +2 -2
  65. package/docs/examples/databases/update-document.md +2 -2
  66. package/docs/examples/functions/create-execution.md +4 -3
  67. package/docs/examples/functions/get-execution.md +2 -2
  68. package/docs/examples/functions/list-executions.md +2 -2
  69. package/docs/examples/graphql/mutation.md +2 -2
  70. package/docs/examples/graphql/query.md +2 -2
  71. package/docs/examples/locale/get.md +2 -2
  72. package/docs/examples/locale/list-codes.md +2 -2
  73. package/docs/examples/locale/list-continents.md +2 -2
  74. package/docs/examples/locale/list-countries-e-u.md +2 -2
  75. package/docs/examples/locale/list-countries-phones.md +2 -2
  76. package/docs/examples/locale/list-countries.md +2 -2
  77. package/docs/examples/locale/list-currencies.md +2 -2
  78. package/docs/examples/locale/list-languages.md +2 -2
  79. package/docs/examples/messaging/create-subscriber.md +2 -2
  80. package/docs/examples/messaging/delete-subscriber.md +2 -2
  81. package/docs/examples/storage/create-file.md +2 -2
  82. package/docs/examples/storage/delete-file.md +2 -2
  83. package/docs/examples/storage/get-file-download.md +1 -1
  84. package/docs/examples/storage/get-file-preview.md +1 -1
  85. package/docs/examples/storage/get-file-view.md +1 -1
  86. package/docs/examples/storage/get-file.md +2 -2
  87. package/docs/examples/storage/list-files.md +2 -2
  88. package/docs/examples/storage/update-file.md +2 -2
  89. package/docs/examples/teams/create-membership.md +2 -2
  90. package/docs/examples/teams/create.md +2 -2
  91. package/docs/examples/teams/delete-membership.md +2 -2
  92. package/docs/examples/teams/delete.md +2 -2
  93. package/docs/examples/teams/get-membership.md +2 -2
  94. package/docs/examples/teams/get-prefs.md +2 -2
  95. package/docs/examples/teams/get.md +2 -2
  96. package/docs/examples/teams/list-memberships.md +2 -2
  97. package/docs/examples/teams/list.md +2 -2
  98. package/docs/examples/teams/update-membership-status.md +2 -2
  99. package/docs/examples/teams/update-membership.md +2 -2
  100. package/docs/examples/teams/update-name.md +2 -2
  101. package/docs/examples/teams/update-prefs.md +2 -2
  102. package/package.json +1 -1
  103. package/src/client.ts +7 -2
  104. package/src/models.ts +4 -0
  105. package/src/services/account.ts +6 -15
  106. package/src/services/avatars.ts +2 -0
  107. package/src/services/functions.ts +6 -1
  108. package/types/models.d.ts +4 -0
  109. package/types/services/account.d.ts +5 -6
  110. package/types/services/avatars.d.ts +2 -0
  111. package/types/services/functions.d.ts +2 -1
@@ -2,10 +2,10 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
9
9
  const result = await account.createAnonymousSession();
10
10
 
11
- console.log(response);
11
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -11,4 +11,4 @@ const result = await account.createEmailPasswordSession(
11
11
  'password' // password
12
12
  );
13
13
 
14
- console.log(response);
14
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -12,4 +12,4 @@ const result = await account.createEmailToken(
12
12
  false // phrase (optional)
13
13
  );
14
14
 
15
- console.log(response);
15
+ console.log(result);
@@ -2,10 +2,10 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
9
9
  const result = await account.createJWT();
10
10
 
11
- console.log(response);
11
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -13,4 +13,4 @@ const result = await account.createMagicURLToken(
13
13
  false // phrase (optional)
14
14
  );
15
15
 
16
- console.log(response);
16
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account, AuthenticatorType } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -10,4 +10,4 @@ const result = await account.createMfaAuthenticator(
10
10
  AuthenticatorType.Totp // type
11
11
  );
12
12
 
13
- console.log(response);
13
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account, AuthenticationFactor } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -10,4 +10,4 @@ const result = await account.createMfaChallenge(
10
10
  AuthenticationFactor.Email // factor
11
11
  );
12
12
 
13
- console.log(response);
13
+ console.log(result);
@@ -2,10 +2,10 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
9
9
  const result = await account.createMfaRecoveryCodes();
10
10
 
11
- console.log(response);
11
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account, OAuthProvider } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -2,7 +2,7 @@ import { Client, Account, OAuthProvider } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -11,4 +11,4 @@ const result = await account.createPhoneToken(
11
11
  '+12065550100' // phone
12
12
  );
13
13
 
14
- console.log(response);
14
+ console.log(result);
@@ -2,10 +2,10 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
9
9
  const result = await account.createPhoneVerification();
10
10
 
11
- console.log(response);
11
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -12,4 +12,4 @@ const result = await account.createPushTarget(
12
12
  '<PROVIDER_ID>' // providerId (optional)
13
13
  );
14
14
 
15
- console.log(response);
15
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -11,4 +11,4 @@ const result = await account.createRecovery(
11
11
  'https://example.com' // url
12
12
  );
13
13
 
14
- console.log(response);
14
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -11,4 +11,4 @@ const result = await account.createSession(
11
11
  '<SECRET>' // secret
12
12
  );
13
13
 
14
- console.log(response);
14
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -10,4 +10,4 @@ const result = await account.createVerification(
10
10
  'https://example.com' // url
11
11
  );
12
12
 
13
- console.log(response);
13
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -13,4 +13,4 @@ const result = await account.create(
13
13
  '<NAME>' // name (optional)
14
14
  );
15
15
 
16
- console.log(response);
16
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -10,4 +10,4 @@ const result = await account.deleteIdentity(
10
10
  '<IDENTITY_ID>' // identityId
11
11
  );
12
12
 
13
- console.log(response);
13
+ console.log(result);
@@ -2,13 +2,12 @@ import { Client, Account, AuthenticatorType } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
9
9
  const result = await account.deleteMfaAuthenticator(
10
- AuthenticatorType.Totp, // type
11
- '<OTP>' // otp
10
+ AuthenticatorType.Totp // type
12
11
  );
13
12
 
14
- console.log(response);
13
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -10,4 +10,4 @@ const result = await account.deletePushTarget(
10
10
  '<TARGET_ID>' // targetId
11
11
  );
12
12
 
13
- console.log(response);
13
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -10,4 +10,4 @@ const result = await account.deleteSession(
10
10
  '<SESSION_ID>' // sessionId
11
11
  );
12
12
 
13
- console.log(response);
13
+ console.log(result);
@@ -2,10 +2,10 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
9
9
  const result = await account.deleteSessions();
10
10
 
11
- console.log(response);
11
+ console.log(result);
@@ -2,10 +2,10 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
9
9
  const result = await account.getMfaRecoveryCodes();
10
10
 
11
- console.log(response);
11
+ console.log(result);
@@ -2,10 +2,10 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
9
9
  const result = await account.getPrefs();
10
10
 
11
- console.log(response);
11
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -10,4 +10,4 @@ const result = await account.getSession(
10
10
  '<SESSION_ID>' // sessionId
11
11
  );
12
12
 
13
- console.log(response);
13
+ console.log(result);
@@ -2,10 +2,10 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
9
9
  const result = await account.get();
10
10
 
11
- console.log(response);
11
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -10,4 +10,4 @@ const result = await account.listIdentities(
10
10
  [] // queries (optional)
11
11
  );
12
12
 
13
- console.log(response);
13
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -10,4 +10,4 @@ const result = await account.listLogs(
10
10
  [] // queries (optional)
11
11
  );
12
12
 
13
- console.log(response);
13
+ console.log(result);
@@ -2,10 +2,10 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
9
9
  const result = await account.listMfaFactors();
10
10
 
11
- console.log(response);
11
+ console.log(result);
@@ -2,10 +2,10 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
9
9
  const result = await account.listSessions();
10
10
 
11
- console.log(response);
11
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -11,4 +11,4 @@ const result = await account.updateEmail(
11
11
  'password' // password
12
12
  );
13
13
 
14
- console.log(response);
14
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -10,4 +10,4 @@ const result = await account.updateMFA(
10
10
  false // mfa
11
11
  );
12
12
 
13
- console.log(response);
13
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -11,4 +11,4 @@ const result = await account.updateMagicURLSession(
11
11
  '<SECRET>' // secret
12
12
  );
13
13
 
14
- console.log(response);
14
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account, AuthenticatorType } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -11,4 +11,4 @@ const result = await account.updateMfaAuthenticator(
11
11
  '<OTP>' // otp
12
12
  );
13
13
 
14
- console.log(response);
14
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -11,4 +11,4 @@ const result = await account.updateMfaChallenge(
11
11
  '<OTP>' // otp
12
12
  );
13
13
 
14
- console.log(response);
14
+ console.log(result);
@@ -2,10 +2,10 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
9
9
  const result = await account.updateMfaRecoveryCodes();
10
10
 
11
- console.log(response);
11
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -10,4 +10,4 @@ const result = await account.updateName(
10
10
  '<NAME>' // name
11
11
  );
12
12
 
13
- console.log(response);
13
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -11,4 +11,4 @@ const result = await account.updatePassword(
11
11
  'password' // oldPassword (optional)
12
12
  );
13
13
 
14
- console.log(response);
14
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -11,4 +11,4 @@ const result = await account.updatePhoneSession(
11
11
  '<SECRET>' // secret
12
12
  );
13
13
 
14
- console.log(response);
14
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -11,4 +11,4 @@ const result = await account.updatePhoneVerification(
11
11
  '<SECRET>' // secret
12
12
  );
13
13
 
14
- console.log(response);
14
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -11,4 +11,4 @@ const result = await account.updatePhone(
11
11
  'password' // password
12
12
  );
13
13
 
14
- console.log(response);
14
+ console.log(result);
@@ -2,7 +2,7 @@ import { Client, Account } from "react-native-appwrite";
2
2
 
3
3
  const client = new Client()
4
4
  .setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5
- .setProject('5df5acd0d48c2'); // Your project ID
5
+ .setProject('<YOUR_PROJECT_ID>'); // Your project ID
6
6
 
7
7
  const account = new Account(client);
8
8
 
@@ -10,4 +10,4 @@ const result = await account.updatePrefs(
10
10
  {} // prefs
11
11
  );
12
12
 
13
- console.log(response);
13
+ console.log(result);