[400] Specify a valid project ID or key

Matt Ohlson (Vendor)
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!
May 10, 2023

I am using a middleware to connect via the API.  I continue to receive a "[400] Specify a valid project ID or key" whenever attempting to create an issue using the below API calls  Any ideas: 

 

{

  "fields": {

     "assignee": {

          "id": "{{89.owner_email}}",

    "duedate": "{{3.`DE:Launch Date`}}",

    "project": {"id": "14505"},

    "summary": "{{3.name}}",

 "description": {

      "content": [

        {

          "content": [

            {

              "text": "{{3.`DE:The Ask?`}}",

              "type": "text"

            }

          ],

          "type": "paragraph"

        }

      ],

      "type": "doc",

      "version": 1

    },

 "customfield_15408": {

      "content": [

        {

          "content": [

            {

              "text": "{{3.`DE:Business Impact`}}",

              "type": "text"

            }

          ],

          "type": "paragraph"

        }

      ],

      "type": "doc",

      "version": 1

    },

        "priority": {

          "id": "{{89.priority_jira_value}}"

        },

        "issuetype": {

          "id": "7"

        },

        "reporter": {

          "id": "{{89.owner_email}}"

        },

        "assignee": {

          "id": "{{89.owner_email}}",

          "customfield_18130": {

            "id": "{{89.owner_email}}"

          },

          "customfield_10205": "{{3.name}}",

          "customfield_10004": "{{89.story_points}}",

          "labels": "[{3.`DE:Jira Labels`}]",

          "components": "[{3.`DE:Jira Labels`}]",

          "issuelinks": "{{3.`DE:Jira Issue Link`}}",

          "customfield_26582": "{{3.`DE:iAttach`}}",

          "customfield_26621": "{{3.`DE:Outcome Renewal iGCR`}}",

          "customfield_26620": "{{3.`DE:Outcome New iGCR`}}",

          "customfield_26622": "{{3.`DE:Outcome GPV`}}",

          "customfield_26623": "{{3.`DE:iRR`}}",

          "customfield_26624": "{{3.`DE:iCVR`}}",

          "customfield_23819": "{{3.`DE:Creative Delivery Date`}}",

          "customfield_24800": "{{3.`DE:Estimated Financial Impact  $`}}",

          "customfield_15121": {

            "id": "{{89.business_unit_jira_value}}"

          },

          "customfield_21400": {

            "id": "{{89.seo_value}}"

          },

          "customfield_16519": {

            "id": "{{89.type_of_change_jira_value}}"

          },

          "customfield_20800": [

            {

              "id": "{{89.regional_marketing_jira_value}}"

            }

          ],

          "customfield_17909": {

            "id": "{{89.mops_needed}}"

          },

          "customfield_23818": {

            "id": "{{89.categories_of_work}}"

          },

          "customfield_26305": {

            "id": "{{89.experiment_theme}}"

          },

          "customfield_15844": {

            "id": "{{89.site_pod_name_jira_value}}"

          },

          "customfield_26577": {

            "id": "{{89.value_type}}"

          },

          "customfield_23501": {

            "id": "{{89.business_alignment}}"

          },

          "customfield_23104": {

            "id": "{{89.international_testing}}"

          },

          "customfield_25401": {

            "id": "{{89.design_work}}"

          },

          "customfield_26576": {

            "id": "{{89.functional_area}}"

          }

        }

      }

    }

  }

}

 

 

OR this call

 

{

"fields": {

"assignee": {

"id": "62cf6b196eba719837223722",

"project": {

"id": "14505"

},

"issuetype": {

"id": "7"

},

"assignee": {

"id": "62cf6b196eba719837223722",

"reporter": {

"id": "62cf6b196eba719837223722"

},

"components": [{

"id": ""

}],

"priority": {

"id": "{{89.priority_jira_value}}"

},

"summary": "{{3.name}}",

"customfield_18130": {

"id": "{{89.owner_email}}"

},

"customfield_10205": "{{3.name}}",

"customfield_10004": "{{89.story_points}}",

"labels": "{{3.`DE:Jira Labels`}}",

"issuelinks": "{{3.`DE:Jira Issue Link`}}",

"customfield_26582": "{{3.`DE:iAttach`}}",

"customfield_26621": "{{3.`DE:Outcome Renewal iGCR`}}",

"customfield_26620": "{{3.`DE:Outcome New iGCR`}}",

"customfield_26622": "{{3.`DE:Outcome GPV`}}",

"customfield_26623": "{{3.`DE:iRR`}}",

"customfield_26624": "{{3.`DE:iCVR`}}",

"customfield_23819": "{{3.`DE:Creative Delivery Date`}}",

"customfield_24800": "{{3.`DE:Estimated Financial Impact  $`}}",

"customfield_15121": {

"id": "{{89.business_unit_jira_value}}"

},

"customfield_21400": {

"id": "{{89.seo_value}}"

},

"customfield_16519": {

"id": "{{89.type_of_change_jira_value}}"

},

"customfield_20800": [{

"id": "{{89.regional_marketing_jira_value}}"

}],

"customfield_17909": {

"id": "{{89.mops_needed}}"

},

"customfield_23818": {

"id": "{{89.categories_of_work}}"

},

"customfield_26305": {

"id": "{{89.experiment_theme}}"

},

"customfield_15844": {

"id": "{{89.site_pod_name_jira_value}}"

},

"customfield_26577": {

"id": "{{89.value_type}}"

},

"customfield_23501": {

"id": "{{89.business_alignment}}"

},

"customfield_23104": {

"id": "{{89.international_testing}}"

},

"customfield_25401": {

"id": "{{89.design_work}}"

},

"customfield_26576": {

"id": "{{89.functional_area}}",

"description": {

"type": "doc",

"version": 1,

"content": [{

"type": "paragraph",

"content": [{

"text": "{{3.`DE:The Ask?`}}",

"type": "text"

}]

}],

"customfield_15408": {

"type": "doc",

"version": 1,

"content": [{

"type": "paragraph",

"content": [{

"text": "{{3.`DE:Business Impact`}}",

"type": "text"

}]

}]

}

}

}

}

}

}

}

1 answer

0 votes
Trudy Claspill
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 10, 2023

Hello @Matt Ohlson (Vendor) 

Welcome to the Atlassian community.

You appear to be missing a closing curly brace on Assignee.

{

  "fields": {

     "assignee": {

          "id": "{{89.owner_email}}"},

    "duedate": "{{3.`DE:Launch Date`}}",

    "project": {"id": "14505"},

 

Additionally have you confirmed that 14505 is a valid ID for a project?

Matt Ohlson (Vendor)
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!
May 12, 2023

Hi Trudy,

Thank you for your reply.  It helped me resolve the Project ID/Issue ID challenge I was having.  

However, I am still receiving the below errors based on the below call. I believe its related to how the Description and customfield_15408 are formatted. Any help would be greatly appreciated:

{
"errorMessages": [],
"errors": {
"customfield_24800": "Specify a number for the custom field (below 100,000,000,000,000)",
"customfield_15408": "Operation value must be a string",
"description": "Operation value must be a string",
"customfield_26621": "Specify a number for the custom field (below 100,000,000,000,000)",
"customfield_26620": "Specify a number for the custom field (below 100,000,000,000,000)",
"customfield_26623": "Specify a number for the custom field (below 100,000,000,000,000)",
"customfield_26622": "Specify a number for the custom field (below 100,000,000,000,000)",
"customfield_26624": "Specify a number for the custom field (below 100,000,000,000,000)",
"customfield_10004": "Specify a number for the custom field (below 100,000,000,000,000)"
}
}

 

{
"fields": {
"assignee": {
"id": "62cf6b196eba719837223722"
},
"duedate": "2023-05-23",
"project": {
"id": "14505"
},
"summary": "Workfront Integration Test Please Ignore",
"description": {
"content": [
{
"content": [
{
"text": "the ask",
"type": "text"
}
],
"type": "paragraph"
}
],
"type": "doc",
"version": 1
},
"customfield_15408": {
"content": [
{
"content": [
{
"text": "this is the business impact this is the business impact this is the business impactthis is the business impact this is the business impactthis is the business impactthis is the business impact this is the business impact this is the business impactthis is the business impactthis is the business impactthis is the business impactjkjl",
"type": "text"
}
],
"type": "paragraph"
}
],
"type": "doc",
"version": 1
},
"priority": {
"id": "3"
},
"issuetype": {
"id": "7"
},
"reporter": {
"id": "62cf6b196eba719837223722"
},
"customfield_18130": {
"id": "62cf6b196eba719837223722"
},
"customfield_10205": "Workfront Integration Test Please Ignore",
"customfield_10004": "",
"customfield_26621": "46",
"customfield_26620": "45",
"customfield_26622": "47",
"customfield_26623": "45",
"customfield_26624": "43",
"customfield_23819": "2023-05-17",
"customfield_24800": "",
"customfield_15121": {
"id": "32989"
},
"customfield_21400": {
"id": "25303"
},
"customfield_16519": {
"id": "18482"
},
"customfield_20800": [
{
"id": "32984"
}
],
"customfield_17909": {
"id": "18468"
},
"customfield_23818": {
"id": "34168"
},
"customfield_26305": {
"id": "33963"
},
"customfield_15844": {
"id": "32325"
},
"customfield_26577": {
"id": "34373"
},
"customfield_23501": {
"id": "34350"
},
"customfield_23104": {
"id": "29215"
},
"customfield_25401": {
"id": "32335"
},
"customfield_26576": {
"id": "34355",
"update": {}
}
}
}

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
TAGS
AUG Leaders

Atlassian Community Events