Skip to main content
POST
/
auth
/
verify
Verify email
curl --request POST \
  --url https://store.salesive.com/api/v1/auth/verify \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --header 'x-shop-id: <api-key>' \
  --data '
{
  "email": "[email protected]",
  "otp": "<string>"
}
'
{
  "status": 123,
  "success": true,
  "message": "<string>",
  "data": {
    "_id": "<string>",
    "email": "[email protected]",
    "token": "<string>"
  }
}

Request

POST /auth/verify
Content-Type: application/json
x-shop-id: {shopId}
{
  "email": "[email protected]",
  "otp": "773390"
}

Headers

HeaderTypeDescription
Content-TypestringAlways set to application/json.
x-shop-idstringShop identifier to associate the user with your store.

Body parameters

FieldTypeRequiredDescription
emailstringYesEmail address that requested the verification code.
otpstringYesSix-digit one-time code the shopper received by email.

Successful response

{
    "status": 200,
    "success": true,
    "message": "Email verified successfully",
    "data": {
        "_id": "68f976e92bb0b821425fdda6",
        "email": "[email protected]",
        "token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9"
    }
}
You receive shopper identifiers and a JWT token, confirming that the email verification succeeded.

Error responses

{
    "status": 400,
    "success": false,
    "message": "Invalid OTP",
    "data": {}
}
{
    "status": 404,
    "success": false,
    "message": "User not found",
    "data": {}
}

Authorizations

Authorization
string
header
required

JWT issued by the Salesive Store API for authenticated shoppers.

x-shop-id
string
header
required

Optional storefront identifier sent as a header to scope responses to a specific shop. Try It requests remember this value once provided.

Headers

x-shop-id
string

Optional identifier that scopes responses to a specific storefront when the referer cannot be inferred.

Body

application/json
email
string<email>
required

Email address that requested the verification code.

otp
string
required

Six-digit one-time code the shopper received by email.

Response

Email verified and session token issued.

status
integer
required
success
boolean
required
message
string
required
data
object
required