APIs & Integrations

nuwang
Member

Passing custom properties via CRM card

SOLVE

Hi All,

I have developed an app that has a CRM card and I want to pass a custom property that is created in app users account under Contact records. I defined the custom property under "PROPERTIES SENT FROM HUBSPOT" in CRM card definition but the its not being pass as a request parameter. 

Is this possible to do ? Or is there any workroud to get this done ?  

0 Upvotes
2 Accepted solutions
Jaycee_Lewis
Solution
Community Manager
Community Manager

Passing custom properties via CRM card

SOLVE

Hi, @nuwang 👋 Thanks for reaching out! Let's see if we can get the conversation going. Hey, @hilton22 @himanshurauthan @AppDev, can you lend a hand here? Or share some additional troubleshooting tips you like to use in similar situations. 

 

Thank you! — Jaycee

linkedin

Jaycee Lewis

Developer Community Manager

Community | HubSpot

View solution in original post

0 Upvotes
coldrickjack
Solution
Top Contributor

Passing custom properties via CRM card

SOLVE

Hi @nuwang,

 

That is true, I am using standard/default properties. However I can also include custom properties. See below for my card configuration, you will notice I'm also sending "favorite_film".

 

Screenshot 2022-09-03 at 11.12.44.png

 

In the portal where I have installed my app I also have the custom property defined. In this case a single line text field with an internal name "favorite_film":

 

Screenshot 2022-09-03 at 11.13.55.png

When I load my CRM record the following data is sent to my FETCH URL, notice the presence of the custom property in the query string:

 

Screenshot 2022-09-03 at 11.15.01.png

So it's certainly possible. If you aren't seeing this then perhaps the custom property is not defined in the portal in which your application is installed?

View solution in original post

0 Upvotes
7 Replies 7
coldrickjack
Top Contributor

Passing custom properties via CRM card

SOLVE

Hey @nuwang,

 

Yes, that should absolutely be possible to achieve. If it's not working then there could be something wrong with your configuration. By default it will pass:

 

  • associatedObjectID = The ID of the Object being loaded in the CRM
  • associatedObjectType = The type of Object being loaded in the CRM
  • portalID = the ID of the portal
  • userEmail = The user accessing the record
  • userID = The user id accessing the record

But you can also specify additional properties as you mentioned. For instance I've setup a CRM Card which makes a request to the following URL:

 

https://webhook.site/2bc84ba9-73b0-4500-bc18-76293942efe5?associatedObjectId=19751&associatedObjectT...


See screenshot of the CRM Card settings:

 

Screenshot 2022-09-01 at 19.06.52.png

 

Also, if it helps I put this article together to compliment the API docs. 

 

Let me know how you get on.

Jack

DTeam8
Member

Passing custom properties via CRM card

SOLVE

Hi @coldrickjack , 
I am trying to fetch Portal ID at CRM card using API, but it shows Undefined at CRM card.

 

I already raise ticket for this issue but still waiting for proper solution from support team, here is ticket reference link for detail - https://community.hubspot.com/t5/APIs-Integrations/API-for-CRM-Card-to-get-Portal-ID/m-p/890345#M695...

 

Here is request URL that I can get from CRM Extension logs - https://39664539.hs-sites.com/_hcms/api/vend-quote-v3?userId=52126082&userEmail=development@webcanop...

In request URL I can see the correct Portal ID but can't display it on the CRM card. Other properties works fine only problem is fetching Portal ID.

 

Please check the above berief and help as soon as possile.
thanks

0 Upvotes
nuwang
Member

Passing custom properties via CRM card

SOLVE

Hey Jack, Thank you for the reply. 

In your example you are passing the original hubspot properties like firstname, lastname etc in a contact record. In my case, I want to pass a custom property that I have defined in contact. 

The custom property is defined under test account that developer account has no idea. But developer account key in the exact property name under "PROPERTIES SENT FROM HUBSPOT" in CRM card definition. The problem is that custom property is not passed through the query parameters. 

0 Upvotes
coldrickjack
Solution
Top Contributor

Passing custom properties via CRM card

SOLVE

Hi @nuwang,

 

That is true, I am using standard/default properties. However I can also include custom properties. See below for my card configuration, you will notice I'm also sending "favorite_film".

 

Screenshot 2022-09-03 at 11.12.44.png

 

In the portal where I have installed my app I also have the custom property defined. In this case a single line text field with an internal name "favorite_film":

 

Screenshot 2022-09-03 at 11.13.55.png

When I load my CRM record the following data is sent to my FETCH URL, notice the presence of the custom property in the query string:

 

Screenshot 2022-09-03 at 11.15.01.png

So it's certainly possible. If you aren't seeing this then perhaps the custom property is not defined in the portal in which your application is installed?

0 Upvotes
nuwang
Member

Passing custom properties via CRM card

SOLVE

Thank you @jackcoldrick 

Yes It worked at my end too. I was able to pass custom properties with data fetch url. It needs follow correct naming convension to refer the property in the CRM card defenition which I have not done correctly. For example if the label of the property is "Test Property", it should refer as "test_property" in CRM card definision. 

0 Upvotes
Jaycee_Lewis
Solution
Community Manager
Community Manager

Passing custom properties via CRM card

SOLVE

Hi, @nuwang 👋 Thanks for reaching out! Let's see if we can get the conversation going. Hey, @hilton22 @himanshurauthan @AppDev, can you lend a hand here? Or share some additional troubleshooting tips you like to use in similar situations. 

 

Thank you! — Jaycee

linkedin

Jaycee Lewis

Developer Community Manager

Community | HubSpot

0 Upvotes
nuwang
Member

Passing custom properties via CRM card

SOLVE

Hi Jaycee, Thank you for the reply. I am still looking for an answer to my question. 

 

0 Upvotes