Skip to main content
After creating an account, Hyparrow sends a 6-digit OTP to your email. Submitting that OTP to this endpoint confirms your address, activates your account, and returns a JWT so you can start making authenticated requests immediately.

Verify email

Endpoint

POST https://api.hyparrow.com/api/v1/auth/verify-email

Request body

email
string
required
The email address you registered with.
otp
string
required
The 6-digit verification code sent to your email. OTPs expire after 10 minutes.

Response

success
boolean
true when the OTP is valid and the email is confirmed.
message
string
A human-readable confirmation string.
data
object

Examples

curl -X POST https://api.hyparrow.com/api/v1/auth/verify-email \
  -H "Content-Type: application/json" \
  -d '{
    "email": "ada.okafor@example.com",
    "otp": "482916"
  }'

Success response

{
  "success": true,
  "message": "Email verified successfully",
  "data": {
    "token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJlbWFpbCI6ImFkYS5va2Fmb3JAZXhhbXBsZS5jb20iLCJleHAiOjE3MDAwMDAwMDAsImlhdCI6MTY5OTkxMzYwMCwicm9sZSI6InVzZXIiLCJ1c2VySWQiOiJhMWIyYzNkNC1lNWY2LTc4OTAtYWJjZC1lZjEyMzQ1Njc4OTAifQ.signature",
    "user": {
      "id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
      "firstName": "Ada",
      "lastName": "Okafor",
      "email": "ada.okafor@example.com",
      "country": "NG",
      "role": "user",
      "accountType": "business",
      "accountStatus": "active",
      "kycStatus": "not_started",
      "emailVerified": true
    }
  }
}

Error response

{
  "success": false,
  "error": "invalid or expired OTP"
}

Resend OTP

If the OTP expired or was not delivered, use this endpoint to send a fresh code to your email address.

Endpoint

POST https://api.hyparrow.com/api/v1/auth/resend-otp

Request body

email
string
required
The email address associated with your unverified account.

Response

success
boolean
true when the new OTP is sent successfully.
message
string
Confirmation that the OTP was sent.

Examples

curl -X POST https://api.hyparrow.com/api/v1/auth/resend-otp \
  -H "Content-Type: application/json" \
  -d '{
    "email": "ada.okafor@example.com"
  }'

Success response

{
  "success": true,
  "message": "OTP sent successfully"
}

Error response

{
  "success": false,
  "error": "email already verified"
}
Each OTP is valid for 10 minutes. Requesting a new OTP does not invalidate previously sent codes; the most recently issued valid code will be accepted.