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
OpenAPIことはじめ
Search
ゆるゆる
September 24, 2021
Programming
0
110
OpenAPIことはじめ
技育CAMP 2021-09 で発表した内容です
https://talent.supporterz.jp/events/c01ce860-9f20-40ce-8d6b-46b14e1b3f25/
ゆるゆる
September 24, 2021
Tweet
Share
More Decks by ゆるゆる
See All by ゆるゆる
改行には気をつけよう
sunyryr
0
25
Docker bake(とCache)でCI/CDを改善する
sunyryr
0
250
WebAPI の設計
sunyryr
0
82
OpenAPI×LaravelでAPI開発を格段に便利にする方法
sunyryr
0
960
server side swift - codable
sunyryr
0
220
iOSアプリだけじゃないSwift
sunyryr
0
130
Other Decks in Programming
See All in Programming
讓數據說話:用 Python、Prometheus 和 Grafana 講故事
eddie
0
390
Sidekiqで実現する 長時間非同期処理の中断と再開 / Pausing and Resuming Long-Running Asynchronous Jobs with Sidekiq
hypermkt
6
3.1k
受け取る人から提供する人になるということ
little_rubyist
0
190
광고 소재 심사 과정에 AI를 도입하여 광고 서비스 생산성 향상시키기
kakao
PRO
0
170
Identifying User Idenity
moro
6
9.6k
Compose 1.7のTextFieldはPOBox Plusで日本語変換できない
tomoya0x00
0
170
見せてあげますよ、「本物のLaravel批判」ってやつを。
77web
6
7k
イベント駆動で成長して委員会
happymana
1
280
Outline View in SwiftUI
1024jp
1
290
リリース8年目のサービスの1800個のERBファイルをViewComponentに移行した方法とその結果
katty0324
5
4.2k
Googleのテストサイズを活用したテスト環境の構築
toms74209200
0
300
Ethereum_.pdf
nekomatu
0
380
Featured
See All Featured
Designing Dashboards & Data Visualisations in Web Apps
destraynor
229
52k
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
27
820
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
226
22k
ReactJS: Keep Simple. Everything can be a component!
pedronauck
665
120k
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
28
9.1k
Statistics for Hackers
jakevdp
796
220k
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
505
140k
Optimizing for Happiness
mojombo
376
69k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
43
6.8k
How GitHub (no longer) Works
holman
310
140k
A Modern Web Designer's Workflow
chriscoyier
693
190k
Rebuilding a faster, lazier Slack
samanthasiow
79
8.7k
Transcript
OpenAPI͜ͱ͡Ί ٕҭCAMP 2021/09/24 @sun-yryr / גࣜձࣾΏΊΈ
ΏΔΏΔ / sun-yryr / @taittide w גࣜձࣾΏΊΈ৽ଔೖࣾ w 4FSWFSTJEF&OHJOFFS 1)1
/PEFKT ͬͯ·͢ɻ GitHub Twitter ܦྺ ͖ͳ͜ͱ w 4XJGU 4FSWFSTJEF $*$% w 75VCFS taittide sunyryr
͘͡ • OpenAPI / Swaggerͱ • ͳͥOpenAPIΛ͏ͷ͔ • OASͷߏ •
OpenAPI͔Βίʔυͷࣗಈੜʹ͍ͭͯ
OpenAPI / Swaggerͱ • REST APIͷهड़ϑΥʔϚοτ • yaml or jsonͰهड़Ͱ͖Δ
• Ұੲલ·ͰSwagger Speci fi cation͕ଘࡏ͍ͯͨ͠ ͜ΕΛݩʹ֦ு͞ΕͯݱࡏΘΕ͍ͯΔͷ͕OpenAPI(Speci fi cation) • ݱࡏόʔδϣϯ3
OpenAPI / Swaggerͱ • OAS(OpenAPI Speci fi cation) Λิॿ͢Δπʔϧͷ૯শ •
Swagger Editor (هड़ɾม) • Swagger UI (දࣔ) • Swagger Codegen (ίʔυੜ)
ͳͥ͏ͷ͔ • ༷͕ݟ͍͢ • ΄΅ελϯμʔυʹͳ͖͍ͬͯͯΔͷͰڞ༗͕͍͢͠ • ίʔυͷࣗಈੜ͕ศར͗͢Δ • ϓϩάϥϜͰѻ͍͍͢
ͳͥ͏ͷ͔ • ༷͕ݟ͍͢ • ΄΅ελϯμʔυʹͳ͖͍ͬͯͯΔͷͰڞ༗͕͍͢͠ • ίʔυͷࣗಈੜ͕ศར͗͢Δ • ϓϩάϥϜͰѻ͍͍͢
ͳͥ͏ͷ͔ • ༷͕ݟ͍͢ • ΄΅ελϯμʔυʹͳ͖͍ͬͯͯΔͷͰڞ༗͕͍͢͠ • ίʔυͷࣗಈੜ͕ศར͗͢Δ • ϓϩάϥϜͰѻ͍͍͢
ͳͥ͏ͷ͔ • ༷͕ݟ͍͢ • ΄΅ελϯμʔυʹͳ͖͍ͬͯͯΔͷͰڞ༗͕͍͢͠ • ίʔυͷࣗಈੜ͕ศར͗͢Δ • ϓϩάϥϜͰѻ͍͍͢
ͳͥ͏ͷ͔ • ༷͕ݟ͍͢ • ΄΅ελϯμʔυʹͳ͖͍ͬͯͯΔͷͰڞ༗͕͍͢͠ • ίʔυͷࣗಈੜ͕ศར͗͢Δ • ϓϩάϥϜͰѻ͍͍͢
https://fortee.jp/phpcon-2021/proposal/5a58e077-6de6-453a-abff-adbe24cc3156
OASͷߏ
• openapi (όʔδϣϯ) • info (ใ) • servers (ϕʔεURL) •
paths (ΤϯυϙΠϯτ) • components (࠶ར༻ՄೳͳΦϒδΣΫτ) • tags (λά)
info ར༻ن
servers
paths
components
None
tags
OpenAPI͔Βίʔυͷࣗಈੜ
Swagger Codegen language: dart, csharp, go, java, python, ruby, php,
swift5, typescript-fetch, javascript, etc…
Swagger Codegen ੜ͞ΕΔϑΝΠϧ ར༻αϯϓϧ
Swagger Codegen service/AService.js
OpenAPIͷΤίγεςϜͰ ։ൃΛศརʹ͍͖ͯ͠·͠ΐ͏ʂ
͓͠·͍