"insufficient scope" for advanced image management API

I’m trying to make some v2 API calls using a Docker pro account. It has admin privileges for the namespace I’m trying to interact with. I can hit most endpoints without issue

>>> requests.get(
    "https://hub.docker.com/v2/access-tokens",
    headers={"Authorization": f"Bearer {token}"},
).json()

{'count': 1,
 'next': None,
 'previous': None,
 'active_count': 1,
 'results': [{'uuid': 'xxx',
   'client_id': 'HUB',
...
   'scopes': ['repo:admin']}]}

But the advanced image API endpoints give me an insufficient scope error

>>> requests.get(
    "https://hub.docker.com/v2/namespaces/<namespace>/repositories/<repo>/images-summary",
    headers={"Authorization": f"Bearer {token}"},
).json()

{'errinfo': {}, 'message': 'insufficient scope'}

There’s no information in the response so I don’t really know where to start debugging this. These endpoints used to work as of a few weeks ago.

Is anyone else experiencing this?

1 Like

This is now fixed; see issue 2224.