isTemplate option in Create Repository REST API not working

I’m trying to create a repository as a template in github using its Create Repository API (https://api.github.com/user/repos )

I tried with the below request body:

{"name":"template test","is_template":true}

I’m getting 200 as response and the repo is getting created, but its still not available as template. I have to manually change it to template from the repo’s settings.

1 Like