# Cannot create Note with null OwnerId via Engagements API

**URL:** <https://community.hubspot.com/t/cannot-create-note-with-null-ownerid-via-engagements-api/61268>\
**Category:** APIs & Integrations\
**Tags:** php, sdk\
**Created:** [July 19, 2022, 5:14pm UTC](https://community.hubspot.com/t/cannot-create-note-with-null-ownerid-via-engagements-api/61268 "2022-07-19T17:14:10Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![deandamasig](https://avatars.discourse-cdn.com/v4/letter/d/90db22/32.png) [@deandamasig](https://community.hubspot.com/u/deandamasig)\
**Post date:** [July 19, 2022, 5:14pm UTC](https://community.hubspot.com/t/cannot-create-note-with-null-ownerid-via-engagements-api/61268/1 "2022-07-19T17:14:10Z")

</div>

Greetings.

As mentioned in your [post regarding the Engagements API](https://developers.hubspot.com/changelog/upcoming-owner-ids-and-the-engagements-api), the Engagements API should still accept empty values for the **hs\_owner\_id** field. However, I’m getting the following error when trying to do so:  
SDK Code:

`$result = $client->engagements()->create($engagement, $associations, $metadata);`

Endpoint:

`https://api.hubapi.com/engagements/v1/engagements`

Payload

```auto
{
 "json": {
 "engagement": {
 "active": true,
 "type": "NOTE",
 "ownerId": null,
 "timestamp": 1658247956000
 },
 "associations": {
 "contactIds": [
 123
 ]
 },
 "metadata": {
 "body": "...."
 },
 "attachments": []
 }
}

```

Error Message:

```auto
{
 "validationResults": [
 {
 "isValid": false,
 "message": "0 was not a valid owner ID",
 "error": "INVALID_OWNER_ID"
 }
 ]
}

```

However, I do not encounter this issue when using different engagement types such as MEETING and CALL.

---

<div class="post-metadata">

**Author:** ![Jaycee\_Lewis](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/jaycee_lewis/32/61352_2.png) [@Jaycee\_Lewis](https://community.hubspot.com/u/Jaycee_Lewis)\
**Post date:** [July 19, 2022, 5:42pm UTC](https://community.hubspot.com/t/cannot-create-note-with-null-ownerid-via-engagements-api/61268/2 "2022-07-19T17:42:18Z")

</div>

Hey, @deandamasig 👋 Thanks for reaching out! I am going to try to reproduce the issue on my end. Once I reproduce, I’ll get it onto my internal resources.

Thank you! — Jaycee

---

<div class="post-metadata">

**Author:** ![deandamasig](https://avatars.discourse-cdn.com/v4/letter/d/90db22/32.png) [@deandamasig](https://community.hubspot.com/u/deandamasig)\
**Post date:** [July 20, 2022, 8:24pm UTC](https://community.hubspot.com/t/cannot-create-note-with-null-ownerid-via-engagements-api/61268/3 "2022-07-20T20:24:51Z")

</div>

Hi [@Jaycee\_Lewis](https://community.hubspot.com/t5/user/viewprofilepage/user-id/127074). Where you able to reproduce the issue?

---

<div class="post-metadata">

**Author:** ![Jaycee\_Lewis](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/jaycee_lewis/32/61352_2.png) [@Jaycee\_Lewis](https://community.hubspot.com/u/Jaycee_Lewis)\
**Post date:** [July 25, 2022, 10:30pm UTC](https://community.hubspot.com/t/cannot-create-note-with-null-ownerid-via-engagements-api/61268/4 "2022-07-25T22:30:46Z")

</div>

Hey, @deandamasig. I get the same validation error using

`"null"`

as well as omitting it completely. I have a request out to my internal resources to either get the correct formatting or to update the documentation.

I’ll follow up here as soon as I know more.

Thanks again! — Jaycee

---

<div class="post-metadata">

**Author:** ![Jaycee\_Lewis](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/jaycee_lewis/32/61352_2.png) [@Jaycee\_Lewis](https://community.hubspot.com/u/Jaycee_Lewis)\
**Post date:** [July 27, 2022, 8:04pm UTC](https://community.hubspot.com/t/cannot-create-note-with-null-ownerid-via-engagements-api/61268/5 "2022-07-27T20:04:34Z")

</div>

Hey, @deandamasig 👋 Quick follow-up. I had time to test again today and received a successful response. Here are my request body and the response:

- Request body

- Response — 200 OK

Intend of using “null” which the system interprets as “0” (zero) I just removed ownerId completely as a property in the body.

I hope this helps get you moving forward 🙌

Have fun coding! — Jaycee
