containers

Registry token

Mints a short-lived EdDSA JWT for the HuggingFace container registry, verifiable via the JWK at /api/keys/jwt.

get/api/registry/token

Query parameters

servicestring required

Registry service identifier — placed in the JWT aud claim.

string
OR
string[]

Response

Docker Distribution v2 token response — see https://distribution.github.io/distribution/spec/auth/jwt/

tokenstring required

EdDSA JWT signed by the moon JWT key, carrying access[].

access_tokenstring required

Identical to token — Docker Distribution v2 accepts either field.

expires_ininteger required

JWT lifetime in seconds.

issued_atstring date-time required

ISO-8601 timestamp at which the JWT was minted.

Changes

Changed in 2 of the 82 revisions of this API.3

    • ○

      api tag containers added

      api-tag-added

    • ○

      api tag container removed

      api-tag-removed

    • ○

      the response's property pattern was changed from ^((\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\d|3[01])|(0[469]|11)-(0[1-9]|[12]\d|30)|(02)-(0[1-9]|1\d|2[0-8])))T([01]\d|2[0-3]):[0-5]\d:[0-5]\d(\.\d+)?(Z)$ to ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d:[0-5]\d(?:\.\d+)?(?:Z))$ for the status

      response-property-pattern-changed