Apis Protocolss
Apis Protocolss
5
RESTFUL REST (Representational State Transfer) is an architectural
style for designing networked applications. For a web service
to be considered RESTful, it must conform to a set of
constraints defined by REST principles.
1. Client-Server Architecture
2. Statelessness
6
5. Layered
System
3. Cacheability •Definition:
architecture The
can
be composed
multiple of
layers,
•Definition: Responses from the each with a
specific
server must explicitly state whether responsibility
(e.g., load
they are cacheable or not. If a balancers,
security layers,
response is cacheable, the client (or
caching proxies,
application
an intermediary) can reuse it for
servers).
6. Code on
subsequent requests.
Demand
(Optional)
4. Uniform Interface
•Definition:
Servers can
•Definition: All interactions between extend client
functionality by
the client and server must follow a transferring
executable code
standardized approach, ensuring (e.g., JavaScript)
to the client.
consistency and simplicity.
Why is it Optional?
Not Always
1.
Many RESTful Necessary:
systems are
designed
exchanging to focus
data solely
between onthe
client and the
executable server.
code is Sending
unnecessary
systems and adds for these
complexity.
Client
2.
One of Independence:
REST's principles is
that the
should client
becode and server
independent.
Sending
client more can makeon
dependent the
the
server for specific
functionality, potentially
7
SOAP
What is SOAP?
Simple Object Access Protocol (SOAP) is a
network protocol for exchanging structured data
between nodes. It uses XML (Extensible Markup
Language) format to transfer messages. It works
on top of application layer protocols like HTTP
and SMTP for notations and transmission. SOAP
allows processes to communicate throughout
platforms, languages, and operating system,
since protocols like HTTP are already installed on
all platforms. SOAP is suited for enterprise-level
applications that require high security, and
reliability.
8
WHAT IS XML?
9
THE MESSAGE IN XML FORMAT
CONTAINS FOUR PARTS WHICH ARE :
11
WHEN DO WE NEED SOAP?
12
THE DIFFERENCES BETWEEN SOAP AND
REST
SOAP API REST API
Works over HTTP, HTTPS, SMTP, XMPP Works over HTTP and HTTPS
14
THANK YOU