# Tempo API won't accept Bearer Token

**URL:** <https://community.developer.atlassian.com/t/tempo-api-wont-accept-bearer-token/88155>\
**Category:** Jira Development\
**Tags:** auth, tempo\
**Created:** [January 24, 2025, 12:28pm UTC](https://community.developer.atlassian.com/t/tempo-api-wont-accept-bearer-token/88155 "2025-01-24T12:28:49Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![AndreasSchultz](https://avatars.discourse-cdn.com/v4/letter/a/53a042/32.png) [@AndreasSchultz](https://community.developer.atlassian.com/u/AndreasSchultz)\
**Post date:** [January 24, 2025, 12:28pm UTC](https://community.developer.atlassian.com/t/tempo-api-wont-accept-bearer-token/88155/1 "2025-01-24T12:28:49Z")

</div>

I’m trying to create worklog entries in tempo through the [https://api.eu.tempo.io/4/worklogs](https://api.eu.tempo.io/4/worklogs) API, but tempo always return 401.

I’ve managed to get the OAuth workflow working and can successfully retrieve a token from the tempo API, it something like:

```auto
{
  "access_token": "25XXXXXXXXXXXXXXXXXXXXXXXXXXXXX-XXXXX_XXXXX-us",
  "expires_in": 2591999,
  "token_type": "Bearer",
  "scope": "accounts:manage accounts:view activities:produce activities:view approvals:manage approvals:view audit:view papertrail:view periods:view plans:manage plans:view projects:manage projects:view rates:manage rates:view schemes:manage schemes:view teams:manage teams:view worklogs:manage worklogs:view",
  "refresh_token": "ZWXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXvBY"
}

```

However, when I try a POST a new worklog or even a GET to [https://api.eu.tempo.io/4/accounts](https://api.eu.tempo.io/4/accounts) with `Authorization: Bearer 25XXXXXXXXXXXXXXXXXXXXXXXXXXXXX-XXXXX_XXXXX-us` I always get a 401. Is there something that needs to be done to the bearer token before using it?

---

<div class="post-metadata">

**Author:** ![AndreasSchultz](https://avatars.discourse-cdn.com/v4/letter/a/53a042/32.png) [@AndreasSchultz](https://community.developer.atlassian.com/u/AndreasSchultz)\
**Post date:** [January 24, 2025, 12:36pm UTC](https://community.developer.atlassian.com/t/tempo-api-wont-accept-bearer-token/88155/2 "2025-01-24T12:36:17Z")

</div>

sign, 5min later an found the problem. When I use [api.tempo.io](http://api.tempo.io) instead of the EU API and it works. This is really strange, since I’m in the EU and did authenticate to the EU endpoint, but whatever, it works.
