Zum Inhalt springen

Check API health

GET
/healthz
curl --request GET \
--url http://localhost:8080/healthz

Liveness and dependency readiness. Never returns application/problem+json: a degraded process answers 503 with the same HealthResponse body so a probe can always read which dependency is down.

Process and required dependencies are healthy.

Media typeapplication/json
object
status
required

ok when every required dependency answered, degraded when at least one did not. The process is alive in both cases.

string
Allowed values: ok degraded
service
required
string
Allowed value: antares-api
dependencies

One entry per checked dependency, keyed by its name.

object
key
additional properties
string
Allowed values: ok unavailable
Example
{
"status": "ok",
"service": "antares-api",
"dependencies": {
"additionalProperty": "ok"
}
}

contract_validation_failed — the OpenAPI request validator rejected the request before the handler ran — or invalid_request when the body is unreadable or is not valid JSON for the declared operation.

Media typeapplication/problem+json

RFC 9457 problem details. type is always https://api.antares.commergy.de/problems/{code} and is built in exactly one place. type, code and title are stable and never localised; only detail is localised, and only where the registry marks the audience as merchant.

object
type
required

Absolute problem type URI. Stable identifier, never localised.

string format: uri-reference
title
required

Stable English summary of the problem type.

string
status
required

The HTTP status code, repeated in the body.

integer
>= 400 <= 599
detail

Human-readable explanation of this occurrence. The only localised field; may be German or English depending on Accept-Language.

string
instance

The request path this occurrence relates to.

string format: uri-reference
code

The registry code, for example price_context_token_expired. This is what a client branches on; never branch on title or detail.

string
errors

Present only for per-item validation failures, above all ingest batches.

Array<object>
object
field
required

Dotted path of the offending field inside the request body, for example prices.CHF.gross.

string
message
required

What is wrong with it, in English.

string
productIndex

0-based index into the request’s products array. Present only for ingest batches, and the only way to map an error back to a product without echoing it.

integer
key
additional properties
any
Examplegenerated
{
"type": "example",
"title": "example",
"status": 1,
"detail": "example",
"instance": "example",
"code": "example",
"errors": [
{
"field": "example",
"message": "example",
"productIndex": 1
}
]
}

Process is running but at least one required dependency is degraded.

Media typeapplication/json
object
status
required

ok when every required dependency answered, degraded when at least one did not. The process is alive in both cases.

string
Allowed values: ok degraded
service
required
string
Allowed value: antares-api
dependencies

One entry per checked dependency, keyed by its name.

object
key
additional properties
string
Allowed values: ok unavailable
Example
{
"status": "ok",
"service": "antares-api",
"dependencies": {
"additionalProperty": "ok"
}
}