You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/account.md
+34-4Lines changed: 34 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -580,7 +580,7 @@ A user is limited to 10 active sessions at a time by default. [Learn more about
580
580
581
581
582
582
```http request
583
-
POST https://cloud.appwrite.io/v1/account/verification
583
+
POST https://cloud.appwrite.io/v1/account/verifications/email
584
584
```
585
585
586
586
** Use this endpoint to send a verification message to your user email address to confirm they are the valid owners of that address. Both the **userId** and **secret** arguments will be passed as query parameters to the URL you have provided to be attached to the verification email. The provided URL should redirect the user back to your app and allow you to complete the verification process by verifying both the **userId** and **secret** parameters. Learn more about how to [complete the verification process](https://appwrite.io/docs/references/cloud/client-web/account#updateVerification). The verification link sent to the user's email address is valid for 7 days.
@@ -596,7 +596,37 @@ Please note that in order to avoid a [Redirect Attack](https://github.com/OWASP/
596
596
597
597
598
598
```http request
599
-
PUT https://cloud.appwrite.io/v1/account/verification
599
+
POST https://cloud.appwrite.io/v1/account/verifications/email
600
+
```
601
+
602
+
** Use this endpoint to send a verification message to your user email address to confirm they are the valid owners of that address. Both the **userId** and **secret** arguments will be passed as query parameters to the URL you have provided to be attached to the verification email. The provided URL should redirect the user back to your app and allow you to complete the verification process by verifying both the **userId** and **secret** parameters. Learn more about how to [complete the verification process](https://appwrite.io/docs/references/cloud/client-web/account#updateVerification). The verification link sent to the user's email address is valid for 7 days.
603
+
604
+
Please note that in order to avoid a [Redirect Attack](https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.md), the only valid redirect URLs are the ones from domains you have set when adding your platforms in the console interface.
605
+
**
606
+
607
+
### Parameters
608
+
609
+
| Field Name | Type | Description | Default |
610
+
| --- | --- | --- | --- |
611
+
| url | string | URL to redirect the user back to your app from the verification email. Only URLs from hostnames in your project platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API. ||
612
+
613
+
614
+
```http request
615
+
PUT https://cloud.appwrite.io/v1/account/verifications/email
616
+
```
617
+
618
+
** Use this endpoint to complete the user email verification process. Use both the **userId** and **secret** parameters that were attached to your app URL to verify the user email ownership. If confirmed this route will return a 200 status code. **
619
+
620
+
### Parameters
621
+
622
+
| Field Name | Type | Description | Default |
623
+
| --- | --- | --- | --- |
624
+
| userId | string | User ID. ||
625
+
| secret | string | Valid verification token. ||
626
+
627
+
628
+
```http request
629
+
PUT https://cloud.appwrite.io/v1/account/verifications/email
600
630
```
601
631
602
632
** Use this endpoint to complete the user email verification process. Use both the **userId** and **secret** parameters that were attached to your app URL to verify the user email ownership. If confirmed this route will return a 200 status code. **
@@ -610,14 +640,14 @@ PUT https://cloud.appwrite.io/v1/account/verification
610
640
611
641
612
642
```http request
613
-
POST https://cloud.appwrite.io/v1/account/verification/phone
643
+
POST https://cloud.appwrite.io/v1/account/verifications/phone
614
644
```
615
645
616
646
** Use this endpoint to send a verification SMS to the currently logged in user. This endpoint is meant for use after updating a user's phone number using the [accountUpdatePhone](https://appwrite.io/docs/references/cloud/client-web/account#updatePhone) endpoint. Learn more about how to [complete the verification process](https://appwrite.io/docs/references/cloud/client-web/account#updatePhoneVerification). The verification code sent to the user's phone number is valid for 15 minutes. **
617
647
618
648
619
649
```http request
620
-
PUT https://cloud.appwrite.io/v1/account/verification/phone
650
+
PUT https://cloud.appwrite.io/v1/account/verifications/phone
621
651
```
622
652
623
653
** Use this endpoint to complete the user phone verification process. Use the **userId** and **secret** that were sent to your user's phone number to verify the user email ownership. If confirmed this route will return a 200 status code. **
0 commit comments