Skip to main content
Create or update an account by submitting your details along with the OTP you received from Request OTP. All four required fields must be present and the OTP must still be valid.

Request

POST /auth/signup
name
string
required
The user’s display name.
email
string
required
The email address associated with the account.
password
string
required
The password for the new account.
otp
string
required
The one-time password sent to your email via the Request OTP endpoint.
role
string
The account role. Accepted values: USER, RIDER, DRIVER, ADMIN. Defaults to the application’s default role if omitted.

Response

message
string
Returns "Account created/updated successfully." on success.

Example

curl -X POST http://localhost:8080/auth/signup \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Alex",
    "email": "alex@example.com",
    "password": "s3cur3P@ss",
    "otp": "482910"
  }'
The OTP must be valid and not expired. Request a new OTP via Request OTP if yours has expired.

Error codes

StatusMeaning
400One or more required fields are missing, the OTP is absent, or the OTP is invalid/expired