Antylogic
DemoApp login

399 operational guides

Docs sections
DocsDocumentation
Device

Check Docs Endpoint With HEAD

Use HEAD on the supported docs index endpoints to confirm that the docs route, service registration and, for the app endpoint, authentication gates are reachable. A successful check returns 200 OK with no JSON body and does not load the docs content bundle.

In this article

Use this guide when operations teams, API consumers or monitoring administrators need a lightweight reachability check for Antylogic documentation endpoints.

Use the public endpoint when the monitor only needs to prove route and docs service reachability. Use the app endpoint when the monitor must also confirm that an authenticated Harbor Demo User session can pass authentication and account gating.

Before you start

  • The backend API is running with docs routes registered through RegisterRoutes and DocsRoutesConfig.
  • For the public check, use HEAD /api/public/docs; no user session is required.
  • For the app check, use HEAD /api/app/docs with a valid Authorization: Bearer token or access_token cookie for a non-pending-deletion account.
  • Use the non-asset docs index routes only. Paths under /assets use separate file-serving rules.

Instructions

  1. 1.

    Choose the endpoint

    Use HEAD /api/public/docs for a public route and docs service reachability check. Use HEAD /api/app/docs when the check must also prove that a valid app session can reach the docs handler after authentication and the pending deletion account gate.

  2. 2.

    Send the HEAD request

    Send an HTTP HEAD request to the chosen index endpoint. Do not expect JSON, article data, media metadata or any response body from a successful check.

  3. 3.

    Interpret 200 OK

    Treat 200 OK as a route and docs service reachability signal. For HEAD /api/app/docs, it also confirms that the supplied session passed authentication and account gating.

  4. 4.

    Handle rejections

    For HEAD /api/app/docs, refresh or replace missing or invalid credentials. If the account is pending deletion, recover the account before using it for this check. If the service returns unavailable, verify docs route configuration before investigating article content.

  5. 5.

    Keep the scope narrow

    Do not use this action as a content health check. Use GET /api/public/docs or GET /api/app/docs when you need to validate the docs index, article payloads, locale handling, search options or media availability.

Validations and limits

  • Only GET and HEAD are accepted by the docs handler; other methods return 405 with metodo no permitido.
  • If the docs service is not configured, the handler returns 503 with documentacion no configurada.
  • HEAD /api/app/docs is stopped before the docs handler when credentials are missing, invalid or resolve to an empty UserID.
  • A pending deletion account is blocked before the docs handler because docs is not in the account gate allowlist.
  • Successful generic HEAD does not load backend/docs-content/articles.json and does not prove that an article slug or docs asset exists.

Expected result

The monitor receives a lightweight status-only signal. Public checks prove the docs route and service are reachable; authenticated app checks additionally prove the supplied session passes authentication and account gating.

Related articles