# Overview | PromptLens Docs

Test prompt changes against representative inputs, compare them with production, publish the version your application uses, and trace it once it ships.



<div className="docs-start-cards">
  <StartCard title="Run your first evaluation" href="/docs/quickstart" description="Build a ticket router, add five test cases, and check its answers with an exact-match evaluator." action="Start the quickstart" secondaryHref="/docs/how-it-works" secondaryAction="Understand the core concepts" />
</div>

## Explore by task [#explore-by-task]

<div className="docs-categories">
  <section className="docs-path-primary">
    <p className="docs-category-title">
      Evaluate and ship prompts
    </p>

    <p className="docs-category-description">
      Build test cases, compare a candidate with production, and publish the version that passes.
    </p>

    1. [Build a dataset](https://www.promptlens.io/docs/prompts/datasets)
    2. [Run a comparison](https://www.promptlens.io/docs/evaluations/comparisons)
    3. [Publish what passes](https://www.promptlens.io/docs/prompts/labels)

    <details className="docs-more-guides">
      <summary>
        More evaluation guides
      </summary>

      * [Create and edit prompts](https://www.promptlens.io/docs/prompts/editing)
      * [Import test cases](https://www.promptlens.io/docs/prompts/imports)
      * [Check structured output](https://www.promptlens.io/docs/prompts/structured-output)
      * [Score with LLM judges](https://www.promptlens.io/docs/prompts/llm-judges)
      * [Read results and coverage](https://www.promptlens.io/docs/evaluations/results)
      * [Take a prompt to production](https://www.promptlens.io/docs/production)
    </details>
  </section>

  <section>
    <p className="docs-category-title">
      Observe production
    </p>

    <p className="docs-category-description">
      Inspect model, tool, and retrieval calls from your running application.
    </p>

    * [Record your first trace](https://www.promptlens.io/docs/help/observability)
    * [Send traces over OpenTelemetry](https://www.promptlens.io/docs/reference/trace-ingestion)
    * [Understand trace content and retention](https://www.promptlens.io/docs/observability/trace-data)
  </section>

  <section>
    <p className="docs-category-title">
      Automate and integrate
    </p>

    <p className="docs-category-description">
      Retrieve prompts in code and run evaluations from CI, webhooks, or an assistant.
    </p>

    * [Retrieve prompts from your app](https://www.promptlens.io/docs/integrations/retrieval)
    * [Automate evaluations through the API](https://www.promptlens.io/docs/integrations/management-api)
    * [Receive results with webhooks](https://www.promptlens.io/docs/integrations/webhooks)
    * [Connect an AI assistant (MCP)](https://www.promptlens.io/docs/mcp)
  </section>
</div>

## Connect your application [#connect-your-application]

Your application retrieves the published prompt over HTTP and sends traces with standard OpenTelemetry exporters. There is no SDK to install.

<CodeBlockTabs defaultValue="Retrieve a prompt">
  <CodeBlockTabsList>
    <CodeBlockTabsTrigger value="Retrieve a prompt">
      Retrieve a prompt
    </CodeBlockTabsTrigger>

    <CodeBlockTabsTrigger value="Send traces">
      Send traces
    </CodeBlockTabsTrigger>
  </CodeBlockTabsList>

  <CodeBlockTab value="Retrieve a prompt">
    ```ts
    const { PROMPTLENS_PROMPT_ID: id, PROMPTLENS_RETRIEVAL_KEY: key } = process.env;
    const res = await fetch(`https://www.promptlens.io/api/v1/prompts/${id}`, {
      headers: { Authorization: `Bearer ${key}` },
    });
    if (!res.ok) throw new Error(`HTTP ${res.status}`);
    // Production messages and settings; call your provider with them.
    const prompt = await res.json();
    ```
  </CodeBlockTab>

  <CodeBlockTab value="Send traces">
    ```sh
    export OTEL_EXPORTER_OTLP_TRACES_ENDPOINT='https://www.promptlens.io/v1/traces'
    export OTEL_EXPORTER_OTLP_TRACES_PROTOCOL='http/json'
    export OTEL_EXPORTER_OTLP_TRACES_HEADERS='Authorization=Bearer%20YOUR_INGESTION_KEY'
    export OTEL_BSP_MAX_EXPORT_BATCH_SIZE=50
    export OTEL_SERVICE_NAME='ticket-router'
    ```
  </CodeBlockTab>
</CodeBlockTabs>

<p className="docs-code-links">
  [View full example in TypeScript and Python](https://www.promptlens.io/docs/integrations/typescript)

   

  [Trace ingestion reference](https://www.promptlens.io/docs/reference/trace-ingestion)
</p>

## More resources [#more-resources]

<div className="docs-directory">
  <section>
    <p className="docs-directory-title">
      Workspace administration
    </p>

    * [Connect a model provider](https://www.promptlens.io/docs/organization/providers)
    * [Fund model calls with credits](https://www.promptlens.io/docs/organization/credits)
    * [Invite members and assign roles](https://www.promptlens.io/docs/organization/members)
    * [Manage plans and billing](https://www.promptlens.io/docs/organization/billing)
  </section>

  <section>
    <p className="docs-directory-title">
      Troubleshooting
    </p>

    * [Fix common problems](https://www.promptlens.io/docs/troubleshooting)
    * [Cancel, retry, and review runs](https://www.promptlens.io/docs/evaluations/run-management)
    * [Check permissions and limits](https://www.promptlens.io/docs/reference/permissions-limits)
  </section>

  <section>
    <p className="docs-directory-title">
      Reference
    </p>

    * [Glossary](https://www.promptlens.io/docs/reference/concepts)
    * [Evaluator rules](https://www.promptlens.io/docs/reference/evaluators)
    * [API reference](https://www.promptlens.io/docs/api-reference)
    * [AI agent resources](https://www.promptlens.io/docs/integrations/agents)
  </section>
</div>
