REST api v3: Create Pull Request not working anymore? #24308
-
I was working on creating some kind of automation on Github with merging PRs (pretty much just trying to trigger a new Pull Request between staging and testing server each time staging is deployed). The API in general is working fine with my access key etc, I can view open PRs in the same “message”: “Invalid request. For ‘links/0/schema’, nil is not an object.” and request I am trying with CURL or Postman is (POST ofc) https://api.github.com/repos/org_name/repo_name/pulls?access_token=token_that_worked_for_get_private_info&title=test&head=master&base=development and this matches docs for https://developer.github.com/v3/pulls/#create-a-pull-request in my opinion. Has the API changed without the documentation being noticed and this feature is now only supported by the v4 GraphQL API or am I just doing something wrong here? edit: used hub to do this eventually. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
@exhibiton , I had a similar problem with python requests module and when I used the json keyword over params keyword, it worked. So, the problem is the data you are posting as the status code indicates. |
Beta Was this translation helpful? Give feedback.
-
hi @jothikanth , what do you mean by “json keyword over params keyword” ? do you mean the HTTP header set with |
Beta Was this translation helpful? Give feedback.
@exhibiton , I had a similar problem with python requests module and when I used the json keyword over params keyword, it worked. So, the problem is the data you are posting as the status code indicates.