Update JWT Auth (retired)
This endpoint is retired and returns 410 Gone. It saved a JWT configuration that the edge never read, so no request was ever checked against it. Nothing is written.
JWTs are checked by the jwt-validation traffic policy rule: create a traffic policy on the endpoint (POST /v1/endpoints/{uuid}/policies), then add a rule to it (POST /v1/endpoints/{uuid}/policies/{policy_uuid}/rules) with rule_type: "jwt-validation" and phase: "on_http_request". The edge refuses a request without a valid token before it reaches your service. The rule's fields are listed under JWT Validation.
JWT validation is not an endpoint auth mode: the endpoint's mode stays none, basic or sso (PUT /v1/endpoints/{uuid}/settings).
Response (410 Gone)
error string
That the setting was retired and how JWTs are checked instead.
code string
retired.controlled_by string
The
jwt-validation rule and the routes that create it.Response — 410 Gone
{
"error": "The endpoint JWT setting (PUT /endpoints/{uuid}/settings/jwt) was retired: it never had any effect. JWTs are checked by the jwt-validation traffic policy rule: ...",
"code": "retired",
"controlled_by": "JWTs are checked by the jwt-validation traffic policy rule: ..."
}
Instead — add a jwt-validation rule
curl -X POST "https://api.ngris.com/v1/endpoints/019bb1e4-e785-77d2-9966-c3cff31d0a0e/policies/019b74e7-6fe8-7784-9d8a-9b7f9cb99a89/rules" \
-H "X-API-KEY: <your_api_key>" \
-H "Content-Type: application/json" \
-d '{
"phase": "on_http_request",
"rule_type": "jwt-validation",
"name": "Require a valid JWT",
"enabled": true,
"config": {
"algorithm": "RS256",
"jwks_url": "https://idp.example.com/.well-known/jwks.json",
"token_location": "header",
"token_name": "Authorization",
"token_prefix": "Bearer ",
"issuer": "https://idp.example.com/",
"audience": "my-api"
}
}'
Was this helpful?