REST ClientFabricAI Agents

list

View as MarkdownOpen in Claude

List AI agent resources in the project.

Response

datalist of objectsRequired
An array of objects containing the list of AI Agent data.

Response Example

Response
{
"data": [
{
"id": "993ed018-9e79-4e50-b97b-984bd5534095",
"project_id": "1313fe58-5e14-4c11-bbe7-6fdfa11fe780",
"display_name": "Support Assistant",
"type": "ai_agent",
"created_at": "2024-05-06T12:20:00Z",
"updated_at": "2024-05-06T12:25:00Z",
"ai_agent": {
"prompt": {
"text": "You are a helpful customer support assistant."
},
"agent_id": "a87db7ed-8ebe-42e4-829f-8ba5a4152f54",
"name": "Support Assistant"
}
}
],
"links": {
"self": "https://example.signalwire.com/api/fabric/resources/ai_agents?page_number=0&page_size=50",
"first": "https://example.signalwire.com/api/fabric/resources/ai_agents?page_number=0&page_size=50"
}
}

Example

from signalwire.rest import RestClient
client = RestClient(
project="your-project-id",
token="your-api-token",
host="your-space.signalwire.com",
)
response = client.fabric.ai_agents.list()
for agent in response.get("data", []):
print(f"{agent['display_name']}: {agent['id']}")