DefinitelyTyped / dt-mergebot

The bot which handles auto-merging your PRs
https://devblogs.microsoft.com/typescript/changes-to-how-we-manage-definitelytyped/
MIT License
112 stars 44 forks source link

Adds a new webhook which returns the JSON data for a PR #405

Closed orta closed 3 years ago

orta commented 3 years ago

Adds a new API end-point which allows anyone to grab the bot's opinion on an arbitrary PR number. You should rightly be wondering what the goal is, well I'm exploring a playground for reviewing DT PRs and I need data from GitHub - specifically a bunch of PR metadata.

To get useful metadata reliably you need an access token etc, so I thought about re-using an existing API - then I wondered, well, I have to re-create some of the logic from the state from the bot. Why not just have the bot fix both issues? So, now you can make an API call to get the PR state for an arbitrary PR.