pub struct VerifyEmail;
Expand description
Verify a user’s email.
§Register Flow
POST /v1/user
- This will send the email for verification
POST
this route with the Verify request.- recieve one of:
- a 200 (
NewSessionResponse
) - a 401 response (
<token>
is invalid)
- a 200 (
- recieve one of:
§Change email Flow (NOT CURRENTLY IMPLEMENTED)
PUT /v1/user/me/email
- this will send an email to verify the old address
POST
this route with the token from the email- this will send an email to verify the new address
POST
this route again with the token from the new address- The new email will get set at this point, recieve one of:
- a 204 (success!)
- a 401 response (
token
is invalid)
- The new email will get set at this point, recieve one of:
§Resend verification email
POST
this route with no auth andResend
- this resend will the verification email
- this will always return a 204 on success.
- Continue the flow you were in.
If no verification is in progress, no email will be sent.
Trait Implementations§
Source§impl ApiEndpoint for VerifyEmail
impl ApiEndpoint for VerifyEmail
Source§type Req = VerifyEmailRequest
type Req = VerifyEmailRequest
The request type for this endpoint.
Source§type Res = Option<NewSessionResponse>
type Res = Option<NewSessionResponse>
The response type for this endpoint.
Source§type Path = VerifyEmailPath
type Path = VerifyEmailPath
The path type for this endpoint.
Source§type Err = EmptyError
type Err = EmptyError
The (inner) error type for this endpoint.
Auto Trait Implementations§
impl Freeze for VerifyEmail
impl RefUnwindSafe for VerifyEmail
impl Send for VerifyEmail
impl Sync for VerifyEmail
impl Unpin for VerifyEmail
impl UnwindSafe for VerifyEmail
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more