Skip to content

Commit c1d61b8

Browse files
committed
Fix wrong ToolResult type in agent-config.d.ts
1 parent 553b05f commit c1d61b8

File tree

2 files changed

+19
-18
lines changed

2 files changed

+19
-18
lines changed

.agents/types/agent-config.d.ts

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -164,15 +164,6 @@ export interface Message {
164164
timestamp?: number
165165
}
166166

167-
/**
168-
* Result from executing a tool
169-
*/
170-
export interface ToolResult {
171-
success: boolean
172-
data?: any
173-
error?: string
174-
}
175-
176167
/**
177168
* Context provided to handleSteps generator function
178169
*/
@@ -190,6 +181,15 @@ export interface ToolCall<T extends ToolName = ToolName> {
190181
args?: Tools.GetToolParams<T>
191182
}
192183

184+
/**
185+
* Result from executing a tool
186+
*/
187+
export interface ToolResult {
188+
toolName: string
189+
toolCallId: string
190+
result: string
191+
}
192+
193193
/**
194194
* JSON Schema definition (for prompt schema or output schema)
195195
*/

common/src/util/agent-config.d.ts

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -164,15 +164,6 @@ export interface Message {
164164
timestamp?: number
165165
}
166166

167-
/**
168-
* Result from executing a tool
169-
*/
170-
export interface ToolResult {
171-
success: boolean
172-
data?: any
173-
error?: string
174-
}
175-
176167
/**
177168
* Context provided to handleSteps generator function
178169
*/
@@ -190,6 +181,16 @@ export interface ToolCall<T extends ToolName = ToolName> {
190181
args?: Tools.GetToolParams<T>
191182
}
192183

184+
/**
185+
* Result from executing a tool
186+
*/
187+
export interface ToolResult {
188+
toolName: string
189+
toolCallId: string
190+
result: string
191+
}
192+
193+
193194
/**
194195
* JSON Schema definition (for prompt schema or output schema)
195196
*/

0 commit comments

Comments
 (0)