Skip to main content

API Reference

Visage provides both REST and WebSocket APIs for face recognition functionality.

Base URL

http://localhost:8000/api/v1

Authentication

Currently, Visage runs on localhost without authentication. For production deployments, implement proper authentication.

Available Endpoints

REST Endpoints

MethodEndpointDescription
GET/healthHealth check
POST/registerRegister a new person
GET/personsList all registered persons
GET/persons/{id}Get person details
DELETE/persons/{id}Delete a person
POST/identifyIdentify a face from image

WebSocket Endpoints

EndpointDescription
/ws/identifyReal-time face identification stream

Response Format

All REST endpoints return JSON responses:

{
"success": true,
"data": {
// Response data
},
"error": null
}

Error responses:

{
"success": false,
"data": null,
"error": {
"code": "ERROR_CODE",
"message": "Human-readable error message"
}
}

Rate Limiting

No rate limiting is currently implemented. Consider adding rate limiting for production use.

Next Steps