Salesforce Menu

Integration interview Question

1.What is SOAP and What is REST?

Representational State Transfer.
It is based URI
Works Over with HTTP and HTTPS


Simple Object Access Protocol.
It is based on Standard XML format
It is works with WSDL

2.Difference between REST API and SOAP API?
Ans :Varies on records that can be handled. Generally if we want to access less number of records we go for REST API.

3.What is WSDL?
A WSDL is an XML Document which contains a standardized description of how to communicate using webservice.

4.What are the different type of WSDL’S?
Enterprise WSDL
Partner WSDL
Metadata WSDL
Tooling WSDL
Delegated Atuntection WSDL

5.Difference between Enterprise WSDL and Partner WSDL?
Enterprise WSDL:
It is used for building client applications for a single salesforce organization.
Customers who use enterprise WSDL document must download and re-consume it when ever their organization makes a change to its custom objects or fields or when ever they want to use a different version of the API.

Partner WSDL:
It is used for building client applications for multiple organizations.
The partner WSDL documention only needs to be downloaded consumed once per version of the API.

6.How can you expose an apex class as a REST web service in salesforce?
An apex class can be exposed as REST web service by using keyword ‘@RestResource’

7.How to fetch data from another Salesforce instance using API?
Use the Web Services API or Bulk API to transfer data We this this is a great job for the Bulk API.

8.How to call Apex method from a Custom Button?
An Apex callout enables you to tightly integrate your Apex with an external service by making a call to an external Web service or sending a HTTP request from Apex code and then receiving the response.
Apex provides integration with Web services that utilize SOAP and WSDL, or HTTP services (RESTful services).

9.What is the use of Chatter REST API?
The Chatter API (also called Chatter REST API) lets you access Chatter information via an optimized REST-based API accessible from any platform. Developers can now build social applications for mobile devices, or highly interactive websites, quickly and efficiently.

10.How to fetch data from another Salesforce instance using API?
Use the FORCE.COM WEB SERVICES API or BULK API to transfer data We this this is a great job for the Bulk API.

11.What are callouts and call ins?
Making a request to an external system from salsforce is callout.

Getting requests from an external system is a call in.

12.How many callouts to external service can be made in a single apex transaction?
A total of 10 callouts are allowed in a single apex transaction.

13.What is the maximum allowed time limit while making a callout to external service in apex?
maximum of 120 second time limit is enforced while making callout to external service

14.What is the default timeout period while calling webservice from Apex.
10 sec.

15.can we define custom time out for each call out?
A custom time time can be defined for each callout.
the minimum time is 1 millisecond and maximum is 120,000 milli seconds.

16.How to increase timeout while calling web service from Apex ?
docSample.DocSamplePort stub = new docSample.DocSamplePort();
stub.timeout_x = 2000; // timeout in milliseconds

Subscribe Now