No v3 API/v4 GraphQL mutation to convert PR to a draft


I am looking for a way to programmatically mark a PR as draft again. I don’t see anything in the v3/v4 APIs. There is only the field, but it’s ready-only. Is that only a UI feature and why?

I did find a mutation in the v4 GraphQL API that I am using for the other way around, i.e. to mark a draft PR as ready-for-review (, but nothing to mark a ready-for-review PR as draft.

Does anybody know how to do that or where I would file a feature request for that?

Thanks in advance, Vedran

I have also been looking around for this in the V3 API. It does not seem possible to me.

Any update on this? Is it now possible to turn a ready into a draft PR via the graphql API?

Or even to do both, draft -> ready and ready -> draft with the v3 API?