I want to create and update issues from my app using v3 api's for it but I am quite confused here regarding the payload construction. I used this api "rest/api/3/field" to fetch the details of the fields in my project, in that let's consider two of the fields one is "summary" and the other one is "description".
{
"id": "description",
"key": "description",
"name": "Description",
"custom": false,
"orderable": true,
"navigable": true,
"searchable": true,
"clauseNames": [
"description"
],
"schema": {
"type": "string",
"system": "description"
}
}
{
"id": "summary",
"key": "summary",
"name": "Summary",
"custom": false,
"orderable": true,
"navigable": true,
"searchable": true,
"clauseNames": [
"summary"
],
"schema": {
"type": "string",
"system": "summary"
}
Here you can see the schema type of both the fields is "string". But in the sample payload for creating an issue they have provided the payload type like this
"description": { "content": [ { "content": [ { "text": "Order entry fails when selecting supplier.", "type": "text" } ], "type": "paragraph" } ], "type": "doc", "version": 1 },
"summary": "Main order flow broken",
Even though the both types are string, their structure differs. The description and summary are necessary fields so that I can hard code them for constructing the payload, but what about for other fields and custom fields, how can I know their payload structure correctly and construct them? Is there any way I could do that, I have to be able to assign values to all fields which I have in my jira account from my app.