Web Services

Page history last edited by Brev Patterson 4 mos ago

REST

REST wiki = http://rest.blueoxen.net/

 

Resource-oriented

GET /accounts/v1/bob/balance # retrieve Bob's balance

PUT /accounts/v1/bob/balance # update Bob's balance

DELETE /accounts/v1/bob # remove Bob's account

 

Methods

GET = retrieve

PUT = create new resources (should be able to GET right back from it)

DELETE=delete whole resources

POST=submit data for processing (doing GET afterwords would return different data)

 

Responses

1XX=internal HTTP functions

2XX=successful responses

200=OK

201=Created

3XX=redirection/caching

4XX=client-side problem

404=Not Found

405=Method Not Allowed (along with Allow HTTP header describing what is)

  • HTTP/1.1 405 Not Allowed
    
  • Allow: GET, PUT, DELETE
    

410=Removed Resources (Gone)

414=Request-URI Too Long (2048 bytes max)

5XX=server-side problem

500=Server Error

 

URL

 

Caching

HTTP 1.1 Cache-Control

 

 

Comments (0)

You don't have permission to comment on this page.