To further enhance the functionality and context within Supahub, you can now include company data when identifying your users. By sending company data like company name, monthly spend, pricing plan, logo etc we will track your companies, making this information accessible throughout Supahub.
Here’s an example on how to add company data to an identify call:
<script id="supahub" type="text/javascript">!(function(s, u, p, a){functionsupahub(){var g = u.createElement(p), h = u.getElementsByTagName(p)[0];(g.id= a),(g.src="https://widget.supahub.com/sdk.js"), h.parentNode.insertBefore(g, h); g.onload=function(){window.SupahubWidget("identify",{// WorkspaceworkspaceName:"workspace-name",// Required: Copy your workspace name from 'workspace-name.supahub.com'// User Dataid:"786",// Required: Unique id that you are using to identify your username:"Username",// Requiredemail:"[email protected]",// Requiredavatar:"https://example.com/images/user-profile.jpg",// OptionalcustomFields:{title:"Product Manager",location:"Paris",},// Optional: Add any type of field, in the format ({key1: "value1", key2: "value2"})// Company Datacompanies:[{id:"786",// Requiredname:"Acme Inc.",// Requiredlogo:"https://example.com/images/company-logo.jpg",// OptionalmonthlySpend:300,// Optional, but recommendedcreatedAt:"2023-05-19T15:35:49.915Z",// Optional},],});};}"function"!=typeof s.SupahubWidget&&(s.SupahubWidget=function(){(s.SupahubWidget.q= s.SupahubWidget.q||[]).push(arguments);}),"complete"=== u.readyState||"interactive"=== u.readyState?supahub(): s.addEventListener("DOMContentLoaded", supahub);})(window,document,"script","supahub-sdk");</script>
For improved sorting capabilities, we strongly recommend including the
monthlySpend for each company.
This helps you to prioritize and identify the most requested posts by your paying users, ensuring that you address their needs effectively.
In situations where users manage multiple companies, add each company to the companies array in the identify call.
You can enhance the information associated with your companies by adding custom fields, such as their chosen pricing plan, employees, industry, and more.
To add custom data for a company to an identify call, follow this example:
<script id="supahub" type="text/javascript">!(function(s, u, p, a){functionsupahub(){var g = u.createElement(p), h = u.getElementsByTagName(p)[0];(g.id= a),(g.src="https://widget.supahub.com/sdk.js"), h.parentNode.insertBefore(g, h); g.onload=function(){window.SupahubWidget("identify",{// WorkspaceworkspaceName:"workspace-name",// Required: Copy your workspace name from 'workspace-name.supahub.com'// User Dataid:"786",// Required: Unique id that you are using to identify your username:"Username",// Requiredemail:"[email protected]",// Requiredavatar:"https://example.com/images/user-profile.jpg",// OptionalcustomFields:{title:"Product Manager",location:"Paris",},// Optional: Add any type of field, in the format ({key1: "value1", key2: "value2"})// Company Datacompanies:[{id:"786",// Requiredname:"Acme Inc.",// Requiredlogo:"https://example.com/images/company-logo.jpg",// OptionalmonthlySpend:300,// Optional, but recommendedcreatedAt:"2023-05-19T15:35:49.915Z",// OptionalcustomFields:{plan:"Premium",employees:100,industry:"technology",},// Optional: Add any type of field, in the format ({key1: "value1", key2: "value2"})},],});};}"function"!=typeof s.SupahubWidget&&(s.SupahubWidget=function(){(s.SupahubWidget.q= s.SupahubWidget.q||[]).push(arguments);}),"complete"=== u.readyState||"interactive"=== u.readyState?supahub(): s.addEventListener("DOMContentLoaded", supahub);})(window,document,"script","supahub-sdk");</script>
By incorporating custom fields, you can gain deeper insights and tailor your analysis in Supahub based on your specific requirements.