# Method: projects.locations.zones.networks.diagnose

- [HTTP request](https://docs.cloud.google.com/distributed-cloud/connected/1.8.0/docs/reference/network/rest/v1/projects.locations.zones.networks/diagnose#body.HTTP_TEMPLATE)
- [Path parameters](https://docs.cloud.google.com/distributed-cloud/connected/1.8.0/docs/reference/network/rest/v1/projects.locations.zones.networks/diagnose#body.PATH_PARAMETERS)
- [Request body](https://docs.cloud.google.com/distributed-cloud/connected/1.8.0/docs/reference/network/rest/v1/projects.locations.zones.networks/diagnose#body.request_body)
- [Response body](https://docs.cloud.google.com/distributed-cloud/connected/1.8.0/docs/reference/network/rest/v1/projects.locations.zones.networks/diagnose#body.response_body)
  - [JSON representation](https://docs.cloud.google.com/distributed-cloud/connected/1.8.0/docs/reference/network/rest/v1/projects.locations.zones.networks/diagnose#body.DiagnoseNetworkResponse.SCHEMA_REPRESENTATION)
- [Authorization scopes](https://docs.cloud.google.com/distributed-cloud/connected/1.8.0/docs/reference/network/rest/v1/projects.locations.zones.networks/diagnose#body.aspect)
- [NetworkStatus](https://docs.cloud.google.com/distributed-cloud/connected/1.8.0/docs/reference/network/rest/v1/projects.locations.zones.networks/diagnose#NetworkStatus)
  - [JSON representation](https://docs.cloud.google.com/distributed-cloud/connected/1.8.0/docs/reference/network/rest/v1/projects.locations.zones.networks/diagnose#NetworkStatus.SCHEMA_REPRESENTATION)
- [SubnetStatus](https://docs.cloud.google.com/distributed-cloud/connected/1.8.0/docs/reference/network/rest/v1/projects.locations.zones.networks/diagnose#SubnetStatus)
  - [JSON representation](https://docs.cloud.google.com/distributed-cloud/connected/1.8.0/docs/reference/network/rest/v1/projects.locations.zones.networks/diagnose#SubnetStatus.SCHEMA_REPRESENTATION)
- [MacsecStatus](https://docs.cloud.google.com/distributed-cloud/connected/1.8.0/docs/reference/network/rest/v1/projects.locations.zones.networks/diagnose#MacsecStatus)
- [Try it!](https://docs.cloud.google.com/distributed-cloud/connected/1.8.0/docs/reference/network/rest/v1/projects.locations.zones.networks/diagnose#try-it)

Get the diagnostics of a single network resource.

### HTTP request

`GET https://edgenetwork.googleapis.com/v1/{name=projects/*/locations/*/zones/*/networks/*}:diagnose`

The URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.

### Path parameters

| Parameters ||
|---|---|
| `name` | `string` Required. The name of the network resource. |

### Request body

The request body must be empty.

### Response body

DiagnoseNetworkResponse contains the current status for a specific network.

If successful, the response body contains data with the following structure:

| JSON representation |
|---|
| ``` { "updateTime": string, "result": { object (`https://docs.cloud.google.com/distributed-cloud/edge/1.8.0/docs/reference/network/rest/v1/projects.locations.zones.networks/diagnose#NetworkStatus`) } } ``` |

| Fields ||
|---|---|
| `updateTime` | ``string (`https://protobuf.dev/reference/protobuf/google.protobuf#timestamp` format)`` The time when the network status was last updated. Uses RFC 3339, where generated output will always be Z-normalized and uses 0, 3, 6 or 9 fractional digits. Offsets other than "Z" are also accepted. Examples: `"2014-10-02T15:01:23Z"`, `"2014-10-02T15:01:23.045123456Z"` or `"2014-10-02T15:01:23+05:30"`. |
| `result` | ``object (`https://docs.cloud.google.com/distributed-cloud/edge/1.8.0/docs/reference/network/rest/v1/projects.locations.zones.networks/diagnose#NetworkStatus`)`` The network status of a specific network. |

### Authorization scopes

Requires the following OAuth scope:

- `https://www.googleapis.com/auth/cloud-platform`

For more information, see the [Authentication Overview](https://docs.cloud.google.com/docs/authentication#authorization-gcp).

## NetworkStatus

NetworkStatus has a list of status for the subnets under the current network.

| JSON representation |
|---|
| ``` { "subnetStatus": [ { object (`https://docs.cloud.google.com/distributed-cloud/edge/1.8.0/docs/reference/network/rest/v1/projects.locations.zones.networks/diagnose#SubnetStatus`) } ], "macsecStatusInternalLinks": enum (`https://docs.cloud.google.com/distributed-cloud/edge/1.8.0/docs/reference/network/rest/v1/projects.locations.zones.networks/diagnose#MacsecStatus`) } ``` |

| Fields ||
|---|---|
| `subnetStatus[]` | ``object (`https://docs.cloud.google.com/distributed-cloud/edge/1.8.0/docs/reference/network/rest/v1/projects.locations.zones.networks/diagnose#SubnetStatus`)`` A list of status for the subnets under the current network. |
| `macsecStatusInternalLinks` | ``enum (`https://docs.cloud.google.com/distributed-cloud/edge/1.8.0/docs/reference/network/rest/v1/projects.locations.zones.networks/diagnose#MacsecStatus`)`` The MACsec status of internal links. |

## SubnetStatus

SubnetStatus contains detailed and current technical information about this subnet resource.

| JSON representation |
|---|
| ``` { "name": string, "macAddress": string, "linkLayerAddresses": [ { object (`https://docs.cloud.google.com/distributed-cloud/edge/1.8.0/docs/reference/network/rest/v1/LinkLayerAddress`) } ] } ``` |

| Fields ||
|---|---|
| `name` | `string` The name of CCFE subnet resource. |
| `macAddress` | `string` BVI MAC address. |
| `linkLayerAddresses[]` | ``object (`https://docs.cloud.google.com/distributed-cloud/edge/1.8.0/docs/reference/network/rest/v1/LinkLayerAddress`)`` A list of LinkLayerAddress, describing the ip address and corresponding link-layer address of the neighbors for this subnet. |

## MacsecStatus

Denotes the status of MACsec sessions for the links of a zone.

| Enums ||
|---|---|
| `MACSEC_STATUS_UNSPECIFIED` | MACsec status not specified, likely due to missing metrics. |
| `SECURE` | All relevant links have at least one MACsec session up. |
| `UNSECURE` | At least one relevant link does not have any MACsec sessions up. |