> ## Documentation Index
> Fetch the complete documentation index at: https://www.edenai.co/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Lynkr

> Use Lynkr with Eden AI to route your gateway to 500+ AI models with tier-based cost optimisation.

export const TechArticleSchema = ({title, description, path, articleSection, about, proficiencyLevel = "Beginner", dependencies, keywords = [], datePublished, dateModified, image, inLanguage = "en"}) => {
  const baseUrl = "https://www.edenai.co/docs";
  const canonicalUrl = `${baseUrl}/${path}`.replace(/\/+$/, "");
  const ogParams = new URLSearchParams({
    division: articleSection || "",
    title: title || "",
    description: description || ""
  });
  const resolvedImage = image || `https://edenai.mintlify.app/_mintlify/api/og?${ogParams.toString()}`;
  const data = {
    "@context": "https://schema.org",
    "@type": "TechArticle",
    "@id": `${canonicalUrl}#techarticle`,
    mainEntityOfPage: {
      "@type": "WebPage",
      "@id": canonicalUrl
    },
    headline: title,
    name: title,
    description: description,
    url: canonicalUrl,
    inLanguage: inLanguage,
    isPartOf: {
      "@type": "WebSite",
      name: "Eden AI Documentation",
      url: baseUrl
    },
    author: [{
      "@type": "Organization",
      name: "Eden AI",
      url: "https://www.edenai.co/"
    }],
    publisher: {
      "@type": "Organization",
      name: "Eden AI",
      url: "https://www.edenai.co/",
      logo: {
        "@type": "ImageObject",
        url: "https://www.edenai.co/assets/logo.png"
      }
    }
  };
  if (articleSection) data.articleSection = articleSection;
  if (about) data.about = {
    "@type": "Thing",
    name: about
  };
  if (proficiencyLevel) data.proficiencyLevel = proficiencyLevel;
  if (dependencies) data.dependencies = dependencies;
  if (keywords && keywords.length) data.keywords = keywords;
  if (datePublished) data.datePublished = datePublished;
  if (dateModified) data.dateModified = dateModified;
  data.image = Array.isArray(resolvedImage) ? resolvedImage : [resolvedImage];
  const json = JSON.stringify(data);
  const schemaId = `techarticle-${canonicalUrl}`;
  React.useEffect(() => {
    if (typeof document === "undefined") return;
    document.querySelectorAll(`script[data-schema-id="${schemaId}"]`).forEach(n => n.remove());
    const script = document.createElement("script");
    script.type = "application/ld+json";
    script.dataset.schemaId = schemaId;
    script.textContent = json;
    document.head.appendChild(script);
    return () => script.remove();
  }, [json, schemaId]);
  return null;
};

<TechArticleSchema title={"Lynkr"} description={"Use Lynkr with Eden AI to route your gateway to 500+ AI models with tier-based cost optimisation."} path="v3/integrations/lynkr" articleSection="AI Gateway" about={"LLM Gateway Integration"} proficiencyLevel="Intermediate" keywords={["Eden AI", "AI API", "Lynkr", "LLM Gateway", "Routing"]} datePublished="2026-07-16T00:00:00Z" dateModified="2026-07-16T00:00:00Z" />

Use Lynkr with Eden AI to route your gateway to 500+ AI models with tier-based cost optimisation.

## Overview

Lynkr is an open-source LLM gateway that cuts costs with **tier-based routing** — it scores each request 0–100 and sends it to the cheapest model that can handle it. Eden AI is a built-in Lynkr provider, so you reach models from OpenAI, Anthropic, Google, Mistral and 500+ more behind one key, with EU-based, GDPR-aligned inference and unified billing.

## Installation

<CodeGroup>
  ```bash npm theme={null}
  npm install -g lynkr
  ```

  ```bash Homebrew theme={null}
  brew tap fast-editor/lynkr
  brew install lynkr
  ```

  ```bash Install script theme={null}
  curl -fsSL https://raw.githubusercontent.com/Fast-Editor/Lynkr/main/install.sh | bash
  ```
</CodeGroup>

## Quick Start

Initialise Lynkr, point it at Eden AI, and start the gateway:

<CodeGroup>
  ```bash Terminal theme={null}
  lynkr init                       # scaffold a .env
  export EDENAI_API_KEY=your-edenai-key
  export MODEL_PROVIDER=edenai      # send all requests to Eden AI
  lynkr start                       # OpenAI-compatible endpoint on port 8081
  ```
</CodeGroup>

```bash curl theme={null}
curl -X POST http://localhost:8081/v1/chat/completions \
  -H "Content-Type: application/json" \
  -d '{
    "model": "mistral/mistral-small-2603",
    "messages": [{"role": "user", "content": "Hello from Lynkr + Eden AI"}]
  }'
```

## Configuration

Lynkr reads provider credentials from environment variables (or a `.env` file):

<CodeGroup>
  ```bash .env theme={null}
  EDENAI_API_KEY=your-edenai-key
  EDENAI_MODEL=openai/gpt-5-mini                       # default model (provider/model naming)
  EDENAI_EMBEDDINGS_MODEL=openai/text-embedding-ada-002
  EDENAI_ENDPOINT=https://api.edenai.run/v3/chat/completions
  ```
</CodeGroup>

### Routing modes

**Static** — every request goes to Eden AI:

<CodeGroup>
  ```bash Static theme={null}
  export MODEL_PROVIDER=edenai
  ```
</CodeGroup>

**Tier-based (recommended for cost)** — set all four tiers to Eden AI models; Lynkr routes by request complexity:

<CodeGroup>
  ```bash Tier-based theme={null}
  export TIER_SIMPLE=edenai:mistral/mistral-small-2603
  export TIER_MEDIUM=edenai:openai/gpt-5-mini
  export TIER_HARD=edenai:anthropic/claude-sonnet-5
  export TIER_EXPERT=edenai:openai/gpt-5.5
  ```
</CodeGroup>

## Available Models

Use the `provider/model` format for any Eden AI model:

**OpenAI**

* `openai/gpt-5.5`
* `openai/gpt-5-mini`

**Anthropic**

* `anthropic/claude-sonnet-5`
* `anthropic/claude-haiku-4-5`

**Google**

* `google/gemini-2.5-pro`
* `google/gemini-3.5-flash`

**Mistral**

* `mistral/mistral-large-2512`
* `mistral/mistral-small-2603`

## Environment Variables

<CodeGroup>
  ```bash .env theme={null}
  EDENAI_API_KEY=your_api_key_here
  EDENAI_MODEL=openai/gpt-5-mini
  EDENAI_ENDPOINT=https://api.edenai.run/v3/chat/completions
  ```
</CodeGroup>

## Next Steps

* [Chat Completions](/docs/v3/llms/chat-completions) - Core LLM endpoint
* [List LLM Models](/docs/v3/llms/listing-models) - Browse available providers and models
* [OpenAI SDK (Python)](/docs/v3/integrations/openai-sdk-python) - Direct SDK usage
