Tempo request with API token => 401 unauthorized

Nicolas Chapit
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 5, 2021

Hi,

Yesterday, I tried to run a script to send timesheet to Tempo using the REST API.

I created a new API token and now I always get as response 401 Unauthorized. 

3-4 days ago, it was working fine and nothing have been changed in my code.

 

My request uses the bearer token authentification.

And calls 

POST https://api.tempo.io/core/3/worklogs

 

Was there any changes on the API side, like switching the authentification way?

Thanks.

1 answer

1 accepted

1 vote
Answer accepted
Nicolas Chapit
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 5, 2021

My bad >.>

Wrong API token...

All good, sorry.

 

You can close this.

Manoj Gnanaseelan August 22, 2023

Your API token is the one you generated in settings and not the OAuth2.0 token, isn't it? In that case, I am using the same, but still getting unauthorized error.

Like Fabio Fragapane likes this
Fabio Fragapane
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!
September 20, 2023

Hello Manoj, did you find a solution for this ? I got the same error and the configuration hasn't changed. Could this be related to v3 or v4 of the api ?
Thanks

Manoj Gnanaseelan September 20, 2023

@Fabio Fragapane From another post I got the info that, to use the Token Authentication with API we have to use the following end point

https://api.tempo.io/4/worklogs

You can try this.

Fabio Fragapane
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!
September 24, 2023

@Manoj Gnanaseelan Thanks Manoj. I had a different issue, the token was expiry. I refreshed it but it didn't work.

I had to re-create the configuration in the other tool (ServiceNow) and then the new token works.

Like Manoj Gnanaseelan likes this
Manoj Gnanaseelan September 24, 2023

@Fabio Fragapane Thanks for sharing. This might be useful for someone else facing similar issue.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events