# Dialpad

> Manage calls and contacts, send messages, and look up users, offices and contact centers.

App · 25 actions. Web page: https://docs.lodol.com/docs/integrations/dialpad

## Actions

### Add call labels

Add labels to a determined call id, keeping any labels already on the call. A label already present is not duplicated. Labels cannot be removed through this endpoint.

**Inputs**

- Call id (`call_id`, text, required): The call's id
- Labels (`labels`, list): The list of labels to attach to the call

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "admin_call_recording_share_links": [],
    "call_id": 1,
    "call_recording_share_links": [],
    "contact": {
      "email": "example",
      "id": "example",
      "name": "example",
      "phone": "example",
      "type": "example"
    },
    "csat_recording_urls": [],
    "csat_score": "example",
    "csat_transcriptions": [],
    "custom_data": "example",
    "date_connected": 1,
    "date_ended": 1,
    "date_rang": 1,
    "date_started": 1,
    "direction": "example",
    "duration": 1.0,
    "entry_point_call_id": 1,
    "entry_point_target": {
      "email": "example",
      "id": "example",
      "name": "example",
      "phone": "example",
      "type": "example"
    },
    "event_timestamp": 1,
    "external_number": "example",
    "group_id": "example",
    "internal_number": "example",
    "is_transferred": false,
    "labels": [],
    "master_call_id": 1,
    "mos_score": 1.0,
    "operator_call_id": 1,
    "proxy_target": {
      "email": "example",
      "id": "example",
      "name": "example",
      "phone": "example",
      "type": "example"
    },
    "recording_details": [],
    "routing_breadcrumbs": [],
    "screen_recording_urls": [],
    "state": "example",
    "target": {
      "email": "example",
      "id": "example",
      "name": "example",
      "phone": "example",
      "type": "example"
    },
    "total_duration": 1.0,
    "transcription_text": "example",
    "voicemail_link": "example",
    "voicemail_recording_id": "example",
    "voicemail_share_link": "example",
    "was_recorded": false
  }
}
```

### Create contact

Create a new contact.

**Inputs**

- Company name (`company_name`, text): [single-line only] The contact's company name.
- Emails (`emails`, list): The contact's emails. The first email in the list is the contact's primary email.
- Extension (`extension`, text): The contact's extension number.
- First name (`first_name`, text, required): [single-line only] The contact's first name.
- Job title (`job_title`, text): [single-line only] The contact's job title.
- Last name (`last_name`, text, required): [single-line only] The contact's last name.
- Owner id (`owner_id`, text): The id of the user who will own this contact. If provided, a local contact will be created for this user. Otherwise, the contact will be created as a shared contact in your company.
- Phones (`phones`, list): The contact's phone numbers. The phone number must be in e164 format. The first number in the list is the contact's primary phone.
- Urls (`urls`, list): A list of websites associated with or belonging to this contact.

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "company_name": "example",
    "display_name": "example",
    "emails": [],
    "extension": "example",
    "first_name": "example",
    "id": "example",
    "job_title": "example",
    "last_name": "example",
    "owner_id": "example",
    "phones": [],
    "primary_email": "example",
    "primary_phone": "example",
    "trunk_group": "example",
    "type": "lead",
    "urls": []
  }
}
```

### Create webhook

Create a new webhook for your company.

**Inputs**

- Hook url (`hook_url`, text, required): The webhook's URL. Triggered events will be sent to the url provided here.
- Secret (`secret`, text): [single-line only] Webhook's signature secret that's used to confirm the validity of the request.

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "hook_url": "example",
    "id": 1,
    "signature": {
      "algo": "example",
      "secret": "example",
      "type": "example"
    }
  }
}
```

### Delete contact

Delete a contact by id.

**Inputs**

- Contact (`contact_id`, text, required): The contact's id.

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "company_name": "example",
    "display_name": "example",
    "emails": [],
    "extension": "example",
    "first_name": "example",
    "id": "example",
    "job_title": "example",
    "last_name": "example",
    "owner_id": "example",
    "phones": [],
    "primary_email": "example",
    "primary_phone": "example",
    "trunk_group": "example",
    "type": "lead",
    "urls": []
  }
}
```

### Delete webhook

Delete a webhook by id.

**Inputs**

- Webhook id (`webhook_id`, text, required): The webhook's ID, which is generated after creating a webhook successfully.

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "hook_url": "example",
    "id": 1,
    "signature": {
      "algo": "example",
      "secret": "example",
      "type": "example"
    }
  }
}
```

### Get call

Get call status and detailed information for a concluded call, including direction, duration, recording URLs, CSAT scores, voicemail metadata, and transcription text. Also returns routing_breadcrumbs, which is only populated for calls routed through a customer-configured API Call Router and is empty for every other call.

**Inputs**

- Call id (`call_id`, text, required): The call's id.

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "admin_call_recording_share_links": [],
    "call_id": 1,
    "call_recording_share_links": [],
    "contact": {
      "email": "example",
      "id": "example",
      "name": "example",
      "phone": "example",
      "type": "example"
    },
    "csat_recording_urls": [],
    "csat_score": "example",
    "csat_transcriptions": [],
    "custom_data": "example",
    "date_connected": 1,
    "date_ended": 1,
    "date_rang": 1,
    "date_started": 1,
    "direction": "example",
    "duration": 1.0,
    "entry_point_call_id": 1,
    "entry_point_target": {
      "email": "example",
      "id": "example",
      "name": "example",
      "phone": "example",
      "type": "example"
    },
    "event_timestamp": 1,
    "external_number": "example",
    "group_id": "example",
    "internal_number": "example",
    "is_transferred": false,
    "labels": [],
    "master_call_id": 1,
    "mos_score": 1.0,
    "operator_call_id": 1,
    "proxy_target": {
      "email": "example",
      "id": "example",
      "name": "example",
      "phone": "example",
      "type": "example"
    },
    "recording_details": [],
    "routing_breadcrumbs": [],
    "screen_recording_urls": [],
    "state": "example",
    "target": {
      "email": "example",
      "id": "example",
      "name": "example",
      "phone": "example",
      "type": "example"
    },
    "total_duration": 1.0,
    "transcription_text": "example",
    "voicemail_link": "example",
    "voicemail_recording_id": "example",
    "voicemail_share_link": "example",
    "was_recorded": false
  }
}
```

### Get call ai recap

Get the Ai Recap for a call.

**Inputs**

- Call id (`call_id`, text, required): The call's id.
- Summary format (`summary_format`, text): The format of the summary to retrieve e.g. short, medium, long, bullet. One of: `bullet`, `long`, `medium`, `short`. Default: `medium`.

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "action_items": [],
    "call_id": "example",
    "date_created": 1,
    "date_modified": 1,
    "disposition": {
      "content": "example",
      "edited": false,
      "format": "example",
      "id": "example",
      "target_short_key": "example"
    },
    "is_internal_call": false,
    "purposes": [],
    "source": "example",
    "summary": {
      "content": "example",
      "date_text_last_edited": 1,
      "edited": false,
      "format": "example",
      "id": "example",
      "null_summary": false,
      "target_short_key": "example"
    }
  }
}
```

### Get call center

Get a call center by id.

**Inputs**

- Call center (`call_center_id`, text, required): The call center's id.

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "advanced_settings": {
      "auto_call_recording": {
        "allow_pause_recording": false,
        "call_recording_inbound": false,
        "call_recording_outbound": false
      },
      "max_wrap_up_seconds": 1
    },
    "alerts": {
      "cc_service_level": 1,
      "cc_service_level_seconds": 1
    },
    "availability_status": "closed",
    "country": "example",
    "first_action": "menu",
    "friday_hours": [],
    "group_description": "example",
    "hold_queue": {
      "allow_queue_callback": false,
      "announce_estimated_wait_time": false,
      "announce_position": false,
      "announcement_interval_seconds": 1,
      "estimated_wait_time_max": 1,
      "max_hold_count": 1,
      "max_hold_seconds": 1,
      "queue_callback_dtmf": "example",
      "queue_callback_threshold": 1,
      "queue_escape_dtmf": "example",
      "stay_in_queue_after_closing": false,
      "unattended_queue": false
    },
    "hours_on": false,
    "id": 1,
    "is_digital": false,
    "monday_hours": [],
    "name": "example",
    "no_operators_action": "ai_agent",
    "office_id": 1,
    "phone_numbers": [],
    "ring_seconds": 1,
    "routing_options": {
      "closed": {
        "action": "ai_agent",
        "action_target_id": 1,
        "action_target_type": "callcenter",
        "dtmf": [],
        "operator_routing": "autopark",
        "try_dial_operators": false
      },
      "open": {
        "action": "ai_agent",
        "action_target_id": 1,
        "action_target_type": "callcenter",
        "dtmf": [],
        "operator_routing": "autopark",
        "try_dial_operators": false
      }
    },
    "saturday_hours": [],
    "state": "active",
    "sunday_hours": [],
    "thursday_hours": [],
    "timezone": "example",
    "tuesday_hours": [],
    "voice_intelligence": {
      "allow_pause": false,
      "auto_start": false
    },
    "voicemail_notification_emails": [],
    "wednesday_hours": []
  }
}
```

### Get call center status

Get live operational metrics for a call center: availability status, available operator count, queued calls, longest wait time, and on-duty operator count.

**Inputs**

- Call center (`call_center_id`, text, required): The call center's id.

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "availability": {
      "name": "example",
      "status": "example"
    },
    "capacity": 1,
    "longest_call_wait_time": 1,
    "on_duty_operators": 1,
    "pending": 1
  }
}
```

### Get company

Get company information: name, primary office, admin contact, plan state and billing address.

**Inputs**: None.

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "account_type": "enterprise",
    "admin_email": "example",
    "country": "example",
    "domain": "example",
    "id": 1,
    "name": "example",
    "office_count": 1,
    "settings": {
      "allow_ai_training": false,
      "has_callai": false
    },
    "state": "active"
  }
}
```

### Get contact

Get a contact by id. Currently, only contacts of type shared and local can be retrieved by this API.

**Inputs**

- Contact (`contact_id`, text, required): The contact's id.

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "company_name": "example",
    "display_name": "example",
    "emails": [],
    "extension": "example",
    "first_name": "example",
    "id": "example",
    "job_title": "example",
    "last_name": "example",
    "owner_id": "example",
    "phones": [],
    "primary_email": "example",
    "primary_phone": "example",
    "trunk_group": "example",
    "type": "lead",
    "urls": []
  }
}
```

### Get department

Get a department by id.

**Inputs**

- Department id (`department_id`, text, required): The department's id.

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "auto_call_recording": false,
    "availability_status": "closed",
    "country": "example",
    "first_action": "menu",
    "friday_hours": [],
    "group_description": "example",
    "hold_queue": {
      "allow_queuing": false,
      "max_hold_count": 1,
      "max_hold_seconds": 1
    },
    "hours_on": false,
    "id": 1,
    "monday_hours": [],
    "name": "example",
    "no_operators_action": "ai_agent",
    "office_id": 1,
    "phone_numbers": [],
    "ring_seconds": 1,
    "routing_options": {
      "closed": {
        "action": "ai_agent",
        "action_target_id": 1,
        "action_target_type": "callcenter",
        "dtmf": [],
        "operator_routing": "autopark",
        "try_dial_operators": false
      },
      "open": {
        "action": "ai_agent",
        "action_target_id": 1,
        "action_target_type": "callcenter",
        "dtmf": [],
        "operator_routing": "autopark",
        "try_dial_operators": false
      }
    },
    "saturday_hours": [],
    "state": "active",
    "sunday_hours": [],
    "thursday_hours": [],
    "timezone": "example",
    "tuesday_hours": [],
    "voice_intelligence": {
      "allow_pause": false,
      "auto_start": false
    },
    "voicemail_notification_emails": [],
    "wednesday_hours": []
  }
}
```

### Get office

Get an office by id.

**Inputs**

- Office (`office_id`, text, required): The office's id.

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "availability_status": "closed",
    "country": "example",
    "e911_address": {
      "address": "example",
      "address2": "example",
      "city": "example",
      "country": "example",
      "state": "example",
      "zip": "example"
    },
    "first_action": "menu",
    "friday_hours": [],
    "id": 1,
    "is_primary_office": false,
    "monday_hours": [],
    "name": "example",
    "no_operators_action": "ai_agent",
    "office_id": 1,
    "office_settings": {
      "allow_device_guest_login": false,
      "block_caller_id_disabled": false,
      "bridged_target_recording_allowed": false,
      "disable_desk_phone_self_provision": false,
      "disable_ivr_voicemail": false,
      "no_recording_message_on_user_calls": false,
      "set_caller_id_disabled": false
    },
    "phone_numbers": [],
    "ring_seconds": 1,
    "routing_options": {
      "closed": {
        "action": "ai_agent",
        "action_target_id": 1,
        "action_target_type": "callcenter",
        "dtmf": [],
        "operator_routing": "autopark",
        "try_dial_operators": false
      },
      "open": {
        "action": "ai_agent",
        "action_target_id": 1,
        "action_target_type": "callcenter",
        "dtmf": [],
        "operator_routing": "autopark",
        "try_dial_operators": false
      }
    },
    "saturday_hours": [],
    "state": "active",
    "sunday_hours": [],
    "thursday_hours": [],
    "timezone": "example",
    "tuesday_hours": [],
    "voicemail_notification_emails": [],
    "wednesday_hours": []
  }
}
```

### Get user

Get a user by id. Returns identity (name, email, job_title), contact details (phone_numbers, extension), status (state, do_not_disturb, is_on_duty, on_duty_status), license type, office membership (office_id, group_details), and voicemail settings.

**Inputs**

- Dialpad user (`dialpad_user_id`, text, required): The user's id. ('me' can be used if you are using a user level API key)

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "admin_office_ids": [],
    "company_id": 1,
    "country": "example",
    "date_active": "example",
    "date_added": "example",
    "date_first_login": "example",
    "date_last_login": "example",
    "display_name": "example",
    "do_not_disturb": false,
    "duty_status_reason": "example",
    "duty_status_started": "example",
    "emails": [],
    "extension": "example",
    "first_name": "example",
    "forwarding_numbers": [],
    "group_details": [],
    "id": 1,
    "image_url": "example",
    "international_dialing_enabled": false,
    "is_admin": false,
    "is_available": false,
    "is_on_duty": false,
    "is_online": false,
    "is_super_admin": false,
    "job_title": "example",
    "language": "example",
    "last_name": "example",
    "license": "admins",
    "location": "example",
    "muted": false,
    "office_id": 1,
    "on_duty_started": "example",
    "on_duty_status": "available",
    "onboarding_completed": false,
    "phone_numbers": [],
    "remote_service": "example",
    "session_type": "call",
    "state": "active",
    "status_message": "example",
    "timezone": "example",
    "voicemail": {
      "is_default_voicemail": false,
      "name": "example",
      "voicemail_notifications_enabled": false
    }
  }
}
```

### List call centers

Get all the call centers for the company.

**Inputs**

- Cursor (`cursor`, text): A token used to return the next page of a previous request. Use the cursor provided in the previous response.
- Include alerts (`include_alerts`, true/false): When false, omits cc_service_level alert settings from the response. Reduces Datastore reads for callers that do not need alert thresholds. Default: `true`.
- Office (`office_id`, text): search call center by office.
- Name search (`name_search`, text): search call centers by name or search by the substring of the name. If input example is 'Cool', output example can be a list of call centers whose name contains the string 'Cool' - ['Cool call center 1', 'Cool call center 2049']

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "cursor": "example",
    "items": []
  }
}
```

### List calls

Get a paginated list of calls matching the specified filter parameters in reverse-chronological order by call start time (i.e. recent calls first)

**Inputs**

- Cursor (`cursor`, text): A token used to return the next page of a previous request. Use the cursor provided in the previous response.
- Include anonymized (`include_anonymized`, true/false): If set to true, includes call records that have been anonymized (e.g., calls associated with deleted users). Defaults to false. Default: `false`.
- Started after (`started_after`, date and time): Only includes calls that started more recently than the specified timestamp. (UTC ms-since-epoch timestamp)
- Started before (`started_before`, date and time): Only includes calls that started prior to the specified timestamp. (UTC ms-since-epoch timestamp)
- Target id (`target_id`, text): The ID of a target to filter against. Defaults to the whole company for company-level API keys and company admins, and to the authenticated user for all other user-level API keys.
- Target type (`target_type`, text): The target type associated with the target ID. Must be provided whenever target_id is provided. One of: `callcenter`, `callrouter`, `channel`, `coachinggroup`, `coachingteam`, `department`, `office`, `room`, `staffgroup`, `unknown`, `user`.

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "cursor": "example",
    "items": []
  }
}
```

### List contacts

Get company shared contacts, or user's local contacts if owner_id is provided.

**Inputs**

- Name (`name`, text): A search string to filter contacts by name.
- Cursor (`cursor`, text): A token used to return the next page of a previous request. Use the cursor provided in the previous response.
- Include local (`include_local`, true/false): If set to True company local contacts will be included. default False. Default: `false`.
- Owner id (`owner_id`, text): The id of the user who owns the contact.

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "cursor": "example",
    "items": []
  }
}
```

### List departments

Get all the departments for an office.

**Inputs**

- Cursor (`cursor`, text): A token used to return the next page of a previous request. Use the cursor provided in the previous response.
- Office (`office_id`, text, required): The office's id.

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "cursor": "example",
    "items": []
  }
}
```

### List offices

Get the offices in the company. The result set depends on the caller: company admins get every office, while a user-level key gets only the offices that user belongs to.

**Inputs**

- Cursor (`cursor`, text): A token used to return the next page of a previous request. Use the cursor provided in the previous response.
- Active only (`active_only`, true/false): Whether we only return active offices.

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "cursor": "example",
    "items": []
  }
}
```

### List users

Get company users, optionally filtering by email.

**Inputs**

- Cursor (`cursor`, text): A token used to return the next page of a previous request. Use the cursor provided in the previous response.
- First name (`first_name`, text): Filter results by first name prefix (e.g. "jo" matches "John", "Jose"). Uses Elasticsearch prefix matching. Cannot be combined with email or number.
- Last name (`last_name`, text): Filter results by last name prefix (e.g. "sm" matches "Smith", "Smythe"). Uses Elasticsearch prefix matching. Cannot be combined with email or number.
- State (`state`, text): Filter results by the specified user state (e.g. active, suspended, deleted). One of: `active`, `all`, `cancelled`, `deleted`, `pending`, `suspended`. Default: `active`.
- Company admin (`company_admin`, true/false): If provided, filter results by the specified value to return only company admins or only non-company admins.
- Email (`email`, text): The user's email.
- Number (`number`, text): The user's phone number, in e164 format.
- Forwarding number (`forwarding_number`, true/false): When true, `number` is also matched against the forwarding numbers users have added to their profile, instead of only the numbers assigned to them by Dialpad. Only applies together with `number`.

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "cursor": "example",
    "items": []
  }
}
```

### List webhooks

Get a list of all the webhooks that are associated with the company.

**Inputs**

- Cursor (`cursor`, text): A token used to return the next page of a previous request. Use the cursor provided in the previous response.

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "cursor": "example",
    "items": []
  }
}
```

### Send sms

Send an SMS message to a phone number or to a Dialpad channel on behalf of a user.

**Inputs**

- Channel hashtag (`channel_hashtag`, text): [single-line only] The hashtag of the channel which should receive the SMS.
- From number (`from_number`, text): The sender's phone number. The number must be assigned to a user or a user group. It will override user_id and sender_group_id.
- Infer country code (`infer_country_code`, true/false): If true, to_numbers will be assumed to be from the specified user's country, and the E164 format requirement will be relaxed. Default: `false`.
- Media (`media`, text): Base64-encoded media attachment (will cause the message to be sent as MMS). (Max 500 KiB raw file size)
- Sender group id (`sender_group_id`, text): The ID of an office, department, or call center that the User should send the message on behalf of.
- Sender group type (`sender_group_type`, text): The sender group's type (i.e. office, department, or callcenter). One of: `callcenter`, `department`, `office`.
- Text (`text`, text): The contents of the message that should be sent.
- To numbers (`to_numbers`, list): Up to 10 E164-formatted phone numbers who should receive the SMS.
- Dialpad user (`dialpad_user_id`, text): The ID of the user who should be the sender of the SMS.

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "contact_id": "example",
    "created_date": "example",
    "device_type": "android",
    "direction": "inbound",
    "from_number": "example",
    "id": 1,
    "message_delivery_result": "accepted",
    "message_status": "failed",
    "target_id": 1,
    "target_type": "callcenter",
    "text": "example",
    "to_numbers": [],
    "user_id": 1
  }
}
```

### Start call

Initiates an outbound call to ring all devices (or a single specified device).

**Inputs**

- Custom data (`custom_data`, text): Extra data to associate with the call. This will be passed through to any subscribed call events.
- Device id (`device_id`, text): The device's id.
- Group id (`group_id`, text): The ID of a group that will be used to initiate the call.
- Group type (`group_type`, text): The type of a group that will be used to initiate the call. One of: `callcenter`, `department`, `office`.
- Is consult (`is_consult`, true/false): Enables the creation of a second call. If there is an ongoing call, it puts it on hold. Default: `false`.
- Outbound caller id (`outbound_caller_id`, text): The e164-formatted number shown to the call recipient (or "blocked"). If set to "blocked", the recipient will receive a call from "unknown caller". The number can be the caller's number, or the caller's group number if the group is provided, or the caller's company reserved number.
- Phone number (`phone_number`, text, required): The e164-formatted number to call.
- Dialpad user (`dialpad_user_id`, text, required): The id of the user who should make the outbound call.

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "call_id": 1
  }
}
```

### Update contact

Update the provided fields for an existing contact.

**Inputs**

- Contact (`contact_id`, text, required): The contact's id.
- Company name (`company_name`, text): [single-line only] The contact's company name.
- Emails (`emails`, list): The contact's emails. The first email in the list is the contact's primary email.
- Extension (`extension`, text): The contact's extension number.
- First name (`first_name`, text): [single-line only] The contact's first name.
- Job title (`job_title`, text): [single-line only] The contact's job title.
- Last name (`last_name`, text): [single-line only] The contact's last name.
- Phones (`phones`, list): The contact's phone numbers. The phone number must be in e164 format. The first number in the list is the contact's primary phone.
- Urls (`urls`, list): A list of websites associated with or belonging to this contact.

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "company_name": "example",
    "display_name": "example",
    "emails": [],
    "extension": "example",
    "first_name": "example",
    "id": "example",
    "job_title": "example",
    "last_name": "example",
    "owner_id": "example",
    "phones": [],
    "primary_email": "example",
    "primary_phone": "example",
    "trunk_group": "example",
    "type": "lead",
    "urls": []
  }
}
```

### Update user

Update the provided fields for an existing user.

**Inputs**

- Dialpad user (`dialpad_user_id`, text, required): The user's id. ('me' can be used if you are using a user level API key)
- Admin office ids (`admin_office_ids`, list): The list of admin office IDs. This is used to set the user as an office admin for the offices with the provided IDs.
- Emails (`emails`, list): The user's emails. This can be used to add, remove, or re-order emails. The first email in the list is the user's primary email.
- Extension (`extension`, text): The user's new extension number. Extensions are optional in Dialpad and turned off by default. If you want extensions please contact support to enable them.
- First name (`first_name`, text): [single-line only] The user's first name.
- Forwarding numbers (`forwarding_numbers`, list): A list of phone numbers that should be dialed in addition to the user's Dialpad number(s) upon receiving a call.
- International dialing enabled (`international_dialing_enabled`, true/false): Whether or not the user is enabled to dial internationally.
- Is super admin (`is_super_admin`, true/false): Whether or not the user is a super admin. (company level administrator)
- Job title (`job_title`, text): [single-line only] The user's job title.
- Keep paid numbers (`keep_paid_numbers`, true/false): Whether or not to keep phone numbers when switching to a support license. Note: Phone numbers require additional number licenses under a support license. Default: `true`.
- Last name (`last_name`, text): [single-line only] The user's last name.
- License (`license`, text): The user's license type. Changing this affects billing for the user. For a Sell license, specify the type as `agents`. For a Support license, specify the type as `support`. One of: `admins`, `agents`, `dpde_all` (Dpde all), `dpde_one` (Dpde one), `lite_lines` (Lite lines), `lite_support_agents` (Lite support agents), `magenta_lines` (Magenta lines), `talk`, `user`.
- Office (`office_id`, text): The user's office id. If provided, the user will be moved to this office. For international offices, the user must not have phone numbers assigned. Once the transfer is complete, your admin can add the phone numbers via the user assign number API. Only supported on paid accounts and there must be enough licenses to transfer the user to the destination office.
- Phone numbers (`phone_numbers`, list): A list of the phone number(s) assigned to this user. This can be used to re-order or remove numbers. To assign a new number, use the assign number API instead.
- State (`state`, text): The user's state. This is used to suspend or re-activate a user. One of: `active`, `suspended`.

**Outputs**

- `data` (object): Dialpad response data.

**Example output**

```json
{
  "data": {
    "admin_office_ids": [],
    "company_id": 1,
    "country": "example",
    "date_active": "example",
    "date_added": "example",
    "date_first_login": "example",
    "date_last_login": "example",
    "display_name": "example",
    "do_not_disturb": false,
    "duty_status_reason": "example",
    "duty_status_started": "example",
    "emails": [],
    "extension": "example",
    "first_name": "example",
    "forwarding_numbers": [],
    "group_details": [],
    "id": 1,
    "image_url": "example",
    "international_dialing_enabled": false,
    "is_admin": false,
    "is_available": false,
    "is_on_duty": false,
    "is_online": false,
    "is_super_admin": false,
    "job_title": "example",
    "language": "example",
    "last_name": "example",
    "license": "admins",
    "location": "example",
    "muted": false,
    "office_id": 1,
    "on_duty_started": "example",
    "on_duty_status": "available",
    "onboarding_completed": false,
    "phone_numbers": [],
    "remote_service": "example",
    "session_type": "call",
    "state": "active",
    "status_message": "example",
    "timezone": "example",
    "voicemail": {
      "is_default_voicemail": false,
      "name": "example",
      "voicemail_notifications_enabled": false
    }
  }
}
```
