function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion

Call External Applications Web Service when SSO enabled using SAML.



Could some one help me in finding out a way for the below requirement.


Our Salesforce Application is SSO enabled using SAML Assertion. We would like to consume external systems webservice from our sfdc, could some let me know, is there any change with common approach specified below.


1.) Take the external system's wsdl file generate client and stub classes using apex.

2.) Consume the classes.



Do we need to provided any authentication steps before we call the webservices?


Please provide the code snippets for the same.



Thanks in Advance.

K. Mani Kumar.


How you authenticate to salesforce has no impact on how you authenticate from salesforce to external systems.


Only the author of the external webservice can tell you if and what type of authentication is required to access their service. 


 Thanks Simon,  I understood your point, the authentication mechanism is defined by the external system, but not within the salesforce.  Could you please provide some details for the below questions: 1)  When we authenticate to the external application, what is the best practice?  Is setting up a key store, or can we pass a security certificate to the external system to authenticate?  We want to stay away from hard coding a username or password back to their application.

2)  How is the data secure as it passes from SFDC to their external system, is it encrypted?

3)  Technical approach and the document to go through, for the above requested questoins? Thank You,K. Mani Kumar.   Thank You,K. Mani Kumar.

Hi All,


I also have the same problem which Kumar is mentioning here.

We are having a WebService which is external but is protected by a Certificate.


I wanted to know how to send the certificate from SFDC when i am making the webservice call..


Any pointers to this would be of great help




Hi Chellappa,


You have to pass the certificate key using the variable. I remember there is an example in the documentaiton.


HI Kumar,


Can u plz elaborate on this.

I have a .jks file with me for certificate.


and we have this method in HttpRequest class.



Are u referring to this method.