OTP Authentication
- Client sends email to
POST /auth/login - Sinas sends a 6-digit code to that email (valid for 10 minutes by default)
- Client submits code to
POST /auth/verify-otp - Sinas returns an access token (short-lived JWT, default 15 min) and a refresh token (long-lived, default 30 days)
- Use the access token in the
Authorization: Bearer <token>header - When the access token expires, use
POST /auth/refreshto get a new one
API Keys
For programmatic access (scripts, CI/CD, integrations), create API keys instead of using short-lived JWT tokens. Each key has its own set of permissions (a subset of the creating user’s permissions).Authorization: Bearer <key> or X-API-Key: <key> headers. Keys can have optional expiration dates.