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
GraphQL入門
Search
K.Mori
January 29, 2020
Technology
1
100
GraphQL入門
社内勉強会での資料です。 #GraphQL #RESTful #SOAP
K.Mori
January 29, 2020
Tweet
Share
More Decks by K.Mori
See All by K.Mori
#DeStudy #01 Rust入門
morikyon
0
98
Other Decks in Technology
See All in Technology
複数サービスを支えるマルチテナント型Batch MLプラットフォーム
lycorptech_jp
PRO
1
880
サラリーマンの小遣いで作るtoCサービス - Cloudflare Workersでスケールする開発戦略
shinaps
2
470
AIエージェント開発用SDKとローカルLLMをLINE Botと組み合わせてみた / LINEを使ったLT大会 #14
you
PRO
0
130
企業の生成AIガバナンスにおけるエージェントとセキュリティ
lycorptech_jp
PRO
2
190
20250910_障害注入から効率的復旧へ_カオスエンジニアリング_生成AIで考えるAWS障害対応.pdf
sh_fk2
3
270
「Linux」という言葉が指すもの
sat
PRO
4
140
Create Ruby native extension gem with Go
sue445
0
120
新アイテムをどう使っていくか?みんなであーだこーだ言ってみよう / 20250911-rpi-jam-tokyo
akkiesoft
0
330
会社紹介資料 / Sansan Company Profile
sansan33
PRO
6
380k
いま注目のAIエージェントを作ってみよう
supermarimobros
0
350
EncryptedSharedPreferences が deprecated になっちゃった!どうしよう! / Oh no! EncryptedSharedPreferences has been deprecated! What should I do?
yanzm
0
480
LLMを搭載したプロダクトの品質保証の模索と学び
qa
0
1.1k
Featured
See All Featured
Faster Mobile Websites
deanohume
309
31k
Balancing Empowerment & Direction
lara
3
620
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
31
2.2k
The Myth of the Modular Monolith - Day 2 Keynote - Rails World 2024
eileencodes
26
3k
Build The Right Thing And Hit Your Dates
maggiecrowley
37
2.9k
Imperfection Machines: The Place of Print at Facebook
scottboms
268
13k
Rails Girls Zürich Keynote
gr2m
95
14k
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
31
2.5k
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
139
34k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
53
2.9k
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
656
61k
Measuring & Analyzing Core Web Vitals
bluesmoon
9
580
Transcript
GraphQL K.Mori (@forestython)
あGraphQL ◦ ◦ ◦ ◦ API ◦
API い
API い ◦ API: Application Programming Interface ◦ あ ◦
あ Google Maps ◦ 1 OK ◦ …
Request 。
Response …
SOAP
SOAP ◦ SOAP: ◦ Simple Object Access Protocol ◦ ◦
あ XML ◦ あHTTP OK ◦ あ ◦
SOAP ◦ ◦ ◦ ◦ BtoB ◦ ◦ XML ◦
◦ REST
<SOAP-ENV:Envelope xmlns:SOAP- ENV="http://schemas.xmlsoap.org/soap/envelope/"> <SOAP-ENV:Body> <getBooks xmlns="http://hogehoge.com/books"> <BookId>810</BookId> </getBooks> </SOAP-ENV:Body> </SOAP-ENV:Envelope>
<SOAP-ENV:Envelope xmlns:SOAP- ENV="http://schemas.xmlsoap.org/soap/envelope/"> <SOAP-ENV:Body> <getBooksResponse xmlns="http://warehouse.example.com/ws"> <getBooksResult> <BookName>Ocha no hon</BookName> <BookId>810</BookId> <author>Ocha-Hakase</author> <price>1000</price> </getBooksResult> </getBooksResponse> </SOAP-ENV:Body> </SOAP-ENV:Envelope> あ ID Request Response
RESTful API
RESTful API ◦ RESTful API: REST Web HTTP ◦ REST:
Representational State Transfer ◦ ◦ Stateless ◦ URI Addressability ◦ HTTP Uniform Interface ◦ 、 Connectability ◦
post 」 RESTfulあ /diary get
」 RESTfulあ … /Postdiary /Getdiary
RESTful API ◦ Response ◦ あ API ◦ Response ◦
◦ ◦ ◦ ISBN ◦ ◦ ◦ URI あ7 ◦ …
RESTful API ◦ ◦ あ API ◦ Response ◦ ◦
◦ ◦ ISBN ◦ ◦ ◦ URI あ7 ◦ 7 API い
RESTful API ◦ ◦ あ API ◦ Response ◦ ◦
◦ ◦ ISBN ◦ ◦ ◦ URI あ7 ◦ ◦ ◦ 3 ◦ … API
GraphQL
GraphQL ◦ 2012 Facebook ◦ 2015 9 4 ◦ REST
Web API ◦ Facebook Twitter, GitHub, Airbnb, New York Times, Netflix Web ◦ ◦ …い
GraphQL ◦ HTTP ◦ ◦ ◦ ◦ ◦ 1
GraphQL ◦ ◦ あ API ◦ ◦ ID =334
Request query { book(authorID:334) { authorName writtenBooks { books {
title price } } } } authorID=334 authorName: books: ➔ title( ) price( )
Response 3 { "data": { "book": { "authorName": "Hanshin Taro",
"writtenBooks": { "books": [ { "title": "Baseball Hero vol.1", "price": 1200 }, { "title": "Baseball Hero vol.6", "price": 1200 }, { "title": "Baseball Hero vol.7", "price": 1800 } ] } } } } { "title": "Baseball Hero vol.2", "price": 1200 }, { "title": "Baseball Hero vol.3", "price": 1300 }, { "title": "Baseball Hero vol.4", "price": 1200 }, { "title": "Baseball Hero vol.5", "price": 1400 }, SOAP い
◦ ◦ ◦ 「 ◦ post 「 ◦ 「 ◦
GraphQL json json …
あ ”Graph” ◦ Graph Graph ◦ ◦ (Directed Acyclic Graph)
◦ (Directed Tree) ◦ 0 ◦ 1 ◦
”Graph” query { book(authorID:334) { authorName writtenBooks { books {
title price } } } } Query book authorName writtenBooks books price title
◦ GraphQL SOAP REST ◦ ◦