Read help desk history
Read the business's solved help desk tickets, newest first, so the agent can learn how their team answers customers. It reads the help desk app connected to THIS agent (list_agent_connections; today zendesk), with read-only actions only, and returns `tickets`, each `{ subject, month, tags, messages }` where every message is `{ from: "customer" | "team", staff, text }` and `staff` is the team member's first name. Only public replies are returned, never internal notes, and only tickets with a customer message and a team reply. Personal details are removed before anything is returned: customer names and email sign-off blocks become [name], and emails, phone numbers, street addresses, links and any number of four or more digits (orders, postcodes, cards) become [email], [phone], [address], [link] and [number]. Check the text yourself before you copy any of it anywhere. `withoutAnAnswer` counts tickets left out because they hold no customer message or no team reply, and `unreadable` counts tickets whose replies the app would not return, with `unreadableReason`. Page through with `page` until `hasMore` is false. Use it to write knowledge sources from the team's real answers: one topic per source, written as the customer's question and the team's answer in the business's own voice, never a copy of a ticket. Only a member who can edit the agent can read it.
Authorization
bearerAuth A personal access token from Settings > API tokens.
In: header
Header Parameters
A key you choose, such as a UUID, that makes this POST safe to retry. Within 24 hours the same key and request answers with the first successful answer and runs nothing, the same key with a different request answers 422 idempotency_key_reused, and a key whose request is still running answers 409 idempotency_key_in_use. A failed request keeps nothing, so the same key runs it again.
1 <= length <= 255Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
curl -X POST "https://example.com/operations/read_help_desk_history" \ -H "Content-Type: application/json" \ -d '{ "agent": "string" }'{}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"code": "string",
"errors": [
{
"path": "string",
"message": "string"
}
],
"estimate": {},
"retryAfterSeconds": 0
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"code": "string",
"errors": [
{
"path": "string",
"message": "string"
}
],
"estimate": {},
"retryAfterSeconds": 0
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"code": "string",
"errors": [
{
"path": "string",
"message": "string"
}
],
"estimate": {},
"retryAfterSeconds": 0
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"code": "string",
"errors": [
{
"path": "string",
"message": "string"
}
],
"estimate": {},
"retryAfterSeconds": 0
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"code": "string",
"errors": [
{
"path": "string",
"message": "string"
}
],
"estimate": {},
"retryAfterSeconds": 0
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"code": "string",
"errors": [
{
"path": "string",
"message": "string"
}
],
"estimate": {},
"retryAfterSeconds": 0
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"code": "string",
"errors": [
{
"path": "string",
"message": "string"
}
],
"estimate": {},
"retryAfterSeconds": 0
}Read a building guide POST
Return one of the guides for building a good agent, in full, as markdown. Read the right one before you write config: 'build-an-agent' before a new build, 'system-prompt' and 'voice-craft' before update_system_prompt, edit_system_prompt or set_tool_description, and 'test-an-agent' before you write or run tests. The guides: 'build-an-agent' (building a new agent), 'system-prompt' (writing prompts and tool descriptions), 'voice-craft' (voice craft), 'test-an-agent' (testing an agent until it's ready). The same text is served as the vai://guides resources and as pages on the public docs.
Re-analyse call POST
Run the post-call analysis again on a call that already has one, with today's analysis prompt, and replace the call's outcome, failure reason, summary and facts. Use it after the analysis changes, to re-grade calls it judged wrong. It sends nothing: a call's first analysis is what sends its alerts, webhooks and follow-ups, so a call with no analysis yet is refused. Returns the outcome and failure reason before and after. Costs one analysis's tokens.