Skip to main content

I am attempting to set up a Webhook Freshdesk automation to PUT ticket data into my CRM. I need the company_ID in the data but cannot get anything to come through with the other fields.

I have tried all of the following:

  • {{ticket.contact.company_id}}
  • {{ticket.contact.companyid}}
  • {{ticket.company.id}}}
  • {ticket.company_id}}
  • {{company_id}}
  • {{ticket.contact.department_id}}

None of these returns any value at all. What is the correct tag for pushing the ID of the company?

In Freshdesk, the company ID isn’t exposed directly as a liquid placeholder in automation webhooks. That’s why none of those variables work. The best workaround is to use {{ticket.company.name}} (which is supported) and then have your CRM look up the ID based on that name.If you really need the numeric ID, you’d have to use the Freshdesk API to fetch the ticket details (GET /api/v2/tickets/{{ticket.id}}) — that response includes "company_id". Unfortunately, automations alone can’t pass it directly in webhook payloads.


Having trouble pulling company information via those ticket variables! Anyone else face this? I found that sometimes relying on a custom field on the ticket directly, populated by a workflow based on the requester's email domain, works. Messy, but effective for my use case. Anyone else have better luck with any of those out of the box? Feels random, a bit like Basket Random .


 

It sounds like you’re very close — Freshdesk’s placeholder structure can be tricky, especially for nested fields like company data. In most cases, the correct variable should be {{ticket.company.id}}, but this only works if the company field is actually populated in the ticket context. You might want to confirm that the ticket has a linked company record and that the automation event has access to that object. If not, a pre-processing step (like an API call to fetch company info before the webhook) could solve the issue.

hope it will sole the issue. By, the way im enjoying coffee.