SlideShare a Scribd company logo
The introduction of RESTful
Uniform Resource Locator(URL)
 Commonly informally termed a web address is a reference to a web
resource that specifies its location on a computer network and a
mechanism for retrieving the resource.
 Format
[ scheme://user:password@host:port/path?query#fragment ]
1. scheme: The canonical form is lowercase and documents that specify
schemes must do so with lowercase letters. It is followed by a colon (:).
Examples of popular schemes include http, ftp, mailto, file, data etc.
2. Authority part:
a. An optional authentication section of a user and password,
separated by a colon, followed by an at symbol (@).
b. A "host", consisting of either a registered name or an IP
address. IPv4addresses must be in dot-decimal notation,
and IPv6 addresses must be enclosed in brackets ([ ]).
c. An optional port number, separated from the hostname by a
colon.
Uniform Resource Locator(URL)
 Format
3. A path, which contains data, usually organized in hierarchical
form, that appears as a sequence of segments separated by
slashes. Such a sequence may resemble or map exactly to a file
system path or web resource(REST).
4. An optional query, separated from the preceding part by a
question mark (?), containing a query string of non-
hierarchical
data. Its syntax is not well defined, but by convention is most
often a sequence of attribute–value pairs separated by a
ampersand (&) or semicolon (;).
Uniform Resource Locator(URL)
 Format
5. An optional fragment, separated from the preceding
part by a hash (#). The fragment contains a fragment
identifier providing direction to a secondary resource. It is
often an ID attribute of a specific element, and web
browsers will scroll this element into view.
Hypertext Transfer Protocol(HTTP)
 HTTP functions as a request–response protocol in
the client–server computing model. A web browser, for
example, may be the client
and an application running on a computer a website may
be the server. The client submits an
HTTP request message to the server. The server, which
provides resources such as HTML files and other content
as JSON/XML/SOAP, or performs other functions on
behalf of the client, returns a response message to the
client. The response contains completion status
information about the request and may also contain
requested content in its message body.
HTTP Request Data Block
HTTP Request Data
 Verb- Indicate HTTP methods such as
1. POST(Create) – This method requests that the server accept the entity enclosed
in the request body as a new subordinate of the web resource identified by the
URI.
2. GET(Read) – The method requests a representation of the specified
resource. Requests using GET should only retrieve data and should have no
other effect.
3. HEAD(read) – This is useful for retrieving meta-information written in
response headers, without having response body.
4. PUT(Update) – This method requests that a web server accept and store the data
enclosed in the request body. If the URI refers to an already existing resource, it is
modified; if the URI does not point to an existing resource, then the server can
create the resource with that URI.
5. PATCH(Update) – This method applies partial modifications to a resource.
6. DELET(Delete) – This method deletes the specified resource.
HTTP Request Data
 URI- Contains the URI, Uniform Resource Identifier
to identify the resource on server
 HTTP Version- Indicate HTTP version, for example
HTTP v1.1 .
 Request Header- Contains metadata for the HTTP
Request message as key-value pairs. For example,
client ( or browser) type, format supported by client,
format of message body, cache settings etc.
 Request Body- Message content or Resource
representation.
HTTP Response Data Block
HTTP Response Data
 Status/Response Code- Indicate Server status for the
requested resource. For example 404 means resource
not found and 200 means response is ok.
 HTTP Version- Indicate HTTP version, for example
HTTP v1.1 .
 Response Header- Contains metadata for the HTTP
Response message as key-value pairs. For example,
content length, content type, response date, server
type etc.
 Response Body- Response message content or
Resource representation.
HTTPS
HTTPS
Method Table
Representation State Transfer(REST)
 Nouns – An URL
 Content Types – JSON, XML, CSS
 Verbs – GET, POST, PUT, DELETE
 Client(browser) deliver a Verb with a
uniform Noun(URL) to a
server(Apache httpd) , and server
implement the Verb in a specified
web resource and response the
results(Content-Types)
represented via browser UI of being
recognizable by humans intuitively.
REST Architectural Elements
 Data Element
a. Resource – The intended conceptual target of a hypertext reference
b. Resource Identifier – HTTP URL
c. Representation – HTTP Content-Type
 Connector
a. Client – HTTP client library
b. Server – Apache API
c. Cache – Browser Cache, Network Cache
d. Resolver – DNS lookup library
e. Tunnel – SSL
 Components
a. User Agent – Browser
b. Origin Server – Apache httpd, M$ II$.
c. Gateway – CGI
d. Proxy – Proxy
REST Constraints Client – Server: Clients(request) and servers(response) communicate over
an intermediate(computer network on separate hardware), but both client
and server may reside in the same system. A server host runs one or more
server programs which share their resources with clients.
 Stateless: Stateless means each request from clients as an independent
transaction that is unrelated to any previous request so that the
communication consists of independent pairs of request and response and
there are no client context being stored on the server between requests.
A stateless protocol does not require the server to retain session
information or status about each communications partner for the duration
of multiple requests.
 Cacheable: A temporary storage of web documents, such as HTML pages and
images, to reduce bandwidth usage. Clients can cache responses. Responses
must define themselves as cacheable to prevent clients from reusing stale or
inappropriate data in response to further requests ; requests may be satisfied
from the cache.
 Layered System: It is a system in which components are grouped, layered, in
a hierarchical arrangement, such that lower layers provide functions and services
that support the functions and services of higher layers. A client cannot
ordinarily tell whether it is connected directly to the end server, or to an
intermediary along the way.
REST Constraints
 Uniform Interface: The four constraints for this uniform interface are
a. Identification of resources: Individual resources are identified in
requests(nouns), Ex: URL
b. Manipulation of resources through representations: a client holds a
representation of a resource, including any metadata attached, it has enough
information to access/process the resource.
Ex: POST , GET, PUT, DELETE
c. Self-descriptive Messages: Each message includes enough information to describe
how to process the message.
Ex. The Content-Type
d. Hypermedia as the engine of application state: A REST client needs no prior
knowledge about how to interact with any particular application or server beyond a
generic understanding of hypermedia. Clients and servers interact through a
fixed interface shared through documentation or an interface description
language (IDL) to loosing coupled for security.
Ex: JSON
 Code on demand (optional) : Servers can temporarily extend or
customize the functionality of a client by the transfer of executable code.
Ex: Python / JavaScript
RESTful System
Connector
Client
Resource
An URL
+
HTML/JSON/X
ML/CSS/IMG
Componen
t
Gateway
Connector
Server
Verb
GET
Connector
Browser
Cache
Tunnel(SSL)
Connector
Network
Cache
Nouns
https://www.example.co
m
Resource Identifier
Content Type
Content-Type:
text/html
Content-Length: 123
{ Data }
Representation
Componen
t
Browser
s
Connector
DNS
Componen
t
httpd
HTTP Is a RESTful System
JavaScript Object Notation(JSON )
 JSON is a lightweight data-interchange format. It is easy for
humans to read and write. It is easy for machines to parse
and generate. It is based on a subset of the JavaScript
Programming Language.
JSON Forms - Object
 An object is an unordered set of name/value pairs. An
object begins with { (left brace) and ends with } (right
brace). Each name is followed by : (colon) and the
name/value pairs are separated by , .
JSON Forms - Array
 An array is an ordered collection of values. An array
begins with [ (left bracket) and ends with ] (right
bracket). Values are separated by ,.
JSON Forms - Value
 A value can be a string in double quotes, or a number,
or true or false or null, or an object or an array. These
structures can be nested.
JSON Forms - String A string is a sequence of zero or more Unicode characters, wrapped in
double quotes, using backslash escapes. A character is represented as a
single character string. A string is very much like a C or Java string.
JSON Forms - Number
 A number is very much like a C or Java number, except
that the octal and hexadecimal formats are not used.
Web Communication Flow Chart

More Related Content

What's hot (20)

KEY
A Conversation About REST - Extended Version
Jeremy Brown
 
PDF
HTTP Request and Response Structure
BhagyashreeGajera1
 
PDF
Deep Web: Databases on the Web
Denis Shestakov
 
PPT
jkljklj
hoefo
 
PPTX
Url web design
Cojo34
 
PDF
Bt0078 website design 2
Techglyphs
 
PPTX
Unit 3 - URLs and URIs
Chandan Gupta Bhagat
 
PDF
semanticweb
Kevin Hutt
 
PPTX
A Deep Dive into RESTful API Design Part 2
VivekKrishna34
 
PPT
Web services for developer
Rafiq Ahmed
 
PPTX
Representational state transfer (rest) architectural style1.1
Vinod Wilson
 
PDF
Semantic Annotation: The Mainstay of Semantic Web
Editor IJCATR
 
PDF
Representational State Transfer (REST) and HATEOAS
Guy K. Kloss
 
PPTX
Json web tokens
ElieHannouch
 
PPT
Web Services
Gaurav Tyagi
 
PPTX
Servlet & jsp
Subhasis Nayak
 
PPTX
Ogsi protocol perspective
Pooja Dixit
 
KEY
A Conversation About REST
Mike Wilcox
 
PPTX
Facebook thrift
Bhuvana Laksminarayanan
 
PPT
Web Services 2009
Cathie101
 
A Conversation About REST - Extended Version
Jeremy Brown
 
HTTP Request and Response Structure
BhagyashreeGajera1
 
Deep Web: Databases on the Web
Denis Shestakov
 
jkljklj
hoefo
 
Url web design
Cojo34
 
Bt0078 website design 2
Techglyphs
 
Unit 3 - URLs and URIs
Chandan Gupta Bhagat
 
semanticweb
Kevin Hutt
 
A Deep Dive into RESTful API Design Part 2
VivekKrishna34
 
Web services for developer
Rafiq Ahmed
 
Representational state transfer (rest) architectural style1.1
Vinod Wilson
 
Semantic Annotation: The Mainstay of Semantic Web
Editor IJCATR
 
Representational State Transfer (REST) and HATEOAS
Guy K. Kloss
 
Json web tokens
ElieHannouch
 
Web Services
Gaurav Tyagi
 
Servlet & jsp
Subhasis Nayak
 
Ogsi protocol perspective
Pooja Dixit
 
A Conversation About REST
Mike Wilcox
 
Facebook thrift
Bhuvana Laksminarayanan
 
Web Services 2009
Cathie101
 

Similar to The introduction of RESTful (20)

PPTX
REST & RESTful Web Services
Halil Burak Cetinkaya
 
PPTX
Restful Fundamentals
Suresh Madhra
 
PPTX
REST & RESTful Web Service
Hoan Vu Tran
 
PPTX
Api 101
DrSimoneDiCola
 
PPT
Http VS. Https
Raed Aldahdooh
 
PPT
thisisahypertextbastamaonanasiyaprom.ppt
luciclaveria65
 
PPTX
Basics of the Web Platform
Sanjeev Verma, PhD
 
PDF
Web Technologies Notes - TutorialsDuniya.pdf
Raghunathan52
 
PDF
Web Technologies Notes - TutorialsDuniya.pdf
Raghunathan52
 
PPTX
RESTful APIs
Adi Challa
 
PPTX
About HTTP and REST
Maggie Georgieva
 
PPTX
A Deep Dive into RESTful API Design Part 1
VivekKrishna34
 
PPTX
computer network introduction. psc notes . Assisant professor in cse.
bushraphd2022
 
PPT
WebEssentials- lecture 3.ppt
SachinKundu10
 
PPTX
Rest APIs Training
Shekhar Kumar
 
PPTX
rest-api-basics.pptx
AgungSutikno1
 
PPTX
Introduction to Web Services
Jeffrey Anderson
 
PDF
HTTP In-depth
Vinayak Hegde
 
PPTX
Evolution Of The Web Platform & Browser Security
Sanjeev Verma, PhD
 
PDF
Communicating on the web
Adrian Cardenas
 
REST & RESTful Web Services
Halil Burak Cetinkaya
 
Restful Fundamentals
Suresh Madhra
 
REST & RESTful Web Service
Hoan Vu Tran
 
Http VS. Https
Raed Aldahdooh
 
thisisahypertextbastamaonanasiyaprom.ppt
luciclaveria65
 
Basics of the Web Platform
Sanjeev Verma, PhD
 
Web Technologies Notes - TutorialsDuniya.pdf
Raghunathan52
 
Web Technologies Notes - TutorialsDuniya.pdf
Raghunathan52
 
RESTful APIs
Adi Challa
 
About HTTP and REST
Maggie Georgieva
 
A Deep Dive into RESTful API Design Part 1
VivekKrishna34
 
computer network introduction. psc notes . Assisant professor in cse.
bushraphd2022
 
WebEssentials- lecture 3.ppt
SachinKundu10
 
Rest APIs Training
Shekhar Kumar
 
rest-api-basics.pptx
AgungSutikno1
 
Introduction to Web Services
Jeffrey Anderson
 
HTTP In-depth
Vinayak Hegde
 
Evolution Of The Web Platform & Browser Security
Sanjeev Verma, PhD
 
Communicating on the web
Adrian Cardenas
 
Ad

Recently uploaded (20)

PDF
𝐁𝐔𝐊𝐓𝐈 𝐊𝐄𝐌𝐄𝐍𝐀𝐍𝐆𝐀𝐍 𝐊𝐈𝐏𝐄𝐑𝟒𝐃 𝐇𝐀𝐑𝐈 𝐈𝐍𝐈 𝟐𝟎𝟐𝟓
hokimamad0
 
PPTX
L1A Season 1 ENGLISH made by A hegy fixed
toszolder91
 
PPTX
法国巴黎第二大学本科毕业证{Paris 2学费发票Paris 2成绩单}办理方法
Taqyea
 
PPTX
L1A Season 1 Guide made by A hegy Eng Grammar fixed
toszolder91
 
PPTX
ONLINE BIRTH CERTIFICATE APPLICATION SYSYTEM PPT.pptx
ShyamasreeDutta
 
PPTX
Research Design - Report on seminar in thesis writing. PPTX
arvielobos1
 
PPTX
unit 2_2 copy right fdrgfdgfai and sm.pptx
nepmithibai2024
 
PDF
Azure_DevOps introduction for CI/CD and Agile
henrymails
 
PDF
Web Hosting for Shopify WooCommerce etc.
Harry_Phoneix Harry_Phoneix
 
PPTX
Orchestrating things in Angular application
Peter Abraham
 
PPT
Agilent Optoelectronic Solutions for Mobile Application
andreashenniger2
 
PPTX
internet básico presentacion es una red global
70965857
 
PPTX
Lec15_Mutability Immutability-converted.pptx
khanjahanzaib1
 
PPTX
一比一原版(SUNY-Albany毕业证)纽约州立大学奥尔巴尼分校毕业证如何办理
Taqyea
 
PPTX
Optimization_Techniques_ML_Presentation.pptx
farispalayi
 
PDF
DevOps Design for different deployment options
henrymails
 
PPT
introduction to networking with basics coverage
RamananMuthukrishnan
 
PDF
The-Hidden-Dangers-of-Skipping-Penetration-Testing.pdf.pdf
naksh4thra
 
PPTX
一比一原版(LaTech毕业证)路易斯安那理工大学毕业证如何办理
Taqyea
 
PPT
Computer Securityyyyyyyy - Chapter 1.ppt
SolomonSB
 
𝐁𝐔𝐊𝐓𝐈 𝐊𝐄𝐌𝐄𝐍𝐀𝐍𝐆𝐀𝐍 𝐊𝐈𝐏𝐄𝐑𝟒𝐃 𝐇𝐀𝐑𝐈 𝐈𝐍𝐈 𝟐𝟎𝟐𝟓
hokimamad0
 
L1A Season 1 ENGLISH made by A hegy fixed
toszolder91
 
法国巴黎第二大学本科毕业证{Paris 2学费发票Paris 2成绩单}办理方法
Taqyea
 
L1A Season 1 Guide made by A hegy Eng Grammar fixed
toszolder91
 
ONLINE BIRTH CERTIFICATE APPLICATION SYSYTEM PPT.pptx
ShyamasreeDutta
 
Research Design - Report on seminar in thesis writing. PPTX
arvielobos1
 
unit 2_2 copy right fdrgfdgfai and sm.pptx
nepmithibai2024
 
Azure_DevOps introduction for CI/CD and Agile
henrymails
 
Web Hosting for Shopify WooCommerce etc.
Harry_Phoneix Harry_Phoneix
 
Orchestrating things in Angular application
Peter Abraham
 
Agilent Optoelectronic Solutions for Mobile Application
andreashenniger2
 
internet básico presentacion es una red global
70965857
 
Lec15_Mutability Immutability-converted.pptx
khanjahanzaib1
 
一比一原版(SUNY-Albany毕业证)纽约州立大学奥尔巴尼分校毕业证如何办理
Taqyea
 
Optimization_Techniques_ML_Presentation.pptx
farispalayi
 
DevOps Design for different deployment options
henrymails
 
introduction to networking with basics coverage
RamananMuthukrishnan
 
The-Hidden-Dangers-of-Skipping-Penetration-Testing.pdf.pdf
naksh4thra
 
一比一原版(LaTech毕业证)路易斯安那理工大学毕业证如何办理
Taqyea
 
Computer Securityyyyyyyy - Chapter 1.ppt
SolomonSB
 
Ad

The introduction of RESTful

  • 2. Uniform Resource Locator(URL)  Commonly informally termed a web address is a reference to a web resource that specifies its location on a computer network and a mechanism for retrieving the resource.  Format [ scheme://user:password@host:port/path?query#fragment ] 1. scheme: The canonical form is lowercase and documents that specify schemes must do so with lowercase letters. It is followed by a colon (:). Examples of popular schemes include http, ftp, mailto, file, data etc. 2. Authority part: a. An optional authentication section of a user and password, separated by a colon, followed by an at symbol (@). b. A "host", consisting of either a registered name or an IP address. IPv4addresses must be in dot-decimal notation, and IPv6 addresses must be enclosed in brackets ([ ]). c. An optional port number, separated from the hostname by a colon.
  • 3. Uniform Resource Locator(URL)  Format 3. A path, which contains data, usually organized in hierarchical form, that appears as a sequence of segments separated by slashes. Such a sequence may resemble or map exactly to a file system path or web resource(REST). 4. An optional query, separated from the preceding part by a question mark (?), containing a query string of non- hierarchical data. Its syntax is not well defined, but by convention is most often a sequence of attribute–value pairs separated by a ampersand (&) or semicolon (;).
  • 4. Uniform Resource Locator(URL)  Format 5. An optional fragment, separated from the preceding part by a hash (#). The fragment contains a fragment identifier providing direction to a secondary resource. It is often an ID attribute of a specific element, and web browsers will scroll this element into view.
  • 5. Hypertext Transfer Protocol(HTTP)  HTTP functions as a request–response protocol in the client–server computing model. A web browser, for example, may be the client and an application running on a computer a website may be the server. The client submits an HTTP request message to the server. The server, which provides resources such as HTML files and other content as JSON/XML/SOAP, or performs other functions on behalf of the client, returns a response message to the client. The response contains completion status information about the request and may also contain requested content in its message body.
  • 7. HTTP Request Data  Verb- Indicate HTTP methods such as 1. POST(Create) – This method requests that the server accept the entity enclosed in the request body as a new subordinate of the web resource identified by the URI. 2. GET(Read) – The method requests a representation of the specified resource. Requests using GET should only retrieve data and should have no other effect. 3. HEAD(read) – This is useful for retrieving meta-information written in response headers, without having response body. 4. PUT(Update) – This method requests that a web server accept and store the data enclosed in the request body. If the URI refers to an already existing resource, it is modified; if the URI does not point to an existing resource, then the server can create the resource with that URI. 5. PATCH(Update) – This method applies partial modifications to a resource. 6. DELET(Delete) – This method deletes the specified resource.
  • 8. HTTP Request Data  URI- Contains the URI, Uniform Resource Identifier to identify the resource on server  HTTP Version- Indicate HTTP version, for example HTTP v1.1 .  Request Header- Contains metadata for the HTTP Request message as key-value pairs. For example, client ( or browser) type, format supported by client, format of message body, cache settings etc.  Request Body- Message content or Resource representation.
  • 10. HTTP Response Data  Status/Response Code- Indicate Server status for the requested resource. For example 404 means resource not found and 200 means response is ok.  HTTP Version- Indicate HTTP version, for example HTTP v1.1 .  Response Header- Contains metadata for the HTTP Response message as key-value pairs. For example, content length, content type, response date, server type etc.  Response Body- Response message content or Resource representation.
  • 11. HTTPS
  • 12. HTTPS
  • 14. Representation State Transfer(REST)  Nouns – An URL  Content Types – JSON, XML, CSS  Verbs – GET, POST, PUT, DELETE  Client(browser) deliver a Verb with a uniform Noun(URL) to a server(Apache httpd) , and server implement the Verb in a specified web resource and response the results(Content-Types) represented via browser UI of being recognizable by humans intuitively.
  • 15. REST Architectural Elements  Data Element a. Resource – The intended conceptual target of a hypertext reference b. Resource Identifier – HTTP URL c. Representation – HTTP Content-Type  Connector a. Client – HTTP client library b. Server – Apache API c. Cache – Browser Cache, Network Cache d. Resolver – DNS lookup library e. Tunnel – SSL  Components a. User Agent – Browser b. Origin Server – Apache httpd, M$ II$. c. Gateway – CGI d. Proxy – Proxy
  • 16. REST Constraints Client – Server: Clients(request) and servers(response) communicate over an intermediate(computer network on separate hardware), but both client and server may reside in the same system. A server host runs one or more server programs which share their resources with clients.  Stateless: Stateless means each request from clients as an independent transaction that is unrelated to any previous request so that the communication consists of independent pairs of request and response and there are no client context being stored on the server between requests. A stateless protocol does not require the server to retain session information or status about each communications partner for the duration of multiple requests.  Cacheable: A temporary storage of web documents, such as HTML pages and images, to reduce bandwidth usage. Clients can cache responses. Responses must define themselves as cacheable to prevent clients from reusing stale or inappropriate data in response to further requests ; requests may be satisfied from the cache.  Layered System: It is a system in which components are grouped, layered, in a hierarchical arrangement, such that lower layers provide functions and services that support the functions and services of higher layers. A client cannot ordinarily tell whether it is connected directly to the end server, or to an intermediary along the way.
  • 17. REST Constraints  Uniform Interface: The four constraints for this uniform interface are a. Identification of resources: Individual resources are identified in requests(nouns), Ex: URL b. Manipulation of resources through representations: a client holds a representation of a resource, including any metadata attached, it has enough information to access/process the resource. Ex: POST , GET, PUT, DELETE c. Self-descriptive Messages: Each message includes enough information to describe how to process the message. Ex. The Content-Type d. Hypermedia as the engine of application state: A REST client needs no prior knowledge about how to interact with any particular application or server beyond a generic understanding of hypermedia. Clients and servers interact through a fixed interface shared through documentation or an interface description language (IDL) to loosing coupled for security. Ex: JSON  Code on demand (optional) : Servers can temporarily extend or customize the functionality of a client by the transfer of executable code. Ex: Python / JavaScript
  • 19. HTTP Is a RESTful System
  • 20. JavaScript Object Notation(JSON )  JSON is a lightweight data-interchange format. It is easy for humans to read and write. It is easy for machines to parse and generate. It is based on a subset of the JavaScript Programming Language.
  • 21. JSON Forms - Object  An object is an unordered set of name/value pairs. An object begins with { (left brace) and ends with } (right brace). Each name is followed by : (colon) and the name/value pairs are separated by , .
  • 22. JSON Forms - Array  An array is an ordered collection of values. An array begins with [ (left bracket) and ends with ] (right bracket). Values are separated by ,.
  • 23. JSON Forms - Value  A value can be a string in double quotes, or a number, or true or false or null, or an object or an array. These structures can be nested.
  • 24. JSON Forms - String A string is a sequence of zero or more Unicode characters, wrapped in double quotes, using backslash escapes. A character is represented as a single character string. A string is very much like a C or Java string.
  • 25. JSON Forms - Number  A number is very much like a C or Java number, except that the octal and hexadecimal formats are not used.