Hi Zappers,
I’m trying to get employee data out of our HR system and/or Directory Service to import it into Freshservice to update requesters.
I know the API query (below) to make to update a requester in Freshservice, but note Freshservice needs you to input the ID of the requester you need to update at the end of the URL, the below example 888.
curl -v -u api_key:X -H 'Content-Type: application/json' -X PUT -d '{ "first_name":"Ronald", "last_name":"Weasley","time_format":"24h" }' 'https://domain.freshservice.com/api/v2/requesters/888'
I don’t know how to firstly look up the requester in Freshservice, then do an API query based on that, can anyone help with ideas please? I have toyed with Line Items and Looping by Zapier, and think i’m on the right lines but can’t quite crack it.
I think the rough order of what I need is:
- Export all employees from the HR system into Zapier to CSV
- Connect Zapier to Google Drive to grab CSV
- Parse the CSV in Zapier to extract each employee’s e-mail address and Name, which hopefully can be used to look up the requester in Freshservice
- Look up the requester ID in Freshservice
- Look up the Line Manager’s requester ID in Freshservice
- Craft an API command per employee to update their Freshservice requester record
I’d be grateful for any help.