Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
REST API Design, Part I
Search
Nate Abele
August 29, 2013
Programming
230
1
Share
REST API Design, Part I
Given at PHP Undiscovered, SF.
Nate Abele
August 29, 2013
More Decks by Nate Abele
See All by Nate Abele
Running Kubernetes in the Browser. Yes, really. Not really. Kind of.
nateabele
1
73
Un-dux Your Front-End
nateabele
1
150
CloudFormation For Fun & Profit (But Mostly Sanity)
nateabele
0
88
Functional Reactive Systems
nateabele
1
180
ngPittsburgh - AngularUI Router Philosophy
nateabele
1
1.2k
The Future of Programming
nateabele
1
580
Past, Present, and Future: The Evolution of PHP Development
nateabele
1
640
The Future of Programming: PHP Argentina 2014
nateabele
1
130
Designing Hypermedia APIs
nateabele
4
710
Other Decks in Programming
See All in Programming
WebAssembly を読み込むベストプラクティス 2026年春版 / Best Practices for Loading WebAssembly (Spring 2026)
petamoriken
4
900
「Linuxサーバー構築標準教科書」を読んでみた #ツナギメオフライン.7
akase244
0
1.4k
Claude Codeをカスタムして自分だけのClaude Codeを作ろう
terisuke
0
150
ソフトウェア設計の結合バランス #phperkaigi
kajitack
0
160
Cache-moi si tu peux : patterns et pièges du cache en production - Devoxx France 2026 - Conférence
slecache
0
320
SREに優しいTerraform構成 modulesとstateの組み方
hiyanger
2
150
How We Benchmarked Quarkus: Patterns and anti-patterns
hollycummins
1
160
セグメントとターゲットを意識するプロポーザルの書き方 〜採択の鍵は、誰に刺すかを見極めるマーケティング戦略にある〜
m3m0r7
PRO
0
640
Terraform言語の静的解析 / static analysis of Terraform language
wata727
1
120
(Re)make Regexp in Ruby: Democratizing internals for the JIT
makenowjust
3
880
実践CRDT
tamadeveloper
0
600
アーキテクチャモダナイゼーションとは何か
nwiizo
19
5.6k
Featured
See All Featured
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
31
2.8k
Are puppies a ranking factor?
jonoalderson
1
3.3k
How to Talk to Developers About Accessibility
jct
2
190
How to build a perfect <img>
jonoalderson
1
5.4k
Conquering PDFs: document understanding beyond plain text
inesmontani
PRO
4
2.7k
Mozcon NYC 2025: Stop Losing SEO Traffic
samtorres
0
220
No one is an island. Learnings from fostering a developers community.
thoeni
21
3.7k
Neural Spatial Audio Processing for Sound Field Analysis and Control
skoyamalab
0
270
Design of three-dimensional binary manipulators for pick-and-place task avoiding obstacles (IECON2024)
konakalab
0
410
Unlocking the hidden potential of vector embeddings in international SEO
frankvandijk
0
770
Put a Button on it: Removing Barriers to Going Fast.
kastner
60
4.2k
Primal Persuasion: How to Engage the Brain for Learning That Lasts
tmiket
0
330
Transcript
RESTFUL API DESIGN
Every time someone mentions RESTful web services, there’s always that
one person that has to chime in: “That’s not really RESTful, it’s just kinda RESTful.” — Steve Klabnik
THE RICHARDSON MATURITY MODEL • Level 0: RPC over HTTP
• Level 1: Resources vs. single service endpoint • Level 2: HTTP Verbs vs. URL-based method calls • Level 3: Hypermedia controls
BASICALLY, A CONTENT-NEGOTIATED STATE MACHINE
<link rel="stylesheet" href="default.css" type="text/css" title="Default Style" />
<form method="POST" action="/items"> <input type="text" name="title" /> </form>
<link rel="next" href="/next" type="content/type" title="Next!" />
MEANINGFUL RESPONSE CODES • 201: Created • 202: We’ll get
back to you • 304: Use the copy I gave you last time • 400: WTF URL parameters • 401: Authentication • 403: Access control
MEANINGFUL RESPONSE CODES • 406: I refuse to speak XML
• 410: Soft deletes • 415: I refuse to listen to XML • 418: Useless, I wanted coffee • 422: Validation failed • 429: Chill out • 451: Legal told me not to • 503: Network/database/dependent service issues
SCALE
VERSIONING?
application/vnd.my-company.app+json; version=2.2 ? X-Version: 2.2 ?
INTENTS
http://api.fbi.gov/wanted? order_by=notoriety,desc& limit=10& page=1& fields=name,aka,known_associates, reward,description,last_seen vs. http://api.fbi.gov/wanted/most https://mathieu.fenniak.net/stop-designing-fragile-web-apis/