---
title: Docker Hub API Integration on Truto
slug: dockerhub
category: Application Development
canonical: "https://truto.one/integrations/detail/dockerhub/"
---

# Docker Hub API Integration on Truto



**Category:** Application Development  
**Status:** Generally available

## MCP-ready AI tools

Truto exposes 44 tools for Docker Hub that AI agents can call directly.

- **list_all_docker_hub_audit_log_actions** — List audit log actions. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password or an organization access token. [GET /v2/auditlogs/{account}/actions]
- **list_all_docker_hub_audit_logs** — List audit log events. Audit logs need a Docker Team or Business subscription. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password or an organization access token. [GET /v2/auditlogs/{account}]
- **create_a_docker_hub_auth_token** — Create access token. Creates and returns a short-lived access token in JWT format for use as a bearer when calling Docker APIs. If successful, the access token returned should be used in the HTTP Authorization header like Authorization: Bearer {accesstoken}. If your organization has SSO enforced, you must use a personal access token (PAT) instead of a password.**_ the connector calls this automatically at connect time and every 5 minutes with the connected identifier and secret; you rarely need to call it yourself. [POST /v2/auth/token]
- **list_all_docker_hub_group_members** — List members of a group. List the members (users) that are in a group. If user is owner of the org or has otherwise elevated permissions, they can search by email and the result will also contain emails. This operation accepts bearer tokens issued from organization access tokens (OATs). The token must have the required resource access and scopes. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [GET /v2/orgs/{org_name}/groups/{group_name}/members]
- **create_a_docker_hub_group_member** — Add a member to a group. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [POST /v2/orgs/{org_name}/groups/{group_name}/members]
- **delete_a_docker_hub_group_member_by_id** — Remove a user from a group. The id is the Docker username to remove. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [DELETE /v2/orgs/{org_name}/groups/{group_name}/members/{username}]
- **list_all_docker_hub_groups** — Get groups of an organization. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [GET /v2/orgs/{org_name}/groups]
- **create_a_docker_hub_group** — Create a new group. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [POST /v2/orgs/{org_name}/groups]
- **get_single_docker_hub_group_by_id** — Get a group of an organization. The id is the group (team) name. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [GET /v2/orgs/{org_name}/groups/{group_name}]
- **update_a_docker_hub_group_by_id** — Update the details for an organization group. The id is the current group (team) name; name is required and description is replaced. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [PUT /v2/orgs/{org_name}/groups/{group_name}]
- **docker_hub_groups_partial_update** — Update some details for an organization group. Pass the current group (team) name as group_id. Only the fields sent are changed. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [PATCH /v2/orgs/{org_name}/groups/{group_name}]
- **delete_a_docker_hub_group_by_id** — Delete an organization group. The id is the group (team) name. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [DELETE /v2/orgs/{org_name}/groups/{group_name}]
- **list_all_docker_hub_invites** — List org invites. Return all pending invites for a given org, only team owners can call this endpoint This operation accepts bearer tokens issued from organization access tokens (OATs). The token must have the required resource access and scopes. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [GET /v2/orgs/{org_name}/invites]
- **create_a_docker_hub_invite** — Bulk create invites. Create multiple invites by emails or DockerIDs. Only a team owner can create invites. This operation accepts bearer tokens issued from organization access tokens (OATs). The token must have the required resource access and scopes. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [POST /v2/invites/bulk]
- **delete_a_docker_hub_invite_by_id** — Cancel an invite. Mark the invite as cancelled so it doesn't show up on the list of pending invites This operation accepts bearer tokens issued from organization access tokens (OATs). The token must have the required resource access and scopes. The id is the invite id (from invites.list). Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [DELETE /v2/invites/{id}]
- **docker_hub_invites_resend** — Resend an invite. Resend a pending invite to the user, any org owner can resend an invite This operation accepts bearer tokens issued from organization access tokens (OATs). The token must have the required resource access and scopes. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [PATCH /v2/invites/{id}/resend]
- **list_all_docker_hub_org_access_tokens** — List access tokens. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [GET /v2/orgs/{org_name}/access-tokens]
- **create_a_docker_hub_org_access_token** — Create access token. Create an access token for an organization. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [POST /v2/orgs/{org_name}/access-tokens]
- **get_single_docker_hub_org_access_token_by_id** — Get access token. Get details of a specific access token for an organization. The id is the access token id. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [GET /v2/orgs/{org_name}/access-tokens/{access_token_id}]
- **update_a_docker_hub_org_access_token_by_id** — Update access token. Update a specific access token for an organization. The id is the access token id. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [PATCH /v2/orgs/{org_name}/access-tokens/{access_token_id}]
- **delete_a_docker_hub_org_access_token_by_id** — Delete access token. Delete a specific access token for an organization. This action cannot be undone. The id is the access token id. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [DELETE /v2/orgs/{org_name}/access-tokens/{access_token_id}]
- **list_all_docker_hub_org_members** — List org members. Returns a list of members for an organization. The following fields are only visible to orgs with insights enabled. - lastloggedinat - lastseenat - lastdesktopversion` To make visible, please see View Insights for organization users. This operation accepts bearer tokens issued from organization access tokens (OATs). The token must have the required resource access and scopes. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [GET /v2/orgs/{org_name}/members]
- **docker_hub_org_members_bulk_export** — Export org members CSV. Export members of an organization as a CSV This operation accepts bearer tokens issued from organization access tokens (OATs). The token must have the required resource access and scopes. Returns the CSV file text. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [GET /v2/orgs/{org_name}/members/export]
- **update_a_docker_hub_org_member_by_id** — Update org member (role). Updates the role of a member in the organization. Only users in the "owners" group of the organization can use this endpoint. This operation accepts bearer tokens issued from organization access tokens (OATs). The token must have the required resource access and scopes. The id is the member's Docker username. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [PUT /v2/orgs/{org_name}/members/{username}]
- **delete_a_docker_hub_org_member_by_id** — Remove member from org. Removes the member from the org, ie. all groups in the org, unless they're the last owner This operation accepts bearer tokens issued from organization access tokens (OATs). The token must have the required resource access and scopes. The id is the member's Docker username. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [DELETE /v2/orgs/{org_name}/members/{username}]
- **docker_hub_org_settings_lookup** — Get organization settings. Returns organization settings by name. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [GET /v2/orgs/{org_name}/settings]
- **docker_hub_org_settings_bulk_update** — Update organization settings. Updates an organization's settings. Some settings are only used when the organization is on a business subscription. Only users with administrative privileges for the organization (owner role) can modify these settings. The following settings are only used on a business subscription: - restrictedimages` Replaces the organization settings for org_name. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [PUT /v2/orgs/{org_name}/settings]
- **list_all_docker_hub_personal_access_tokens** — List personal access tokens. Returns a paginated list of personal access tokens. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [GET /v2/access-tokens]
- **create_a_docker_hub_personal_access_token** — Create personal access token. Creates and returns a personal access token. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [POST /v2/access-tokens]
- **get_single_docker_hub_personal_access_token_by_id** — Get personal access token. Returns a personal access token by UUID. The id is the token UUID. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [GET /v2/access-tokens/{uuid}]
- **update_a_docker_hub_personal_access_token_by_id** — Update personal access token. Updates a personal access token partially. You can either update the token's label or enable/disable it. The id is the token UUID. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [PATCH /v2/access-tokens/{uuid}]
- **delete_a_docker_hub_personal_access_token_by_id** — Delete personal access token. Deletes a personal access token permanently. This cannot be undone. The id is the token UUID. Docker rejects connections made with a personal access token here (403 "token issued from personal access token is not allowed"); the account must be connected with the Docker password. [DELETE /v2/access-tokens/{uuid}]
- **list_all_docker_hub_repositories** — List repositories in a namespace. Returns a list of repositories within the specified namespace (organization or user). Public repositories are accessible to everyone, while private repositories require appropriate authentication and permissions. OAT listing behavior: an OAT with the scope-repository-list scope sees all repositories including private ones. An OAT without that scope only sees public repositories. This filtering is silent: the response is a normal 200 with no indication that private repositories were withheld. [GET /v2/namespaces/{namespace}/repositories]
- **create_a_docker_hub_repository** — Create a new repository. Creates a new repository within the specified namespace. The repository will be created with the provided metadata including name, description, and privacy settings. This operation accepts bearer tokens issued from organization access tokens (OATs). The token must have the required resource access and scopes. [POST /v2/namespaces/{namespace}/repositories]
- **get_single_docker_hub_repository_by_id** — Get repository in a namespace. Returns a repository within the specified namespace (organization or user). Public repositories are accessible to everyone, while private repositories require appropriate authentication and permissions. This operation accepts bearer tokens issued from organization access tokens (OATs). The token must have the required resource access and scopes. The id is the repository name (without the namespace). [GET /v2/namespaces/{namespace}/repositories/{repository}]
- **create_a_docker_hub_repository_group** — Assign a group (Team) to a repository for access. Assigns an organization group (team) to a repository with a specified permission level. This operation accepts bearer tokens issued from organization access tokens (OATs). The token must have the required resource access and scopes. [POST /v2/repositories/{namespace}/{repository}/groups]
- **docker_hub_repository_immutable_tags_bulk_update** — Update repository immutable tags. Updates the immutable tags configuration for this repository. Only users with administrative privileges for the repository can modify these settings. This operation accepts bearer tokens issued from organization access tokens (OATs). The token must have the required resource access and scopes. Replaces the immutable-tag settings of the repository. [PATCH /v2/namespaces/{namespace}/repositories/{repository}/immutabletags]
- **docker_hub_repository_immutable_tags_verify** — Verify repository immutable tags. Validates the immutable tags regex passed in the request body and returns a list of tags matching it in this repository. Only users with administrative privileges for the repository can call this endpoint. This operation accepts bearer tokens issued from organization access tokens (OATs). The token must have the required resource access and scopes. [POST /v2/namespaces/{namespace}/repositories/{repository}/immutabletags/verify]
- **list_all_docker_hub_repository_tags** — List repository tags. Returns the list of tags for the specified repository. This operation accepts bearer tokens issued from organization access tokens (OATs). The token must have the required resource access and scopes. [GET /v2/namespaces/{namespace}/repositories/{repository}/tags]
- **get_single_docker_hub_repository_tag_by_id** — Read repository tag. Returns details for a specific tag in the specified repository. This operation accepts bearer tokens issued from organization access tokens (OATs). The token must have the required resource access and scopes. The id is the tag name, e.g. `latest`. [GET /v2/namespaces/{namespace}/repositories/{repository}/tags/{tag}]
- **delete_a_docker_hub_registry_manifest_by_id** — Delete an image manifest (and so every tag pointing at it) from your repository in the Docker registry. The id must be the manifest digest (`sha256:...`, e.g. the `digest` from repository_tags.get), not a tag. Needs a truto_registry_token (truto_registry_token) from registry_tokens.create with `pull,push,delete`. [DELETE https://registry-1.docker.io/v2/<namespace>/<repository>/manifests/<digest>]
- **get_single_docker_hub_registry_manifest_by_id** — Get an image manifest from the Docker registry by tag or digest: for multi-platform images an index listing each platform (os/architecture) with its digest, otherwise the config and layer digests and sizes. A 404 (MANIFEST_UNKNOWN) means the tag or digest does not exist, so this also checks whether an image exists. Counts as a pull against Docker's pull rate limit. The id is a tag (e.g. `latest`) or a digest (`sha256:...`). Needs a truto_registry_token with `pull`. [GET https://registry-1.docker.io/v2/<namespace>/<repository>/manifests/<reference>]
- **list_all_docker_hub_registry_tags** — List the tags of a repository straight from the Docker registry (registry API, lexical order). Page with `n` (page size) and `last` (the last tag of the previous page). Needs a truto_registry_token from registry_tokens.create with `pull` for this repository. [GET https://registry-1.docker.io/v2/<namespace>/<repository>/tags/list]
- **create_a_docker_hub_registry_token** — Get a Docker Registry bearer token for one repository (OAuth2 password grant at auth.docker.io, using the connected username and token or password). Registry tokens are scoped to a single repository and expire after 300 seconds. Pass the returned access_token as truto_registry_token to registry_tags.list and registry_manifests.get/delete for the same repository. actions: `pull` to read, `pull,push,delete` to delete manifests in your own repository. [POST https://auth.docker.io/token]

## How it works

1. **Link your customer's Docker Hub account.** Use Truto's frontend SDK; we handle every OAuth and API key flow so you don't need to create the OAuth app.
2. **Authentication is automatic.** Truto refreshes tokens, stores credentials securely, and injects them into every API request.
3. **Call Truto's API to reach Docker Hub.** The Proxy API is a 1-to-1 mapping of the Docker Hub API.
4. **Get a unified response format.** Every response uses a single shape, with cursor-based pagination and data in the `result` field.

## Use cases

- **Add container security scanning for your users** — Security and vulnerability management platforms can let customers connect their Docker Hub accounts to continuously scan private images and base layers for CVEs, pulling manifests directly from both the management and registry APIs.
- **Automate developer onboarding and offboarding** — IAM, HRIS, and IdP platforms can sync employee directories with Docker Hub organizations to auto-invite new hires, assign them to the right groups, and revoke access and tokens when they leave.
- **Power CI/CD and artifact lifecycle automation** — DevOps and GitOps platforms can create repositories, monitor new tags, enforce immutability on production images, and purge stale manifests to keep registry storage costs under control.
- **Collect compliance evidence automatically** — GRC and SIEM tools can ingest Docker Hub audit logs, org settings, and access token inventories to generate SOC2 evidence and flag dormant credentials without manual customer uploads.
- **Enforce repository governance at scale** — Platform engineering tools can standardize repository configuration, team-based access, and immutable tag policies across customer orgs from a single pane of glass.

## What you can build

- **Private image vulnerability scanning** — List a customer's repositories, mint short-lived registry tokens, and pull manifests to analyze image layers and dependencies for security flaws.
- **Zero-touch Docker Hub provisioning** — Trigger org invites, assign users to groups, and remove members automatically based on HRIS or IdP lifecycle events.
- **Automated registry cleanup policies** — Let users define retention rules (e.g., delete dev-branch tags older than 30 days) and execute manifest deletions across their repositories.
- **Immutable tag enforcement** — Verify immutability status across production repositories and bulk-apply immutable tag rules to prevent overwrites of release artifacts.
- **Audit log streaming into SIEM** — Continuously pull Docker Hub audit log events and org settings into your platform to monitor access governance and detect anomalies.
- **Access token hygiene dashboard** — Inventory personal and organization access tokens, surface stale or unused credentials, and let security teams revoke them in bulk.

## FAQs

### Which Docker Hub authentication methods does Truto support?

Truto handles the credentials your end users need to connect, including username/password, Personal Access Tokens (PATs), and Organization Access Tokens (OATs). Truto also manages the short-lived (300-second) registry bearer tokens required to call the Docker Registry API.

### Can I use Personal Access Tokens for user and group management?

No. Docker Hub strictly rejects PATs for organization, group, member, and invite endpoints. These operations require an Organization Access Token or password-based auth, and Truto routes requests using the correct credential type automatically.

### Does Truto unify the Docker Hub REST API and the Docker Registry API?

Yes. Docker Hub exposes two distinct APIs — one for management (orgs, repos, members, audit logs) and one for registry operations (tags, manifests). Truto exposes tools for both and handles the registry's short-lived token exchange so you don't have to.

### What image data can I pull for scanning or analysis?

You can list repositories, list repository tags, list registry tags, and fetch individual registry manifests by digest. This is enough to enumerate images and analyze their layer structure for vulnerability scanning or SBOM generation.

### Can I manage immutable tags and enforce release policies?

Yes. Truto exposes tools to verify immutable tag status on a repository and to bulk-update immutable tag rules, which is useful for enforcing that production tags cannot be overwritten.

### What compliance and audit data is available?

You can list all audit log actions and audit log entries, look up org settings, and list personal and organization access tokens — the core data points needed for SOC2, access reviews, and SIEM ingestion.

### How does Truto handle pagination and rate limits?

Truto normalizes pagination across Docker Hub endpoints and manages retries and backoff when Docker Hub rate limits are hit, so your integration code stays simple regardless of customer data volume.
