# Cannot create timeline event via Hubspot API

**URL:** <https://community.hubspot.com/t/cannot-create-timeline-event-via-hubspot-api/11756>\
**Category:** APIs & Integrations\
**Tags:** developer-tools\
**Created:** [May 18, 2018, 9:19pm UTC](https://community.hubspot.com/t/cannot-create-timeline-event-via-hubspot-api/11756 "2018-05-18T21:19:57Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Richter](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/richter/32/35493_2.png) [@Richter](https://community.hubspot.com/u/Richter)\
**Post date:** [May 18, 2018, 9:19pm UTC](https://community.hubspot.com/t/cannot-create-timeline-event-via-hubspot-api/11756/1 "2018-05-18T21:19:57Z")

</div>

I cannot create a timeline event with developer api via oAUTH

get error 422 with message “eventTypeId must be greater than or equal to 1 (was 0)”  
It appears the format must need to be different as compared to generating other things like Contacts.  
In my developer portal, my body is below which you can see is setting eventTypeId. Must be something simple that I just have wrong in my call. Also, response copy below from dev portal.

{“properties”:[{“property”:“id”,“value”:“11111”},{“property”:“eventTypeId”,“value”:“25605”},{“property”:“DESCRIPTION”,“value”:“Attended Webinar: 20170919-WBN-AdWeek-Add-Transparency”},{“[property":“email”,“value”:"bb@plainsmobile.com](mailto:property%22:%22email%22,%22value%22:%22bb@plainsmobile.com)”}]}

{“status”:“error”,“message”:“unprocessable entity”,“correlationId”:“34983d9e-2be3-4b3c-85a0-587f7f5e09e3”,“errors”:[“eventTypeId must be greater than or equal to 1 (was 0)”,“id may not be null (was null)”],“requestId”:“5d6a1079476d970af765a72fbf66e925”}

---

<div class="post-metadata">

**Author:** ![Richter](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/richter/32/35493_2.png) [@Richter](https://community.hubspot.com/u/Richter)\
**Post date:** [May 18, 2018, 9:42pm UTC](https://community.hubspot.com/t/cannot-create-timeline-event-via-hubspot-api/11756/2 "2018-05-18T21:42:07Z")

</div>

I was able to create event now I just cannot see it in the company portal. Anybody know how to get the timeline events to show up?

---

<div class="post-metadata">

**Author:** ![Derek\_Gervais](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/derek_gervais/32/17429_2.png) [@Derek\_Gervais](https://community.hubspot.com/u/Derek_Gervais)\
**Post date:** [May 22, 2018, 5:28pm UTC](https://community.hubspot.com/t/cannot-create-timeline-event-via-hubspot-api/11756/3 "2018-05-22T17:28:48Z")

</div>

Hi @Richter,

Have you checked the timeline filters on that particular object record? If that’s not the issue, can you give me a link to the object record in HubSpot and also a link to your dev portal?

 ![](https://d2qpr2jzcazej7.cloudfront.net/original/3X/8/9/89483a8de9bdc55d982e59c9c8b6de05e4fd8ee4.png) [knowledge.hubspot.com](https://knowledge.hubspot.com/articles/kcs_article/contacts/how-do-i-change-which-activities-display-on-a-contact-company-deal-ticket-record-timeline)

 ![29ad476bde5f5b0596e6d93e215ec3bb1ad46200.png](https://d2qpr2jzcazej7.cloudfront.net/original/2X/2/29ad476bde5f5b0596e6d93e215ec3bb1ad46200.png)

### [How do I change which activities display on a contact, company, deal, or ticket…](https://knowledge.hubspot.com/articles/kcs_article/contacts/how-do-i-change-which-activities-display-on-a-contact-company-deal-ticket-record-timeline)

Learn how to customize the timeline on a contact, company, deal, or ticket record to display specific types of information.

---

<div class="post-metadata">

**Author:** ![Richter](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/richter/32/35493_2.png) [@Richter](https://community.hubspot.com/u/Richter)\
**Post date:** [May 22, 2018, 7:35pm UTC](https://community.hubspot.com/t/cannot-create-timeline-event-via-hubspot-api/11756/4 "2018-05-22T19:35:18Z")

</div>

also would like to not on this issue that the timeline excepts the data sent to be in a different format than the property format. api is looking for something raw like this;  
{  
“id”: params.id,  
“eventTypeId”: params.eventTypeId,  
“DESCRIPTION”: params.DESCRIPTION,  
“email”: params.email,  
“timestamp”: params.timestamp,  
“DATE”: params.DATE  
}

---

<div class="post-metadata">

**Author:** ![Richter](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/richter/32/35493_2.png) [@Richter](https://community.hubspot.com/u/Richter)\
**Post date:** [May 22, 2018, 7:33pm UTC](https://community.hubspot.com/t/cannot-create-timeline-event-via-hubspot-api/11756/5 "2018-05-22T19:33:41Z")

</div>

I resolved, I just had to click on check box in portal to show migration events. thanks for help
