I am trying to use the Jira Rest API to gather data from Jira tickets in my project using python. I want to be able to collect the comments, custom fields, and summary/key.
Trying to use the following code:
Hello @Noah F Wilson
If you refer to the Jira Cloud REST API documentation, you will see there is no POST endpoint with the path /rest/api/3/jql
You probably should be using the Search for Issues using JQL (POST) endpoint which has the path /rest/api/3/search/jql
I recommend that you use an API test tool like Postman to validate your requests independently of your code.
Ahhhh I am sorry this is a typo in my code, I am using /rest/api/3/search/jql and still getting this error. I will check the Postman tool to validate thanks!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
When you get such error responses from a REST APII when making a complex request, break the request down into smaller pieces and solve the problem one step at time.
Start by making the simplest request possible to that API endpoint; declare just the jql parameter and its value only. If that request works, then start adding more parameters and their values, one by one, making sure each new combination works, until you encounter which one is causing the problem. Then, refer to the documentation to confirm:
Have fun
PS. In your Python code, I can see which of your request parameters is invalid and causing the error, but I would like you to try the problem solving process for yourself, rather than just give you the answer. I hope you understand my rational and take it in the manner intended.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.