Logo
Search
Docs

Toggle connector

PUT https://app.sulus.ai/api/v1/agents/{agent_id}/connectors/{connector_id}

Enable or disable a connector for this agent

Authentication

Send a bearer token created on your dashboard's Developer page:

Authorization: Bearer <YOUR_API_KEY>

Path parameters

agent_id string Required

The agent id (UUID).

Validation: uuid (route-constrained)
Stored in ai_projects.uid
connector_id string Required

The connector uid from the list response.

Validation: uuid (route-constrained)
Stored in ai_mcp_connectors.uid

Request body

enabled boolean Required

Desired state.

Validation: required|boolean
Stored in ai_project_mcp_connectors.is_enabled

Errors

StatusMeaningBody
404 Agent not found, or you do not have access to it
404 Connector not found, inactive, or not available to you
403 You do not have MCP access to this agent. {"message":"You do not have MCP access to this agent."}
422 Validation failed {"message":"…","errors":{"field":["…"]}}
401 Missing or invalid bearer token
403 Feature ai_chat not enabled for the account

Notes

  • Requires connector permission on the agent (independent of write access).
curl --request PUT \
  --url https://app.sulus.ai/api/v1/agents/{agent_id}/connectors/{connector_id} \
  --header 'Authorization: Bearer <YOUR_API_KEY>' \
  --header 'Content-Type: application/json' \
  --data '{"enabled": true}'
import requests

url = "https://app.sulus.ai/api/v1/agents/{agent_id}/connectors/{connector_id}"
headers = {"Authorization": "Bearer <YOUR_API_KEY>"}
payload = {"enabled": true}

response = requests.put(url, json=payload, headers=headers)
print(response.json())
package main

import (
	"fmt"
	"io"
	"net/http"
	"strings"
)

func main() {
	url := "https://app.sulus.ai/api/v1/agents/{agent_id}/connectors/{connector_id}"
	payload := strings.NewReader(`{"enabled": true}`)
	req, _ := http.NewRequest("PUT", url, payload)
	req.Header.Add("Authorization", "Bearer <YOUR_API_KEY>")
	req.Header.Add("Content-Type", "application/json")
	res, _ := http.DefaultClient.Do(req)
	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)
	fmt.Println(string(body))
}
Response 200
{
    "message": "\"Docs search\" enabled for this agent.",
    "data": {
        "uid": "c3d4e5f6-0000-4000-8000-000000000030",
        "enabled": true
    }
}