roder_core/
external_tools.rs1use crate::Runtime;
3
4#[derive(Debug, Clone)]
5pub struct PendingExternalExecution {
6 pub request_id: String,
7 pub thread_id: String,
8 pub turn_id: String,
9 pub tool_name: String,
10}
11
12impl Runtime {
13 pub async fn pending_external_executions(&self) -> Vec<PendingExternalExecution> {
14 self.pending_external_tool_calls
15 .lock()
16 .await
17 .iter()
18 .map(|(id, pending)| PendingExternalExecution {
19 request_id: id.clone(),
20 thread_id: pending.thread_id.clone(),
21 turn_id: pending.turn_id.clone(),
22 tool_name: pending.tool_name.clone(),
23 })
24 .collect()
25 }
26}