---
title: "POST /monitors"
method: POST
path: "/monitors"
---

# POST /monitors

`POST /monitors`

Creates a monitor between a source subnet and destination IP address. Within a monitor you'll create one or more probes that monitor network traffic between your source Amazon Web Services VPC subnets and your destination IP addresses. Each probe then aggregates and sends metrics to Amazon CloudWatch.

You can also create a monitor with probes using this command. For each probe, you define the following:

*   `source`—The subnet IDs where the probes will be created.
    
*   `destination`— The target destination IP address for the probe.
    
*   `destinationPort`—Required only if the protocol is `TCP`.
    
*   `protocol`—The communication protocol between the source and destination. This will be either `TCP` or `ICMP`.
    
*   `packetSize`—The size of the packets. This must be a number between `56` and `8500`.
    
*   (Optional) `tags` —Key-value pairs created and assigned to the probe.

## Request body

- object
  - `monitorName` string, required — The name identifying the monitor. It can contain only letters, underscores (_), or dashes (-), and can be up to 200 characters.
  - `probes` CreateMonitorProbeInput[] — Displays a list of all of the probes created for a monitor.
    - `sourceArn` string, required — The ARN of the subnet.
    - `destination` string, required — The destination IP address. This must be either <code>IPV4</code> or <code>IPV6</code>.
    - `destinationPort` integer — The port associated with the <code>destination</code>. This is required only if the <code>protocol</code> is <code>TCP</code> and must be a number between <code>1</code> and <code>65536</code>.
    - `protocol` 'TCP' | 'ICMP', required — The protocol used for the network traffic between the <code>source</code> and <code>destination</code>. This must be either <code>TCP</code> or <code>ICMP</code>.
    - `packetSize` integer — The size of the packets sent between the source and destination. This must be a number between <code>56</code> and <code>8500</code>.
    - `probeTags` object — The list of key-value pairs created and assigned to the monitor.
  - `aggregationPeriod` integer — The time, in seconds, that metrics are aggregated and sent to Amazon CloudWatch. Valid values are either <code>30</code> or <code>60</code>. <code>60</code> is the default if no period is chosen.
  - `clientToken` string — Unique, case-sensitive identifier to ensure the idempotency of the request. Only returned if a client token was provided in the request.
  - `tags` object — The list of key-value pairs created and assigned to the monitor.

## Response `200`

Success

- CreateMonitorOutput
  - `monitorArn` string, required — The ARN of the monitor.
  - `monitorName` string, required — The name of the monitor.
  - `state` 'PENDING' | 'ACTIVE' | 'INACTIVE' | 'ERROR' | 'DELETING', required — The state of the monitor.
  - `aggregationPeriod` integer — The number of seconds that metrics are aggregated by and sent to Amazon CloudWatch. This will be either <code>30</code> or <code>60</code>.
  - `tags` object — The list of key-value pairs assigned to the monitor.

## Other responses

- `480` — AccessDeniedException
- `481` — ThrottlingException
- `482` — ValidationException
- `483` — InternalServerException
- `484` — ConflictException
- `485` — ServiceQuotaExceededException

---

[API](https://skmtc.net/aws/apis/networkmonitor.md) · [All operations](https://skmtc.net/aws/apis/networkmonitor/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/aws/networkmonitor/versions/f1fb54da1a06/schema)
