docs: remove remaining directory query param mentions from SDK docs

This commit is contained in:
Dax Raad
2025-09-02 22:25:18 -04:00
parent 11e41e7564
commit c67b721787

View File

@@ -146,13 +146,10 @@ await client.app.log({
level: "info", level: "info",
message: "Operation completed", message: "Operation completed",
}, },
query: { directory: "/path/to/project" },
}) })
// List available agents // List available agents
const agents = await client.app.agents({ const agents = await client.app.agents()
query: { directory: "/path/to/project" },
})
``` ```
--- ---
@@ -170,14 +167,10 @@ const agents = await client.app.agents({
```javascript ```javascript
// List all projects // List all projects
const projects = await client.project.list({ const projects = await client.project.list()
query: { directory: "/path/to/project" },
})
// Get current project // Get current project
const currentProject = await client.project.current({ const currentProject = await client.project.current()
query: { directory: "/path/to/project" },
})
``` ```
--- ---
@@ -194,9 +187,7 @@ const currentProject = await client.project.current({
```javascript ```javascript
// Get current path information // Get current path information
const pathInfo = await client.path.get({ const pathInfo = await client.path.get()
query: { directory: "/path/to/project" },
})
``` ```
--- ---
@@ -213,13 +204,9 @@ const pathInfo = await client.path.get({
#### Examples #### Examples
```javascript ```javascript
const config = await client.config.get({ const config = await client.config.get()
query: { directory: "/path/to/project" },
})
const { providers, default: defaults } = await client.config.providers({ const { providers, default: defaults } = await client.config.providers()
query: { directory: "/path/to/project" },
})
``` ```
--- ---
@@ -256,12 +243,9 @@ const { providers, default: defaults } = await client.config.providers({
// Create and manage sessions // Create and manage sessions
const session = await client.session.create({ const session = await client.session.create({
body: { title: "My session" }, body: { title: "My session" },
query: { directory: "/path/to/project" },
}) })
const sessions = await client.session.list({ const sessions = await client.session.list()
query: { directory: "/path/to/project" },
})
// Send a prompt message // Send a prompt message
const result = await client.session.prompt({ const result = await client.session.prompt({
@@ -270,7 +254,6 @@ const result = await client.session.prompt({
model: { providerID: "anthropic", modelID: "claude-3-5-sonnet-20241022" }, model: { providerID: "anthropic", modelID: "claude-3-5-sonnet-20241022" },
parts: [{ type: "text", text: "Hello!" }], parts: [{ type: "text", text: "Hello!" }],
}, },
query: { directory: "/path/to/project" },
}) })
``` ```
@@ -297,11 +280,11 @@ const textResults = await client.find.text({
}) })
const files = await client.find.files({ const files = await client.find.files({
query: { query: "*.ts", directory: "/path/to/project" }, query: { query: "*.ts" },
}) })
const content = await client.file.read({ const content = await client.file.read({
query: { path: "src/index.ts", directory: "/path/to/project" }, query: { path: "src/index.ts" },
}) })
``` ```
@@ -352,7 +335,6 @@ await client.tui.showToast({
await client.auth.set({ await client.auth.set({
path: { id: "anthropic" }, path: { id: "anthropic" },
body: { type: "api", key: "your-api-key" }, body: { type: "api", key: "your-api-key" },
query: { directory: "/path/to/project" },
}) })
``` ```
@@ -370,9 +352,7 @@ await client.auth.set({
```javascript ```javascript
// Listen to real-time events // Listen to real-time events
const events = await client.event.subscribe({ const events = await client.event.subscribe()
query: { directory: "/path/to/project" },
})
for await (const event of events.stream) { for await (const event of events.stream) {
console.log("Event:", event.type, event.properties) console.log("Event:", event.type, event.properties)
} }