Upgrade to Pro — share decks privately, control downloads, hide ads and more …

HTTP

commondream
October 08, 2011

 HTTP

This talk that I gave at ConvergeSE 2011 goes over the basics of the HTTP protocol and how to use the great constructs given to us in HTTP to build APIs.

commondream

October 08, 2011
Tweet

More Decks by commondream

Other Decks in Technology

Transcript

  1. WARNING It’s about to get real in here! Be sure

    you have cURL installed! If you don’t, you can download it at: http://bit.ly/curl-download
  2. Me!

  3. I’m pedantic enough to be a little irritated by the

    common “Web vs Native” usage. They’re all Web apps, and this argument is really about client platforms; no more, no less. - Tim Bray http://www.tbray.org/ongoing/When/201x/2011/06/14/Native-vs-Web
  4. > telnet google.com 80 Trying 74.125.67.147... Connected to google.com. Escape

    character is '^]'. GET / HTTP/1.1 Host: www.google.com
  5. GET

  6. PUT

  7. HTTP/1.1 200 OK Date: Mon, 20 Jun 2011 01:31:09 GMT

    Expires: -1 Cache-Control: private, max-age=0 Content-Type: text/html; charset=ISO-8859-1 Set-Cookie: PREF=ID=e446d3d1e8716b64:FF=0:TM=1308533469:LM=1 8; expires=Wed, 19-Jun-2013 01:31:09 GMT; path=/ Set-Cookie: NID=48=LjvfA6B_EsbDM8pmkis7YdVijYG2RLCc78Ne0my9Q eSzuB6iCOkDOAl78_oEMugbXV2lD82hyLkeJhuY6-RiVZkRK 20-Dec-2011 01:31:09 GMT; path=/; domain=.google Server: gws X-XSS-Protection: 1; mode=block <!doctype html><html><head><meta http-equiv="con
  8. Status Headers Body HTTP/1.1 200 OK Date: Mon, 20 Jun

    2011 01:31:09 GMT Expires: -1 Cache-Control: private, max-age=0 Content-Type: text/html; charset=ISO-8859-1 Set-Cookie: PREF=ID=e446d3d1e8716b64:FF=0:TM=1308533469:LM=1 8; expires=Wed, 19-Jun-2013 01:31:09 GMT; path=/ Set-Cookie: NID=48=LjvfA6B_EsbDM8pmkis7YdVijYG2RLCc78Ne0my9Q eSzuB6iCOkDOAl78_oEMugbXV2lD82hyLkeJhuY6-RiVZkRK 20-Dec-2011 01:31:09 GMT; path=/; domain=.google Server: gws X-XSS-Protection: 1; mode=block <!doctype html><html><head><meta http-equiv="con
  9. Response Headers Expires Set-Cookie Content-Length Connection Cache-Control ETag Content-Type Server

    Location WWW-Authenticate Date http://en.wikipedia.org/wiki/List_of_HTTP_headers