# Update Capacity Pool

Allows to update the existing Capacity Pool. By using this endpoint it is possible to remove Unassigned Channels from
the Capacity Pool.

## Request

HTTP Method: `PATCH`

URI Path: `/v3/capacity_pools/{id}`

### URI Query Parameters

| Name | Type | Is Required? | Description |
| --- | --- | --- | --- |
| id | `string` | Yes | Unique ID number allocated to this Capacity Pool. |

### Request Body Object Attributes

| Title | Type | Nullable | Description |
| --- | --- | --- | --- |
| total\_channels\_count | `integer` | False | Total number of channels in the Capacity Pool. |

## Examples

Sample 1

[[DIDWW-API-EXAMPLE-START]]

http

```
 1PATCH /v3/capacity_pools/b8db1d7c-f415-4530-a340-c774bcc1c55f HTTP/1.1
 2Host: api.didww.com
 3Content-Type: application/vnd.api+json
 4Accept: application/vnd.api+json
 5Authorization: Bearer [access token]
 6
 7{
 8  "data": {
 9    "id": "b8db1d7c-f415-4530-a340-c774bcc1c55f",
10    "type": "capacity_pools",
11    "attributes": {
12      "total_channels_count": 8
13    }
14  }
15}
```

curl

```
1curl -i -X PATCH https://api.didww.com/v3/capacity_pools/b8db1d7c-f415-4530-a340-c774bcc1c55f -H "Accept: application/vnd.api+json" -H "Content-Type: application/vnd.api+json" -H "Authorization: Bearer [access token]" --data-raw '{"data": {"attributes": {"total_channels_count": 8}, "id": "b8db1d7c-f415-4530-a340-c774bcc1c55f", "type": "capacity_pools"}}'
```

response

```
 1HTTP/1.1 200 OK
 2Content-Type: application/vnd.api+json
 3
 4{
 5  "data": {
 6    "id": "b8db1d7c-f415-4530-a340-c774bcc1c55f",
 7    "type": "capacity_pools",
 8    "attributes": {
 9      "name": "Extended",
10      "renew_date": "2018-07-21",
11      "total_channels_count": 8,
12      "assigned_channels_count": 7,
13      "minimum_limit": 5,
14      "minimum_qty_per_order": 1,
15      "setup_price": "25.0",
16      "monthly_price": "25.0",
17      "metered_rate": "0.02"
18    },
19    "relationships": {
20      "countries": {
21        "links": {
22          "self": "https://api.didww.com/v3/capacity_pools/b8db1d7c-f415-4530-a340-c774bcc1c55f/relationships/countries",
23          "related": "https://api.didww.com/v3/capacity_pools/b8db1d7c-f415-4530-a340-c774bcc1c55f/countries"
24        }
25      },
26      "shared_capacity_groups": {
27        "links": {
28          "self": "https://api.didww.com/v3/capacity_pools/b8db1d7c-f415-4530-a340-c774bcc1c55f/relationships/shared_capacity_groups",
29          "related": "https://api.didww.com/v3/capacity_pools/b8db1d7c-f415-4530-a340-c774bcc1c55f/shared_capacity_groups"
30        }
31      },
32      "qty_based_pricings": {
33        "links": {
34          "self": "https://api.didww.com/v3/capacity_pools/b8db1d7c-f415-4530-a340-c774bcc1c55f/relationships/qty_based_pricings",
35          "related": "https://api.didww.com/v3/capacity_pools/b8db1d7c-f415-4530-a340-c774bcc1c55f/qty_based_pricings"
36        }
37      }
38    }
39  },
40  "meta": {
41    "api_version": "2026-11-19"
42  }
43}
```

[[DIDWW-API-EXAMPLE-END]]

## Other Responses

| Code | Success | Description |
| --- | --- | --- |
| 404 | No | [Not Found](../../../specification/errors/index.html#api-not-found) |
| 422 | No | [Validation Error Object](../../../specification/errors/index.html#api-validation-error-object). The new channel count was rejected. |
| 400 | No | [Bad Request](../../../specification/errors/index.html#api-bad-request). The body carries a member the API does not accept. |
| 401 | No | [Unauthorized](../../authentication.html#authentication-v35) |
| 403 | No | The customer is in read-only mode. Also returned when the access token carries the `read` scope, which does not cover this method (title `Insufficient scope`, `WWW-Authenticate: Bearer error="insufficient_scope"`). See [Scopes](../../authentication.html#authentication-scopes-v35). |
| 429 | No | The request budget of the account for the current window is spent (`too_many_requests`). `Retry-After` gives the number of seconds to wait. |
