API Reference
The Apostille system exposes three API groups, each with its own authentication requirements.
API Groups
| API | Base Path | Auth | Description |
|---|---|---|---|
| Citizen | /citizen | Cognito (Citizen Pool) | Endpoints for citizen portal |
| Admin | /admin | Cognito (Admin Pool) | Endpoints for admin portal |
| Public | /public | None | Public verification endpoint |
Authentication
All protected endpoints require a valid JWT token in the Authorization header:
Authorization: Bearer <token>Tokens are obtained through Cognito authentication flows.
Common Response Format
Success Response
{
"data": { ... },
"message": "Operation successful"
}Error Response
{
"error": {
"code": "VALIDATION_ERROR",
"message": "Description of the error"
}
}HTTP Status Codes
| Code | Description |
|---|---|
| 200 | Success |
| 201 | Created |
| 400 | Bad Request - Invalid input |
| 401 | Unauthorized - Missing or invalid token |
| 403 | Forbidden - Insufficient permissions |
| 404 | Not Found |
| 500 | Internal Server Error |
Last updated on