I’m developing an app for the MSP Freshservice account to display company information in New ticket and contact detail page but unable to see the required information about the company.
Below is the payload I’m receiving in Contact details page active: false address: null created_at: “Jul 24th 2019” custom_field: “cf_type_of_contact: N/A” deleted: false description: null email: “andrea@freshservice.com” external_id: null helpdesk_agent: false id: 14000244900 job_title: “Manager” language: “en” mobile: null name: “Andrea” phone: null time_zone: “Eastern Time (US & Canada)” updated_at: “Jul 24th 2019”
Could you share API’s that you used to fetch the payloads for Contact details page and New ticket page?
This is the API that is used for fetching the details of a single company:
Retrieve the Department (or Company in MSP Mode) with the given ID from Freshservice
Hi @Anand_Chandran
I’m using data API to retrieve contact info
client.data.get('contact').then(function(data) {
var req_data = data.contact;
callback(req_data);
}).catch(function() {
displayErr("Unexpected error occurred, please try after some time.", client);
});
There is no information about company details at least id also not present. In the initial conversation, there is a response payload for the contact page, please refer.
And in the New ticket page I’m using search API to get selected contact details, As mentioned in the previous conv there is department_ids but it’s returning an empty array even though a company is associated with that requester/contact.
So no where I’m getting info about company names/ids to make the API call that you mentioned.
Hi @soujanya,
Can you try using the department object in data API to fetch the company-related information?
Also, Search API returning empty results can be a bug if the relevant company presents in the portal and relevant filters are applied. We will report it to the Freshservice product team. We may not get an ETA for the bugs immediately.
Could you please share the sample request and results along with x-request-id that can help the team troubleshoot the API?