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
210
Other Decks in Programming
See All in Programming
ThorVG Viewer In VS Code
nors
0
760
Grafana:建立系統全知視角的捷徑
blueswen
0
320
CSC307 Lecture 03
javiergs
PRO
1
490
CSC307 Lecture 04
javiergs
PRO
0
660
インターン生でもAuth0で認証基盤刷新が出来るのか
taku271
0
190
Lambda のコードストレージ容量に気をつけましょう
tattwan718
0
110
【卒業研究】会話ログ分析によるユーザーごとの関心に応じた話題提案手法
momok47
0
190
AI前提で考えるiOSアプリのモダナイズ設計
yuukiw00w
0
220
AI Agent Tool のためのバックエンドアーキテクチャを考える #encraft
izumin5210
6
1.8k
カスタマーサクセス業務を変革したヘルススコアの実現と学び
_hummer0724
0
620
KIKI_MBSD Cybersecurity Challenges 2025
ikema
0
1.3k
Apache Iceberg V3 and migration to V3
tomtanaka
0
150
Featured
See All Featured
Typedesign – Prime Four
hannesfritz
42
2.9k
Money Talks: Using Revenue to Get Sh*t Done
nikkihalliwell
0
150
[RailsConf 2023] Rails as a piece of cake
palkan
59
6.3k
The World Runs on Bad Software
bkeepers
PRO
72
12k
Product Roadmaps are Hard
iamctodd
PRO
55
12k
Technical Leadership for Architectural Decision Making
baasie
1
240
Deep Space Network (abreviated)
tonyrice
0
45
DevOps and Value Stream Thinking: Enabling flow, efficiency and business value
helenjbeal
1
89
CoffeeScript is Beautiful & I Never Want to Write Plain JavaScript Again
sstephenson
162
16k
The Cost Of JavaScript in 2023
addyosmani
55
9.5k
ReactJS: Keep Simple. Everything can be a component!
pedronauck
666
130k
Testing 201, or: Great Expectations
jmmastey
46
8k
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