# Timeline events authentication not working

**URL:** <https://community.hubspot.com/t/timeline-events-authentication-not-working/57389>\
**Category:** APIs & Integrations\
**Tags:** timeline-and-extensions-apis\
**Created:** [May 20, 2022, 1:34pm UTC](https://community.hubspot.com/t/timeline-events-authentication-not-working/57389 "2022-05-20T13:34:30Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![EAminoff](https://avatars.discourse-cdn.com/v4/letter/e/5fc32e/32.png) [@EAminoff](https://community.hubspot.com/u/EAminoff)\
**Post date:** [May 20, 2022, 1:34pm UTC](https://community.hubspot.com/t/timeline-events-authentication-not-working/57389/1 "2022-05-20T13:34:30Z")

</div>

Hi! I have a problem while trying to get all timeline events from my hubspot app.  
In the code im successfully getting contacts, owners etc. with my oauth requests but when i try to use:

try {

const apiResponse =

await hubspotClient.crm.timeline.templatesApi.getAll(appId)

console.log(JSON.stringify(apiResponse.body, null, 2))

} catch (e) {

e.message === ‘HTTP request failed’

? console.error(JSON.stringify(e.response, null, 2))

: console.error(e)

}

i get the following error:

body: {  
status: ‘error’,  
message: ‘Any of the listed authentication credentials are missing’,  
correlationId: ‘2b8ada6e-af25-4a80-b363-a07a398ed30a’,  
engagement: {  
hapikey: ‘hapikey not engaged. hapikey is not present in query params.’,  
‘oauth-token’: ‘oauth-token not engaged. OAuth access token not found in request header.’,  
‘service-to-service’: ‘service-to-service not engaged. Metadata for service-to-service request not found.’,  
‘internal-cookie’: ‘internal-cookie not engaged. Cookie not found in the request.’,  
‘app-cookie’: ‘app-cookie not engaged. App cookie is not present on the request.’  
}

I have checked my scopes and it includes timeline. Hoping that someone can point me in the right direction. Best regards

---

<div class="post-metadata">

**Author:** ![dennisedson](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/dennisedson/32/28044_2.png) [@dennisedson](https://community.hubspot.com/u/dennisedson)\
**Post date:** [May 20, 2022, 8:24pm UTC](https://community.hubspot.com/t/timeline-events-authentication-not-working/57389/2 "2022-05-20T20:24:01Z")

</div>

@EAminoff ,

If you are looking to grab the template, you will need to use your developer API key referenced in [the docs](https://developers.hubspot.com/docs/api/crm/timeline)

 ![CRM_API___Timeline_events.png](https://d2qpr2jzcazej7.cloudfront.net/original/3X/1/8/18aeee38e5932792c7c19768617521252a4fcef6.png)

---

<div class="post-metadata">

**Author:** ![EAminoff](https://avatars.discourse-cdn.com/v4/letter/e/5fc32e/32.png) [@EAminoff](https://community.hubspot.com/u/EAminoff)\
**Post date:** [May 23, 2022, 11:19am UTC](https://community.hubspot.com/t/timeline-events-authentication-not-working/57389/3 "2022-05-23T11:19:05Z")

</div>

[Accounts Dashboard | HubSpot](https://developers.hubspot.com/docs/api/crm/timeline) under POST  
/crm/v3/timeline/events The API reference for node.js is incorrect. It says  
hubspotClient.crm.timeline.events.eventsApi.create even though it should  
be hubspotClient.crm.timeline.eventsApi.create. Thought you might want to  
know. Thanks again for your help. Best regards,

---

<div class="post-metadata">

**Author:** ![AHussain17](https://avatars.discourse-cdn.com/v4/letter/a/f6c823/32.png) [@AHussain17](https://community.hubspot.com/u/AHussain17)\
**Post date:** [August 25, 2023, 7:23am UTC](https://community.hubspot.com/t/timeline-events-authentication-not-working/57389/4 "2023-08-25T07:23:53Z")

</div>

Getting same error , i have to use oauth access token ,  
Because i have to use this api on the behalf of my user who login and will provide access token to me ,  
and i tried alot and getting the same above error  
provided by @EAminoff  
so, @dennisedson please let me know how i can use this api , with access token , i need to do CRUD operation with timeline event templates .  
@lindahl

---

<div class="post-metadata">

**Author:** ![lindahl](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/lindahl/32/220871_2.png) [@lindahl](https://community.hubspot.com/u/lindahl)\
**Post date:** [May 23, 2022, 9:41am UTC](https://community.hubspot.com/t/timeline-events-authentication-not-working/57389/5 "2022-05-23T09:41:22Z")

</div>

Hi @EAminoff , just doing a double check, did you add the right appId in the path as well as declaring the variable when doing the GET request? The request is quite simple so I guess we just need to double check either OAuth token or appId is incorrect/not present.

---

<div class="post-metadata">

**Author:** ![EAminoff](https://avatars.discourse-cdn.com/v4/letter/e/5fc32e/32.png) [@EAminoff](https://community.hubspot.com/u/EAminoff)\
**Post date:** [May 23, 2022, 11:05am UTC](https://community.hubspot.com/t/timeline-events-authentication-not-working/57389/6 "2022-05-23T11:05:05Z")

</div>

Hello! I managed to make the get request with the developers API-key. Thank  
you for your help!
