Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,367,641
Community Members
 
Community Events
168
Community Groups

Hash format in Pull Request event payloads (Webhooks)

Hi there,

Is there a reason why Pull Request event payloads include just a part of Git commit hash (first 12 characters) rather than all 40 characters?

"commit" : { "hash" :  "d3022fc0ca3d" }

Repository event payloads include full Git commit hashes:

"target": {  "type": "commit",
  "hash": "d3022fc0ca3d65c7f6654eea129d6bf0cf0ee08e",
  ...

Are there any plans to change this in the future?

https://support.atlassian.com/bitbucket-cloud/docs/event-payloads/

Thank you!

1 answer

0 votes

Hi Rimas,

We have a report about this in our issue tracker:

The first two comments in that issue are from our developers, you can read them for an explanation of why this is occurring as well as workarounds on how to get the full hash.

If we change this now there is a risk of breaking any client or application that was dependent on only the short version of the hash. So any solution would need to take this into account as well and it's not likely that this will be fixed in the short term.

I would recommend selecting the option "This affects my team" in the bug report to indicate you are affected by this and you are also welcome to leave a comment with your feedback there. You can also select the "Start watching this issue" option in the ticket if you'd like to get notified via email on updates.

Kind regards,
Theodora

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PERMISSIONS LEVEL
Site Admin
TAGS

Atlassian Community Events