# dockerhub.repository

A public image repository on Docker Hub: description, stars, pulls, dates, categories, and its most recent tags with their sizes and platforms.

Docker Hub repository, one of the Docker Hub scrapers.

| | |
| --- | --- |
| Id | `dockerhub.repository` |
| Version | 1 |
| Billed per | request — 1 unit for a charged run |
| Runs | within one request |

Start it with `POST /v1/scrapers/dockerhub.repository/runs`. How runs work is in [Running a scraper](https://docs.enrichednow.com/running-a-scraper.md); what a run costs is in [Usage and units](https://docs.enrichednow.com/usage-and-units.md).

## Inputs

The fields of `input`. A field that is not listed here is refused.

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `repository` | string | yes | The repository: nginx for an official image, namespace/name such as grafana/grafana, or its address on hub.docker.com. Limit: at least 1 characters, at most 500 characters. |
| `max_tags` | integer | no | Return this many of the repository's tags, most recently pushed first; 0 returns none and saves a request. Limit: 0 to 100. Default: `10`. |
| `include_readme` | boolean | no | true also returns the repository's overview (its README). Default: `false`. |

- `repository` is the name as Docker writes it: `nginx` for an official image, `namespace/name` for any other. A tag or a `docker.io/` prefix is ignored, and the repository's address on hub.docker.com works too.
- An official image is under the namespace `library` and has `is_official` `true`.
- `tags` is the most recently pushed tags first, `max_tags` of them, each with `size_bytes`, `digest` and `platforms`; `tag_count` is how many the repository has in all.
- `readme` is the repository's overview in Markdown, returned only with `include_readme: true`.
- A repository that does not exist, or is private, ends the run `failed` with `not_found`, and costs nothing — see [the reasons of this family](https://docs.enrichednow.com/results-and-statuses.md#docker-hub).

## Record fields

Every record of a run has these fields. A value that is not known is `null` — never an empty string and never `0`.

| Field | Type | Notes |
| --- | --- | --- |
| `full_name` | string | The repository as namespace/name, e.g. "grafana/grafana"; an official image is under "library", e.g. "library/nginx". |
| `namespace` | string | The account or organisation the repository belongs to; "library" for an official image. |
| `name` | string | The repository's own name. |
| `url` | string | The repository's page on hub.docker.com. |
| `is_official` | boolean | True for a Docker Official Image. |
| `description` | string or null | The repository's short description. |
| `readme` | string or null | The repository's overview (its README, in Markdown) when include_readme asked for it. |
| `stars` | integer or null | How many accounts starred the repository. |
| `pulls` | integer or null | How often the repository's images were pulled, in all. |
| `last_updated_at` | string (date-time) or null | When an image was last pushed to the repository, in UTC. |
| `registered_at` | string (date-time) or null | When the repository was created, in UTC. |
| `status` | string or null | The repository's state in Docker Hub's words, e.g. "active". |
| `categories` | array of string | The categories Docker Hub lists the repository under, e.g. ["Web servers"]. |
| `tag_count` | integer or null | How many tags the repository has; null when the tags were not asked for or could not be read. |
| `tags` | array of object | The most recently pushed tags first, as many as max_tags asked for. |
| `tags[].name` | string | The tag, e.g. "latest", "1.27-alpine". |
| `tags[].last_updated_at` | string (date-time) or null | When the tag was last pushed, in UTC. |
| `tags[].size_bytes` | integer or null | The compressed size of the tag's image in bytes; for a tag with several platforms, the one Docker Hub shows first. |
| `tags[].digest` | string or null | The tag's content digest (sha256:…); null where Docker Hub states none. |
| `tags[].platforms` | array of string | The platforms the tag has an image for, e.g. ["linux/amd64", "linux/arm64/v8"]. |
| `tags[].last_pulled_at` | string (date-time) or null | When the tag was last pulled, in UTC, where Docker Hub states it. |
| `fetched_at` | string (date-time) | When the repository was read, in UTC. |

## Example request

It starts a run with this scraper's example input and waits up to 60 seconds for it. The key is read from `ENRICHEDNOW_API_KEY`.

```bash
curl -X POST "https://api.enrichednow.com/v1/scrapers/dockerhub.repository/runs?wait=60" \
  -H "Authorization: Bearer $ENRICHEDNOW_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"input":{"repository":"nginx","max_tags":3}}'
```

## Example response

The run, once it has ended. A run that has not ended within `wait` comes back with `202` and the status `queued` or `running`.

```json
{
  "id": "run_841742f37553189ff9c27ba1",
  "scraper_id": "dockerhub.repository",
  "scraper_version": 1,
  "status": "ok",
  "reason": null,
  "input": {
    "repository": "nginx",
    "max_tags": 3
  },
  "record_count": 1,
  "units": 1,
  "units_per_request": 1,
  "units_per_record": null,
  "units_per_page": null,
  "diagnostics": {
    "requests": 1,
    "bytes": 259214,
    "wall_ms": 885,
    "facts": {}
  },
  "created_at": "2026-11-16T22:37:50.170950Z",
  "started_at": "2026-11-16T22:37:50.178331Z",
  "finished_at": "2026-11-16T22:37:51.066313Z"
}
```

Its records, from `GET /v1/runs/{id}/records`. The record is a real one: this scraper's own parser read it from a page recorded from the site.

```json
{
  "records": [
    {
      "full_name": "library/nginx",
      "namespace": "library",
      "name": "nginx",
      "url": "https://hub.docker.com/_/nginx",
      "is_official": true,
      "description": "Official build of Nginx.",
      "readme": null,
      "stars": 21422,
      "pulls": 13610589212,
      "last_updated_at": "2026-11-18T19:55:13.910348Z",
      "registered_at": "2014-06-05T19:14:45Z",
      "status": "active",
      "categories": [
        "Web servers"
      ],
      "tag_count": 1409,
      "tags": [
        {
          "name": "trixie-perl",
          "last_updated_at": "2026-11-18T19:55:11.281584Z",
          "size_bytes": 76072254,
          "digest": "sha256:9657d43040dc2a10c5697a68ab158c2ea50980c3338d5b1d876add119b92d346",
          "platforms": [
            "linux/amd64",
            "linux/ppc64le",
            "linux/386"
          ],
          "last_pulled_at": "2026-11-18T22:41:47.574035Z"
        },
        {
          "name": "stable-trixie-perl",
          "last_updated_at": "2026-11-18T19:55:06.331941Z",
          "size_bytes": 75784146,
          "digest": "sha256:39914e7bd94a6de938c6cf785ef6d1640a6810e5c027f97d7097ab8daa5596d8",
          "platforms": [
            "linux/amd64",
            "linux/ppc64le",
            "linux/386"
          ],
          "last_pulled_at": "2026-11-18T22:42:25.003976Z"
        }
      ],
      "fetched_at": "2026-11-19T18:07:40.050613Z"
    }
  ],
  "next_cursor": null
}
```

What was done to the record for this page, and nothing else — the API returns every value whole. A text that was cut ends with `… [truncated]`.

- Shortened: `tags`: 3 items, the first 2 shown.
- Shortened: `tags[0].platforms`: 8 items, the first 3 shown.
- Shortened: `tags[1].platforms`: 8 items, the first 3 shown.

A run does not always end `ok`. [Results and statuses](https://docs.enrichednow.com/results-and-statuses.md#reason-codes) lists every status and the reasons every scraper shares; [the reasons of the Docker Hub scrapers](https://docs.enrichednow.com/results-and-statuses.md#docker-hub) are in their own section there.
