Timeline endpoints

I am trying to migrate my timeline endpoints from v1 that uses api key to v3.
I heard that the API keys are deprecating, but in the documentation it was also mentioned to use oauth for timelines endpoints.
But somehow the timeline endpoints don’t seem to work both with private access token, as well as the oauth.
Everytime i try to acces with anything apart from apikey, i get the following error "This oauth-token (CPzOkam) does not have proper permissions! (requires all of [developers-read]) "
Please help

Hi @NNelissen

I spent way too much time trying to get Version 3 of the Timeline API working… in the end I abandoned my code and went back to Version 1 because I could use OAuth and I couldn’t update a Timeline Event using Version 3.

I have read somewhere you can use a Developers API Key (which may explain “requires all of [developers-read]”) but I could only get Version 1 working reliably with OAuth (I’ve avoided API keys for a while).

At some stage - I assume - Private Apps will work with Version 3. And, hopefully we will be able to Update a Timeline Event.

Have fun

Mike

Hey Mike, for using Oauth in v1 as well i get the above error.
could you share your curl request for this?

Hi @NNelissen

I’m using the PHP SDK, so my code will only help if you’re using the same SDK (there are other SDKs).

Here’s the Timeline Class, which may help.

And I think you’ll find the SDK uses OAuth2.

What language are you working in?

Mike

I am trying to run this on an integration tool, works similar to postman.

I believe there are some endpoints in timeline collection which always had OAuth option for them available.

Example -
1. Gets the event (/crm/v3/timeline/events/{eventTemplateId}/{eventId})

2. Create a single event (/crm/v3/timeline/events)

But for endpoints alike the ones mentioned below, we still “developer account API key” for the documentation test page -
1. List all event templates for your app (/crm/v3/timeline/{appId}/event-templates)
2. Create an event template for your app (/crm/v3/timeline/{appId}/event-templates)

Even if I try to pass private app api token, and give it admin access with all scopes added, still I am getting errors like -
Case 1 - For API Key (GET)
{
“status”: “error”,
“message”: “This oauth-token (pat-na1-7a8e8) does not have proper permissions! (requires all of [developers-read])”,
“correlationId”: “38e36d4c-fa40-4b30-a30b-155bc11fe0db”
}

Case 2 - API Key (POST)
{
“status”: “error”,
“message”: “This oauth-token (pat-na1-7a8e8) does not have proper permissions! (requires all of [developers-write])",
“correlationId”: "5fc9c808-e211-4f73-ba06-0b79ea6b5cd5”
}
----------
To Sum the questions I pose here are
1. I don’t understand whether husbot hasn’t updated these endpoints to use private app - api access token yet, why does the documentation still ask for ‘developer account API key’ to authenticate?
2. What can I do to fix the persistent permissions error?

3. The App ID required in the URL path for these endpoints should be of a ‘Public OAuth App’ and access token from a ‘Private App’?