I try to create new task or stroy on my jira project but when I used post method an error 403 spawn. I have this error with my Angular code but with Postman it works perfectly.
In angular, I have no problem with get method.
let jiraTemplate = {
"fields":
{
"project": {
"key": "JIR"
},
"summary": "test",
"description": {
"version": 1,
"type": "doc",
"content": [
{
"type": "paragraph",
"content": [
{
"type": "text",
"text": "description",
}
]
}
]
},
"issuetype": {
"name": "Story",
}
}
}
}
});
const url = 'https://<myWebSite>.atlassian.net/rest/api/3/issue/'
const header = new HttpHeaders({
'Authorization': 'Basic ' + btoa("<login>:<token>"),
'Accept': 'application/json',
'Content-Type': 'application/json;charset=UTF-8',
});
const option = {headers: header}
this.http.post(url, JSON.stringify(jiraTemplate), option)
.subscribe(data => {
console.log('🚀 ~ data', data);
})
Join the largest European gathering of the Atlassian Community and reimagine what’s possible when great teams and transformative technology come together. Plus, grab your Super Fan ticket now and save over €1,000 on your pass before prices rise on 3 June.
Register nowOnline forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.