---
title: "POST /v1/gateways"
method: POST
path: "/v1/gateways"
---

# POST /v1/gateways

`POST /v1/gateways`

Creates a new gateway. The request must include at least one network (up to 4).

## Request body

- object
  - `egressCidrBlocks` String[], required — The range of IP addresses that are allowed to contribute content or initiate output requests for flows communicating with this gateway. These IP addresses should be in the form of a Classless Inter-Domain Routing (CIDR) block; for example, 10.0.0.0/16.
  - `name` string, required — The name of the gateway. This name can not be modified after the gateway is created.
  - `networks` GatewayNetwork[], required — The list of networks that you want to add.
    - `CidrBlock` string, required — A unique IP address range to use for this network. These IP addresses should be in the form of a Classless Inter-Domain Routing (CIDR) block; for example, 10.0.0.0/16.
    - `Name` string, required — The name of the network. This name is used to reference the network and must be unique among networks in this gateway.

## Response `201`

Success

- CreateGatewayResponse
  - `Gateway` object — The settings for a gateway, including its networks.
    - `EgressCidrBlocks` String[], required — The range of IP addresses that contribute content or initiate output requests for flows communicating with this gateway. These IP addresses should be in the form of a Classless Inter-Domain Routing (CIDR) block; for example, 10.0.0.0/16.
    - `GatewayArn` string, required — The Amazon Resource Name (ARN) of the gateway.
    - `GatewayMessages` MessageDetail[]
      - `Code` string, required — The error code.
      - `Message` string, required — The specific error message that MediaConnect returns to help you understand the reason that the request did not succeed.
      - `ResourceName` string — The name of the resource.
    - `GatewayState` 'CREATING' | 'ACTIVE' | 'UPDATING' | 'ERROR' | 'DELETING' | 'DELETED' — The current status of the gateway.
    - `Name` string, required — The name of the gateway. This name can not be modified after the gateway is created.
    - `Networks` GatewayNetwork[], required — The list of networks in the gateway.
      - `CidrBlock` string, required — A unique IP address range to use for this network. These IP addresses should be in the form of a Classless Inter-Domain Routing (CIDR) block; for example, 10.0.0.0/16.
      - `Name` string, required — The name of the network. This name is used to reference the network and must be unique among networks in this gateway.

## Other responses

- `480` — CreateGateway420Exception
- `481` — BadRequestException
- `482` — InternalServerErrorException
- `483` — ForbiddenException
- `484` — ServiceUnavailableException
- `485` — TooManyRequestsException
- `486` — ConflictException

---

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