Skip to main content

API Reference

This documentation covers all public API endpoints available in Lormex.

Endpoints Overview

EndpointMethodDescription
/api/servicesGETList all services with pagination
/api/services/:slugGETGet details of a specific service
/api/visitorsGETGet active visitor count
/api/visitorsPOSTRegister an active session
/api/overviewGETGet all services with 24h history
/api/revivalsGETList revivals with pagination
/api/metricsGETGet metrics for a specific service
/api/metricsPOSTSubmit metrics for a service
/api/metrics/allGETGet metrics for all services
/api/metrics/historyGETGet historical data for all services

Authentication

Currently, all API endpoints are publicly accessible without authentication.

Response Codes

CodeDescription
200Success
400Bad Request - Invalid parameters
403Forbidden - Invalid request (bots blocked)
404Not Found - Resource doesn’t exist
415Unsupported Media Type
500Internal Server Error

Caching

Most endpoints include caching headers:
  • s-maxage=30 - CDN cache for 30 seconds
  • stale-while-revalidate=120 - Serve stale while refreshing
Some endpoints like /api/overview and /api/metrics/history use no-store for real-time data.