I’m curious of other people’s experience with the Microsoft Dynamics 365 CRM Zapier app and mainly around custom lookup fields on certain entities, I have found several issues with the app which looks like it’s not usable at all (as in will always be broken based on the payload data it sends). It doesn’t appear to confirm to the Dynamics 365 API requirements in some areas for fields like lookups.
Here’s an example payload Zapier is sending when testing a Contact and lead creation zap. The contact record is created just fine, and then the ID of the contact is passed to the lead step. I suspect the contact is created because it’s just standard fields and no lookups.
When getting to the lead entity, it gets more complicated with custom fields and lookups and I think where things start going bad.
Example payload values being sent by Zapier on a zap test.
campaignid: /campaigns(c5b08212-bfa8-ed11-aad1-6045bdd28837)
ccl1000_acknowledged: true
ccl1000_closeenquiry: true
ccl1000_enquiryautocompleted: true
ccl1000_enquiryclassification: 100000000
ccl1000_enquirytypeid: /ccl1000_enquirytypes(d79ac383-f455-e511-93f4-0050569e3c1b) ccl1000_originatingactivitytype: 940220002
ccl3016_enquirysubmittedby: 999200003
ccl3016_enquirytype: 999200002
leadsourcecode: 100000003
parentcontactid: 5023e4bd-3efc-e511-80df-c4346bac29f8
Problems:
- campaignid, ccl1000_enquirytypeid and parentcontactid do not have @odata.bind in the property name. This should be added at the end to work and is required for relational/lookup fields
- ccl1000_enquirytypeid is a custom field and I think where possibly Zapier will start to struggle. Technically you can determine custom fields via EntityDefintions, but this is a custom lookup to a custom entity. It does however appear to know this given the value uses the plural entity name (ccl1000_enquirytypes), so there’s at least some handling.
- The contact value for parentcontactid needs to be /contacts(5023e4bd-3efc-e511-80df-c4346bac29f8) (I could technically, implement a formatter to adjust this value, but I cannot modify the property names being used highlighted above.
Taking the original payload data, converting to JSON and sending directly through the Dynamics 365 Web API allows this data to work (assuming the campaign and contact ID are valid).
{
"campaignid@odata.bind": "/campaigns(c5b08212-bfa8-ed11-aad1-6045bdd28837)",
"ccl1000_acknowledged": true,
"ccl1000_closeenquiry": true,
"ccl1000_enquiryautocompleted": true,
"ccl1000_enquiryclassification": 100000000,
"ccl1000_enquirytypeid@odata.bind": "/ccl1000_enquirytypes(d79ac383-f455-e511-93f4-0050569e3c1b)",
"ccl1000_originatingactivitytype": 940220002,
"ccl3016_enquirysubmittedby": 999200003,
"ccl3016_enquirytype": 999200002,
"leadsourcecode": 100000003,
"parentcontactid@odata.bind": "/contacts(5023e4bd-3efc-e511-80df-c4346bac29f8)"
}
However in it’s current state it appears the Zapier app is quite broken and won’t work for custom fields or more advanced uses.
Given you don’t seem to be able to modify the payload data with the app, has anyone had success with custom POST requests using the Dynamics 365 API. I know how to use the API without Zapier, the issue is having a client that is authenticated with OAuth, the Microsoft Dynamics 365 CRM app takes care of all of that and ideally it would be great to be able to use it, just currently it doesn’t appear to handle lookups well.
For reference I have also sent these findings through a support ticket, I’m more curious on any other users who happen to use the Microsoft Dynamics 365 CRM app with Zapier and if there’s any customisations or workarounds I’m not aware of?
Thanks,
James