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
0
1.5k
Claude Agent SDK を使ってみよう
Claude Code Meetup Tokyo #1
Hayami Shuhei
October 17, 2025
Tweet
Share
More Decks by Hayami Shuhei
See All by Hayami Shuhei
Flutterと Vibe Coding で個人開発!
hyshu
1
330
BLoCパターンとflutter_bloc
hyshu
0
130
Melos x Pub Workspaces で 沢山のアプリとパッケージを管理するのに 苦労した話
hyshu
1
50
Jasprが凄い話
hyshu
0
340
CanvasKitの描画の仕組みを調べてみる
hyshu
0
170
Other Decks in Programming
See All in Programming
Register is more than clipboard
satorunooshie
1
430
coconala_slide_pop.pdf
yukihito13
0
280
Functional Calisthenics in Kotlin: Kotlinで「関数型エクササイズ」を実践しよう
lagenorhynque
0
110
Vueのバリデーション、結局どれを選べばいい? ― 自作バリデーションの限界と、脱却までの道のり ― / Which Vue Validation Library Should We Really Use? The Limits of Self-Made Validation and How I Finally Moved On
neginasu
3
1.8k
Nitro v3
kazupon
2
220
自動テストを活かすためのテスト分析・テスト設計の進め方/JaSST25 Shikoku
goyoki
1
210
CSC509 Lecture 08
javiergs
PRO
0
280
Kotlinで実装するCPU/GPU 「協調的」パフォーマンス管理
matuyuhi
0
320
Blazing Fast UI Development with Compose Hot Reload (Bangladesh KUG, October 2025)
zsmb
2
490
MCPサーバー「モディフィウス」で変更容易性の向上をスケールする / modifius
minodriven
7
1.3k
Pythonに漸進的に型をつける
nealle
1
160
Migration to Signals, Resource API, and NgRx Signal Store
manfredsteyer
PRO
0
160
Featured
See All Featured
Speed Design
sergeychernyshev
32
1.2k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
46
7.8k
A better future with KSS
kneath
239
18k
Imperfection Machines: The Place of Print at Facebook
scottboms
269
13k
Bootstrapping a Software Product
garrettdimon
PRO
307
110k
The Cost Of JavaScript in 2023
addyosmani
55
9.2k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
31
2.7k
Facilitating Awesome Meetings
lara
57
6.6k
Building a Modern Day E-commerce SEO Strategy
aleyda
45
8k
Scaling GitHub
holman
463
140k
How To Stay Up To Date on Web Technology
chriscoyier
791
250k
Art, The Web, and Tiny UX
lynnandtonic
303
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