Authentication
Register, log in, and manage access tokens. TeXeR uses email-based OTP (one-time password) authentication. After verifying an OTP, you receive a JWT that must be included in all subsequent API requests.
Base URL
All API requests use the following base URL:
Terminal
https://api.texer.orgInclude your token in the Authorization header:
Terminal
Authorization: Bearer YOUR_TOKENPOST /auth/signup
Create a new account. An OTP will be sent to the provided email address.
Auth: None required
Terminal
curl -X POST https://api.texer.org/auth/signup \
-H "Content-Type: application/json" \
-d '{"email": "user@university.edu", "name": "Jane Doe"}'JSON
{
"message": "Account created. OTP sent to user@university.edu",
"expires_in": 300
}POST /auth/login
Request an OTP for an existing account. The code is valid for 5 minutes.
Auth: None required
Terminal
curl -X POST https://api.texer.org/auth/login \
-H "Content-Type: application/json" \
-d '{"email": "user@university.edu"}'JSON
{
"message": "OTP sent to user@university.edu",
"expires_in": 300
}POST /auth/verify-login
Submit the OTP code to receive a JWT access token. This token is used for all authenticated endpoints.
Auth: None required
Terminal
curl -X POST https://api.texer.org/auth/verify-login \
-H "Content-Type: application/json" \
-d '{"email": "user@university.edu", "otp": "482910"}'JSON
{
"token": "eyJhbGciOiJIUzI1NiIs...",
"user": {
"uid": "usr_a1b2c3d4",
"email": "user@university.edu",
"name": "Jane Doe",
"plan": "free"
}
}