---
title: "Calculate Expected Llm Usage For An Agent"
method: POST
path: "/v1/convai/agent/{agent_id}/llm-usage/calculate"
tags: ["Agents Platform"]
---

# Calculate Expected Llm Usage For An Agent

`POST /v1/convai/agent/{agent_id}/llm-usage/calculate`

Calculates expected number of LLM tokens needed for the specified agent.

## Path parameters

- `agent_id` string, required

## Headers

- `xi-api-key` string, nullable — Your API key. This is required by most endpoints to access our API programmatically. You can view your xi-api-key using the 'Profile' tab on the website.

## Request body

- LLMUsageCalculatorRequestModel
  - `prompt_length` integer, nullable — Length of the prompt in characters.
  - `number_of_pages` integer, nullable — Pages of content in pdf documents OR urls in agent's Knowledge Base.
  - `rag_enabled` boolean, nullable — Whether RAG is enabled.

## Response `200`

Successful Response

- LLMUsageCalculatorResponseModel
  - `llm_prices` LLMUsageCalculatorLLMResponseModel[], required
    - `llm` 'gpt-4o-mini' | 'gpt-4o' | 'gpt-4' | 'gpt-4-turbo' | 'gpt-4.1' | 'gpt-4.1-mini' | 'gpt-4.1-nano' | 'gpt-5' | 'gpt-5.1' | 'gpt-5.2' | 'gpt-5.2-chat-latest' | 'gpt-5.4' | 'gpt-5.4-mini' | 'gpt-5.4-nano' | 'gpt-5.5' | 'gpt-5.6-sol' | 'gpt-5.6-terra' | 'gpt-5.6-luna' | 'gpt-5-mini' | 'gpt-5-nano' | 'gpt-3.5-turbo' | 'gemini-1.5-pro' | 'gemini-1.5-flash' | 'gemini-2.0-flash' | 'gemini-2.0-flash-lite' | 'gemini-2.5-flash-lite' | 'gemini-2.5-flash' | 'gemini-3-pro-preview' | 'gemini-3-flash-preview' | 'gemini-3.1-pro-preview' | 'gemini-3.1-flash-lite-preview' | 'gemini-3.1-flash-lite' | 'gemini-3.5-flash' | 'gemini-3.5-flash-lite' | 'gemini-3.6-flash' | 'gemini-3.7-flash' | 'claude-sonnet-4-5' | 'claude-opus-4-7' | 'claude-opus-4-8' | 'claude-sonnet-4-6' | 'claude-sonnet-5' | 'claude-sonnet-4' | 'claude-haiku-4-5' | 'claude-3-7-sonnet' | 'claude-3-5-sonnet' | 'claude-3-5-sonnet-v1' | 'claude-3-haiku' | 'grok-beta' | 'custom-llm' | 'qwen3-4b' | 'qwen3-30b-a3b' | 'qwen36-35b-a3b' | 'qwen35-397b-a17b' | 'gpt-oss-20b' | 'gpt-oss-120b' | 'glm-45-air-fp8' | 'gemini-2.5-flash-preview-09-2025' | 'gemini-2.5-flash-lite-preview-09-2025' | 'gemini-2.5-flash-preview-05-20' | 'gemini-2.5-flash-preview-04-17' | 'gemini-2.5-flash-lite-preview-06-17' | 'gemini-2.0-flash-lite-001' | 'gemini-2.0-flash-001' | 'gemini-1.5-flash-002' | 'gemini-1.5-flash-001' | 'gemini-1.5-pro-002' | 'gemini-1.5-pro-001' | 'claude-sonnet-4@20250514' | 'claude-sonnet-4-5@20250929' | 'claude-haiku-4-5@20251001' | 'claude-3-7-sonnet@20250219' | 'claude-3-5-sonnet@20240620' | 'claude-3-5-sonnet-v2@20241022' | 'claude-3-haiku@20240307' | 'gpt-5-2025-08-07' | 'gpt-5.1-2025-11-13' | 'gpt-5.2-2025-12-11' | 'gpt-5.4-2026-03-05' | 'gpt-5.4-mini-2026-03-17' | 'gpt-5.4-nano-2026-03-17' | 'gpt-5.5-2026-04-23' | 'gpt-5-mini-2025-08-07' | 'gpt-5-nano-2025-08-07' | 'gpt-4.1-2025-04-14' | 'gpt-4.1-mini-2025-04-14' | 'gpt-4.1-nano-2025-04-14' | 'gpt-4o-mini-2024-07-18' | 'gpt-4o-2024-11-20' | 'gpt-4o-2024-08-06' | 'gpt-4o-2024-05-13' | 'gpt-4-0613' | 'gpt-4-0314' | 'gpt-4-turbo-2024-04-09' | 'gpt-3.5-turbo-0125' | 'gpt-3.5-turbo-1106' | 'watt-tool-8b' | 'watt-tool-70b', required
    - `price_per_minute` number, required

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.net/elevenlabs/apis/elevenlabs-api-documentation.md) · [All operations](https://skmtc.net/elevenlabs/apis/elevenlabs-api-documentation/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/elevenlabs/elevenlabs-api-documentation/revisions/b96b80bcbb83/schema)
