AI Langdock

AI Langdock

Certified

Use Langdock models

Connects to Langdock's Completion API, which exposes OpenAI/Azure OpenAI-backed models on the OPENAI route and Claude models on the ANTHROPIC route. Set modelFamily to match the modelName you use: Claude models are only reachable when modelFamily is ANTHROPIC. Use the langdock.ListModels task with the matching family to discover valid modelName values.

Embeddings always go through the OpenAI route (only text-embedding-ada-002 is supported there). If your key is refused for embeddings, use a workspace API key with the Embedding API scope. Image generation is not offered by the Completion API.

For a dedicated deployment, set baseUrl to the route root that matches the operation you are using this provider for, e.g. https://acme.langdock.com/api/public/openai/eu/v1 for chat/embeddings on the OpenAI route, or https://acme.langdock.com/api/public/anthropic/eu/v1/ for chat on the Anthropic route; it then takes precedence over region.

yaml
type: io.kestra.plugin.ai.provider.Langdock

Chat completion with a Langdock-hosted OpenAI model

yaml
id: chat_completion
namespace: company.ai

inputs:
  - id: prompt
    type: STRING

tasks:
  - id: chat_completion
    type: io.kestra.plugin.ai.completion.ChatCompletion
    provider:
      type: io.kestra.plugin.ai.provider.Langdock
      apiKey: "{{ secret('LANGDOCK_API_KEY') }}"
      modelFamily: OPENAI
      modelName: gpt-5.4-mini
    messages:
      - type: SYSTEM
        content: You are a helpful assistant, answer concisely, avoid overly casual language or unnecessary verbosity.
      - type: USER
        content: "{{ inputs.prompt }}"

AI agent using a Langdock-hosted Claude model with a Kestra tool

yaml
id: agent_with_tool
namespace: company.ai

inputs:
  - id: prompt
    type: STRING
    defaults: "Log the message 'Hello from Langdock!'"

tasks:
  - id: agent
    type: io.kestra.plugin.ai.agent.AIAgent
    provider:
      type: io.kestra.plugin.ai.provider.Langdock
      apiKey: "{{ secret('LANGDOCK_API_KEY') }}"
      modelFamily: ANTHROPIC
      modelName: claude-sonnet-4-6-default
    prompt: "{{ inputs.prompt }}"
    tools:
      - type: io.kestra.plugin.ai.tool.KestraTask
        tasks:
          - id: log
            type: io.kestra.plugin.core.log.Log
            message: "..."

Ingest documents into a KV embedding store using Langdock embeddings

yaml
id: document_ingestion
namespace: company.ai

tasks:
  - id: ingest
    type: io.kestra.plugin.ai.rag.IngestDocument
    provider:
      type: io.kestra.plugin.ai.provider.Langdock
      apiKey: "{{ secret('LANGDOCK_WORKSPACE_API_KEY') }}"
      modelName: text-embedding-ada-002
    embeddings:
      type: io.kestra.plugin.ai.embeddings.KestraKVStore
    drop: true
    fromExternalURLs:
      - https://raw.githubusercontent.com/kestra-io/docs/refs/heads/main/README.md
Properties

API Key

Model name

Base URL

Custom base URL to override the default endpoint (useful for local tests, WireMock, or enterprise gateways).

CA PEM certificate content

CA certificate as text, used to verify SSL/TLS connections when using custom endpoints.

Client PEM certificate content

PEM client certificate as text, used to authenticate the connection to enterprise AI endpoints.

DefaultOPENAI
Possible Values
OPENAIANTHROPIC

Model family

Selects which Langdock Completion API route serves the request:

  • OPENAI (default): the OpenAI-compatible route, for OpenAI/Azure OpenAI-backed models.
  • ANTHROPIC: the Anthropic Messages-compatible route, required to reach Claude models. Ignored for embeddings, which always use the OpenAI route.
DefaultEU
Possible Values
EUUS

Region

The Langdock region that serves the request. Ignored when a dedicated-deployment baseUrl is set.