autopicDocumentation

Référence de l'API

Service

État du service et version déployée. Ces routes ne demandent pas d'authentification.

État du service

GET/healthPublic

Returns service and PostgreSQL connectivity status.

Ne demande pas d'authentification.

Réponse 200

  • statusstringobligatoire

    Valeurs : ok

  • databasestringobligatoire

    Valeurs : ok

Erreurs

  • 400Invalid request
  • 503Service unavailable
Requête
curl https://api.autopic.io/health
Réponse 200
{
  "status": "ok",
  "database": "ok"
}

Version déployée

GET/versionPublic

Reports the commit the running binary was built from. Public and unauthenticated: checking what is deployed should not need the admin key.

Ne demande pas d'authentification.

Réponse 200

  • commitstring
  • shortCommitstring
  • buildTimestring
  • dirtyboolean

    Built from a working tree with uncommitted changes.

  • sourcestring

    Where the commit came from.

    Valeurs : ldflags, environment, buildinfo, unavailable

Requête
curl https://api.autopic.io/version
Réponse 200
{
  "commit": "98af74ad3e1f0c2b4a5d6e7f8a9b0c1d2e3f4a5b",
  "shortCommit": "98af74a",
  "buildTime": "string",
  "dirty": true,
  "source": "ldflags"
}