How to manually re-add webhook to public repo in a GitHub organization


When the webhook to is (mistakenly) removed in a public GitHub repo what is the easiest way to get it back? Preferably for a maintainer of the repo which does not have org permission to manage Codecov GitHub app. :slight_smile:



not applicable

Additional Information


We were doing fine up to this part. :wink:

Assuming you have access to add a webhook, I wonder if revoking your OAuth and signing back to Codecov would do it. Failing that, you may need to look into settings a team bot

Let me know if either of those work.

Since CodeCov wasn’t working for us using Pester <=v4.9 have removed it in some repos. Now that it works we need to readd it again. :wink:

Maintainers do have the right to add webhooks, they are admins on the repos. But not finding any OAuth to remove. :thinking:
In it says in

Codecov uses GitHub Webhooks to keep in sync with your project.

A webhook has been enabled through GitHub Integrations. No setup required.

I do have org permission to manage the GitHub App. Is there are an easy way for me to re-add the webhook in all repos that currently missing it? But I was hoping there was a way for the maintainers to just add the webhook to the GitHub repo settings webhook page. :slightly_smiling_face:

I rather not use the Team Bot since GitHub App works perfectly. :slightly_smiling_face:

You can try using the API to activate it, that may put the webhook back. I’m not sure without doing a code dive, which I don’t have the bandwidth for currently. (will add to my list if that doesn’t work, though)

I tried but the result was:

{"meta": {"status": 400}, "error": {"reason": "You may only activate private repositories.", "context": null}}

Just noticed that on the repo settings on Codecov there should be a button to create the web hook back, do you see that?

I can’t see a button that would do that. I browse to and under the “Genaral” tab there are a section “GitHub Webhook”, but it only have this text:

Codecov uses GitHub Webhooks to keep in sync with your project.

A webhook has been enabled through GitHub Integrations. No setup required.

Arg. Apparently my view is messing with me today.

It’s looking like the only solution is getting an org admin to toggle the app on GitHub, but I’m still looking for another solution.

The maintainer is currently adding the necessary steps to the pipeline to upload reports to We will see if that will trigger the re-creation of the webhook (by the report is uploaded). Curious if the webhook is not needed when we have the GitHub App? Maybe the webhook in the other repos are something old before the GitHub App existed?

Based on the wording, I think it may be. I’d try uploading and see if things work correctly without it.

It did upload correctly and it posted back to the PR:

Just wondering now if we loose any functionality without the webhook. :thinking: Though, if we do not need the webhook that is even better! :smiley:


Tried upload from a newer repository:

It seems it uploaded the file:

But on the PR does not show:

You have an indenting issue around notify: :wink:

The primary issue though, is that you need to path fix source into your report path so we can match them:

Ah, notify should not be part of Codecov.yml since we don’t use the properties under it. :thinking:
I just realized too that it was a bad repository to test with since that have the folder structure totally different than the others. :confused: I will try with another one in a bit. :slightly_smiling_face:

1 Like

I update this repo (PR) as well, and it seems to work without the webhook. So this might have been a non-issue. :thinking: :smile:

1 Like

You mean the note that “webhooks aren’t needed when using the app” might be true? :woman_facepalming:

(to be 100% clear, I’m facepalming myself, not you. Very happy it’s working correctly) :smiley:

Haha. Sorry I took you down the rabbit hole. :wink:

All good :slight_smile: