Overview

Returns a list of all stacks associated with your ToolRouter account, including their configuration and server details.

Endpoint

GET https://api.toolrouter.ai/v1/stacks

Authentication

This endpoint requires an API key. Include it in the Authorization header:

Authorization: Bearer YOUR_API_KEY

Response

stacks
array

Array of stack objects

Example Request

curl -X GET "https://api.toolrouter.ai/v1/stacks" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json"

Example Response

[
  {
    "stack_id": "stack_123e4567-e89b-12d3-a456-426614174000",
    "stack_name": "Production Stack",
    "configuration": {
      "analytics_enabled": true
    },
    "servers": [
      {
        "server_name": "Gmail Server",
        "enabled_tools": [
          "gmail_send_email",
          "gmail_search_emails",
          "gmail_read_email"
        ]
      },
      {
        "server_name": "Google Calendar",
        "enabled_tools": [
          "calendar_list_events",
          "calendar_create_event"
        ]
      }
    ],
    "created_at": "2024-01-15T10:30:00Z",
    "updated_at": "2024-01-20T14:45:00Z"
  },
  {
    "stack_id": "stack_987f6543-e21c-34d5-b678-426614174001",
    "stack_name": "Development Stack",
    "configuration": {
      "analytics_enabled": false
    },
    "servers": [
      {
        "server_name": "Linear",
        "enabled_tools": [
          "linear_create_issue",
          "linear_search_issues"
        ]
      }
    ],
    "created_at": "2024-01-10T08:15:00Z",
    "updated_at": "2024-01-18T16:20:00Z"
  }
]

Error Responses

401 Unauthorized

Invalid or missing API key

{
  "detail": "Unauthorized"
}
429 Too Many Requests

Rate limit exceeded

{
  "detail": "Too many requests"
}
500 Internal Server Error

Server error occurred

{
  "detail": "Failed to list stacks"
}