Updating Default Branch - GitHub GraphQL API

Viewed 108

I’m trying to update the default branch for a repository using the GutHib v4 API, but having trawled through the documentation there doesn’t seem to be a mutation available to do this.

I have the current default branch ID from querying the repository properties.

I assumed it would be under updateRepository, but that’s quite high level and I can’t see any other obvious options available to do this.

I assume they won’t have missed adding this functionality so I guess I’m just looking in the wrong places.

Has anyone done this before or have an idea where the mutation might sit?

0 Answers
Related