Returns every supported knowledge connector with THIS org's connection state…
Returns every supported knowledge connector with THIS org's connection state and the REAL number of documents each has ingested into the org's store.
GET /v1/knowledge/connectors
| Address | https://api.hanzo.ai/v1/knowledge/connectors |
| Method | GET |
| Operation | get_knowledge_connectors |
| Auth | Authorization: Bearer $HANZO_API_KEY |
Returns every supported knowledge connector with THIS org's connection state and the REAL number of documents each has ingested into the org's store. A provider that is configured for the deployment but not yet connected appears as disconnected, so the console can offer a Connect button. No secret is ever returned.
Request
GET /v1/knowledge/connectors takes no parameters and no body — the credential is the whole request.
Response
| Status | Body | Meaning |
|---|---|---|
200 | kbConnectorsOut | ok |
200 body — 9 fields.
| Field | In | Type | Always | Description |
|---|---|---|---|---|
connectors | body | connectorView[] | — | Connectors is every supported provider with this org's connection state. |
connectors[].account | body | string | — | Account names the connected external account. |
connectors[].configured | body | boolean | — | Configured is true when this deployment holds OAuth credentials for the provider. |
connectors[].docCount | body | integer | — | DocCount is the live count of this provider's documents in the org's store. |
connectors[].error | body | string | — | Error is the last sync failure, if any. |
connectors[].kind | body | string | — | Kind is "native" for a first-party Go connector, "piece" for a long-tail one. |
connectors[].lastSync | body | string | — | LastSync is when the last pull finished. |
connectors[].provider | body | string | — | Provider is the connector's id. |
connectors[].status | body | string | — | Status is connected, disconnected, syncing or error. |
Failure carries the platform error shape — see Errors.
Examples
hanzo has no subcommand for this operation — the CLI serves only what cloud's live route table confirms. Use HTTP or an SDK.
import { Configuration, KnowledgeApi } from 'hanzoai';
const api = new KnowledgeApi(new Configuration({ accessToken: process.env.HANZO_API_KEY }));
const { data } = await api.getKnowledgeConnectors();from hanzoai.cloud import ApiClient, Configuration
from hanzoai.cloud.api import KnowledgeApi
client = ApiClient(Configuration(access_token=os.environ["HANZO_API_KEY"]))
result = KnowledgeApi(client).get_knowledge_connectors()cfg := cloud.NewConfiguration()
cfg.AddDefaultHeader("Authorization", "Bearer "+os.Getenv("HANZO_API_KEY"))
client := cloud.NewAPIClient(cfg)
resp, _, err := client.KnowledgeAPI.GetKnowledgeConnectors(context.Background()).Execute()
if err != nil {
return err
}use hanzo_cloud::apis::{configuration::Configuration, knowledge_api};
let mut cfg = Configuration::new();
cfg.bearer_access_token = std::env::var("HANZO_API_KEY").ok();
let result = knowledge_api::get_knowledge_connectors(&cfg, Default::default()).await?;import ai.hanzo.cloud.ApiClient;
import ai.hanzo.cloud.api.KnowledgeApi;
ApiClient client = new ApiClient();
client.setRequestInterceptor(b -> b.header("Authorization", "Bearer " + System.getenv("HANZO_API_KEY")));
var result = new KnowledgeApi(client).getKnowledgeConnectors();The method above is the one at the current release of the document. [email protected] (npm) and [email protected] (PyPI) were generated from an earlier release, where this operation carried a different id, so it spells the method differently — regenerating the clients is what makes the two agree. SDKs →
curl https://api.hanzo.ai/v1/knowledge/connectors \
-H "Authorization: Bearer $HANZO_API_KEY"The door reaches knowledge through the knowledge tool, which names its 9 operations with its own verbs — this one among them, under a name only the door declares. describe explains any of them:
curl -X POST https://api.hanzo.ai/v1/mcp \
-H "Content-Type: application/json" \
-d '{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "describe",
"arguments": {
"op": "list_kb_connectors"
}
}
}'How is this guide?