Print this page

error: "System.CalloutException: Callout loop not allowed"

Knowledge Article Number 000181795
Description Scenario-
Getting error: "System.CalloutException: Callout loop not allowed" on making call to a webservice from another salesforce.

Question-
Is it possible to call a webservice from another salesforce?
Resolution Call out in a package cannot reference an object in another ORG and if attempted throws "System.CalloutException: Callout loop not allowed" error. However, we can implement following workarounds:

1. BATCH APEX (Refer: https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/apexcode/apex_batch_interface.htm)

2. Scheduler to perform this asynchronously. (Refer : https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/apexcode/apex_scheduler.htm)
 
 




promote demote