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
JSON API
Search
Paul McMahon
April 28, 2016
Technology
140
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
JSON API
Paul McMahon
April 28, 2016
More Decks by Paul McMahon
See All by Paul McMahon
Why Ember.js?
pwim
0
1.1k
A developer's perspective on entrepreneurship
pwim
1
390
Using GitHub to get a better job
pwim
11
2.3k
Using Analytics to Improve UX
pwim
0
3.4k
Event Organizers Co-Edo edition
pwim
0
2.9k
Creating a RESTful API for mobile applications
pwim
6
310
勉強会を開催する大まかな流れ
pwim
2
10k
Creating International Communities in Japan
pwim
0
220
英語でコミットを書こう
pwim
52
28k
Other Decks in Technology
See All in Technology
從開發到部署全都交給 AI:實作 AI 驅動的自動化流程
appleboy
0
160
AI Agentをシステムに組み込む前にゆるく向き合ってみる
hayama17
0
140
Agile and AI Redmine Japan 2026
hiranabe
4
480
時期が悪い!それでもRaspberry Piを買って遊んで活用するには / 20260627-osc26do-rpi-jikigawarui
akkiesoft
0
820
ぼっちではじめた登壇が「51名」「241件」の発信に化けた
subroh0508
1
310
Microsoft のサポートとフィードバック総まとめ
murachiakira
PRO
0
110
PostgreSQL 19 新機能概要 OSC Hokkaido 2026
nori_shinoda
0
250
From Prompt Engineering to Loop Engineering
shibuiwilliam
1
230
FPGAの開発コンペでZephyrを使ってみた
iotengineer22
0
200
フルカイテン株式会社 エンジニア向け採用資料
fullkaiten
0
11k
OTel × Datadog で 「AI活用」を計測し、改善に繋げる
shihochan
2
640
SteampipeとExcel Power QueryでAWS構成定義書の作成を自動化する
jhashimoto
0
180
Featured
See All Featured
[RailsConf 2023] Rails as a piece of cake
palkan
59
6.7k
A Tale of Four Properties
chriscoyier
163
24k
Designing Dashboards & Data Visualisations in Web Apps
destraynor
231
55k
Conquering PDFs: document understanding beyond plain text
inesmontani
PRO
4
2.8k
Improving Core Web Vitals using Speculation Rules API
sergeychernyshev
21
1.5k
Why Your Marketing Sucks and What You Can Do About It - Sophie Logan
marketingsoph
0
170
Designing Powerful Visuals for Engaging Learning
tmiket
1
430
Optimising Largest Contentful Paint
csswizardry
37
3.7k
Deep Space Network (abreviated)
tonyrice
0
210
AI: The stuff that nobody shows you
jnunemaker
PRO
8
730
The Art of Delivering Value - GDevCon NA Keynote
reverentgeek
16
2k
jQuery: Nuts, Bolts and Bling
dougneiner
66
8.5k
Transcript
JSON API A SPECIFICATION FOR BUILDING APIS IN JSON PAUL
MCMAHON DOORKEEPERגࣜձࣾ @PWIM
େڕళ
API'S ARE HARD
CREATING A NEW API ISN'T SOMETHING YOU DO REGULARITY
DIFFERENT TECHNOLOGIES MAKE DIFFERENT ASSUMPTIONS ABOUT BEST PRACTICES
BACKWARDS COMPATIBILITY MAKES RESTRUCTURING HARD
CONVENTION OVER CONFIGURATION
DEVELOPING AN APPLICATION INVOLVES A LOT OF DECISIONS THAT DON'T
MATTER.
ALLOWS TO BUILD UP GENERALIZED TOOLING
JSON API
STANDARDIZES AN API'S JSON RESPONSE, SO YOU DON'T NEED TO
THINK ABOUT IT
CLIENT LIBRARIES IN JAVASCRIPT, IOS, RUBY, PHP, PERL, JAVA, ANDROID.
SERVER LIBRARIES IN PHP, NODE.JS, RUBY, PYTHON, GO, .NET, JAVA,
ELIXIR, PERL.
INITIAL DRAFT IN 2013, STABLE VERSION 1.0 IN 2015
BASIC EXAMPLE GET /events/42716 { "data": { "type": "events", "id":
"1", "attributes": { "title": "Machida Tech Night" "starts_at": "2016-04-28T10:00:00.000Z" "ends_at": "2016-04-28T12:30:00.000Z" }, "relationships": { "data": { "type": "group", "id": "6918" } } } }
SPARE FIELDSETS & RELATIONSHIPS GET /events/42716?include=group { "data": { "type":
"events", "id": "1", "attributes": { "title": "ୈ3ճ Machida Tech Night" }, "relationships": { "data": { "type": "group", "id": "6918" } } }, "included": [ { "type": "group", "id": "6918", "attributes": { "name": "Machida Tech Night" } ] }
PAGINATION & FILTERING GET /events?filter[title]=Machida&page[number]=2&page[size]=1 { "meta": { "total-pages": 3
}, "data": [{ "type": "events", "id": "1", "attributes": { "title": "ୈ3ճ Machida Tech Night" }, "relationships": { "data": { "type": "group", "id": "6918" } } }], "links": { "self": "https://api.doorkeeper.jp/events?filter[title]=Machida&page[number]=2&page[size]=1", "first": "https://api.doorkeeper.jp/events?filter[title]=Machida&page[number]=1&page[size]=1", "prev": "https://api.doorkeeper.jp/events?filter[title]=Machida&page[number]=1&page[size]=1", "next": "https://api.doorkeeper.jp/events?filter[title]=Machida&page[number]=3&page[size]=1", "last": "https://api.doorkeeper.jp/events?filter[title]=Machida&page[number]=3&page[size]=1" } }
RESOURCES > http://jsonapi.org/ > https://github.com/rails-api/ active_model_serializers > http://emberjs.com/