Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Creating Issues with API but Description does not seem to get created

SMARTdeveloper September 6, 2021

I've searched and it seems that I need to follow an Atlassian Document Format to add to description field and I believe that I am doing that. The creation of the issue succeeds but when I look at the issue either in browser or via API the content part of the Description field is empty.

In the body of the request I have this:

 

        "description": {
            "type": "doc",
            "version": 1,
            "content": [
                {
                    "type": "paragraph",
                    "content": [
                        {
                            "type": "text",
                            "text": "Why no description?"
                        }
                    ]
                }
            ]
        },
and when I try to retrieve the newly created issue I get this:
        "description": {
            "type": "doc",
            "version": 1,
            "content": []
        },
What is going on here you think? 

2 answers

1 accepted

0 votes
Answer accepted
Vikrant Yadav
Community Champion
September 6, 2021

Hi @SMARTdeveloper  Check this :- https://blog.developer.atlassian.com/creating-a-jira-cloud-issue-in-a-single-rest-call/

have you tried to create issue manually in jira, description field is avaiable on create screen and view screen ? 

SMARTdeveloper September 7, 2021

Yes. Description is available when I create a new issue on the site.

When I open an issue created by API I can supply a description and getting the issue again in postman will now show that the description object is filled out.

 

        "description": {
            "version": 1,
            "type": "doc",
            "content": [
                {
                    "type": "paragraph",
                    "content": [
                        {
                            "type": "text",
                            "text": "Manually added description"
                        }
                    ]
                }
            ]
        },
SMARTdeveloper September 7, 2021

Turned out our JIRA guys has made a custom description field and are clearing the description field. They just forgot to tell the API developer.

So that's the reason why its not updating.

Thanks.

Vikrant Yadav
Community Champion
September 7, 2021

@SMARTdeveloper  Great :). same i was thinking. Due to custom Description fied, it was not working. Above API work for system description field only. 

Finally it works for you. 

Thanks

V.Y

Suggest an answer

Log in or Sign up to answer