# setEmployeeDefaultAssignees

Who becomes the owner of a contact an AI employee works when the contact has no owner. `mode` decides what `assigneeUserIds` holds (teammate user ids, listTeamMembers): TEAM_RANDOM (the default, any active teammate), NONE (nobody) and SAME_AS_NEW_LEADS (the organization's lead routing) take `[]`; SPECIFIC_USER exactly one; ROUND_ROBIN_LIST two or more, in rotation order. A mismatched pair is refused.

- Call: `POST https://server.goliathdata.com/api/v1/call` with `{ "operationId": "setEmployeeDefaultAssignees", "variables": {...} }`
- Scope: `WRITE`
- Type: mutation
- Idempotency: honors `Idempotency-Key` (24 h)
- Rate-limited: no

## Variables

- `employeeId`: `ID!` (required)
- `mode`: `ContactAgentDefaultAssigneeMode!` (required, one of `TEAM_RANDOM`, `ROUND_ROBIN_LIST`, `SPECIFIC_USER`, `NONE`, `SAME_AS_NEW_LEADS`)
- `assigneeUserIds`: `[ID!]!` (required)

## Response (data, an example)

```json
{
  "aiEmployeesMutation": {
    "setContactAgentDefaultAssignees": {
      "id": "<ID>",
      "defaultAssignees": {
        "mode": "TEAM_RANDOM",
        "assigneeUserIds": [
          "<ID>"
        ]
      },
      "updatedAt": "2026-01-01T00:00:00.000Z"
    }
  }
}
```

## Example

```bash
curl https://server.goliathdata.com/api/v1/call \
  -H "Authorization: Bearer $GOLIATH_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{
    "operationId": "setEmployeeDefaultAssignees",
    "variables": {
      "employeeId": "<employeeId>",
      "mode": "TEAM_RANDOM",
      "assigneeUserIds": [
        "<assigneeUserIds>"
      ]
    }
  }'
```
