Authentication
Protected endpoints take a bearer token issued to a signed-in session.
GET /api/investor/portfolio-summary
Authorization: Bearer <session access token>A service key is a database credential, not an API authority. It is never accepted as a bearer token on an application endpoint.
Error shape
Errors return a JSON object with a human-readable message, and a stable code where the caller is expected to branch on it.
{
"error": "Multi-factor verification required.",
"code": "MFA_REQUIRED"
}| Status | Meaning |
|---|---|
| 401 | No session, or the token is not valid |
| 403 | Authenticated, but not entitled to this resource — or suspended |
| 404 | Not found, or not yours; the two are deliberately indistinguishable |
| 400 | The request is malformed, or names a resource that is not yours to reference |
| 429 | Rate limited |
Multi-factor
| Code | What the caller must do |
|---|---|
| MFA_REQUIRED | The account holds a verified factor — present a session that has satisfied it |
| MFA_ENROLLMENT_REQUIRED | The account's role requires a second factor and has none — enrol one |
Rate limits
Limits are applied per actor, per rolling window. When a limit is exceeded the response is 429 and carries the headers below; honour Retry-After rather than retrying immediately.
HTTP/1.1 429 Too Many Requests
Retry-After: 60
X-RateLimit-Limit: 60
X-RateLimit-Window: 60Sensitive families — administration, verification, and assistant endpoints — carry a tighter limit than ordinary investor and issuer endpoints.
