> ## Documentation Index
> Fetch the complete documentation index at: https://docs.stateset.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Retrieve a voice session evaluation

> Fetches the quality evaluation record for a specific voice session.

Fetches the quality evaluation record for a specific voice session.

### Request body

`AutomationPayload`

<ParamField body="call_sid" type="string,null">
  Twilio call SID
</ParamField>

<ParamField body="customer_phone" type="string,null">
  Customer phone number in E.164 format
</ParamField>

<ParamField body="metadata" type="object">
  Optional workflow-specific metadata
</ParamField>

<ParamField body="reason" type="string,null">
  Human-readable workflow reason or note
</ParamField>

<ParamField body="session_id" type="string,null">
  Voice session identifier when the automation is tied to a persisted session
</ParamField>

<ParamField body="to" type="string,null">
  Destination phone number or escalation target
</ParamField>

### Response

`AutomationResponse`

<ResponseField name="error" type="string,null">
  Error message (present on failure)
</ResponseField>

<ResponseField name="ok" type="boolean" required>
  Whether the automation executed successfully
</ResponseField>

<ResponseField name="result" type="object">
  Result payload returned by the function (present on success)
</ResponseField>

### Status codes

| Code  | Meaning                                        |
| ----- | ---------------------------------------------- |
| `200` | Automation executed successfully               |
| `400` | Automation execution failed                    |
| `401` | Unauthorized - invalid or missing bearer token |
| `500` | Internal server error                          |

<RequestExample>
  ```bash cURL theme={null}
  curl --request POST \
    --url 'https://api.voice.stateset.com/api/v1/automations/voice/get-eval' \
    --header 'Authorization: Bearer YOUR_API_KEY' \
    --header 'Content-Type: application/json' \
    --data '{
    "call_sid": "CA1234567890abcdef1234567890abcdef",
    "customer_phone": "+15555555678",
    "metadata": {
      "order_id": "ORD-12345"
    },
    "reason": "customer requested a human agent",
    "session_id": "550e8400-e29b-41d4-a716-446655440000"
  }'
  ```
</RequestExample>

<ResponseExample>
  ```json 200 theme={null}
  {
    "ok": true,
    "result": {
      "message_sid": "SM1234567890abcdef",
      "queued_at": "2026-05-14T17:42:09Z"
    }
  }
  ```
</ResponseExample>
