SlideShare a Scribd company logo
Webservices In Salesforce (Part 1)
Presenter: Surya Kanta Mekap,
Mindfire Solutions
Email: suryam@mindfiresolutions.com
SkypeId: mfsi_suryam
Date: 4 Oct 2013
Overview
1. Introduction
2. What is SOAP?
3. What is REST?
4. SOAP vs REST
5. What to Choose?
6. SOAP Webservice
7. Public SOAP Webservice
8. SOAP Callout
9. Testing Webservice Callout
10. Summary
Webservice?
Webservice is a sofware function or method of an application exposed
to the outside world allowing other application to invoke it from the
web.
What is SOAP?
The Simple Object Access Protocol(SOAP) web service is a
architecture pattern, which specifies the basic rules to be considered
while designing web service platforms. The SOAP message itself
consists of an envelope, inside of which are the SOAP headers and
body, the actual information we want to send. It is based on the
standard XML format, designed especially to transport and store
structured data. SOAP may also refer to the format of the XML that the
envelope uses.
Best for activity oriented services. An activity is more than just
insert or update or delete a record.
What is REST?
Representational State Transfer(REST) is another architectural
pattern. Unlike SOAP, RESTful applications use the GET, POST, PUT
and DELETE to perform CRUD operations. REST is resource-oriented
and uses URI (or RESTful URLs).
Roy Fielding is the Man who introduced the word REST and the
concept in his doctoral thesis in 2000.
Itโ€™s an excellent choice of technology for use with mobile
applications and browser-based clients.
SOAP vs REST
โ—

โ—

โ—

โ—

โ—

โ—

โ—

โ—

SOAP is a XML based messaging protocol and REST is not a protocol but an
architectural style.
SOAP has a standard specification but there is none for REST.
Even SOAP based web services can be implemented in RESTful style. REST is a concept
that does not tie with any protocols.
REST does not enforces message format as XML or JSON or etc. But SOAP is XML
based message protocol.
REST follows stateless model. SOAP has specifications for stateful implementation as
well.
SOAP is strongly typed, has strict specification for every part of implementation. But
REST gives the concept and less restrictive about the implementation.
SOAP uses interfaces(WSDL) and named operations to expose business logic. REST uses
(generally) URI and methods like (GET, PUT, POST, DELETE) to expose resources.
REST only works over HTTP and HTTPS. SOAP works over HTTP, HTTPS, SMTP,
XMPP, etc.
What to Choose?
If you want a web service that is activity oriented or requires
additional level of security or secure messaging then SOAP service is
the best option to choose. Activity is much more than just CRUD
operations.
If you want a web service that is more of resource-oriented, need to
do some CRUD operation on a resource then REST service is the best
option to choose. Due to its light weight it is mostly preferred for
browser based and mobile based applications.
In general, when you're publishing an API to the outside world that
is either complex or likely to change, SOAP will be more useful. Other
than that, REST is usually the better option.
SOAP Webservice
1. First, create and define an Apex class as global. Then create and define an
Apex method using both the static and webservice modifiers as shown
below.
global class HelloWorld {
webService static string sayHello(){
return 'Hello';
}
}
The global access modifier declares that the class is visible to all Apex
scripts everywhere.
This means the class can be used by any Apex code, not just the Apex in the
same application.
SOAP Webservice(Continued...)
2. To access the webservice WSDL, go to Setup | App Setup | Develop | Apex
Classes, find the specific class where the web service is defined and click on
the WSDL hyperlink and download it.
3. Collect the Enterprise WSDL from Setup | App Setup | Develop | API by
clicking Generate Enterprise WSDL link.
The Partner and Enterprise WSDL have a login() method for which we
need it along with our custom webservice wsdl so that we can give the
username and password, get the session id, and then switch over to our
custom web service to make it work. Session ids are tied to a given user in the
organization, so we need to control what they can access by giving them their
own profile and locking down access to only what they need to get to.
Those are the WSDL files which are to be imported into the external
application(s) that will be invoking the web service.
SOAP Webservice(Continued...)
โ—

โ—

โ—

โ—

โ—
โ—

โ—

The webservice modifier can't be used on a class itself, or an interface or
interface methods or variables.
The @future annotation needs to be used to make the Apex method
execute asynchronously.
Asynchronous callouts can be made with triggers but synchronous callout
with trigger is not supported(use actionpoller to check and show if a
response has been received while other transactions were ongoing).
All classes or inner classes that contain methods or variables defined with
the webservice keyword must be declared as global.
You must define any method that uses the webservice keyword as static.
Methods defined with the webservice keyword cannot take the following
elements as parameters. While these elements can be used within the
method, they cannot be used as return values.
Maps, Sets, Pattern objects, Matcher objects, Exception objects.
You must use the webservice keyword with any member variables that
you want to expose as part of a web service.
Public SOAP Webservice
1) Create a SOAP webservice.
2) Go to Site > Setup > App Setup > Develop > Sites > Select your Site >
Give access of class "MerchandiseManager" to site profile
3) Extract WSDL of your class, go to your class and then click "Generate
WSDL". Now all we need to change the SOAP address location in the
generated WSDL soap:address tag location value.
Lets say this is the location:
https://ap1.salesforce.com/services/Soap/class/HelloWorld
And our site URL is
https://mindfire-surya-developer-edition.ap1.force.com/
So our final location will be:
https://mindfire-surya-developeredition.ap1.force.com/services/Soap/class/HelloWorld
SOAP Callout
Apex Callouts enable Apex to invoke external SOAP web services using
WSDL so that you connect to third party services.
Before any Apex callout can call an external site, that site must be
registered in the Remote Site Settings page, or the callout fails.
Skipping this will result in "System.CalloutException: IO Exception:
Unauthorized endpoint, please check Setup->Security->Remote site settings.
endpoint ="...
SOAP Callout(wsdl2apex)
1. Collect the WSDL for the application that the salesforce is going to
consume.
2. Import the WSDL into Salesforce
Develop > Apex Classes > Generate from WSDL.
3. The successfully generated Apex class includes methods for calling the
third-party Web service represented by the WSDL document. Now create an
instance of the stub in your Apex code and call the methods on generated
Apex class.
Some free SOAP webservices with WSDL can be found :
http://www.actionscript.org/forums/showthread.php3?t=70742
WSDL Parsing Errors
There is a list of Supported WSDL Features listed:

http://wiki.developerforce.com/page/Apex_Web_Services_and_Callouts#Supported_WSD

Beyond those you can modify the source WSDL to get a reasonable level of
support. For example:
1. WSDL with multiple portType, binding, port are not supported in Apex so
do keep only respective PortType, binding and port before generating class
from WSDL.
2. Datatype โ€œanyTypeโ€ is not supported in WSDLs used to generate Apex
code that is saved using API version 15.0 and later, change the same to
โ€œstringโ€.
3. โ€ฆ......
SOAP Callout(Continued...)
The WSDL2Apex generated code supports HTTP Headers. For example, you can use
this feature to set the value of a cookie in an authorization header. To set HTTP
headers, add inputHttpHeaders_x and outputHttpHeaders_x to the stub.
Here's an example that sets input HTTP Headers:
docSample.DocSamplePort stub = new docSample.DocSamplePort();
stub.inputHttpHeaders_x = new Map<String, String>();
//Setting a basic authentication header
stub.inputHttpHeaders_x.put('Authorization', 'Basic
QWxhZGRpbjpvcGVuIHNlc2FtZQ==');
//Setting a cookie header
stub.inputHttpHeaders_x.put('Cookie', 'name=value');
//Setting a custom HTTP header
stub.inputHttpHeaders_x.put('myHeader', 'myValue');
....
SOAP Callout(Continued...)
Here's one that accesses output HTTP Headers information:
docSample.DocSamplePort stub = new docSample.DocSamplePort();
stub.outputHttpHeaders_x = new Map<String, String>();
String input = 'This is the input string';
String output = stub.EchoString(input);
//Getting cookie header
String cookie = stub.outputHttpHeaders_x.get('Set-Cookie');
//Getting custom header
String myHeader = stub.outputHttpHeaders_x.get('My-Header');
Testing SOAP Callout
Apex provides the built-in WebServiceMock interface and the
Test.setMock method that we can use to receive fake responses in a
test method for a SOAP callout.

Security
Authentication(Certificate 2way SSL)
Authorization(SessionID or OAuth 2.0)
Crypto class
EncodingUtil Class
Certificate
Server Certificate
Client Certificate
- Legacy Process
stub.clientCert_x = 'xyz....';
stub.clientCertPasswd_x = 'passwd'; // <<< Password for the keystore
-Salesforce Org
stub.clientCertName_x = 'Certificate Name'; // <<< Salesforceโ€™s certificate name
When SFDC makes a call to a secured server, it first tries to see if the server has a
Server Certificate. If it does, then it sends the Client Certificate. If this Client
Certificate is accepted by the web server, then the communication is valid and the
data is sent to and fro between SFDC and the web server
Oauth 2.0
OAuth endpoints are the URLs you use to make OAuth authentication
requests to Salesforce.
You need to use the correct Salesforce OAuth endpoint when issuing
authentication requests in your application. The primary OAuth endpoints
are:
For authorization: https://login.salesforce.com/services/oauth2/authorize
For token requests: https://login.salesforce.com/services/oauth2/token
For revoking OAuth tokens:
https://login.salesforce.com/services/oauth2/revoke
All endpoints require secure HTTP (HTTPS). Each OAuth flow defines
which endpoints you need to use and what request data you need to provide.
-Web Server Agent Oauth
-User Agent Oauth
-Username Password Agent OAuth
References
http://wiki.developerforce.com/page/Apex_Web_Services_and_Callouts
http://forceguru.blogspot.in/2012/09/creating-public-web-service-in.html
http://blog.deadlypenguin.com/blog/2012/02/03/salesforce-and-soapui/
http://kperisetla.blogspot.in/2012/05/restful-services-on-forcecom-through.html
http://www.fishofprey.com/2011/03/consuming-aspnet-web-service-from.html
http://www.salesforce.com/us/developer/docs/apexcode/index.htm

http://stackoverflow.com/questions/209905/representational-state-transfer-rest-and-simple-object-ac
http://www.salesforce.com/us/developer/docs/api_rest/index_Left.html

http://blog.deadlypenguin.com/blog/2012/04/13/salesforce-and-soapui-using-the-default-query-meth
http://medbiq.org/std_specs/techguidelines/knowingwhentorest.pdf
http://www.developingthefuture.net/web-services-overview/
http://www.tgerm.com/2010/12/invoking-apex-wsdl-web-services-from.html

http://blogs.developerforce.com/tech-pubs/2011/10/salesforce-apis-what-they-are-when-to-use-them
Question and Answers
Thank You
Ad

More Related Content

What's hot (20)

Introduction to Struts 1.3
Introduction to Struts 1.3Introduction to Struts 1.3
Introduction to Struts 1.3
Ilio Catallo
ย 
Java Servlets
Java ServletsJava Servlets
Java Servlets
BG Java EE Course
ย 
Web container and Apache Tomcat
Web container and Apache TomcatWeb container and Apache Tomcat
Web container and Apache Tomcat
Auwal Amshi
ย 
XML DTD and Schema
XML DTD and SchemaXML DTD and Schema
XML DTD and Schema
hamsa nandhini
ย 
Introduction to SOA
Introduction to SOAIntroduction to SOA
Introduction to SOA
saeed shargi ghazani
ย 
Node js
Node jsNode js
Node js
Fatih ลžimลŸek
ย 
Simple object access protocol(soap )
Simple object access protocol(soap )Simple object access protocol(soap )
Simple object access protocol(soap )
balamurugan.k Kalibalamurugan
ย 
Solr vs ElasticSearch
Solr vs ElasticSearchSolr vs ElasticSearch
Solr vs ElasticSearch
Dikshant Shahi
ย 
MapReduce in Cloud Computing
MapReduce in Cloud ComputingMapReduce in Cloud Computing
MapReduce in Cloud Computing
Mohammad Mustaqeem
ย 
Django REST Framework
Django REST FrameworkDjango REST Framework
Django REST Framework
Load Impact
ย 
Hive
HiveHive
Hive
Manas Nayak
ย 
AWS (Amazon Redshift) presentation
AWS (Amazon Redshift) presentationAWS (Amazon Redshift) presentation
AWS (Amazon Redshift) presentation
Volodymyr Rovetskiy
ย 
Microservices
MicroservicesMicroservices
Microservices
SmartBear
ย 
Jdbc ppt
Jdbc pptJdbc ppt
Jdbc ppt
sandeep54552
ย 
Hive(ppt)
Hive(ppt)Hive(ppt)
Hive(ppt)
Abhinav Tyagi
ย 
CQRS and Event Sourcing for IoT applications
CQRS and Event Sourcing for IoT applicationsCQRS and Event Sourcing for IoT applications
CQRS and Event Sourcing for IoT applications
Michael Blackstock
ย 
Presentation1.pptx
Presentation1.pptxPresentation1.pptx
Presentation1.pptx
PradeepDyavannanavar
ย 
Introduction to Spring Boot!
Introduction to Spring Boot!Introduction to Spring Boot!
Introduction to Spring Boot!
Jakub Kubrynski
ย 
55 New Features in Java SE 8
55 New Features in Java SE 855 New Features in Java SE 8
55 New Features in Java SE 8
Simon Ritter
ย 
Hibernate notes
Hibernate notesHibernate notes
Hibernate notes
Rajeev Uppala
ย 
Introduction to Struts 1.3
Introduction to Struts 1.3Introduction to Struts 1.3
Introduction to Struts 1.3
Ilio Catallo
ย 
Web container and Apache Tomcat
Web container and Apache TomcatWeb container and Apache Tomcat
Web container and Apache Tomcat
Auwal Amshi
ย 
XML DTD and Schema
XML DTD and SchemaXML DTD and Schema
XML DTD and Schema
hamsa nandhini
ย 
Solr vs ElasticSearch
Solr vs ElasticSearchSolr vs ElasticSearch
Solr vs ElasticSearch
Dikshant Shahi
ย 
MapReduce in Cloud Computing
MapReduce in Cloud ComputingMapReduce in Cloud Computing
MapReduce in Cloud Computing
Mohammad Mustaqeem
ย 
Django REST Framework
Django REST FrameworkDjango REST Framework
Django REST Framework
Load Impact
ย 
AWS (Amazon Redshift) presentation
AWS (Amazon Redshift) presentationAWS (Amazon Redshift) presentation
AWS (Amazon Redshift) presentation
Volodymyr Rovetskiy
ย 
Microservices
MicroservicesMicroservices
Microservices
SmartBear
ย 
CQRS and Event Sourcing for IoT applications
CQRS and Event Sourcing for IoT applicationsCQRS and Event Sourcing for IoT applications
CQRS and Event Sourcing for IoT applications
Michael Blackstock
ย 
Introduction to Spring Boot!
Introduction to Spring Boot!Introduction to Spring Boot!
Introduction to Spring Boot!
Jakub Kubrynski
ย 
55 New Features in Java SE 8
55 New Features in Java SE 855 New Features in Java SE 8
55 New Features in Java SE 8
Simon Ritter
ย 
Hibernate notes
Hibernate notesHibernate notes
Hibernate notes
Rajeev Uppala
ย 

Similar to Webservices in SalesForce (part 1) (20)

Web services in java
Web services in javaWeb services in java
Web services in java
maabujji
ย 
JavaEE6 my way
JavaEE6 my wayJavaEE6 my way
JavaEE6 my way
Nicola Pedot
ย 
Xml web services
Xml web servicesXml web services
Xml web services
Raghu nath
ย 
Express node js
Express node jsExpress node js
Express node js
Yashprit Singh
ย 
Create Home Directories on Storage Using WFA and ServiceNow integration
Create Home Directories on Storage Using WFA and ServiceNow integrationCreate Home Directories on Storage Using WFA and ServiceNow integration
Create Home Directories on Storage Using WFA and ServiceNow integration
Rutul Shah
ย 
Major project report
Major project reportMajor project report
Major project report
Omprakash Dhakad
ย 
Servlets
ServletsServlets
Servlets
Akshay Ballarpure
ย 
Rest web service
Rest web serviceRest web service
Rest web service
Hamid Ghorbani
ย 
MuleSoft London Community February 2020 - MuleSoft and OData
MuleSoft London Community February 2020 - MuleSoft and ODataMuleSoft London Community February 2020 - MuleSoft and OData
MuleSoft London Community February 2020 - MuleSoft and OData
Pace Integration
ย 
Web service through cxf
Web service through cxfWeb service through cxf
Web service through cxf
Roger Xia
ย 
Exchange of data over internet using web service(e.g., soap and rest) in SAS ...
Exchange of data over internet using web service(e.g., soap and rest) in SAS ...Exchange of data over internet using web service(e.g., soap and rest) in SAS ...
Exchange of data over internet using web service(e.g., soap and rest) in SAS ...
Kevin Lee
ย 
Xamarin Workshop Noob to Master โ€“ Week 5
Xamarin Workshop Noob to Master โ€“ Week 5Xamarin Workshop Noob to Master โ€“ Week 5
Xamarin Workshop Noob to Master โ€“ Week 5
Charlin Agramonte
ย 
Server side programming bt0083
Server side programming bt0083Server side programming bt0083
Server side programming bt0083
Divyam Pateriya
ย 
ASP.NET Core Interview Questions PDF By ScholarHat.pdf
ASP.NET Core Interview Questions PDF By ScholarHat.pdfASP.NET Core Interview Questions PDF By ScholarHat.pdf
ASP.NET Core Interview Questions PDF By ScholarHat.pdf
Scholarhat
ย 
Web API or WCF - An Architectural Comparison
Web API or WCF - An Architectural ComparisonWeb API or WCF - An Architectural Comparison
Web API or WCF - An Architectural Comparison
Adnan Masood
ย 
Frequently asked MuleSoft Interview Questions and Answers from Techlightning
Frequently asked MuleSoft Interview Questions and Answers from TechlightningFrequently asked MuleSoft Interview Questions and Answers from Techlightning
Frequently asked MuleSoft Interview Questions and Answers from Techlightning
Arul ChristhuRaj Alphonse
ย 
Bt0083 server side programing
Bt0083 server side programing Bt0083 server side programing
Bt0083 server side programing
Techglyphs
ย 
Creating Web Services with Zend Framework - Matthew Turland
Creating Web Services with Zend Framework - Matthew TurlandCreating Web Services with Zend Framework - Matthew Turland
Creating Web Services with Zend Framework - Matthew Turland
Matthew Turland
ย 
Web services soap and rest by mandakini for TechGig
Web services soap and rest by mandakini for TechGigWeb services soap and rest by mandakini for TechGig
Web services soap and rest by mandakini for TechGig
Mandakini Kumari
ย 
Build Message-Based Web Services for SOA
Build Message-Based Web Services for SOABuild Message-Based Web Services for SOA
Build Message-Based Web Services for SOA
Jeffrey Hasan
ย 
Web services in java
Web services in javaWeb services in java
Web services in java
maabujji
ย 
JavaEE6 my way
JavaEE6 my wayJavaEE6 my way
JavaEE6 my way
Nicola Pedot
ย 
Xml web services
Xml web servicesXml web services
Xml web services
Raghu nath
ย 
Express node js
Express node jsExpress node js
Express node js
Yashprit Singh
ย 
Create Home Directories on Storage Using WFA and ServiceNow integration
Create Home Directories on Storage Using WFA and ServiceNow integrationCreate Home Directories on Storage Using WFA and ServiceNow integration
Create Home Directories on Storage Using WFA and ServiceNow integration
Rutul Shah
ย 
Major project report
Major project reportMajor project report
Major project report
Omprakash Dhakad
ย 
Rest web service
Rest web serviceRest web service
Rest web service
Hamid Ghorbani
ย 
MuleSoft London Community February 2020 - MuleSoft and OData
MuleSoft London Community February 2020 - MuleSoft and ODataMuleSoft London Community February 2020 - MuleSoft and OData
MuleSoft London Community February 2020 - MuleSoft and OData
Pace Integration
ย 
Web service through cxf
Web service through cxfWeb service through cxf
Web service through cxf
Roger Xia
ย 
Exchange of data over internet using web service(e.g., soap and rest) in SAS ...
Exchange of data over internet using web service(e.g., soap and rest) in SAS ...Exchange of data over internet using web service(e.g., soap and rest) in SAS ...
Exchange of data over internet using web service(e.g., soap and rest) in SAS ...
Kevin Lee
ย 
Xamarin Workshop Noob to Master โ€“ Week 5
Xamarin Workshop Noob to Master โ€“ Week 5Xamarin Workshop Noob to Master โ€“ Week 5
Xamarin Workshop Noob to Master โ€“ Week 5
Charlin Agramonte
ย 
Server side programming bt0083
Server side programming bt0083Server side programming bt0083
Server side programming bt0083
Divyam Pateriya
ย 
ASP.NET Core Interview Questions PDF By ScholarHat.pdf
ASP.NET Core Interview Questions PDF By ScholarHat.pdfASP.NET Core Interview Questions PDF By ScholarHat.pdf
ASP.NET Core Interview Questions PDF By ScholarHat.pdf
Scholarhat
ย 
Web API or WCF - An Architectural Comparison
Web API or WCF - An Architectural ComparisonWeb API or WCF - An Architectural Comparison
Web API or WCF - An Architectural Comparison
Adnan Masood
ย 
Frequently asked MuleSoft Interview Questions and Answers from Techlightning
Frequently asked MuleSoft Interview Questions and Answers from TechlightningFrequently asked MuleSoft Interview Questions and Answers from Techlightning
Frequently asked MuleSoft Interview Questions and Answers from Techlightning
Arul ChristhuRaj Alphonse
ย 
Bt0083 server side programing
Bt0083 server side programing Bt0083 server side programing
Bt0083 server side programing
Techglyphs
ย 
Creating Web Services with Zend Framework - Matthew Turland
Creating Web Services with Zend Framework - Matthew TurlandCreating Web Services with Zend Framework - Matthew Turland
Creating Web Services with Zend Framework - Matthew Turland
Matthew Turland
ย 
Web services soap and rest by mandakini for TechGig
Web services soap and rest by mandakini for TechGigWeb services soap and rest by mandakini for TechGig
Web services soap and rest by mandakini for TechGig
Mandakini Kumari
ย 
Build Message-Based Web Services for SOA
Build Message-Based Web Services for SOABuild Message-Based Web Services for SOA
Build Message-Based Web Services for SOA
Jeffrey Hasan
ย 
Ad

More from Mindfire Solutions (20)

Physician Search and Review
Physician Search and ReviewPhysician Search and Review
Physician Search and Review
Mindfire Solutions
ย 
diet management app
diet management appdiet management app
diet management app
Mindfire Solutions
ย 
Business Technology Solution
Business Technology SolutionBusiness Technology Solution
Business Technology Solution
Mindfire Solutions
ย 
Remote Health Monitoring
Remote Health MonitoringRemote Health Monitoring
Remote Health Monitoring
Mindfire Solutions
ย 
Influencer Marketing Solution
Influencer Marketing SolutionInfluencer Marketing Solution
Influencer Marketing Solution
Mindfire Solutions
ย 
ELMAH
ELMAHELMAH
ELMAH
Mindfire Solutions
ย 
High Availability of Azure Applications
High Availability of Azure ApplicationsHigh Availability of Azure Applications
High Availability of Azure Applications
Mindfire Solutions
ย 
IOT Hands On
IOT Hands OnIOT Hands On
IOT Hands On
Mindfire Solutions
ย 
Glimpse of Loops Vs Set
Glimpse of Loops Vs SetGlimpse of Loops Vs Set
Glimpse of Loops Vs Set
Mindfire Solutions
ย 
Oracle Sql Developer-Getting Started
Oracle Sql Developer-Getting StartedOracle Sql Developer-Getting Started
Oracle Sql Developer-Getting Started
Mindfire Solutions
ย 
Adaptive Layout In iOS 8
Adaptive Layout In iOS 8Adaptive Layout In iOS 8
Adaptive Layout In iOS 8
Mindfire Solutions
ย 
Introduction to Auto-layout : iOS/Mac
Introduction to Auto-layout : iOS/MacIntroduction to Auto-layout : iOS/Mac
Introduction to Auto-layout : iOS/Mac
Mindfire Solutions
ย 
LINQPad - utility Tool
LINQPad - utility ToolLINQPad - utility Tool
LINQPad - utility Tool
Mindfire Solutions
ย 
Get started with watch kit development
Get started with watch kit developmentGet started with watch kit development
Get started with watch kit development
Mindfire Solutions
ย 
Swift vs Objective-C
Swift vs Objective-CSwift vs Objective-C
Swift vs Objective-C
Mindfire Solutions
ย 
Material Design in Android
Material Design in AndroidMaterial Design in Android
Material Design in Android
Mindfire Solutions
ย 
Introduction to OData
Introduction to ODataIntroduction to OData
Introduction to OData
Mindfire Solutions
ย 
Ext js Part 2- MVC
Ext js Part 2- MVCExt js Part 2- MVC
Ext js Part 2- MVC
Mindfire Solutions
ย 
ExtJs Basic Part-1
ExtJs Basic Part-1ExtJs Basic Part-1
ExtJs Basic Part-1
Mindfire Solutions
ย 
Spring Security Introduction
Spring Security IntroductionSpring Security Introduction
Spring Security Introduction
Mindfire Solutions
ย 
Physician Search and Review
Physician Search and ReviewPhysician Search and Review
Physician Search and Review
Mindfire Solutions
ย 
Business Technology Solution
Business Technology SolutionBusiness Technology Solution
Business Technology Solution
Mindfire Solutions
ย 
Remote Health Monitoring
Remote Health MonitoringRemote Health Monitoring
Remote Health Monitoring
Mindfire Solutions
ย 
Influencer Marketing Solution
Influencer Marketing SolutionInfluencer Marketing Solution
Influencer Marketing Solution
Mindfire Solutions
ย 
High Availability of Azure Applications
High Availability of Azure ApplicationsHigh Availability of Azure Applications
High Availability of Azure Applications
Mindfire Solutions
ย 
Glimpse of Loops Vs Set
Glimpse of Loops Vs SetGlimpse of Loops Vs Set
Glimpse of Loops Vs Set
Mindfire Solutions
ย 
Oracle Sql Developer-Getting Started
Oracle Sql Developer-Getting StartedOracle Sql Developer-Getting Started
Oracle Sql Developer-Getting Started
Mindfire Solutions
ย 
Adaptive Layout In iOS 8
Adaptive Layout In iOS 8Adaptive Layout In iOS 8
Adaptive Layout In iOS 8
Mindfire Solutions
ย 
Introduction to Auto-layout : iOS/Mac
Introduction to Auto-layout : iOS/MacIntroduction to Auto-layout : iOS/Mac
Introduction to Auto-layout : iOS/Mac
Mindfire Solutions
ย 
LINQPad - utility Tool
LINQPad - utility ToolLINQPad - utility Tool
LINQPad - utility Tool
Mindfire Solutions
ย 
Get started with watch kit development
Get started with watch kit developmentGet started with watch kit development
Get started with watch kit development
Mindfire Solutions
ย 
Material Design in Android
Material Design in AndroidMaterial Design in Android
Material Design in Android
Mindfire Solutions
ย 
Introduction to OData
Introduction to ODataIntroduction to OData
Introduction to OData
Mindfire Solutions
ย 
Spring Security Introduction
Spring Security IntroductionSpring Security Introduction
Spring Security Introduction
Mindfire Solutions
ย 
Ad

Recently uploaded (20)

UiPath Community Berlin: Orchestrator API, Swagger, and Test Manager API
UiPath Community Berlin: Orchestrator API, Swagger, and Test Manager APIUiPath Community Berlin: Orchestrator API, Swagger, and Test Manager API
UiPath Community Berlin: Orchestrator API, Swagger, and Test Manager API
UiPathCommunity
ย 
Dev Dives: Automate and orchestrate your processes with UiPath Maestro
Dev Dives: Automate and orchestrate your processes with UiPath MaestroDev Dives: Automate and orchestrate your processes with UiPath Maestro
Dev Dives: Automate and orchestrate your processes with UiPath Maestro
UiPathCommunity
ย 
"PHP and MySQL CRUD Operations for Student Management System"
"PHP and MySQL CRUD Operations for Student Management System""PHP and MySQL CRUD Operations for Student Management System"
"PHP and MySQL CRUD Operations for Student Management System"
Jainul Musani
ย 
Automation Hour 1/28/2022: Capture User Feedback from Anywhere
Automation Hour 1/28/2022: Capture User Feedback from AnywhereAutomation Hour 1/28/2022: Capture User Feedback from Anywhere
Automation Hour 1/28/2022: Capture User Feedback from Anywhere
Lynda Kane
ย 
SAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdf
SAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdfSAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdf
SAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdf
Precisely
ย 
Special Meetup Edition - TDX Bengaluru Meetup #52.pptx
Special Meetup Edition - TDX Bengaluru Meetup #52.pptxSpecial Meetup Edition - TDX Bengaluru Meetup #52.pptx
Special Meetup Edition - TDX Bengaluru Meetup #52.pptx
shyamraj55
ย 
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptxDevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
Justin Reock
ย 
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdfThe Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
Abi john
ย 
Role of Data Annotation Services in AI-Powered Manufacturing
Role of Data Annotation Services in AI-Powered ManufacturingRole of Data Annotation Services in AI-Powered Manufacturing
Role of Data Annotation Services in AI-Powered Manufacturing
Andrew Leo
ย 
tecnologias de las primeras civilizaciones.pdf
tecnologias de las primeras civilizaciones.pdftecnologias de las primeras civilizaciones.pdf
tecnologias de las primeras civilizaciones.pdf
fjgm517
ย 
How Can I use the AI Hype in my Business Context?
How Can I use the AI Hype in my Business Context?How Can I use the AI Hype in my Business Context?
How Can I use the AI Hype in my Business Context?
Daniel Lehner
ย 
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Impelsys Inc.
ย 
Manifest Pre-Seed Update | A Humanoid OEM Deeptech In France
Manifest Pre-Seed Update | A Humanoid OEM Deeptech In FranceManifest Pre-Seed Update | A Humanoid OEM Deeptech In France
Manifest Pre-Seed Update | A Humanoid OEM Deeptech In France
chb3
ย 
Electronic_Mail_Attacks-1-35.pdf by xploit
Electronic_Mail_Attacks-1-35.pdf by xploitElectronic_Mail_Attacks-1-35.pdf by xploit
Electronic_Mail_Attacks-1-35.pdf by xploit
niftliyevhuseyn
ย 
AI and Data Privacy in 2025: Global Trends
AI and Data Privacy in 2025: Global TrendsAI and Data Privacy in 2025: Global Trends
AI and Data Privacy in 2025: Global Trends
InData Labs
ย 
Image processinglab image processing image processing
Image processinglab image processing  image processingImage processinglab image processing  image processing
Image processinglab image processing image processing
RaghadHany
ย 
TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...
TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...
TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...
TrustArc
ย 
Complete Guide to Advanced Logistics Management Software in Riyadh.pdf
Complete Guide to Advanced Logistics Management Software in Riyadh.pdfComplete Guide to Advanced Logistics Management Software in Riyadh.pdf
Complete Guide to Advanced Logistics Management Software in Riyadh.pdf
Software Company
ย 
Datastucture-Unit 4-Linked List Presentation.pptx
Datastucture-Unit 4-Linked List Presentation.pptxDatastucture-Unit 4-Linked List Presentation.pptx
Datastucture-Unit 4-Linked List Presentation.pptx
kaleeswaric3
ย 
Network Security. Different aspects of Network Security.
Network Security. Different aspects of Network Security.Network Security. Different aspects of Network Security.
Network Security. Different aspects of Network Security.
gregtap1
ย 
UiPath Community Berlin: Orchestrator API, Swagger, and Test Manager API
UiPath Community Berlin: Orchestrator API, Swagger, and Test Manager APIUiPath Community Berlin: Orchestrator API, Swagger, and Test Manager API
UiPath Community Berlin: Orchestrator API, Swagger, and Test Manager API
UiPathCommunity
ย 
Dev Dives: Automate and orchestrate your processes with UiPath Maestro
Dev Dives: Automate and orchestrate your processes with UiPath MaestroDev Dives: Automate and orchestrate your processes with UiPath Maestro
Dev Dives: Automate and orchestrate your processes with UiPath Maestro
UiPathCommunity
ย 
"PHP and MySQL CRUD Operations for Student Management System"
"PHP and MySQL CRUD Operations for Student Management System""PHP and MySQL CRUD Operations for Student Management System"
"PHP and MySQL CRUD Operations for Student Management System"
Jainul Musani
ย 
Automation Hour 1/28/2022: Capture User Feedback from Anywhere
Automation Hour 1/28/2022: Capture User Feedback from AnywhereAutomation Hour 1/28/2022: Capture User Feedback from Anywhere
Automation Hour 1/28/2022: Capture User Feedback from Anywhere
Lynda Kane
ย 
SAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdf
SAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdfSAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdf
SAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdf
Precisely
ย 
Special Meetup Edition - TDX Bengaluru Meetup #52.pptx
Special Meetup Edition - TDX Bengaluru Meetup #52.pptxSpecial Meetup Edition - TDX Bengaluru Meetup #52.pptx
Special Meetup Edition - TDX Bengaluru Meetup #52.pptx
shyamraj55
ย 
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptxDevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
Justin Reock
ย 
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdfThe Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
The Evolution of Meme Coins A New Era for Digital Currency ppt.pdf
Abi john
ย 
Role of Data Annotation Services in AI-Powered Manufacturing
Role of Data Annotation Services in AI-Powered ManufacturingRole of Data Annotation Services in AI-Powered Manufacturing
Role of Data Annotation Services in AI-Powered Manufacturing
Andrew Leo
ย 
tecnologias de las primeras civilizaciones.pdf
tecnologias de las primeras civilizaciones.pdftecnologias de las primeras civilizaciones.pdf
tecnologias de las primeras civilizaciones.pdf
fjgm517
ย 
How Can I use the AI Hype in my Business Context?
How Can I use the AI Hype in my Business Context?How Can I use the AI Hype in my Business Context?
How Can I use the AI Hype in my Business Context?
Daniel Lehner
ย 
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Impelsys Inc.
ย 
Manifest Pre-Seed Update | A Humanoid OEM Deeptech In France
Manifest Pre-Seed Update | A Humanoid OEM Deeptech In FranceManifest Pre-Seed Update | A Humanoid OEM Deeptech In France
Manifest Pre-Seed Update | A Humanoid OEM Deeptech In France
chb3
ย 
Electronic_Mail_Attacks-1-35.pdf by xploit
Electronic_Mail_Attacks-1-35.pdf by xploitElectronic_Mail_Attacks-1-35.pdf by xploit
Electronic_Mail_Attacks-1-35.pdf by xploit
niftliyevhuseyn
ย 
AI and Data Privacy in 2025: Global Trends
AI and Data Privacy in 2025: Global TrendsAI and Data Privacy in 2025: Global Trends
AI and Data Privacy in 2025: Global Trends
InData Labs
ย 
Image processinglab image processing image processing
Image processinglab image processing  image processingImage processinglab image processing  image processing
Image processinglab image processing image processing
RaghadHany
ย 
TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...
TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...
TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...
TrustArc
ย 
Complete Guide to Advanced Logistics Management Software in Riyadh.pdf
Complete Guide to Advanced Logistics Management Software in Riyadh.pdfComplete Guide to Advanced Logistics Management Software in Riyadh.pdf
Complete Guide to Advanced Logistics Management Software in Riyadh.pdf
Software Company
ย 
Datastucture-Unit 4-Linked List Presentation.pptx
Datastucture-Unit 4-Linked List Presentation.pptxDatastucture-Unit 4-Linked List Presentation.pptx
Datastucture-Unit 4-Linked List Presentation.pptx
kaleeswaric3
ย 
Network Security. Different aspects of Network Security.
Network Security. Different aspects of Network Security.Network Security. Different aspects of Network Security.
Network Security. Different aspects of Network Security.
gregtap1
ย 

Webservices in SalesForce (part 1)

  • 1. Webservices In Salesforce (Part 1) Presenter: Surya Kanta Mekap, Mindfire Solutions Email: [email protected] SkypeId: mfsi_suryam Date: 4 Oct 2013
  • 2. Overview 1. Introduction 2. What is SOAP? 3. What is REST? 4. SOAP vs REST 5. What to Choose? 6. SOAP Webservice 7. Public SOAP Webservice 8. SOAP Callout 9. Testing Webservice Callout 10. Summary
  • 3. Webservice? Webservice is a sofware function or method of an application exposed to the outside world allowing other application to invoke it from the web.
  • 4. What is SOAP? The Simple Object Access Protocol(SOAP) web service is a architecture pattern, which specifies the basic rules to be considered while designing web service platforms. The SOAP message itself consists of an envelope, inside of which are the SOAP headers and body, the actual information we want to send. It is based on the standard XML format, designed especially to transport and store structured data. SOAP may also refer to the format of the XML that the envelope uses. Best for activity oriented services. An activity is more than just insert or update or delete a record.
  • 5. What is REST? Representational State Transfer(REST) is another architectural pattern. Unlike SOAP, RESTful applications use the GET, POST, PUT and DELETE to perform CRUD operations. REST is resource-oriented and uses URI (or RESTful URLs). Roy Fielding is the Man who introduced the word REST and the concept in his doctoral thesis in 2000. Itโ€™s an excellent choice of technology for use with mobile applications and browser-based clients.
  • 6. SOAP vs REST โ— โ— โ— โ— โ— โ— โ— โ— SOAP is a XML based messaging protocol and REST is not a protocol but an architectural style. SOAP has a standard specification but there is none for REST. Even SOAP based web services can be implemented in RESTful style. REST is a concept that does not tie with any protocols. REST does not enforces message format as XML or JSON or etc. But SOAP is XML based message protocol. REST follows stateless model. SOAP has specifications for stateful implementation as well. SOAP is strongly typed, has strict specification for every part of implementation. But REST gives the concept and less restrictive about the implementation. SOAP uses interfaces(WSDL) and named operations to expose business logic. REST uses (generally) URI and methods like (GET, PUT, POST, DELETE) to expose resources. REST only works over HTTP and HTTPS. SOAP works over HTTP, HTTPS, SMTP, XMPP, etc.
  • 7. What to Choose? If you want a web service that is activity oriented or requires additional level of security or secure messaging then SOAP service is the best option to choose. Activity is much more than just CRUD operations. If you want a web service that is more of resource-oriented, need to do some CRUD operation on a resource then REST service is the best option to choose. Due to its light weight it is mostly preferred for browser based and mobile based applications. In general, when you're publishing an API to the outside world that is either complex or likely to change, SOAP will be more useful. Other than that, REST is usually the better option.
  • 8. SOAP Webservice 1. First, create and define an Apex class as global. Then create and define an Apex method using both the static and webservice modifiers as shown below. global class HelloWorld { webService static string sayHello(){ return 'Hello'; } } The global access modifier declares that the class is visible to all Apex scripts everywhere. This means the class can be used by any Apex code, not just the Apex in the same application.
  • 9. SOAP Webservice(Continued...) 2. To access the webservice WSDL, go to Setup | App Setup | Develop | Apex Classes, find the specific class where the web service is defined and click on the WSDL hyperlink and download it. 3. Collect the Enterprise WSDL from Setup | App Setup | Develop | API by clicking Generate Enterprise WSDL link. The Partner and Enterprise WSDL have a login() method for which we need it along with our custom webservice wsdl so that we can give the username and password, get the session id, and then switch over to our custom web service to make it work. Session ids are tied to a given user in the organization, so we need to control what they can access by giving them their own profile and locking down access to only what they need to get to. Those are the WSDL files which are to be imported into the external application(s) that will be invoking the web service.
  • 10. SOAP Webservice(Continued...) โ— โ— โ— โ— โ— โ— โ— The webservice modifier can't be used on a class itself, or an interface or interface methods or variables. The @future annotation needs to be used to make the Apex method execute asynchronously. Asynchronous callouts can be made with triggers but synchronous callout with trigger is not supported(use actionpoller to check and show if a response has been received while other transactions were ongoing). All classes or inner classes that contain methods or variables defined with the webservice keyword must be declared as global. You must define any method that uses the webservice keyword as static. Methods defined with the webservice keyword cannot take the following elements as parameters. While these elements can be used within the method, they cannot be used as return values. Maps, Sets, Pattern objects, Matcher objects, Exception objects. You must use the webservice keyword with any member variables that you want to expose as part of a web service.
  • 11. Public SOAP Webservice 1) Create a SOAP webservice. 2) Go to Site > Setup > App Setup > Develop > Sites > Select your Site > Give access of class "MerchandiseManager" to site profile 3) Extract WSDL of your class, go to your class and then click "Generate WSDL". Now all we need to change the SOAP address location in the generated WSDL soap:address tag location value. Lets say this is the location: https://ap1.salesforce.com/services/Soap/class/HelloWorld And our site URL is https://mindfire-surya-developer-edition.ap1.force.com/ So our final location will be: https://mindfire-surya-developeredition.ap1.force.com/services/Soap/class/HelloWorld
  • 12. SOAP Callout Apex Callouts enable Apex to invoke external SOAP web services using WSDL so that you connect to third party services. Before any Apex callout can call an external site, that site must be registered in the Remote Site Settings page, or the callout fails. Skipping this will result in "System.CalloutException: IO Exception: Unauthorized endpoint, please check Setup->Security->Remote site settings. endpoint ="...
  • 13. SOAP Callout(wsdl2apex) 1. Collect the WSDL for the application that the salesforce is going to consume. 2. Import the WSDL into Salesforce Develop > Apex Classes > Generate from WSDL. 3. The successfully generated Apex class includes methods for calling the third-party Web service represented by the WSDL document. Now create an instance of the stub in your Apex code and call the methods on generated Apex class. Some free SOAP webservices with WSDL can be found : http://www.actionscript.org/forums/showthread.php3?t=70742
  • 14. WSDL Parsing Errors There is a list of Supported WSDL Features listed: http://wiki.developerforce.com/page/Apex_Web_Services_and_Callouts#Supported_WSD Beyond those you can modify the source WSDL to get a reasonable level of support. For example: 1. WSDL with multiple portType, binding, port are not supported in Apex so do keep only respective PortType, binding and port before generating class from WSDL. 2. Datatype โ€œanyTypeโ€ is not supported in WSDLs used to generate Apex code that is saved using API version 15.0 and later, change the same to โ€œstringโ€. 3. โ€ฆ......
  • 15. SOAP Callout(Continued...) The WSDL2Apex generated code supports HTTP Headers. For example, you can use this feature to set the value of a cookie in an authorization header. To set HTTP headers, add inputHttpHeaders_x and outputHttpHeaders_x to the stub. Here's an example that sets input HTTP Headers: docSample.DocSamplePort stub = new docSample.DocSamplePort(); stub.inputHttpHeaders_x = new Map<String, String>(); //Setting a basic authentication header stub.inputHttpHeaders_x.put('Authorization', 'Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ=='); //Setting a cookie header stub.inputHttpHeaders_x.put('Cookie', 'name=value'); //Setting a custom HTTP header stub.inputHttpHeaders_x.put('myHeader', 'myValue'); ....
  • 16. SOAP Callout(Continued...) Here's one that accesses output HTTP Headers information: docSample.DocSamplePort stub = new docSample.DocSamplePort(); stub.outputHttpHeaders_x = new Map<String, String>(); String input = 'This is the input string'; String output = stub.EchoString(input); //Getting cookie header String cookie = stub.outputHttpHeaders_x.get('Set-Cookie'); //Getting custom header String myHeader = stub.outputHttpHeaders_x.get('My-Header');
  • 17. Testing SOAP Callout Apex provides the built-in WebServiceMock interface and the Test.setMock method that we can use to receive fake responses in a test method for a SOAP callout. Security Authentication(Certificate 2way SSL) Authorization(SessionID or OAuth 2.0) Crypto class EncodingUtil Class
  • 18. Certificate Server Certificate Client Certificate - Legacy Process stub.clientCert_x = 'xyz....'; stub.clientCertPasswd_x = 'passwd'; // <<< Password for the keystore -Salesforce Org stub.clientCertName_x = 'Certificate Name'; // <<< Salesforceโ€™s certificate name When SFDC makes a call to a secured server, it first tries to see if the server has a Server Certificate. If it does, then it sends the Client Certificate. If this Client Certificate is accepted by the web server, then the communication is valid and the data is sent to and fro between SFDC and the web server
  • 19. Oauth 2.0 OAuth endpoints are the URLs you use to make OAuth authentication requests to Salesforce. You need to use the correct Salesforce OAuth endpoint when issuing authentication requests in your application. The primary OAuth endpoints are: For authorization: https://login.salesforce.com/services/oauth2/authorize For token requests: https://login.salesforce.com/services/oauth2/token For revoking OAuth tokens: https://login.salesforce.com/services/oauth2/revoke All endpoints require secure HTTP (HTTPS). Each OAuth flow defines which endpoints you need to use and what request data you need to provide. -Web Server Agent Oauth -User Agent Oauth -Username Password Agent OAuth
  • 20. References http://wiki.developerforce.com/page/Apex_Web_Services_and_Callouts http://forceguru.blogspot.in/2012/09/creating-public-web-service-in.html http://blog.deadlypenguin.com/blog/2012/02/03/salesforce-and-soapui/ http://kperisetla.blogspot.in/2012/05/restful-services-on-forcecom-through.html http://www.fishofprey.com/2011/03/consuming-aspnet-web-service-from.html http://www.salesforce.com/us/developer/docs/apexcode/index.htm http://stackoverflow.com/questions/209905/representational-state-transfer-rest-and-simple-object-ac http://www.salesforce.com/us/developer/docs/api_rest/index_Left.html http://blog.deadlypenguin.com/blog/2012/04/13/salesforce-and-soapui-using-the-default-query-meth http://medbiq.org/std_specs/techguidelines/knowingwhentorest.pdf http://www.developingthefuture.net/web-services-overview/ http://www.tgerm.com/2010/12/invoking-apex-wsdl-web-services-from.html http://blogs.developerforce.com/tech-pubs/2011/10/salesforce-apis-what-they-are-when-to-use-them