Skip to navigation

Calculate expected LLM usage

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

Path parameters

agent_idstringRequired

Headers

xi-api-keystringOptional

Request

This endpoint expects an object.
prompt_lengthinteger or nullOptional
Length of the prompt in characters.
number_of_pagesinteger or nullOptional
Pages of content in pdf documents OR urls in agent's Knowledge Base.
rag_enabledboolean or nullOptional
Whether RAG is enabled.
service_tierenum or nullOptionalDefaults to standard

Service tier to price against. Only affects models that offer the tier; others fall back to their standard price.

Allowed values:

Response

Successful Response
llm_priceslist of objects

Errors

422
Unprocessable Entity Error