See what scoring a goal costs

GET
/v1/agents/{id}/goal/quote

Prices scoring before you turn it on: maxUsd is the most one judgement can cost (a hard ceiling), typicalUsd is an estimate of a usual one. A conversation is judged at most maxScoresPerConversation times, and a goal read from a known outcome costs nothing (outcomeIsFree). Pass sampleRate to price a share of conversations. The ceiling is the longest goal text allowed; pass criteriaBytes (the UTF-8 size of a goal being edited) to price that text.

Requires an API key with the workspace:read scope.

Authorization

apiKey
headerAuthorizationBearer <token>

A secret API key from the dashboard (Developers → API keys): vl_live_…, or vl_test_… for test mode. Each operation says which scope the key needs.

Path Parameters

id*string

The agent id.

Query Parameters

sampleRate?number

The share of conversations to score, above 0 up to 1. Default: the goal's own.

Range0 < value <= 1
criteriaBytes?|

The UTF-8 byte size of the goal text being edited, at most 2000. Default: the longest a goal may be.

Range0 <= value <= 2000

Response Body

The most one judgement can cost, a typical one, and the limits

application/json
  1. response
maxUsd*number
typicalUsd*number
maxScoresPerConversation*integer
sampleRate*number
outcomeIsFree*boolean
Example Request
curl "https://api.vlayers.ai/v1/agents/$AGENT_ID/goal/quote?sampleRate=0.5" \  -H "Authorization: Bearer $VOICELAYER_API_KEY"
Example Response
{  "maxUsd": 0.0123,  "typicalUsd": 0.0031,  "maxScoresPerConversation": 3,  "sampleRate": 1,  "outcomeIsFree": true}