Creating a note and adding it to contact

Following the

API, I’m trying to create a note and attach it to a contact.

This seems to return a proper response but no note is created for the user.
I should be able to see it here

But I don’t (The note you see was manually added using the GUI).
Following the docs I can’t seem to find what I’m doing wrong.
I’m passing the contact ID I want the note to be added to.
I get a response that a note was created, but I never see it.
I honestly can’t see what I’m doing wrong.
If you have any idea, let me know.

Hi @VictorCooper :waving_hand:

As per the documentation, you’ll need to specify the association type within the request body. For example:

{
 "properties": {
 "hs_note_body": "This is a test note",
 "hs_timestamp": "2019-10-30T03:30:17.883Z"
 },
 "associations": [
 {
 "to": {
 "id": "51"
 },
 "types": [
 {
 "associationCategory": "HUBSPOT_DEFINED",
 "associationTypeId": 202
 }
 ]
 }
 ]
}

Where 51 is the Contact ID to be associated to the new Note and 202 is the association type ID for the association type “note_to_contact”. You can retrieve all association types by making a GET request to:

I hope this proves useful. Please let me know if you have any follow-up questions.

hello zach_threadint I have the same problem. API retrieves created but note that not present

Same problem even added types

Hey, @RTatusko @Wenson can you share a simple example using Postman? I just tested the example from @zach_threadint and it worked flawlessly.

I used Postman

I have a Contact called Linda Belcher who had no associated Notes

I took the request body example from Zach and changed the value for `id` to match Linda

Request and body

POST https://api.hubapi.com/crm/v3/objects/notes

{
 "properties": {
 "hs_note_body": "This is a test note",
 "hs_timestamp": "2019-10-30T03:30:17.883Z"
 },
 "associations": [
 {
 "to": {
 "id": "851"
 },
 "types": [
 {
 "associationCategory": "HUBSPOT_DEFINED",
 "associationTypeId": 202
 }
 ]
 }
 ]
}

Response

{
 "id": "63457555073",
 "properties": {
 "hs_body_preview": "This is a test note",
 "hs_body_preview_html": "<html>\n <head></head>\n <body>\n This is a test note\n </body>\n</html>",
 "hs_body_preview_is_truncated": "false",
 "hs_createdate": "2024-10-29T22:18:36.261Z",
 "hs_lastmodifieddate": "2024-10-29T22:18:36.261Z",
 "hs_note_body": "This is a test note",
 "hs_object_id": "63457555073",
 "hs_object_source": "INTEGRATION",
 "hs_object_source_id": "959085",
 "hs_object_source_label": "INTEGRATION",
 "hs_timestamp": "2019-10-30T03:30:17.883Z"
 },
 "createdAt": "2024-10-29T22:18:36.261Z",
 "updatedAt": "2024-10-29T22:18:36.261Z",
 "archived": false
}

Screenshot of record in-app

Talk soon! — Jaycee

Facing same issue, Created via API but not visible on UI

Hey @aryang23-airmdr - thanks for following up here!
Sorry to hear that you’re having this issue. I’d like to re-tag @zach_threadint to see if he has any follow up context for us.
In the meantime, can you confirm that you specified the association type within the request body? I want to make sure we provide Zach with all of the details of this issue to help troubleshoot this more quickly for you.
Shane, Senior Community Moderator