This version correctly reflects the Secryn authentication model:
All Secryn API requests must be authenticated using a Bearer token.
Secryn does not support session-based authentication, cookies, or query-string tokens. All authentication is performed using the Authorization header.
Every request must include:
Authorization: Bearer YOUR_TOKEN
Accept: application/json
If the header is missing or invalid, the API returns:
401 Unauthorized
Secryn supports two types of API tokens:
Vault Access Keys are machine credentials scoped to a project.
They:
curl --request GET \
--url "https://secryn.example.com/api/v1/vaults/{vault_id}" \
--header "Accept: application/json" \
--header "Authorization: Bearer VAULT_ACCESS_KEY"
Vault access keys are intended for:
When a Key or Certificate is marked as Public during creation:
Public tokens apply only to:
Secrets can never be public.
curl --request GET \
--url "https://secryn.example.com/api/v1/certificates/{certificate_id}" \
--header "Accept: application/json" \
--header "Authorization: Bearer RESOURCE_PUBLIC_TOKEN"
This token:
Authentication verifies identity. Authorization determines access.
Vault Access Keys:
Public Resource Tokens:
Unauthorized access attempts return:
403 Forbidden
To invalidate a public token:
A new token is generated if public visibility is re-enabled.
| Status | Meaning |
|---|---|
| 401 | Missing or invalid token |
| 403 | Valid token but insufficient permissions |
| 404 | Resource not found or not accessible |