Can you update a contact with only the email address as a reference?

I’m wanting to automate updating contact details from an external system.

The documentation says I need to reference the contact by its ID; can I not do so using its email as that is unique? A previous implementation I did with HappyFox allowed either.

I would rather not have the extra overhead of searching for a contact.

Hi @Stuart_Anderton,

While I understand the reason behind the request, this is not possible in Freshdesk at the moment since we only use the contact id(integer value) as the unique identifier for an existing contact a Freshdesk Account.

So the workflow to be followed will be to search for the contact with the email address -

  1. Search for User by Email
curl --location --request GET '' \ --header 'Authorization: Basic <Base64(API_KEY:X)>'
  1. Then update the contact using the contact id.

P.S - If you are using a JS Framework, you can consume our JS SDK which has built in functions to do this for you. For more information please view the documentation in the link here.

Sample Code -

var freshdesk = require("@freshworks/freshdesk");
let fd = new freshdesk({ domain: '', api_key: 'xxxxxxxxx'});
fd.contacts.getAllContacts('').then(function (result) {
}).catch(function (err) {

Hope this helps.

Let me know if you need any more help.

1 Like