Forums

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

Create jira task: Unexpected token < in JSON at position 1

Oleg Matiunin
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!
July 4, 2024

 

I have been successfully using api v2 for more than a year to create Jira tasks in a project. Without changing anything - today the create request stopped working. I can’t understand what the problem is.

jira ulr =  'https://my-domain.com/rest/api/2/isue/'
Node.js:


const response = await fetch(JIRA_URL, {
method: 'POST',
headers: {

'Content-Type': 'application/json',
Authorization: `Bearer ${jiraToken}`,
},
body: JSON.stringify(issuerConfig),
})


Where 

issuerConfig is js object like : 
{
fields: {
... standart data that worked before many years
}
}

1 answer

0 votes
Mohamed Benziane
Community Champion
July 4, 2024

Hi,

Can you share the json that you are using ?

Suggest an answer

Log in or Sign up to answer