API reference
Shared capabilities for Trida products: Core (projects, keys, webhooks), Notify, Pay, Billing, AI. One API key per project; every key is scoped. Version 0.1.0. Generated from the OpenAPI contract: it cannot drift from the API.
Base URLs: https://api.trida.lu (Production), https://api-dev.trida.lu (Development). Authenticate with x-api-key.
Operations
GET /api/health
Liveness and readiness of this process
No scope required beyond a valid key.
Responses Status Meaning Body 200Healthy Health 503Database unreachable Health
Example curl -X GET "https://api.trida.lu/api/health" \
-H "x-api-key: $TRIDA_API_KEY"
core
GET /core/v1/projects/me
The project the API key belongs to, with its theme and languages
Required scope: projects:read
Responses
Example curl -X GET "https://api.trida.lu/core/v1/projects/me" \
-H "x-api-key: $TRIDA_API_KEY"
POST /core/v1/subjects/erase
Erase or anonymize a person in every capability of the project, keeping what the law requires to keep
Required scope: subjects:erase
Parameters Name In Type Required Notes idempotency-keyheader string yes
Request body object
Field Type Required Notes subjectobject yes
Responses Status Meaning Body 200What each capability erased; the list is empty while no capability holds data about people SubjectErased 400The body or the Idempotency-Key is not valid PlatformError 401API key missing, invalid or revoked PlatformError 403The key lacks the subjects:erase scope PlatformError 409A request with this Idempotency-Key is still being processed PlatformError 422This Idempotency-Key was already used with a different request PlatformError
Example curl -X POST "https://api.trida.lu/core/v1/subjects/erase" \
-H "x-api-key: $TRIDA_API_KEY" \
-H "Idempotency-Key: $(uuidgen)" \
-H "content-type: application/json" \
-d '{"subject":{"type":"phone","value":"string"}}'
GET /core/v1/usage
Usage of the project by day, capability and metric, and its daily limits (UTC days, at most 92)
Required scope: usage:read
Parameters Name In Type Required Notes fromquery string no toquery string no
Responses Status Meaning Body 200The usage Usage 400A date is not YYYY-MM-DD, from is after to, or the range exceeds 92 days PlatformError 401API key missing, invalid or revoked PlatformError 403The key lacks the usage:read scope PlatformError
Example curl -X GET "https://api.trida.lu/core/v1/usage" \
-H "x-api-key: $TRIDA_API_KEY"
GET /core/v1/webhook-endpoints
List the endpoints of the project, never a secret
Required scope: webhooks:read
Responses
Example curl -X GET "https://api.trida.lu/core/v1/webhook-endpoints" \
-H "x-api-key: $TRIDA_API_KEY"
POST /core/v1/webhook-endpoints
Declare an endpoint that receives the events of the project; the secret is returned once
Required scope: webhooks:write
Parameters Name In Type Required Notes idempotency-keyheader string yes
Request body object
Field Type Required Notes urlstring (uri) yes max length 2048 eventTypesarray of string yes
Responses Status Meaning Body 201The endpoint and its HMAC secret, in clear this one time WebhookEndpointCreated 400The body or the Idempotency-Key is not valid, the address is not a public HTTPS address, or the project already has 20 endpoints PlatformError 401API key missing, invalid or revoked PlatformError 403The key lacks the webhooks scope this route needs PlatformError 409A request with this Idempotency-Key is still being processed PlatformError 422This Idempotency-Key was already used with a different request PlatformError
Example curl -X POST "https://api.trida.lu/core/v1/webhook-endpoints" \
-H "x-api-key: $TRIDA_API_KEY" \
-H "Idempotency-Key: $(uuidgen)" \
-H "content-type: application/json" \
-d '{"url":"https://example.com/webhooks/trida","eventTypes":["string"]}'
DELETE /core/v1/webhook-endpoints/{id}
Delete an endpoint and its secrets
Required scope: webhooks:write
Parameters Name In Type Required Notes idpath string (uuid) yes idempotency-keyheader string yes
Responses Status Meaning Body 204Deleted 400The Idempotency-Key is missing or not valid PlatformError 401API key missing, invalid or revoked PlatformError 403The key lacks the webhooks scope this route needs PlatformError 404No such endpoint in this project PlatformError 409A request with this Idempotency-Key is still being processed PlatformError 422This Idempotency-Key was already used with a different request PlatformError
Example curl -X DELETE "https://api.trida.lu/core/v1/webhook-endpoints/$ID" \
-H "x-api-key: $TRIDA_API_KEY" \
-H "Idempotency-Key: $(uuidgen)"
POST /core/v1/webhook-endpoints/{id}/rotate-secret
Make a new secret the active one; the previous one keeps signing until it is retired, so nothing is interrupted
Required scope: webhooks:write
Parameters Name In Type Required Notes idpath string (uuid) yes idempotency-keyheader string yes
Responses
Example curl -X POST "https://api.trida.lu/core/v1/webhook-endpoints/$ID/rotate-secret" \
-H "x-api-key: $TRIDA_API_KEY" \
-H "Idempotency-Key: $(uuidgen)"
POST /core/v1/webhook-endpoints/{id}/retire-previous-secret
End a rotation: the previous secret stops signing, only the active one remains
Required scope: webhooks:write
Parameters Name In Type Required Notes idpath string (uuid) yes idempotency-keyheader string yes
Responses
Example curl -X POST "https://api.trida.lu/core/v1/webhook-endpoints/$ID/retire-previous-secret" \
-H "x-api-key: $TRIDA_API_KEY" \
-H "Idempotency-Key: $(uuidgen)"
POST /core/v1/events/{id}/replay
Replay an event to the active endpoints subscribed to its type: same eventId, new deliveries, fresh signature
Required scope: webhooks:write
Parameters Name In Type Required Notes idpath string (uuid) yes idempotency-keyheader string yes
Responses Status Meaning Body 200How many deliveries were created, one per active subscribed endpoint (0 if none) WebhookReplayResult 400The Idempotency-Key is missing or not valid, or the event is still being dispatched for the first time PlatformError 401API key missing, invalid or revoked PlatformError 403The key lacks the webhooks scope this route needs PlatformError 404No such event in this project PlatformError 409A request with this Idempotency-Key is still being processed PlatformError 422This Idempotency-Key was already used with a different request PlatformError
Example curl -X POST "https://api.trida.lu/core/v1/events/$ID/replay" \
-H "x-api-key: $TRIDA_API_KEY" \
-H "Idempotency-Key: $(uuidgen)"
POST /core/v1/webhook-endpoints/{id}/test
Send a signed test event (core.webhook.test) to this endpoint only, to try reception and signature verification
Required scope: webhooks:write
Parameters Name In Type Required Notes idpath string (uuid) yes idempotency-keyheader string yes
Responses Status Meaning Body 200The test event was queued; it is delivered like any other event, signed with the active secrets WebhookTestSent 400The Idempotency-Key is missing or not valid PlatformError 401API key missing, invalid or revoked PlatformError 403The key lacks the webhooks scope this route needs PlatformError 404No such endpoint in this project PlatformError 409A request with this Idempotency-Key is still being processed PlatformError 422This Idempotency-Key was already used with a different request PlatformError
Example curl -X POST "https://api.trida.lu/core/v1/webhook-endpoints/$ID/test" \
-H "x-api-key: $TRIDA_API_KEY" \
-H "Idempotency-Key: $(uuidgen)"
Schemas
HealthField Type Required Notes status"ok" | "degraded"yes env"local" | "dev" | "prod"yes versionstring yes commitstring yes db"up" | "down"yes queue"up" | "idle"yes queueDeadinteger yes queueFailed24hinteger yes webhooksDead24hinteger yes breakersarray of object yes lastMigrationstring or null yes
{
"status": "ok",
"env": "local",
"version": "string",
"commit": "string",
"db": "up",
"queue": "up",
"queueDead": 0,
"queueFailed24h": 0,
"webhooksDead24h": 0,
"breakers": [
{
"provider": "string",
"state": "closed"
}
],
"lastMigration": "string"
}
ProjectMeField Type Required Notes idstring (uuid) yes slugstring yes namestring yes mode"test" | "live"yes languagesarray of string yes themeobject yes
{
"id": "2c4d0f3a-7b2e-4a1e-9a7f-1c2d3e4f5a6b",
"slug": "demo",
"name": "Démo",
"mode": "test",
"languages": [
"fr",
"en"
],
"theme": {
"logoUrl": null,
"primary": "#23306b",
"accent": "#c5e6f4",
"background": "#ffffff",
"text": "#152f4e"
}
}
SubjectErasedField Type Required Notes capabilitiesarray of object yes
{
"capabilities": [
{
"capability": "string",
"erased": 0
}
]
}
UsageField Type Required Notes fromstring yes pattern ^\d{4}-\d{2}-\d{2}$ tostring yes pattern ^\d{4}-\d{2}-\d{2}$ dataarray of object yes limitsarray of object yes
{
"from": "string",
"to": "string",
"data": [
{
"day": "string",
"capability": "string",
"metric": "string",
"count": 0
}
],
"limits": [
{
"capability": "string",
"metric": "string",
"dailyLimit": 0
}
]
}
WebhookEndpointCreatedField Type Required Notes idstring (uuid) yes urlstring yes eventTypesarray of string yes activeboolean yes hasPreviousSecretboolean yes createdAtstring (date-time) yes secretstring yes
{
"id": "11111111-2222-4333-8444-555555555555",
"url": "string",
"eventTypes": [
"string"
],
"active": true,
"hasPreviousSecret": true,
"createdAt": "2026-10-18T10:00:00.000Z",
"secret": "string"
}
WebhookEndpointListField Type Required Notes dataarray of object yes
{
"data": [
{
"id": "11111111-2222-4333-8444-555555555555",
"url": "string",
"eventTypes": [
"string"
],
"active": true,
"hasPreviousSecret": true,
"createdAt": "2026-10-18T10:00:00.000Z"
}
]
}
WebhookSecretRotatedField Type Required Notes idstring (uuid) yes secretstring yes
{
"id": "11111111-2222-4333-8444-555555555555",
"secret": "string"
}
WebhookEndpointField Type Required Notes idstring (uuid) yes urlstring yes eventTypesarray of string yes activeboolean yes hasPreviousSecretboolean yes createdAtstring (date-time) yes
{
"id": "11111111-2222-4333-8444-555555555555",
"url": "string",
"eventTypes": [
"string"
],
"active": true,
"hasPreviousSecret": true,
"createdAt": "2026-10-18T10:00:00.000Z"
}
WebhookReplayResultField Type Required Notes eventIdstring (uuid) yes deliveriesinteger yes min 0
{
"eventId": "11111111-2222-4333-8444-555555555555",
"deliveries": 0
}
WebhookTestSentField Type Required Notes eventIdstring (uuid) yes endpointIdstring (uuid) yes
{
"eventId": "11111111-2222-4333-8444-555555555555",
"endpointId": "11111111-2222-4333-8444-555555555555"
}