Design measurement before deployment
Start with the business outcome, then choose the record that represents it:- Use a conversation when each completed interaction is one observation.
- Use a Task attempt when unanswered, failed, or delivery-only attempts belong in the population.
- Use one terminal Task outcome when a retry sequence should count once rather than once per attempt.
null. Test successful, negative, and inconclusive conversations before using that field in a metric.
Keep the population and denominator explicit. A conversion rate over completed conversations, a
contact rate over all attempts, and a final yield over Tasks answer different questions even when
they use the same Agent.
Query bounded logs
UseGET /api/v2/logs with targetAccountId and a bounded start and end range for routine analysis. Select only required fields and filters. Use CSV for large exports; follow pagination for JSON results.
Log filters support the comparison options documented in OpenAPI. Request field metadata when building a new integration rather than assuming every account produces the same custom reporting fields.
Expand a conversation
A log, Task attempt, or Contact communication entry can include a conversation reference withroomId and message uuid.
- Read one complete conversation with
/api/v2/conversation/{roomId}/{uuid}. - Read room messages with
/api/v2/messages/{roomId}. - Use the batch conversation route for a bounded set of lookups.
Build an incident packet
For a customer-impacting event:- Query the exact time window and account scope.
- Identify affected Task, room, conversation, and Agent IDs.
- Expand the relevant conversations.
- Establish a timeline from source timestamps.
- Separate observed impact from inferred cause.
- Recommend a bounded remediation and verification step.
Calculate comparable metrics
UsePOST /api/v2/logs/timeSeries for aggregate and time-bucketed results. Define the population, denominator, formula, aggregation, scaling, and time range explicitly.
For reporting-field rates, decide how null values affect the denominator. For retry workflows, decide whether the metric measures attempts or one terminal outcome per Task. Filter Task attempts explicitly when attempts without conversations belong in the population.
Validate a metric against live data before saving it to organization dashboard settings. Preserve unrelated stored metrics when updating the settings array.
Use this sequence for a new dashboard metric:
- Query a bounded sample of the underlying logs and verify the expected records and fields.
- Submit the proposed definition to
POST /api/v2/logs/timeSeries. - Check the metric value together with
eventCount; a rate without its denominator is incomplete. - Compare the result with the source records, including null and failed-attempt behavior.
- Save the verified definition in the organization account’s
settings.metricsarray while preserving unrelated metrics, then re-read the account.
minimumSampleSize when small groups or time buckets should not produce a displayed result.
For an Agent experiment, filter results by experiments.id and experiments.variant, and keep the
metric definition, audience, channel mix, and time range comparable across variants.
For metric definitions, Task-outcome filters, and incident workflow details, use the Vida API Skill.