langfuse-api
Interact with the Langfuse API. Use when user wants to query traces, fetch prompts, create datasets, manage scores, or do anything else via the Langfuse REST API.
Works with
---
name: langfuse-api
description: Interact with the Langfuse API. Use when user wants to query traces, fetch prompts, create datasets, manage scores, or do anything else via the Langfuse REST API.
license: MIT
---
# Langfuse API
Help users interact with Langfuse via the REST API.
## When to Use
- User wants to query or export traces
- User wants to manage prompts programmatically
- User wants to create/update datasets or dataset items
- User wants to fetch or create scores
- User wants to manage projects or API keys
- Any other Langfuse API interaction
## Workflow
### 1. Check Credentials
Before making any API call, verify credentials are available:
```bash
echo $LANGFUSE_PUBLIC_KEY # pk-...
echo $LANGFUSE_SECRET_KEY # sk-...
echo $LANGFUSE_HOST # https://cloud.langfuse.com (or self-hosted/EU/US URL)
```
If not set, ask user:
- "I need your Langfuse API credentials. You can find them in Settings → API Keys in the Langfuse UI."
- "Which Langfuse host are you using? (cloud.langfuse.com, us.cloud.langfuse.com, eu.cloud.langfuse.com, or self-hosted URL)"
### 2. Fetch Fresh API Reference
**Always fetch the current API reference before making calls.** The API may have new endpoints or changed parameters.
Fetch: https://api.reference.langfuse.com
Look for the specific endpoint needed for the user's request. The reference contains:
- All available endpoints
- Required and optional parameters
- Request/response schemas
- Authentication details
### 3. Make the API Call
**Authentication:** Basic Auth with `LANGFUSE_PUBLIC_KEY` as username and `LANGFUSE_SECRET_KEY` as password.
**Base URL:** `{LANGFUSE_HOST}/api/public`
Example:
```bash
curl -X GET "${LANGFUSE_HOST}/api/public/traces" \
-u "${LANGFUSE_PUBLIC_KEY}:${LANGFUSE_SECRET_KEY}" \
-H "Content-Type: application/json"
```
### 4. Handle Pagination
Many endpoints return paginated results. Check for:
- `page` and `limit` parameters
- `meta.totalItems` and `meta.totalPages` in response
- Iterate if user needs all results
## Common Use Cases
| User Request | Endpoint to Look Up |
|--------------|---------------------|
| "Get my recent traces" | GET /traces |
| "Export traces from last week" | GET /traces with date filters |
| "Fetch a specific prompt" | GET /prompts/{name} |
| "Create a dataset" | POST /datasets |
| "Add items to dataset" | POST /dataset-items |
| "Get scores for a trace" | GET /scores with traceId filter |
| "List all prompts" | GET /prompts |
## Important Notes
- **Always fetch fresh docs** - Don't rely on cached knowledge of the API
- **Check rate limits** - The API has rate limits; handle 429 responses
- **Validate responses** - Check for errors before processing data
- **Large exports** - For bulk data, use pagination and consider streaming to file
## OpenAPI Spec
For programmatic access or generating types:
```
https://cloud.langfuse.com/generated/api/openapi.yml
```More API Design skills
lark-event
larksuite/cli
Lark/Feishu real-time event listening / subscribing / consuming: stream events as NDJSON via `lark-cli event consume <EventKey>` (covers IM messages/reactions/chat changes, Approval status changes, Task updates, VC meeting started/joined/ended, Minutes generated, Whiteboard updated, etc.). Use for Lark bots, real-time message processing, long-running subscribers, streaming webhook/push handlers. Supports `--max-events` / `--timeout` bounded runs and a stderr ready-marker contract — designed for AI agents running as subprocesses.
lark-contact
larksuite/cli
飞书 / Lark 通讯录:按姓名 / 邮箱解析成 open_id,或按 open_id 反查姓名 / 部门 / 邮箱 / 联系方式 / 个人状态 / 签名,以及按关键词搜索当前用户可见的机器人 / 智能体(agent)。当用户提到一个名字要下一步发消息 / 排日程,或拿到 open_id 想查具体信息时使用。不负责部门树遍历、按部门列员工、组织架构图,这类需求走原生 OpenAPI。
lark-openapi-explorer
larksuite/cli
飞书/Lark 原生 OpenAPI 探索:从官方文档库中挖掘未经 CLI 封装的原生 OpenAPI 接口。当用户的需求无法被现有 lark-* skill 或 lark-cli 已注册命令满足,需要查找并调用原生飞书 OpenAPI 时使用。

