# getPhoneLineRingPolicy

One line's own ring policy (its override of the org default), in getPhoneRouting's shape; null when the line follows the default. `phoneLineId` from getPhoneRouting or listCommunicationChannels.

- Call: `POST https://server.goliathdata.com/api/v1/call` with `{ "operationId": "getPhoneLineRingPolicy", "variables": {...} }`
- Scope: `READ`
- Type: query
- Idempotency: a read; rejects `Idempotency-Key`
- Rate-limited: no

## Variables

- `phoneLineId`: `ID!` (required)

## Response (data, an example)

```json
{
  "ringPolicyQuery": {
    "phoneLineRingPolicy": {
      "id": "<ID>",
      "humanStage": {
        "targetKind": "EXTERNAL",
        "ringSeconds": 0,
        "externalE164": "…",
        "specificUser": {
          "id": "<ID>",
          "name": "…"
        },
        "phoneLineIds": [
          "<ID>"
        ],
        "userGroupId": "<ID>",
        "ringAllTeamMembers": true,
        "areaCodeForwardingMap": "…",
        "ownerlessStep": {
          "targetKind": "EXTERNAL",
          "externalE164": "…",
          "specificUser": {
            "id": "<ID>",
            "name": "…"
          },
          "phoneLineIds": [
            "<ID>"
          ],
          "userGroupId": "<ID>"
        },
        "schedule": {
          "timezone": "…",
          "days": [
            {
              "day": "MON",
              "open": "…",
              "close": "…",
              "enabled": true
            }
          ]
        }
      },
      "aiStage": {
        "agents": [
          {
            "id": "<ID>",
            "name": "…",
            "canAnswerCalls": true,
            "cannotAnswerReason": "PAUSED"
          }
        ],
        "rotation": "SINGLE"
      }
    }
  }
}
```

## Example

```bash
curl https://server.goliathdata.com/api/v1/call \
  -H "Authorization: Bearer $GOLIATH_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "operationId": "getPhoneLineRingPolicy",
    "variables": {
      "phoneLineId": "<phoneLineId>"
    }
  }'
```
