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
Claude Agent SDK を使ってみよう
Search
Hayami Shuhei
October 17, 2025
Programming
2.1k
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Claude Agent SDK を使ってみよう
Claude Code Meetup Tokyo #1
※スライド中にある自作パッケージは、サードパーティー製ツールにおける利用禁止の方針が明確になったため非公開にしております
Hayami Shuhei
October 17, 2025
More Decks by Hayami Shuhei
See All by Hayami Shuhei
スマートグラスで並列バイブコーディング
hyshu
0
300
Flutterと Vibe Coding で個人開発!
hyshu
1
400
BLoCパターンとflutter_bloc
hyshu
0
150
Melos x Pub Workspaces で 沢山のアプリとパッケージを管理するのに 苦労した話
hyshu
1
65
Jasprが凄い話
hyshu
1
410
CanvasKitの描画の仕組みを調べてみる
hyshu
0
270
Other Decks in Programming
See All in Programming
そこに3びきプロダクトがいるじゃろう——生成AI時代における“価値が届かない理由”の構造
kosuket
0
180
分散システム、なんですぐ死んでしまうん?耐障害性を高めたいあなたのためのレジリエンスパターン入門
mshibuya
7
6.9k
Apache Hive: そしてCloud Native Lakehouseへ
okumin
1
170
FDEが実現するAI駆動経営の現在地
gonta
2
230
Apache Hive: Toward a Cloud Native Lakehouse
okumin
0
160
SREの積み重ねがAI駆動開発のガードレールになった ― 7つの実践/SRE Guardrails The 7
tomoyakitaura
8
5.5k
ビデオ通話が繋がる0.2秒で何が起きているのか
supurazako
2
150
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
420
PHP に部分適用が来るぞ!……ところで何それ?おいしいの? #phpcon / phpcon-2026
shogogg
0
390
ITヒヤリハットを整理してみた ~ライフサイクルと原因から考える再発防止策~
koukimiura
1
120
Claude Opus 4.6以後の受託開発エンジニアの変化(Claude Code開発ノウハウ大公開スペシャルbyクラスメソッド)
iidatakuma
1
880
Built Our Own Background Agent at LayerX #aidevex_findy
layerx
PRO
9
3.5k
Featured
See All Featured
The Limits of Empathy - UXLibs8
cassininazir
1
550
HTML-Aware ERB: The Path to Reactive Rendering @ RubyCon 2026, Rimini, Italy
marcoroth
3
370
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
55
3.4k
Design in an AI World
tapps
1
270
Prompt Engineering for Job Search
mfonobong
0
380
Design of three-dimensional binary manipulators for pick-and-place task avoiding obstacles (IECON2024)
konakalab
0
500
Navigating Weather and Climate Data
rabernat
0
410
Reality Check: Gamification 10 Years Later
codingconduct
0
2.2k
Primal Persuasion: How to Engage the Brain for Learning That Lasts
tmiket
0
390
Learning to Love Humans: Emotional Interface Design
aarron
275
41k
The #1 spot is gone: here's how to win anyway
tamaranovitovic
3
1.1k
Stop Working from a Prison Cell
hatefulcrawdad
274
21k
Transcript
Claude Agent SDK Λ ͬͯΈΑ͏ Claude Code Meetup T
okyo #1 aq (Hayami Shuhei) 2025/10/17
ࣗݾհ Claude Code Max͕ग़͙ͯ͢ʹՃೖɺ20xΛ2ͭܖͯͨ࣌͠ظ ccrunnerͱ͍͏؆୯ͳ Claude Code Runner Λ࡞͍ͬͯ·͢
YAMLͰఆٛɺUsage limit ͕དྷͨΒղআ·Ͱࣗಈػ https://github.com/hyshu/ccrunner BR ਫलฏʣϞόΠϧΞϓϦ։ൃऀ
Claude Code SDK ͔Β Claude Agent SDKʹʂ ίʔσΟϯάҎ֎ͷ༻్ߟྀͯ͠ύοέʔδ໊͕มߋ͞Εͨ →AnthropicࣾͰϝϞऔΓಈը࡞ͳͲͰ͍ͬͯΔΒ͍͠
ίʔσΟϯά༻ͷγεςϜϓϩϯϓτҎ֎ઃఆՄೳʹ ΧελϜMCPػೳ͕Ճ͞Εͨ →ϝιουΛMCPαʔόʔΘΓʹઃఆͰ͖ΔͷͰɺπʔϧొ͕؆୯ʹ https://www.anthropic.com/engineering/building-agents-with-the-claude-agent-sdk
import { query } from '@anthropic-ai/claude-code-sdk'; // claude
-p "Hello" ʹ૬ result = query({ prompt: "Hello" }); // allowedTools Ͱૢ࡞ΛڐՄ͢Δ߹ result = query({ prompt: "Hello", options: { allowedTools: [ "Task", "Bash", "Read", "Edit", ….. ], } }); ͜Ε·Ͱ
import { query } from '@anthropic-ai/claude-agent-sdk'; // systemPromptͰγεςϜϓϩϯϓτΛઃఆՄೳʹ //
settingSourcesͰࢀর͢ΔCLAUDE.mdsettings.jsonΛࢦఆ result = query({ prompt: "Hello", options: { systemPrompt: { type: "preset", preset: "claude_code" }, settingSources: ["user", "project", "local"], allowedTools: [ "Task", "Bash", "Read", "Edit", ….. ], } }) ͜Ε͔Β
·ͱΊ Claude Agent SDK ʹͳ͔ͬͯΒࣗ༝͕େ෯ʹ্͕ͬͨ → γεςϜϓϩϯϓτΛม͑Ε௨ৗͷ Claude API
ͷΑ͏ͳ͍ํՄೳʹ ΧελϜMCPͱͯ͠BashίϚϯυΛ࣮ߦɺAPIͷ௨৴ɺଞCLIͷ࣮ߦͳͲͳͲ ccrunnerΛࠓ·ͰʹόʔδϣϯΞοϓ͔ͨͬͨ͠ͷͷɺେ෯ʹ༷ݟ͞ ͳ͍ͱ͍͚ͳͦ͞͏ͳͷͰແཧͰͨ͠(^_^;) →͜͏ͨ͠ํ͕ྑͦ͞͏Έ͍ͨͳΞΠσΞΛืूதͰ͢
͝ਗ਼ௌ͋Γ͕ͱ͏͍͟͝·ͨ͠ 9!BRIBZBNJ