0

I am tring to use "clone report" functionility from MetadataService and MetadataService.MetadataPort and MetadataService.Report. I am geting and endpoint related issue "System.CalloutException: IO Exception: Unauthorized endpoint, please check Setup->Security->Remote site settings. endpoint = https://ap4.salesforce.com/services/Soap/m/37.0"

Please sort me out.

Thanks in Advance...

1 Answer 1

0

You need to go to Setup > Security > Remote Site Settings, and add https://ap4.salesforce.com to the list as a new Remote Site. This is a security feature that requires admins to set up endpoints before any Apex Code can communicate with a particular server.

2
  • I did the same. But Error remains same. Some time error changes to "System.CalloutException: Web service callout failed: WebService returned a SOAP Fault: '' is not a valid value for the enum 'ReportFormat' faultcode=soapenv:Client faultactor=" Please suggest me
    – Lerner
    Jan 8, 2017 at 15:59
  • @Lerner That's not the same error. You'll need to share your code for us to help you. The Remote Site Setting was the problem for your original question.
    – sfdcfox
    Jan 8, 2017 at 17:05

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .