0

at my company we want to make use of the relatively new API feature "Automerge" (not through a UI but through an API call), However we can't seem to find any documentation of a webhook (or other asyc way) of finding out if a merge request failed and why, anyone know a way to receive such a notification?

Thanks! :)

3
  • Couldn't find anything in the docs (docs.github.com/en/developers/webhooks-and-events/webhooks/…), but here's a way to test this: Create a new GitHub App and install it in your repository. Configure some smee.io URL as webhook URL and enable all types of events. With that setup, trigger the automerge and see if an event is fired. Commented Nov 17, 2021 at 8:00
  • 1
    Thanks rethab, unfortunately we couldn't find anything that would convey automerge failure in there and github.com support confirmed there's no good way of doing that currently. Commented Nov 18, 2021 at 7:30
  • Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Commented Nov 23, 2021 at 5:56

1 Answer 1

0

Hope this saves some work for someone out there, we asked Github.com support directly and they said there was no async / webhooky way of doing this (as of Nov 2021).

Here's a quote from the support person when asked if there were a way to find out, here's what they wrote:

There wouldn't be a great way to discern that (reason for failure) and it may be better when you see that, to use the REST API to Get the Pull Request to get some additional information.

looking at the documentation as suggested in the quote above it seems that through the "closed" action and "merged" key one could discern whether a merge was successful or not, but without any further information about the failure.

Sign up to request clarification or add additional context in comments.

1 Comment

Your answer could be improved with additional supporting information. Please edit to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers in the help center.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.