# REST Resource: projects.locations.zones.subnets

- [Resource: Subnet](https://docs.cloud.google.com/distributed-cloud/connected/1.6.1/docs/reference/network/rest/v1/projects.locations.zones.subnets#Subnet)
  - [JSON representation](https://docs.cloud.google.com/distributed-cloud/connected/1.6.1/docs/reference/network/rest/v1/projects.locations.zones.subnets#Subnet.SCHEMA_REPRESENTATION)
- [Methods](https://docs.cloud.google.com/distributed-cloud/connected/1.6.1/docs/reference/network/rest/v1/projects.locations.zones.subnets#METHODS_SUMMARY)

## Resource: Subnet

Message describing Subnet object

| JSON representation |
|---|
| ``` { "name": string, "createTime": string, "updateTime": string, "labels": { string: string, ... }, "description": string, "network": string, "ipv4Cidr": [ string ], "ipv6Cidr": [ string ], "vlanId": integer, "state": enum (`https://docs.cloud.google.com/distributed-cloud/connected/1.6.1/docs/reference/network/rest/v1/ResourceState`) } ``` |

| Fields ||
|---|---|
| `name` | `string` Required. The canonical resource name of the subnet. |
| `createTime` | ``string (`https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.Timestamp` format)`` Output only. The time when the subnet was created. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: `"2014-10-02T15:01:23Z"` and `"2014-10-02T15:01:23.045123456Z"`. |
| `updateTime` | ``string (`https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.Timestamp` format)`` Output only. The time when the subnet was last updated. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: `"2014-10-02T15:01:23Z"` and `"2014-10-02T15:01:23.045123456Z"`. |
| `labels` | `map (key: string, value: string)` Labels associated with this resource. An object containing a list of `"key": value` pairs. Example: `{ "name": "wrench", "mass": "1.3kg", "count": "3" }`. |
| `description` | `string` Optional. A free-text description of the resource. Max length 1024 characters. |
| `network` | `string` Required. The network that this subnetwork belongs to. |
| `ipv4Cidr[]` | `string` The ranges of ipv4 addresses that are owned by this subnetwork. |
| `ipv6Cidr[]` | `string` The ranges of ipv6 addresses that are owned by this subnetwork. |
| `vlanId` | `integer` Optional. VLAN id provided by user. If not specified we assign one automatically. |
| `state` | ``enum (`https://docs.cloud.google.com/distributed-cloud/connected/1.6.1/docs/reference/network/rest/v1/ResourceState`)`` Output only. Current stage of the resource to the device by config push. |

| ## Methods ||
|---|---|
| ### `https://docs.cloud.google.com/distributed-cloud/connected/1.6.1/docs/reference/network/rest/v1/projects.locations.zones.subnets/create` | Creates a new Subnet in a given project and location. |
| ### `https://docs.cloud.google.com/distributed-cloud/connected/1.6.1/docs/reference/network/rest/v1/projects.locations.zones.subnets/delete` | Deletes a single Subnet. |
| ### `https://docs.cloud.google.com/distributed-cloud/connected/1.6.1/docs/reference/network/rest/v1/projects.locations.zones.subnets/get` | Gets details of a single Subnet. |
| ### `https://docs.cloud.google.com/distributed-cloud/connected/1.6.1/docs/reference/network/rest/v1/projects.locations.zones.subnets/list` | Lists Subnets in a given project and location. |
| ### `https://docs.cloud.google.com/distributed-cloud/connected/1.6.1/docs/reference/network/rest/v1/projects.locations.zones.subnets/patch` | Updates the parameters of a single Subnet. |