https://retellai.com/?utm_source=discord&utm_medium=seo logo
How it unit cost calculated
# ❓・ai-evy-support
s
@AI Evy How it unit cost calculated
a
Thanks for tagging me @Sanjay. I'll look through relevant sources and get back to you shortly.
### Answer Retell AI generally bills based on actual call duration, but there are specific exceptions that can affect your unit cost [(1) ]() : Rule 1: Minimum Duration for Dynamic Opening Messages - Applies to calls shorter than 10 seconds that use dynamic opening messages when AI speaks first - Minimum charge of 10 seconds applies - Example: A 6-second call with dynamic opening messages enabled will be billed for 10 seconds (4 seconds additional charge) Rule 2: LLM Price Scaling for Long Prompts - Applies when agents use more than 3,500 LLM tokens in their prompts - Duration is scaled proportionally based on token usage - Calculation: Scaling Factor = Prompt LLM Tokens ÷ 3,500 - Billed Duration = Original Duration × Scaling Factor (rounded up) - Example: A 60-second call using 4,200 tokens has a scaling factor of 1.2, resulting in 72 seconds billed (12 seconds additional charge) The token calculation includes global prompt, functions (tool descriptions) , state/node prompt, transcript between agent and user, and tool call history and results . Flex mode commonly triggers this rule as it compiles all node prompts, transitions, and tool descriptions into a single LLM context . Retell reports effective usage cost, not just the raw vendor rate, which includes overhead, rounding, and platform margin [(2) ]() .
​ To learn more, see the sources I considered: [[1] Exceptions to Our Per-Minute Pricing](https://docs.retellai.com/accounts/billing-exceptions) [[2] Discord message from @sergio_38714 on 2025-12-28](https://discord.com/channels/1186424376300679209/1186462578310910112/1454822306244333608) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
s
@AI Evy the unit price that comes in the call_analyzed web hook
a
Thanks for the follow-up, @Sanjay. I'll get back to you soon.
### Answer The
call_analyzed
webhook event includes a
call_cost
object with detailed pricing information [(1) ]() . Within this object, you'll find: -
product_costs
array: Contains individual product costs, where each item includes: - `product`: The product name (e.g., "elevenlabs_tts") [(2) ]() - `cost`: The actual cost for that product - `unit_price`: The price per unit for that specific product - `is_transfer_leg_cost`: Boolean indicating if this is from a transfer leg - **`total_duration_seconds`**: Total call duration in seconds - **`total_duration_unit_price`**: The unit price per second/minute for the overall call duration - **`combined_cost`**: The total combined cost of the call The unit price represents the per-unit rate charged for each product or service used during the call. For duration-based billing,
total_duration_unit_price
shows the rate per time unit .
​ To learn more, see the sources I considered: [[1] Webhook Overview](https://docs.retellai.com/features/webhook-overview) [[2] Create Web Call](https://docs.retellai.com/api-references/create-web-call) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.