# Questions Regarding API Functionality for Custom Objects in HubSpot

**URL:** <https://community.hubspot.com/t/questions-regarding-api-functionality-for-custom-objects-in-hubspot/121066>\
**Category:** APIs & Integrations\
**Tags:** professional\
**Created:** [November 21, 2024, 10:53am UTC](https://community.hubspot.com/t/questions-regarding-api-functionality-for-custom-objects-in-hubspot/121066 "2024-11-21T10:53:21Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![DSushko](https://avatars.discourse-cdn.com/v4/letter/d/46a35a/32.png) [@DSushko](https://community.hubspot.com/u/DSushko)\
**Post date:** [November 21, 2024, 10:53am UTC](https://community.hubspot.com/t/questions-regarding-api-functionality-for-custom-objects-in-hubspot/121066/1 "2024-11-21T10:53:21Z")

</div>

Hello everyone,

I am reaching out with some questions regarding the API functionality for custom objects in HubSpot. Specifically, I have created a custom object called “appointments” and am now attempting to write a Python program utilizing the HubSpot API client to create meetings in batch for this custom object. However, I have encountered the following issues:  
1.) AssociationTypeId for Custom Objects and Meetings  
I am unable to find the associationTypeId for linking the custom object to meetings. This information does not seem to be available in the API documentation or within my account.  
In the settings, I can set associations with limited CRM objects, such as contacts, tickets, or other custom objects. However, this does not seem to extend to meetings, which is required for batch creation.  
2.) Unexpected Results for AssociationTypeId  
When attempting to retrieve the associationTypeId via a read HTTP request, the response I received was as follows:  
“meetings”: {  
“paging”: null,  
“results”: [  
{“id”: “XXXXXXXXXXX”, “type”: “appointments\_to\_meeting\_event”}  
]  
}  
The associationTypeId/type appears as a string in the response, whereas I was expecting a numeric value. Could you clarify this discrepancy?  
3.) Assigning Multiple Users as Attendees  
When creating a meeting using the HubSpot Meeting tool, it is possible to assign multiple users (not contacts) as attendees. However, I could not find any reference to this functionality in the API documentation. Could you provide guidance on which properties to use to achieve this and where to find the corresponding IDs for the users I wish to assign as attendees?  
Thanks!

---

<div class="post-metadata">

**Author:** ![Josh](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/josh/32/17115_2.png) [@Josh](https://community.hubspot.com/u/Josh)\
**Post date:** [November 21, 2024, 1:41pm UTC](https://community.hubspot.com/t/questions-regarding-api-functionality-for-custom-objects-in-hubspot/121066/2 "2024-11-21T13:41:50Z")

</div>

Hi @DSushko,

I think you’ll want to use the Engagements API to associate your meetings to the custom object. Here’s an example:

```lia-code-sample
{
 "engagement": {
 "type": "MEETING"
 },
 "associations": {
 "contactIds": [],
 "companyIds": [],
 "dealIds": [],
 "ownerIds": [],
 "customObjectIds": {
 "appointments": ["YOUR_CUSTOM_OBJECT_RECORD_ID"]
 }
 },
 "metadata": {
 "title": "Meeting Title",
 "startTime": 1622548800000,
 "endTime": 1622552400000,
 "body": "Meeting Description"
 }
}

```

The API will return a string-based identifier vs numeric. Try this:

```lia-code-sample
{
 "from": { "id": "YOUR_CUSTOM_OBJECT_RECORD_ID" },
 "to": { "id": "MEETING_ID" },
 "type": "appointments_to_meeting_event"
}

```

Lastly, you should be able to assign internal attendees using “hs\_meeting\_internal\_attendees” and separating each user ID for the internal attendee with a semicolon.

Hope this puts you on the right track!

Josh

---

<div class="post-metadata">

**Author:** ![SteveHTM](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/stevehtm/32/22074_2.png) [@SteveHTM](https://community.hubspot.com/u/SteveHTM)\
**Post date:** [November 21, 2024, 7:18pm UTC](https://community.hubspot.com/t/questions-regarding-api-functionality-for-custom-objects-in-hubspot/121066/3 "2024-11-21T19:18:24Z")

</div>

@DSushko - This is a confusing part of teh associations documentation, but the API call you want to use to dynamically discover all possible association values between two object types is:

[https://api.hubapi.com/crm/v4/associations/{fromObjectType}/{toObjectType}/labels](https://api.hubapi.com/crm/v4/associations/%7BfromObjectType%7D/%7BtoObjectType%7D/labels)

custom objects, with their own freshly minted type, will not be in teh documentation list!

Have fun!

Steve

---

<div class="post-metadata">

**Author:** ![DSushko](https://avatars.discourse-cdn.com/v4/letter/d/46a35a/32.png) [@DSushko](https://community.hubspot.com/u/DSushko)\
**Post date:** [November 27, 2024, 9:27am UTC](https://community.hubspot.com/t/questions-regarding-api-functionality-for-custom-objects-in-hubspot/121066/4 "2024-11-27T09:27:51Z")

</div>

Thanks for the quick response! I see, with this command I actually got a typeID which is a needed associationTypeId, right? Any chance that you know how assigning multiple users as attendees via API works? Thanks a lot in advance!
