• English
  • Octop Providers API: Configure LLM Providers and Models

    The Providers API lets you configure which LLM providers and models your agents use. Providers can be per-user (created by any authenticated user and visible only to them) or admin-global (created under /api/admin/providers and shared across all accounts). All agents reference providers by name when selecting a model.

    Endpoints

    MethodPathAuthDescription
    GET/providersuserList providers visible to current user
    POST/providersuserCreate a per-user provider
    GET/providers/{id}userGet provider details
    PATCH/providers/{id}ownerUpdate provider config
    DELETE/providers/{id}ownerDelete provider
    POST/providers/{id}/testuserPing the provider
    POST/admin/providersadminCreate a global shared provider
    PATCH/admin/providers/{id}adminUpdate a shared provider
    DELETE/admin/providers/{id}adminDelete a shared provider
    GET/modelsuserList resolved models across all enabled providers
    GET/models/activeuserGet the currently active model
    PUT/models/activeadminSet the active model

    Create a provider

    Provide a name, a kind, and the connection details for your chosen LLM service.

    OpenAI
    Ollama (local)
    DashScope
    OpenAI
    curl -X POST http://127.0.0.1:8088/api/providers \
      -H 'Authorization: Bearer $TOKEN' \
      -H 'Content-Type: application/json' \
      -d '{
        "name": "openai",
        "kind": "openai",
        "base_url": "https://api.openai.com/v1",
        "api_key": "sk-..."
      }'
    NOTE

    API keys are stored encrypted at rest and will not appear in plaintext in any GET response. If you need to update a key, send a PATCH request with the new api_key value.

    Test a provider

    After creating a provider, verify the connection is healthy by calling its test endpoint. Octop sends a minimal model request with a timeout. For embedding providers, it probes the embeddings endpoint instead. Common authentication, quota, rate-limit, and provider-outage failures are returned as localized guidance when Octop can classify the upstream error.

    cURL
    Response (success)
    Response (failure)
    cURL
    curl -X POST http://127.0.0.1:8088/api/providers/openai/test \
      -H 'Authorization: Bearer $TOKEN'

    Pass model_id or embedding: true in the JSON body when you want to test a specific chat or embedding model.

    List resolved models

    GET /models returns the combined list of models available across all providers enabled for your account. Use the model values from this list when creating or updating agents.

    cURL
    cURL
    curl http://127.0.0.1:8088/api/models \
      -H 'Authorization: Bearer $TOKEN'

    Set the active model

    The active model is the system-wide default used when an agent does not specify a default_model. Only admins can change it.

    cURL
    cURL
    curl -X PUT http://127.0.0.1:8088/api/models/active \
      -H 'Authorization: Bearer $TOKEN' \
      -H 'Content-Type: application/json' \
      -d '{"provider_name": "openai", "model": "gpt-4o"}'
    WARNING

    Deleting a provider that is still referenced by one or more agents returns 409 PROVIDER_REFERENCED. Update or delete the dependent agents before removing the provider.

    Admin-managed shared providers

    Admins can create providers that are visible to every user by posting to /api/admin/providers instead of /api/providers. The request body is identical. Use PATCH /admin/providers/{id} and DELETE /admin/providers/{id} to manage these shared rows. Regular users can list and test shared providers but cannot modify or delete them.

    ACP (Agent Client Protocol)

    The ACP endpoints let you configure external runner connections that agents can invoke as tools. These endpoints are separate from provider configuration but live in the same authentication context.

    MethodPathAuthDescription
    GET/acpuserList your global runners
    PUT/acpuserReplace the global runner list
    GET/acp/{runner_name}userGet a specific runner
    PUT/acp/{runner_name}userUpsert a runner
    DELETE/acp/{runner_name}userDelete a custom runner
    GET/agents/{aid}/acpownerGlobal runners + per-agent tool-enabled flag
    PUT/agents/{aid}/acpownerUpdate tool-enabled flag and optionally the global list
    TIP

    See the ACP integration guide for the full runner object schema and setup examples.