# Create Note And Associated To Contact

**URL:** <https://community.hubspot.com/t/create-note-and-associated-to-contact/75228>\
**Category:** APIs & Integrations\
**Tags:** contacts\
**Created:** [February 15, 2023, 3:24am UTC](https://community.hubspot.com/t/create-note-and-associated-to-contact/75228 "2023-02-15T03:24:12Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![LOsorio25](https://avatars.discourse-cdn.com/v4/letter/l/e36b37/32.png) [@LOsorio25](https://community.hubspot.com/u/LOsorio25)\
**Post date:** [February 15, 2023, 3:24am UTC](https://community.hubspot.com/t/create-note-and-associated-to-contact/75228/1 "2023-02-15T03:24:12Z")

</div>

curl --location --request POST ‘[https://api.hubspot.com/crm/v3/objects/notes](https://api.hubspot.com/crm/v3/objects/notes)’ \

--header ‘Authorization: Bearer COHmlpjlMBIT\_geTU8Bi-\_IcAED89x8A4MewARjrq7cLIMmc1RcopvZWMhSz3L0aUHzYsFszfd7\_A-HOoI5oSDo7AHVtx\_8HAAD8\_\_f\_4P\_8zjyGAABg\_iY0PQwg-Jz\_D\_7D\_\_85AAD4hef\_\_\_\_w\_\_MLAACA\_\_8DAMPlAQJCFAedJXWSPzz65htKoI6WpII3qVyDSgNuYTFSAFoA’ \

--header ‘Content-Type: application/json’ \

--header ‘Cookie: \_\_cf\_bm=NaE\_vS7mKBdsTMkdrUESMfDrEGhE0xG4nE\_Qn6spr4c-1676429160-0-ATu+12jIPyF/xG2HnomtAXIc633jntjuFQDyUAdnkYA+3y78WcrJykuRihpNwyuoKOmDeb6y97l/Si3hRdqgwW8=; \_\_cfruid=b53e01ceed7b98532d9a5dde0ce7a6b465931c25-1676429749’ \

--data-raw '{

“properties”: {

“hs\_timestamp”: “2023-02-14T16:41:59.155Z”,

“hs\_note\_body”: “Spoke with decision maker Carla. Attached the proposal and draft of contract.”,

“hubspot\_owner\_id”: 326581017

},

“associations”: [

{

“to”: {

“id”: 51

},

“types”: [

{

“associationCategory”: “HUBSPOT\_DEFINED”,

“associationTypeId”: 20132323223

} ]

}

]

}’

but I am getting the following error and I dont know how to fixed

{

“status”: “error”,

“message”: “Invalid input JSON on line 15, column 43: Numeric value (20132323223) out of range of int (-2147483648 - 2147483647)”,

“correlationId”: “23185474-6577-420f-8b74-6426470836fc”

the associationTypeId

---

<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:** [February 15, 2023, 4:36pm UTC](https://community.hubspot.com/t/create-note-and-associated-to-contact/75228/2 "2023-02-15T16:36:26Z")

</div>

Hi, @LOsorio25 👋 It looks like you have an incorrect association typeId. It should be a much shorter value — 202, for example. [Retrieve association types](https://developers.hubspot.com/docs/api/crm/associations#:~:text=Retrieve%20association%20types).

The HubSpot defined **Note \> Contact** typeId is 202. You can use this endpoint to find the type Ids for any Object \> Object.

`GET /crm/v4/associations/{fromObjectType}/{toObjectType}/labels`

Example from Postman:

Request

`GET {{API URL}}/crm/v4/associations/notes/contacts/labels`

Response

```lia-code-sample
{
 "results": [
 {
 "category": "HUBSPOT_DEFINED",
 "typeId": 202,
 "label": null
 }
 ]
}

```

 ![CleanShot 2023-02-15 at 09.35.39.png](https://d2qpr2jzcazej7.cloudfront.net/original/3X/5/f/5f9e7d3f31bf1f43f589b5716d1d592d2b0206d9.png)

Have fun building! — Jaycee

---

<div class="post-metadata">

**Author:** ![LOsorio25](https://avatars.discourse-cdn.com/v4/letter/l/e36b37/32.png) [@LOsorio25](https://community.hubspot.com/u/LOsorio25)\
**Post date:** [February 15, 2023, 5:25pm UTC](https://community.hubspot.com/t/create-note-and-associated-to-contact/75228/3 "2023-02-15T17:25:17Z")

</div>

Thank you, but this number 202 can be hardcode it ? Is this the same number  
over all accounts on hubspot ?
