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.8k
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
360
BLoCパターンとflutter_bloc
hyshu
0
140
Melos x Pub Workspaces で 沢山のアプリとパッケージを管理するのに 苦労した話
hyshu
1
55
Jasprが凄い話
hyshu
1
370
CanvasKitの描画の仕組みを調べてみる
hyshu
0
220
Other Decks in Programming
See All in Programming
「ブロックテーマでは再現できない」は本当か?
inc2734
0
1.1k
Go 1.26でのsliceのメモリアロケーション最適化 / Go 1.26 リリースパーティ #go126party
mazrean
1
310
izumin5210のプロポーザルのネタ探し #tskaigi_msup
izumin5210
1
500
Rubyと楽しいをつくる / Creating joy with Ruby
chobishiba
0
200
Rで始めるML・LLM活用入門
wakamatsu_takumu
0
120
24時間止められないシステムを守る-医療ITにおけるランサムウェア対策の実際
koukimiura
2
180
今、アーキテクトとして 品質保証にどう関わるか
nealle
0
200
ぼくの開発環境2026
yuzneri
1
290
株式会社 Sun terras カンパニーデック
sunterras
0
1.9k
Go Conference mini in Sendai 2026 : Goに新機能を提案し実装されるまでのフロー徹底解説
yamatoya
0
470
Ruby x Terminal
a_matsuda
5
520
atmaCup #23でAIコーディングを活用した話
ml_bear
4
720
Featured
See All Featured
Building a A Zero-Code AI SEO Workflow
portentint
PRO
0
360
Efficient Content Optimization with Google Search Console & Apps Script
katarinadahlin
PRO
1
360
Responsive Adventures: Dirty Tricks From The Dark Corners of Front-End
smashingmag
254
22k
Highjacked: Video Game Concept Design
rkendrick25
PRO
1
300
Breaking role norms: Why Content Design is so much more than writing copy - Taylor Woolridge
uxyall
0
190
A Soul's Torment
seathinner
5
2.4k
The Art of Programming - Codeland 2020
erikaheidi
57
14k
Building a Scalable Design System with Sketch
lauravandoore
463
34k
Leveraging LLMs for student feedback in introductory data science courses - posit::conf(2025)
minecr
1
180
Paper Plane (Part 1)
katiecoart
PRO
0
5k
Darren the Foodie - Storyboard
khoart
PRO
3
2.7k
[RailsConf 2023] Rails as a piece of cake
palkan
59
6.3k
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