You need to sign in to do that
Don't have an account?
Tobias Letzner
Callout failed trying to call a flow with an external service IM from a process
Im trying to call a flow from a process to start an invocable method.
The process waits for a certain status on the case object to start the flow with a scheduled action:
I get a 'pending uncommitted changes' error everytime I try do call the flow.
My flow looks like this:
Any suggestions?
The process waits for a certain status on the case object to start the flow with a scheduled action:
I get a 'pending uncommitted changes' error everytime I try do call the flow.
My flow looks like this:
Any suggestions?
The issue occurs when you first perform DML and then callout in the same transaction. You need to perform Callout in the future method so your callout and DML will be in the different transaction.
Call future methods from process builder, call the future method from the in-vocable method.
Sample Code:
===========
Review below links for more information.
https://help.salesforce.com/articleView?id=000328873&type=1&mode=1
https://help.salesforce.com/articleView?id=000326129&type=1&mode=1
https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/apexcode/apex_callouts_wsdl2apex_testing_dml.htm
https://salesforce.stackexchange.com/questions/120012/problem-with-process-builder-invocable-method-and-webservice-call-out
Hope above information was helpful.
Please mark as Best Answer so that it can help others in the future.
Thanks,
Vinay Kumar
+1
Need to run an External Service while creating and updating records that are relevant to the ES.