# Get All Notes for a ticket

**URL:** <https://community.hubspot.com/t/get-all-notes-for-a-ticket/53140>\
**Category:** APIs & Integrations\
**Created:** [March 14, 2022, 7:59pm UTC](https://community.hubspot.com/t/get-all-notes-for-a-ticket/53140 "2022-03-14T19:59:17Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![vplatform](https://avatars.discourse-cdn.com/v4/letter/v/65b543/32.png) [@vplatform](https://community.hubspot.com/u/vplatform)\
**Post date:** [March 14, 2022, 7:59pm UTC](https://community.hubspot.com/t/get-all-notes-for-a-ticket/53140/1 "2022-03-14T19:59:17Z")

</div>

Hey all,

I am currently trying to get a list of all the notes, along with their hs\_\_note\_body, or the body\_preview (to pull the note message into our internal systems). I’ve been been looking over/sending requests to the Ticket/Notes/Engagements API’s. So far I’ve only been able to do this by:  
1) hitting [https://api.hubapi.com/crm/v3/objects/tickets/{{ticketId}](https://api.hubapi.com/crm/v3/objects/tickets/%7B%7BticketId%7D)}?hapikey={{KEY\_HERE}}&associations=engagments

to pull ticket Details and its associations to notes, example response below:

```lia-code-sample
{
 "id": "...",
 "properties": {
....
 },
 "associations": {
 "engagements": {
 "results": [
 {
 "id": "engagementId1",
 "type": "ticket_to_engagement"
 },
 {
 "id": "engagementId2",
 "type": "ticket_to_engagement"
 },
 {
 "id": "engagementId3",
 "type": "ticket_to_engagement"
 },
 {
 "id": "engagementId4",
 "type": "ticket_to_engagement"
 }
 ]
 }
 }
}

```

then using the engagementIds from the above response to hit:

2)[https://api.hubapi.com/engagements/v1/engagements/{{EngagmeentID}}?hapikey={{KEY\_HERE}}](https://api.hubapi.com/engagements/v1/engagements/%7B%7BEngagmeentID%7D%7D?hapikey=%7B%7BKEY_HERE%7D%7D) to pull data for that 1 note (based on its engagementID) to get its bodyPreview. Example Below:

```lia-code-sample
{
 "engagement": {
......
 "source": "CRM_UI",
 "allAccessibleTeamIds": [],
 "bodyPreview": "hi",
 "queueMembershipIds": [],
 "bodyPreviewIsTruncated": false,
 "bodyPreviewHtml": "<html>\n <head></head>\n <body>\n <p>hi</p>\n </body>\n</html>"
 },
 "associations": {
 "contactIds": [],
 "companyIds": [],
 "dealIds": [],
 "ownerIds": [],
 "workflowIds": [],
 "ticketIds": [
 1234
 ],
 "contentIds": [],
 "quoteIds": []
 },
 "attachments": [],
 "metadata": {
 "body": "<p>hi</p>"
 }
}

```

I would have to do this call several times, for every unique ticketId I wanted to gather Note body information from.  
I haven’t seen a batch “get all notes and their details, given a ticketId” endpoint - there’s got to be a better way to do the above? this is the closest thing that I’ve seen in the forums, but it doesn’t appear to be what we’re looking for  
[https://community.hubspot.com/t5/APIs-Integrations/Getting-Latest-Notes-In-Tickets/m-p/571049#M50703](https://community.hubspot.com/t5/APIs-Integrations/Getting-Latest-Notes-In-Tickets/m-p/571049#M50703)

---

<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:** [March 15, 2022, 8:08am UTC](https://community.hubspot.com/t/get-all-notes-for-a-ticket/53140/2 "2022-03-15T08:08:18Z")

</div>

hi vplatform

You can directly get the notes using notes engaments API i.e. **GET`/crm/v3/objects/notes`**

refer to = [https://developers.hubspot.com/docs/api/crm/notes](https://developers.hubspot.com/docs/api/crm/notes), it already have the params hs\_\_note\_body which you want , you dont have to calll a seperate API to achieve this

Hope this helps! If we were able to answer your query, kindly help the community by marking it as a solution. Thanks and Regards.

**``**

---

<div class="post-metadata">

**Author:** ![vplatform](https://avatars.discourse-cdn.com/v4/letter/v/65b543/32.png) [@vplatform](https://community.hubspot.com/u/vplatform)\
**Post date:** [March 15, 2022, 1:28pm UTC](https://community.hubspot.com/t/get-all-notes-for-a-ticket/53140/3 "2022-03-15T13:28:57Z")

</div>

[@ChehakWadhdwa](https://community.hubspot.com/t5/user/viewprofilepage/user-id/345416)  
I don’t want to get a random list of all the notes possible (say we have 1,000 tickets created in our dashboard, then your above solution to just hit GET/crm/v3/objects/notes would retrieve a paginated dump of all notes that exist, regardless of a specific ticketId). I want to specifiy a **ticketId** in the request above, and **get a list of all notes for that ticketId**

---

<div class="post-metadata">

**Author:** ![jaysonb](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/jaysonb/32/50655_2.png) [@jaysonb](https://community.hubspot.com/u/jaysonb)\
**Post date:** [June 10, 2022, 6:12pm UTC](https://community.hubspot.com/t/get-all-notes-for-a-ticket/53140/4 "2022-06-10T18:12:52Z")

</div>

No response either? Everyone just points to the API docs. Trying to do this with contacts/deals. I want to get all notes associated with a contact\_id.

---

<div class="post-metadata">

**Author:** ![laurabren](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/laurabren/32/10217_2.png) [@laurabren](https://community.hubspot.com/u/laurabren)\
**Post date:** [May 17, 2023, 4:40pm UTC](https://community.hubspot.com/t/get-all-notes-for-a-ticket/53140/5 "2023-05-17T16:40:28Z")

</div>

@jaysonb just curious, did the solution @aaylsworth outlined work for your use case?

---

<div class="post-metadata">

**Author:** ![Mahfuz1](https://avatars.discourse-cdn.com/v4/letter/m/d6d6ee/32.png) [@Mahfuz1](https://community.hubspot.com/u/Mahfuz1)\
**Post date:** [September 19, 2023, 6:40pm UTC](https://community.hubspot.com/t/get-all-notes-for-a-ticket/53140/6 "2023-09-19T18:40:58Z")

</div>

@laurabren no.

---

<div class="post-metadata">

**Author:** ![aaylsworth](https://avatars.discourse-cdn.com/v4/letter/a/3ab097/32.png) [@aaylsworth](https://community.hubspot.com/u/aaylsworth)\
**Post date:** [August 8, 2022, 5:44pm UTC](https://community.hubspot.com/t/get-all-notes-for-a-ticket/53140/7 "2022-08-08T17:44:18Z")

</div>

I recently used the **/crm/v3/objects/notes/search** endpoint to get a lost of notes associated with a certain custom objectId. Should be able to modify it for your use case.

```lia-code-sample
// /crm/v3/objects/notes/search
{
 "filterGroups": [
 {
 "filters": [
 {
 "propertyName": "hs_attachment_ids",
 "operator": "EQ",
 "value": "<<ticketId>>"
 }
 ]
 }
 ],
 "properties": [
 "hs_note_body"
 ]
}

```

---

<div class="post-metadata">

**Author:** ![Mahfuz1](https://avatars.discourse-cdn.com/v4/letter/m/d6d6ee/32.png) [@Mahfuz1](https://community.hubspot.com/u/Mahfuz1)\
**Post date:** [September 19, 2023, 6:38pm UTC](https://community.hubspot.com/t/get-all-notes-for-a-ticket/53140/8 "2023-09-19T18:38:20Z")

</div>

@aaylsworth what will be the propertyName?

returning

{

```
"total": 0,

"results": \[]

```

}

even the data is there

---

<div class="post-metadata">

**Author:** ![psymon25](https://avatars.discourse-cdn.com/v4/letter/p/8edcca/32.png) [@psymon25](https://community.hubspot.com/u/psymon25)\
**Post date:** [September 20, 2023, 4:53pm UTC](https://community.hubspot.com/t/get-all-notes-for-a-ticket/53140/9 "2023-09-20T16:53:04Z")

</div>

Try this works my end

```lia-code-sample
//https://api.hubapi.com/crm/v3/objects/notes/search

{
 "filterGroups": [
 {
 "filters": [
 {
 "propertyName": "associations.ticket",
 "operator": "EQ",
 "value":"YOUR TICKET ID"
 }
 ]
 }
 ],
 "properties": ["hs_note_body"]
}

```

---

<div class="post-metadata">

**Author:** ![Mahfuz1](https://avatars.discourse-cdn.com/v4/letter/m/d6d6ee/32.png) [@Mahfuz1](https://community.hubspot.com/u/Mahfuz1)\
**Post date:** [September 20, 2023, 5:48pm UTC](https://community.hubspot.com/t/get-all-notes-for-a-ticket/53140/10 "2023-09-20T17:48:56Z")

</div>

Thanks @psymon25 . It worked

---

<div class="post-metadata">

**Author:** ![VGlobal](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/vglobal/32/203737_2.png) [@VGlobal](https://community.hubspot.com/u/VGlobal)\
**Post date:** [September 18, 2024, 4:53am UTC](https://community.hubspot.com/t/get-all-notes-for-a-ticket/53140/11 "2024-09-18T04:53:56Z")

</div>

This worked!!!
