Canonical: https://weaveos.com/reference/langfuse/fetch-a-production-prompt

1. [Software capabilities](https://weaveos.com/reference)
2. /[Langfuse](https://weaveos.com/reference/langfuse)
3. /Fetch a production prompt from Langfuse

[![](https://weaveos.com/reference/logos/langfuse.png)Langfuse](https://weaveos.com/reference/langfuse)

# Fetch a production prompt from Langfuse

Fetch a Langfuse prompt by its production label through the Public API, or use the Python SDK to fetch and compile the prompt in your application.

Documentation reviewed November 27, 2026 · 2 methods with sources

## Ways to do it

1. [1API: GET /api/public/v2/prompts/{promptName}](https://weaveos.com/reference/langfuse/fetch-a-production-prompt#method-1)
2. [2SDK: langfuse.get\_prompt()](https://weaveos.com/reference/langfuse/fetch-a-production-prompt#method-2)

API

### GET /api/public/v2/prompts/{promptName}

Retrieve a prompt by name and label or by an explicit version through Langfuse’s Public API.

[Read source: Langfuse Public API prompt label resolution](https://langfuse.com/docs/prompt-management/features/prompt-version-control#label-resolution)

- Requirements

  A Langfuse host URL, a public key and secret key for Basic authentication, and a URL-encoded prompt name.

- Limitations

  Omitting label and version selects the production label. If that label is missing, the API returns 404. Supply either label or version.

Example shell

Copy

```
curl --fail "$LANGFUSE_BASE_URL/api/public/v2/prompts/order-status-reply?label=production" \
  -u "$LANGFUSE_PUBLIC_KEY:$LANGFUSE_SECRET_KEY"
```

SDK

### langfuse.get\_prompt()

Fetch a text prompt through the Python SDK and compile its variables before using the result.

[Read source: Langfuse prompt management quickstart](https://langfuse.com/docs/prompt-management/get-started#use-prompt-diy)

- Requirements

  The Langfuse Python SDK, a configured project key pair and host, and a named prompt with the production label.

- Limitations

  The SDK defaults to text prompts. Pass type="chat" to fetch a chat prompt.

Example text

Copy

```
from langfuse import get_client

langfuse = get_client()
prompt = langfuse.get_prompt("order-status-reply", label="production")
compiled = prompt.compile(customer_name="Taylor", order_id="EXAMPLE-100")
```

## More from Langfuse

[View all 1 Langfuse tasks](https://weaveos.com/reference/langfuse)
