[SalesForce] Error Using Flows – Required Field Missing

I am attempting to create an automation that populates opportunity contact roles when contacts are selected by the user creating the opportunity.

Upon pushing the flow live, I am getting the following error:

An error occurred at element Create_Contact_Role_for_Ecommerce (FlowRecordCreate).
INSERT — INSERT FAILED — ERRORS : (REQUIRED_FIELD_MISSING) Required fields are missing: [OpportunityId, ContactId]

what do I need to add the Variable Fields so they are no longer missing?

enter image description here

enter image description here

Best Answer

You can create SObject variable like ContactObj and assign that value as default to the EcommerceContactId variable.

Flow variable assignment

And before creating Opportunity Contact Role you should make sure the values of Opportunity Id and Contact Id must be available