Skip to content

Instantly share code, notes, and snippets.

@toddysm
Last active January 30, 2024 05:26
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save toddysm/c8598bd2dba74a8f8c4900e35cd0e17a to your computer and use it in GitHub Desktop.
Save toddysm/c8598bd2dba74a8f8c4900e35cd0e17a to your computer and use it in GitHub Desktop.
Docker Hub Registry Authentication REST Requests

### Get the registry root GET https://registry-1.docker.io/

### Get the registry root GET https://registry-1.docker.io

### Get the registry root GET http://registry-1.docker.io

### Get the /v2 endpoint GET https://registry-1.docker.io/v2

### HEAD the /v2 endpoint HEAD https://registry-1.docker.io/v2

### POST the /v2 endpoint POST https://registry-1.docker.io/v2

### PUT the /v2 endpoint PUT https://registry-1.docker.io/v2

### DELETE the /v2 endpoint DELETE https://registry-1.docker.io/v2

### Get the /v2/ endpoint GET https://registry-1.docker.io/v2/

### HEAD the /v2/ endpoint HEAD https://registry-1.docker.io/v2/

### PUT the /v2/ endpoint PUT https://registry-1.docker.io/v2/

### DELETE the /v2/ endpoint DELETE https://registry-1.docker.io/v2/

### Authenticate for the /v2/ endpoint GET https://auth.docker.io/token?service=registry.docker.io

### Get the /v2/ endpoint with auth token GET https://registry-1.docker.io/v2/ Authorization: Bearer eyJhbGciOiJSUzI1NiI...

### Get the /v2/ endpoint with auth token on registry.docker.io GET https://registry.docker.io/v2/ Authorization: Bearer eyJhbGciOiJSUzI1NiI...

### Get the /v2/_catalog with /v2/ issues auth token GET https://registry-1.docker.io/v2/_catalog Authorization: Bearer eyJhbGciOiJSUzI1NiI...

### Get the /v2/library/python/manifests/3.10 with /v2/ issues auth token GET https://registry-1.docker.io/v2/library/python/manifests/3.10 Authorization: Bearer eyJhbGciOiJSUzI1NiI...

### Authenticate for the /v2/_catalog endpoint GET https://auth.docker.io/token?service=registry.docker.io&scope=registry:catalog:*

### Authenticate for the /v2/library/python/manifests/3.10 endpoint GET https://auth.docker.io/token?service=registry.docker.io&scope=repository:library/python:pull

### Pull the manifest for the python:3.10 image GET https://registry-1.docker.io/v2/library/python/manifests/3.10 Authorization: Bearer eyJhbGciOiJSUzI1NiI...

### List the tags for the python repository GET https://registry-1.docker.io/v2/library/python/tags/list Authorization: Bearer eyJhbGciOiJSUzI1NiI...

### Authenticate for pull and push for the /v2/library/python/manifests/3.10 endpoint GET https://auth.docker.io/token?service=registry.docker.io&scope=repository:library/python:pull,push

### List the tags for the python repository GET https://registry-1.docker.io/v2/library/python/tags/list Authorization: Bearer eyJhbGciOiJSUzI1NiI...

### Authenticate with username and password for the /v2/toddysm/python GET https://auth.docker.io/token?service=registry.docker.io&scope=repository:toddysm/python:pull,push,delete Authorization: Basic <base64_encoded_username_and_password>

### List the tags with the auth token GET https://registry-1.docker.io/v2/toddysm/python/tags/list Authorization: Bearer eyJhbGciOiJSUzI1NiI...

### Delete a manifest with the auth token DELETE https://registry-1.docker.io/v2/toddysm/python/manifests/3.10 Authorization: Bearer eyJhbGciOiJSUzI1NiI...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment