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

# Update Deployment

> Partially update the deployment section of an agent

## Update Agent Deployment

Partially update the **deployment** section of an agent. Only the fields you include are merged into the existing config; omitted fields remain unchanged.

The deployment section controls phone number routing — which numbers the agent handles for inbound calls and which numbers it dials from for outbound calls.

***

## Path Parameters

<ParamField path="agent_id" type="string" required>
  UUID of the agent to update.
</ParamField>

***

## Body Parameters

<ParamField body="deployment" type="object">
  Deployment configuration wrapper.

  <Expandable title="deployment fields">
    <ParamField body="phone" type="object">
      Phone channel deployment settings.

      <Expandable title="phone fields">
        <ParamField body="call_type" type="object">
          Routing configuration for inbound and outbound calls.

          <Expandable title="call_type fields">
            <ParamField body="Inbound" type="string">
              Phone number (E.164) to receive inbound calls on. Pass `""` to clear.
            </ParamField>

            <ParamField body="Outbound" type="array">
              List of phone numbers (E.164) the agent may dial from for outbound calls.
            </ParamField>
          </Expandable>
        </ParamField>
      </Expandable>
    </ParamField>
  </Expandable>
</ParamField>

***

## Request Example

<RequestExample>
  ```bash cURL theme={null}
  curl -X PATCH https://api.vaanivoice.ai/api/agent/7ec4155e-0e62-440a-b983-5974f7697854/deployment \
    -H "X-API-Key: vaani_<your_key>" \
    -H "Content-Type: application/json" \
    -d '{
      "deployment": {
        "phone": {
          "call_type": {
            "Inbound": "+911234567890",
            "Outbound": ["+911234567890", "+919876543210"]
          }
        }
      }
    }'
  ```

  ```javascript JavaScript theme={null}
  const response = await fetch(
    "https://api.vaanivoice.ai/api/agent/7ec4155e-0e62-440a-b983-5974f7697854/deployment",
    {
      method: "PATCH",
      headers: {
        "X-API-Key": "vaani_<your_key>",
        "Content-Type": "application/json",
      },
      body: JSON.stringify({
        deployment: {
          phone: {
            call_type: {
              Inbound: "+911234567890",
              Outbound: ["+911234567890"],
            },
          },
        },
      }),
    }
  );
  const data = await response.json();
  console.log(data);
  ```

  ```python Python theme={null}
  import requests

  requests.patch(
      "https://api.vaanivoice.ai/api/agent/7ec4155e-0e62-440a-b983-5974f7697854/deployment",
      headers={"X-API-Key": "vaani_<your_key>", "Content-Type": "application/json"},
      json={
          "deployment": {
              "phone": {
                  "call_type": {
                      "Inbound": "",
                      "Outbound": ["+911234567890"],
                  }
              }
          }
      },
  )
  ```
</RequestExample>

***

## Response

<ResponseExample>
  ```json Success (200) theme={null}
  {
    "success": true,
    "message": "Deployment section updated successfully"
  }
  ```
</ResponseExample>

<Note>
  Phone numbers must be in [E.164 format](https://en.wikipedia.org/wiki/E.164) (e.g. `+911234567890`). Pass an empty string `""` for `Inbound` to remove inbound routing.
</Note>
