Getting image tags from Webhook Notifications

I’m running Docker Distribution 2.3.1 and Docker Engine 1.10.2. I have enabled webhook notifications and am hoping to get the image repository name and tag name in the notification. The notification doesn’t include the image’s tag, just the digest, which I expect based on what I read here (Backwards incompatible change on webhook notifications from 2.0 to 2.1 · Issue #966 · distribution/distribution · GitHub).

The event that’s received includes the image’s digest. I’m expecting to be able to query for the image’s manifest using the digest and get the tag back in the JSON description ($ curl -v -X GET 127.0.0.1:5000/v2/java/manifests/sha256:deca86615e81e37318c217b0f3340b394262206f5214a64ebb3430d9cd6bbb8d | jq .). However, the JSON description does not include tag. Besides the layers array (which seemed too large to paste here), all that’s include is:

"config": {
    "digest": "sha256:736600fd4ae51d27f72a348028c35989ab2c6324a92876728452d7125bdceac3",
    "size": 4950,
    "mediaType": "application/octet-stream"
  },
  "mediaType": "application/vnd.docker.distribution.manifest.v2+json",
  "schemaVersion": 2

This info does not include the tag. However, if I lookup by tag I do get the tag back ($ curl -v -X GET 127.0.0.1:5000/v2/java/manifests/8 | jq .):

"architecture": "amd64",
  "tag": "8",
  "name": "java",
  "schemaVersion": 1

Am I going the wrong direction in trying to determine an image’s tag from a webhook notification? Or am I querying the registry incorrectly? Any help is appreciated.

I think this has been addressed in this PR (https://github.com/docker/distribution/commit/afe2bdd1c5194ac85a59adf1fdd14c9da054356e#diff-244ed6061d1518cc8f9076637b0fd9dc).