Type Definitions
All types are exported as TypeScript interfaces from @faos/sdk.
import type {
AgentResponse,
ShortcutResolution,
ShortcutDefinition,
ShortcutListOptions,
FaosClientOptions,
} from '@faos/sdk';
AgentResponse​
Response from an agent invocation.
interface AgentResponse {
content: string;
agent_id: string;
metadata: Record<string, unknown>;
}
| Property | Type | Description |
|---|---|---|
content | string | The agent's response text |
agent_id | string | ID of the agent that responded |
metadata | Record<string, unknown> | Additional response metadata |
ShortcutResolution​
Result of resolving a shortcut command to an agent.
interface ShortcutResolution {
resolved: boolean;
agent_id: string | null;
module_key: string | null;
module_name: string | null;
agent_name: string | null;
task_template: string | null;
capabilities: string[];
suggestions: string[];
}
| Property | Type | Description |
|---|---|---|
resolved | boolean | Whether the shortcut was resolved |
agent_id | string | null | Resolved agent ID |
module_key | string | null | Module key (e.g., "faos-bank") |
module_name | string | null | Module display name |
agent_name | string | null | Agent display name |
task_template | string | null | Default task template for agent |
capabilities | string[] | Agent capabilities |
suggestions | string[] | Suggested shortcuts if unresolved |
ShortcutDefinition​
Definition of an available shortcut.
interface ShortcutDefinition {
pattern: string;
type: 'module' | 'agent' | 'command';
description: string;
module_key: string;
agent_id?: string;
examples: string[];
}
| Property | Type | Description |
|---|---|---|
pattern | string | Shortcut pattern (e.g., "bank credit-analyst") |
type | "module" | "agent" | "command" | Shortcut type |
description | string | Human-readable description |
module_key | string | Module key |
agent_id | string | undefined | Agent ID if agent-level shortcut |
examples | string[] | Usage examples |
ShortcutListOptions​
Options for listing shortcuts.
interface ShortcutListOptions {
module?: string;
search?: string;
}
| Property | Type | Description |
|---|---|---|
module | string | Filter by module key |
search | string | Search query string |
FaosClientOptions​
Options for the FaosClient constructor.
interface FaosClientOptions {
apiKey: string;
baseUrl?: string;
timeout?: number;
}
| Property | Type | Default | Description |
|---|---|---|---|
apiKey | string | required | FAOS API key |
baseUrl | string | "https://api.faosx.ai" | API base URL |
timeout | number | 30000 | Request timeout in milliseconds |