History

docs(sdk): invoke tools by address, not id (#1916)

Aarushi Singh committed 2 months ago

Commit 0ae7a251 parent f9a158c1 file · +2 −2Browse files

Unified · Split

packages/core/sdk/README.md+2−2
@@ -42,7 +42,7 @@ const executor = await createExecutor({ onElicitation: "accept-all" }); · 41 unmodified lines
4242 const tools = await executor.tools.list();
4343 const target = tools[0];
4444 if (target) {
45− const result = await executor.tools.invoke(target.id, {
45+ const result = await executor.tools.invoke(target.address, {
4646 /* args matching target.inputSchema */
4747 });
4848 console.log(result);
@@ -54,7 +54,7 @@ await executor.close(); · 5 unmodified lines
5454 Pass an `options` object only if you need to override the executor-level handler for a single call (rare — typically used by hosts that bridge per-client elicitation channels):
5555
5656 ```ts
57−await executor.tools.invoke(target.id, args, {
57+await executor.tools.invoke(target.address, args, {
5858 onElicitation: customHandler,
5959 });
6060 ```

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t