---
title: "Test domain classification with sample queries"
method: POST
path: "/workspace/{workspaceId}/test-connection"
tags: ["Workspace"]
---

# Test domain classification with sample queries

`POST /workspace/{workspaceId}/test-connection`

## Request

- Base URL: `https://api.savanto.ai`
- URL: `https://api.savanto.ai/workspace/{workspaceId}/test-connection`
- Auth: HTTP bearer

## Path parameters

- `workspaceId` string, required

## Request body

- object
  - `domain` object, required
    - `id` string, required
    - `name` string, required
    - `classifierPrompt` string, required
    - `agentPrompt` string, required
    - `mcpServers` object[], required
      - `name` string, required
      - `url` string, uri, required
      - `requiresAuth` boolean, required
      - `staticAuth` object
        - `type` 'bearer' | 'header' | 'basic', required
        - `headerName` string
        - `value` string, required
    - `apiEndpoints` object[]
      - `name` string, required
      - `baseUrl` string, uri, required
      - `responseFormat` 'json' | 'xml', required
      - `auth` object
        - `type` 'bearer' | 'header' | 'basic' | 'query', required
        - `headerName` string
        - `queryParamName` string
        - `value` string, required
      - `requiresAuth` boolean
      - `endpoints` object[], required
        - `toolName` string, required
        - `description` string, required
        - `method` 'GET' | 'POST' | 'PUT' | 'DELETE' | 'PATCH', required
        - `path` string, required
        - `parameters` object[], required
          - `name` string, required
          - `in` 'query' | 'path' | 'body', required
          - `required` boolean, required
          - `description` string, required
          - `type` 'string' | 'number' | 'boolean', required
          - `defaultValue` string
        - `requestTimeoutMs` integer
        - `dropPaths` string[]
    - `progressMessage` string, required
    - `enabled` boolean
    - `toolStrategy` 'required' | 'auto'
    - `maxToolTurns` integer
    - `exclusive` boolean
    - `composerRenderHint` 'card' | 'inline' | 'prose-only' | 'gallery'
    - `composerVerbosity` 'terse' | 'standard' | 'detailed'
    - `composerPrivacy` 'public' | 'sensitive'
    - `digestTemplate` string
    - `composerStreamingFields` string[]
    - `toolProgressMessages` object
  - `testQueries` string[], required

## Response `200`

Test results

- object
  - `object` 'event', required
  - `requestId` string, required
  - `data` object, required

## Other responses

- `400`: Validation error
- `401`: Unauthorized
- `403`: Forbidden
- `404`: Not found
- `409`: Conflict
- `413`: Payload too large
- `429`: Rate limit exceeded

---

[API](https://skmtc.dev/savanto/apis/savanto-api.md) · [All operations](https://skmtc.dev/savanto/apis/savanto-api/llms.txt) · [OpenAPI document](https://skmtc.dev/savanto/apis/savanto-api/revisions/82437327a878?raw)
