3

I have a Google Event with a list of invitees. I have a python code which syncs this event with Salesforce by creating a Event sObject. I queried for the emails in the invitees list of my Google event to check whether such a contact exists.

Now I want to add Invitees through my python code to the Event sObject created in sync with Google Event.Is it possible to add Invitees(who are Contacts) to Event sObject programmatically?

Thanks

3

Explore Event Relationship object of salesforce .

https://developer.salesforce.com/docs/atlas.en-us.api.meta/api/sforce_api_objects_eventattendee.htm

You can create an Event relationship in salesforce and attach the contact Id if it exists in sfdc

EventRelation er = new EventRelation(EventId = '00UD0000005zijH', 
RelationId = '003D000000Q8aeV', isParent = true, isInvitee = false);
insert er;

RelationId is a contact, lead, user, or calendar

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.