Email Addresses

Used to interact with the email addresses of the logged in user.

Get Email Addresses

Retrieve all the email addresses associated with the current user.

SecurityDevBrowser or ProductionBrowser or ProductionNativeApp and ProductionNativeFlag)
Request
query Parameters
_clerk_session_id
string

The session_id associated with the requesting user.

Responses
200

Returns UserEmailAddresses array.

401

Request was not successful

403

Request was not successful

404

Request was not successful

get/v1/me/email_addresses
Response samples
application/json
[
  • {
    }
]

Create Email Address

Add an email address to the current user. The address then needs to be verified using the prepare_verification and attempt_verification endpoints.

SecurityDevBrowser or ProductionBrowser or ProductionNativeApp and ProductionNativeFlag)
Request
query Parameters
_clerk_session_id
string

The session_id associated with the requesting user.

Request Body schema: application/x-www-form-urlencoded
email_address
string

The email address to be added to the user.

Responses
200

Returns the response for Session wrapped Email object.

400

Request was not successful

401

Request was not successful

403

Request was not successful

404

Request was not successful

422

Request was not successful

post/v1/me/email_addresses
Request samples
application/x-www-form-urlencoded
email_address=string
Response samples
application/json
{
  • "response": {
    },
  • "client": {
    }
}

Attempt Email Address Verification

Attempt to verify an email address that was previously created.

SecurityDevBrowser or ProductionBrowser or ProductionNativeApp and ProductionNativeFlag)
Request
path Parameters
email_id
required
string

The email_id.

query Parameters
_clerk_session_id
string

The session_id associated with the requesting user.

Request Body schema: application/x-www-form-urlencoded
code
string

The code that was previously sent to the email address.

Responses
200

Returns the response for Session wrapped Email object.

400

Request was not successful

401

Request was not successful

403

Request was not successful

404

Request was not successful

422

Request was not successful

post/v1/me/email_addresses/{email_id}/attempt_verification
Request samples
application/x-www-form-urlencoded
code=string
Response samples
application/json
{
  • "response": {
    },
  • "client": {
    }
}

Prepare Email Address Verification

Depending on the given strategy, the API will prepare the verification for the email address. In particular, * for email_code, the API will send a verification email to the address containing a code. * for email_link, the API will send a verification email to the address containg a link to the verification attempt endpoint.

SecurityDevBrowser or ProductionBrowser or ProductionNativeApp and ProductionNativeFlag)
Request
path Parameters
email_id
required
string

The email_id.

query Parameters
_clerk_session_id
string

The session_id associated with the requesting user.

Request Body schema: application/x-www-form-urlencoded
strategy
string

The strategy to be prepared for email verification.

Enum: "email_code" "email_link"
redirect_url
string or null

Used with the email_link strategy.

Responses
200

Returns the response for Session wrapped Email object.

401

Request was not successful

403

Request was not successful

404

Request was not successful

422

Request was not successful

post/v1/me/email_addresses/{email_id}/prepare_verification
Request samples
application/x-www-form-urlencoded
strategy=email_code&redirect_url=string
Response samples
application/json
{
  • "response": {
    },
  • "client": {
    }
}

Get Email Address

Retrieve an email address by id.

SecurityDevBrowser or ProductionBrowser or ProductionNativeApp and ProductionNativeFlag)
Request
path Parameters
email_id
required
string

The email_id.

query Parameters
_clerk_session_id
string

The session_id associated with the requesting user.

Responses
200

Returns the response for Session wrapped Email object.

401

Request was not successful

403

Request was not successful

404

Request was not successful

get/v1/me/email_addresses/{email_id}
Response samples
application/json
{
  • "response": {
    },
  • "client": {
    }
}

Delete email address

Delete an email address by id.

SecurityDevBrowser or ProductionBrowser or ProductionNativeApp and ProductionNativeFlag)
Request
path Parameters
email_id
required
string

The email_id.

query Parameters
_clerk_session_id
string

The session_id associated with the requesting user.

Responses
200

Returns a Deleted User object.

400

Request was not successful

401

Request was not successful

403

Request was not successful

404

Request was not successful

delete/v1/me/email_addresses/{email_id}
Response samples
application/json
{
  • "response": {
    },
  • "client": {
    }
}