Forums

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

How do we Map custom field ids to custom field names

venkateswarlu August 13, 2019

I have integrated Jira with other remote systems and it has given the responce in JSON like this

                <issue>

                                <id>41468</id>

                                <self>http://dev-jira.lamresearch.com:8080/rest/api/2/issue/41468</self>

                                <key>IP-1</key>

                                <fields>

                                                <resolution />

                                                <customfield_10510 />

                                                <customfield_10500 />

                                                <customfield_10501 />

                                                <customfield_11710 />

                                                <customfield_10503 />

                                                <customfield_10504 />

                                                <customfield_10505 />

                                                <customfield_10506 />

                                                <customfield_10507 />

                                                <customfield_10508 />

                                                <customfield_10509 />

                                                <lastViewed>2019-08-12T17:55:48.220+0000</lastViewed>

                                                <priority>

                                                                <self>http://dev-jira.lamresearch.com:8080/rest/api/2/priority/1</self>

                                                                <iconUrl>http://dev-jira.lamresearch.com:8080/images/icons/priorities/blocker.svg</iconUrl>

                                                                <name>Blocker</name>

                                                                <id>1</id>

                                                </priority>

                                                <customfield_10102 />

                                                <customfield_11700 />

                                                <customfield_11702 />

                                                <customfield_11701 />

                                                <customfield_11704 />

                                                <timeestimate />

                                                <aggregatetimeoriginalestimate />

                                                <customfield_11706 />

                                                <customfield_11705 />

                                                <customfield_11707 />

                                                <customfield_11709 />

                                                <assignee />

                                                <status>

                                                                <self>http://dev-jira.lamresearch.com:8080/rest/api/2/status/10100</self>

                                                                <description></description>

                                                                <iconUrl>http://dev-jira.lamresearch.com:8080/</iconUrl>

                                                                <name>To Do</name>

                                                                <id>10100</id>

                                                                <statusCategory>

                                                                                <self>http://dev-jira.lamresearch.com:8080/rest/api/2/statuscategory/2</self>

                                                                                <id>2</id>

                                                                                <key>new</key>

                                                                                <colorName>blue-gray</colorName>

                                                                                <name>To Do</name>

                                                                </statusCategory>

                                                </status>

                                                <customfield_12110 />

                                                <customfield_12111 />

                                                <customfield_10210 />

                                                <customfield_12114 />

                                                <customfield_10211 />

                                                <customfield_12113 />

                                                <customfield_10203 />

                                                <customfield_12107 />

                                                <customfield_10204 />

                                                <customfield_12106 />

                                                <customfield_10205 />

                                                <customfield_12109 />

                                                <customfield_10206 />

                                                <customfield_12108 />

                                                <customfield_10207 />

                                                <aggregatetimeestimate />

                                                <customfield_10208 />

                                                <customfield_10209 />

                                                <creator>

1 comment

Comment

Log in or Sign up to comment
DPKJ
Community Champion
August 13, 2019

If you are using Jira  Rest APIs, you can use `expand=names` parameter to get names of custom-field in response.

Like this, https://<jira_base_url>/rest/api/2/search?maxResults=10&expand=names

Like # people like this
venkateswarlu August 13, 2019

Thank you so much for your quick responce .

I have a doubt in your URL what search?maxResults=10 indicates?

Derek Lee
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
June 15, 2022

The maxResults parameter will get up to (but it's merely a suggestion) that number of results. In this case you'll get up to 10 tickets.

I have played with maxResults = 1000 but usually get 100 tickets in response. setting the maxResults provides a parameter that is useful when you write scripts to account for pagination of the results.

TAGS
AUG Leaders

Atlassian Community Events