# Timeline overview

**URL:** <https://community.hubspot.com/t/timeline-overview/11570>\
**Category:** APIs & Integrations\
**Tags:** events\
**Created:** [June 28, 2018, 7:33pm UTC](https://community.hubspot.com/t/timeline-overview/11570 "2018-06-28T19:33:24Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![system](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/system/32/124_2.png) [@system](https://community.hubspot.com/u/system)\
**Post date:** [June 28, 2018, 7:33pm UTC](https://community.hubspot.com/t/timeline-overview/11570/1 "2018-06-28T19:33:24Z")

</div>

I’m attempting to follow this docs article:  
 ![](https://d2qpr2jzcazej7.cloudfront.net/original/3X/3/7/37c00aeef7cfa7b8b407fe12b8bb7634c50ec78d.png) [developers.hubspot.com](https://developers.hubspot.com/docs/methods/timeline/timeline-overview)

### [Timeline API Overview](https://developers.hubspot.com/docs/methods/timeline/timeline-overview)

Overview and Walkthrough for the Timeline API

I followed the pre req and created a dev account and created a new app.

Got the hapi key, user id, and the app id.

Attempt to create an event type and it gives me this error:  
{“status”:“error”,“message”:“UserId not provided in request”, …

I can’t figure out where I’m going wrong since I’m just copying and pasting the command from the article  
curl -X POST -H “Content-Type: application/json” -d ’  
{  
“name” : “Example event type”,  
“applicationId”: xxxxx  
}’  
[https://api.hubapi.com/integrations/v1/xxxxx/timeline/event-types?hapikey=xxxxx&userId=xxxx](https://api.hubapi.com/integrations/v1/xxxxx/timeline/event-types?hapikey=xxxxx&userId=xxxx)

---

<div class="post-metadata">

**Author:** ![robertainslie](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/robertainslie/32/1875_2.png) [@robertainslie](https://community.hubspot.com/u/robertainslie)\
**Post date:** [June 29, 2018, 2:08pm UTC](https://community.hubspot.com/t/timeline-overview/11570/2 "2018-06-29T14:08:36Z")

</div>

Hi @scotts

Try wrapping your URL in single quotes, so the command becomes like this:

`curl -X POST -H "Content-Type: application/json" -d '{"name" : "Billing", "applicationId": [app-id]}' 'https://api.hubapi.com/integrations/v1/[app-id]/timeline/event-types?hapikey=[hapi]&userId=[userId]'`

---

<div class="post-metadata">

**Author:** ![system](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/system/32/124_2.png) [@system](https://community.hubspot.com/u/system)\
**Post date:** [June 29, 2018, 2:18pm UTC](https://community.hubspot.com/t/timeline-overview/11570/3 "2018-06-29T14:18:55Z")

</div>

[@Robert\_Ainslie](https://community.hubspot.com/u/robert_ainslie)

Okay that worked, that’s frustrating lol

Any particular reason why I had to wrap it in single quotes?

---

<div class="post-metadata">

**Author:** ![robertainslie](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/robertainslie/32/1875_2.png) [@robertainslie](https://community.hubspot.com/u/robertainslie)\
**Post date:** [June 29, 2018, 2:38pm UTC](https://community.hubspot.com/t/timeline-overview/11570/4 "2018-06-29T14:38:18Z")

</div>

Glad that worked!

I’m not a curl expert, but I think it’s because the URL has parameters - if params are present, you have to treat the URL as a string. I’ll follow up with the keeper of the docs to see if we can alter the example curl request to avoid future confusion.

---

<div class="post-metadata">

**Author:** ![system](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/system/32/124_2.png) [@system](https://community.hubspot.com/u/system)\
**Post date:** [June 29, 2018, 2:41pm UTC](https://community.hubspot.com/t/timeline-overview/11570/5 "2018-06-29T14:41:39Z")

</div>

[@Robert\_Ainslie](https://community.hubspot.com/u/robert_ainslie) that would be amazing, thanks again!

---

<div class="post-metadata">

**Author:** ![robertainslie](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/robertainslie/32/1875_2.png) [@robertainslie](https://community.hubspot.com/u/robertainslie)\
**Post date:** [June 29, 2018, 2:53pm UTC](https://community.hubspot.com/t/timeline-overview/11570/6 "2018-06-29T14:53:26Z")

</div>

Found the reason - it depends on the type of console you’re using. Bash tries to turn ? and & into commands. So, on some terminals quotes aren’t required, but they are in others.

I had the doc updated still, but, that’s the reason.

---

<div class="post-metadata">

**Author:** ![system](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/system/32/124_2.png) [@system](https://community.hubspot.com/u/system)\
**Post date:** [June 29, 2018, 7:23pm UTC](https://community.hubspot.com/t/timeline-overview/11570/7 "2018-06-29T19:23:34Z")

</div>

[@Robert\_Ainslie](https://community.hubspot.com/u/robert_ainslie) Off topic to the original question but in the same timeline API docs.

The second step “2. Defining Event Properties” both curl commands require the application id to be in the request data.

curl -X POST -H “Content-Type: application/json” -d ’  
{  
“name” : “webinarName”,  
“label” : “Webinar Name”,  
“propertyType”: “String”  
}’  
‘[https://api.hubapi.com/integrations/v1/\](https://api.hubapi.com/integrations/v1/%5C)\</timeline/event-types/\<\>/properties?hapikey=\<\>&userId=\<\>’

Needed to be

curl -X POST -H “Content-Type: application/json” -d ’  
{  
“name” : “webinarName”,  
“label” : “Webinar Name”,  
“propertyType”: “String”,  
“applicationId”: \<\>

}’  
‘[https://api.hubapi.com/integrations/v1/\](https://api.hubapi.com/integrations/v1/%5C)\</timeline/event-types/\<\>/properties?hapikey=\<\>&userId=\<\>’

Before it would work correctly

---

<div class="post-metadata">

**Author:** ![robertainslie](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/robertainslie/32/1875_2.png) [@robertainslie](https://community.hubspot.com/u/robertainslie)\
**Post date:** [June 29, 2018, 7:26pm UTC](https://community.hubspot.com/t/timeline-overview/11570/8 "2018-06-29T19:26:52Z")

</div>

Thanks for the heads up and can pass along as well.

The overview example should definitely include that, but my general recommendation is to view the specific doc for each of these calls, which includes more exhaustive detail. In this case, this one: [Accounts Dashboard | HubSpot](https://developers.hubspot.com/docs/methods/timeline/create-event-type) and this one: [Accounts Dashboard | HubSpot](https://developers.hubspot.com/docs/methods/timeline/create-timeline-event-type-property)
