Skip to main content
Credal | Documentation

Search documentation

Type to search this documentation.

On this pageOverview

Remove Collection From Copilot

POST https://api.credal.ai/api/v0/copilots/removeCollectionFromCopilot Content-Type: application/json

Unlink a collection with a agent. The API Key used must be added to both the collection and the agent beforehand.

Reference: https://docs.credal.ai/api-reference/api-reference/copilots/remove-collection-from-copilot

  • Authorization header (bearer token, required) — Bearer authentication of the form Bearer <token>, where token is your auth token.

This endpoint expects an object.

  • copilotId (UUID, required) — Credal-generated agent ID to add the collection to.
  • collectionId (UUID, required) — Credal-generated collection ID to add.

Request

JSON
{
  "copilotId": "82e4b12a-6990-45d4-8ebd-85c00e030c24",
  "collectionId": "def1055f-83c5-43d6-b558-f7a38e7b299e"
}

SDK Code

Example0
import { CredalClient } from "@credal/sdk";

async function main() {
    const client = new CredalClient({
        apiKey: "YOUR_TOKEN_HERE",
    });
    await client.copilots.removeCollectionFromCopilot({
        copilotId: "82e4b12a-6990-45d4-8ebd-85c00e030c24",
        collectionId: "def1055f-83c5-43d6-b558-f7a38e7b299e",
    });
}
main();
Example0
from credal import CredalV0
import uuid

client = CredalV0(
    api_key="YOUR_TOKEN_HERE",
)

client.copilots.remove_collection_from_copilot(
    copilot_id=uuid.UUID("82e4b12a-6990-45d4-8ebd-85c00e030c24"),
    collection_id=uuid.UUID("def1055f-83c5-43d6-b558-f7a38e7b299e"),
)
Suggest an edit

Propose a replacement for this page. The site team reviews it before applying any changes.

Export
Documentation menu