> For the complete documentation index, see [llms.txt](https://docs.i3d.net/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.i3d.net/connectivity/dedicated-networks-api/creating-a-network.md).

# Creating a network

Create a network with [`PUT /networks/{networkId}`](https://docs.i3d.net/api/api_dedicated_networks.md#networks).

Requires write access (see [Prerequisites](https://docs.i3d.net/connectivity/dedicated-networks-api/getting-started.md#prerequisites)).

## Network request body properties

<table data-full-width="true"><thead><tr><th width="200">Property</th><th width="110">Value type</th><th width="110">Required</th><th>Description</th><th>Example value</th></tr></thead><tbody><tr><td><code>connectivity.type</code></td><td>string</td><td>Required</td><td><code>public</code> for an internet-connected network, <code>private</code> for a Layer 2 segment that carries traffic between your own machines only. A private network you create is isolated: it has no gateway and does not route to the internet or to your other networks.</td><td><code>public</code></td></tr><tr><td><code>fabric</code></td><td>string</td><td>Required</td><td>Fabric slug from <code>GET /fabrics</code>.</td><td><code>montreal-a</code></td></tr><tr><td><code>name</code></td><td>string</td><td>Optional</td><td>A label for the network, up to 100 characters. Not unique. You can change or clear it later, see <a href="https://docs.i3d.net/connectivity/dedicated-networks-api/managing-networks.md#renaming-a-network-patch">Renaming a network</a>.</td><td><code>web tier</code></td></tr><tr><td><code>addressing.source</code></td><td>string</td><td>Optional</td><td><code>provider</code> (default): i3D.net supplies the address space. <code>none</code>: no prefixes are created, you get a bare Layer 2 segment (private networks only).</td><td><code>provider</code></td></tr><tr><td><code>addressing.prefixes</code></td><td>array</td><td>See description</td><td>The initial prefixes. Each entry states either <code>{"family": 4, "size": 24}</code> (i3D.net selects the subnet) or, on a private network, <code>{"cidr": "10.20.30.0/24"}</code> (the exact subnet from your own address plan; see <a href="#choosing-the-private-subnet-yourself">Choosing the private subnet yourself</a>). <strong>Required for public networks.</strong> Optional for private networks: when omitted, exactly one IPv4 /24 is created. The largest block you can request is a /24 (a <code>size</code> of 24 or higher).</td><td><code>[{"family": 4, "size": 24}]</code></td></tr><tr><td><code>retention</code></td><td>string</td><td>Optional</td><td>Lifecycle of the network. Networks you create are always <code>persistent</code>; omit the field. Declaring <code>ephemeral</code> is rejected.</td><td><code>persistent</code></td></tr><tr><td><code>contractId</code></td><td>string</td><td>See description</td><td>The contract the network's prefixes are billed under. Required unless <code>addressing.source</code> is <code>none</code> (then it must be omitted).</td><td><code>PD-2026-000481</code></td></tr></tbody></table>

## Example request

[`PUT /networks/{networkId}`](https://docs.i3d.net/api/api_dedicated_networks.md#networks)

Request body for a public network with one IPv4 /24:

```json
{
  "connectivity": { "type": "public" },
  "fabric": "montreal-a",
  "name": "web tier",
  "addressing": {
    "source": "provider",
    "prefixes": [
      { "family": 4, "size": 24 }
    ]
  },
  "contractId": "PD-2026-000481"
}
```

Request body for a private network with one derived /24 (no `prefixes` needed):

```json
{
  "connectivity": { "type": "private" },
  "fabric": "montreal-a",
  "name": "db tier",
  "contractId": "PD-2026-000481"
}
```

Request body for a private network on a subnet you choose:

```json
{
  "connectivity": { "type": "private" },
  "fabric": "montreal-a",
  "name": "db tier",
  "addressing": {
    "prefixes": [
      { "cidr": "10.20.30.0/24" }
    ]
  },
  "contractId": "PD-2026-000481"
}
```

## Choosing the private subnet yourself

On a private network you can state the exact subnet of an initial prefix with `cidr` instead of `family` and `size`. i3D.net still allocates and records it; the network reaches `active` with exactly that subnet, so it fits the address plan you already use elsewhere. Rules:

* Each entry in `addressing.prefixes` states **either** `cidr` **or** `family` + `size`, never both. Entries of one request may mix the two forms.
* IPv4 subnets must be inside `10.0.0.0/8`, `172.16.0.0/12` or `192.168.0.0/16`, with a mask between /24 and /29. IPv6 subnets must be inside `fd00::/8`, with a mask between /48 and /64.
* The value must be the network address (`10.20.30.0/24`, not `10.20.30.5/24`).
* Two prefixes in one request must not overlap each other.
* Public networks never take a `cidr`: i3D.net selects public subnets.

A request that breaks one of these rules is refused with `422` (error code `E020001`) and nothing is created. A subnet that is already in use on one of your private networks is not refused up front: the create is accepted and the network then settles in state `failed` (see [Network lifecycle and states](https://docs.i3d.net/connectivity/dedicated-networks-api/network-lifecycle-and-states.md)); pick another subnet and create the network again with a new UUID. A replay of the same UUID with a different `cidr` is a `409` (error code `E020003`).

## Response

If the request is accepted, you receive `202 Accepted` with the network in state `provisioning` and a link to the operation that provisions it.

```json
{
  "id": "01984f2e-1c3a-7d21-9d10-3542f27adccf",
  "state": "provisioning",
  "connectivity": { "type": "public" },
  "fabric": "montreal-a",
  "name": "web tier",
  "addressing": { "source": "provider" },
  "retention": "persistent",
  "createdAt": "2026-07-27T09:00:00Z",
  "updatedAt": "2026-07-27T09:00:00Z",
  "links": {
    "self": { "href": "/networks/01984f2e-1c3a-7d21-9d10-3542f27adccf" },
    "operation": { "href": "/networks/01984f2e-1c3a-7d21-9d10-3542f27adccf/operation" },
    "prefixes": { "href": "/prefixes?filters[networkId][eq]=01984f2e-1c3a-7d21-9d10-3542f27adccf" },
    "ipAddresses": { "href": "/networks/01984f2e-1c3a-7d21-9d10-3542f27adccf/ip-addresses" }
  }
}
```

The `vlanId` is not in this response yet: it appears once the network has been provisioned.

{% hint style="warning" %}
Persistent prefixes under a contract are billed. See [Usage and limits](https://docs.i3d.net/connectivity/dedicated-networks-api/usage-and-limits.md) for what is currently billable on your account.
{% endhint %}

## Retries and idempotency

The same UUID with a different body is refused with `409` (error code `E020003`). `PUT` only ever creates; it never replaces an existing network. To create another network, use a new UUID.

Poll the network until it is `active`; see [Network lifecycle and states](https://docs.i3d.net/connectivity/dedicated-networks-api/network-lifecycle-and-states.md). Then [list its prefixes](https://docs.i3d.net/connectivity/dedicated-networks-api/prefixes-and-ip-addresses.md#listing-the-prefixes-of-a-network) for the subnet, gateway and VLAN.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.i3d.net/connectivity/dedicated-networks-api/creating-a-network.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
