---
title: Deploy a dynamic route version
---

[Skip to content](#_top)

[API Reference](https://developers.cloudflare.com/api/go)

[AI Gateway](https://developers.cloudflare.com/api/go/resources/ai_gateway)

[Dynamic Routing](https://developers.cloudflare.com/api/go/resources/ai_gateway/subresources/dynamic_routing)

Copy Markdown

Open in **Claude**Open in **ChatGPT**Open in **Cursor**

---

**Copy Markdown****View as Markdown**

# Deploy a dynamic route version

client.AIGateway.DynamicRouting.NewDeployment(ctx, gatewayID, id, params) (\*[DynamicRoutingNewDeploymentResponse](<https://developers.cloudflare.com/api/go/resources/ai_gateway#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)>), error)

POST/accounts/{account\_id}/ai-gateway/gateways/{gateway\_id}/routes/{id}/deployments

Deploys the specified version of a dynamic route so that it serves traffic. Deploy an earlier version to roll back.

##### Security

<details>

<summary>API Token</summary>



The preferred authorization scheme for interacting with the Cloudflare API. <a href="https://developers.cloudflare.com/fundamentals/api/get-started/create-token/">Create a token</a>.

**Example:**<code>Authorization: Bearer Sn3lZJTBX6kkg7OdcBUAxOO963GEIyGQqnFTOFYY</code>

</details>

<details>

<summary>API Email + API Key</summary>



The previous authorization scheme for interacting with the Cloudflare API, used in conjunction with a Global API key.

**Example:**<code>X-Auth-Email: user@example.com</code>

The previous authorization scheme for interacting with the Cloudflare API. When possible, use API tokens instead of Global API keys.

**Example:**<code>X-Auth-Key: 144c9defac04969c7bfad8efaa8ea194</code>

</details>

##### Accepted Permissions (at least one required)

`AI Gateway Write`

##### ParametersExpand Collapse

gatewayID string

[Link to this property](<#(resource)%20ai_gateway.dynamic_routing%20%3E%20(method)%20create_deployment%20%3E%20(params)%20default%20%3E%20(param)%20gateway_id%20%3E%20(schema)>)

id string

[Link to this property](<#(resource)%20ai_gateway.dynamic_routing%20%3E%20(method)%20create_deployment%20%3E%20(params)%20default%20%3E%20(param)%20id%20%3E%20(schema)>)

<details>

<summary>

params DynamicRoutingNewDeploymentParams

</summary>

AccountID param.Field\[string]

Path param

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(method)%20create_deployment%20%3E%20(params)%20default%20%3E%20(param)%20account_id">Link to this property</a>

VersionID param.Field\[string]

Body param

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(method)%20create_deployment%20%3E%20(params)%20default%20%3E%20(param)%20version_id">Link to this property</a>

</details>

[Link to this property](<#(resource)%20ai_gateway.dynamic_routing%20%3E%20(method)%20create_deployment%20%3E%20(params)%20default>)

##### ReturnsExpand Collapse

<details>

<summary>

type DynamicRoutingNewDeploymentResponse struct{…}

</summary>

ID string

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20id">Link to this property</a>

CreatedAt Time

formatdate-time

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20created_at">Link to this property</a>

<details>

<summary>

Elements \[]DynamicRoutingNewDeploymentResponseElement

</summary>

One of the following:

<details>

<summary>

type DynamicRoutingNewDeploymentResponseElementsObject struct{…}

</summary>

ID string

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%200%20%3E%20(property)%20id">Link to this property</a>

<details>

<summary>

Outputs DynamicRoutingNewDeploymentResponseElementsObjectOutputs

</summary>

<details>

<summary>

Next DynamicRoutingNewDeploymentResponseElementsObjectOutputsNext

</summary>

ElementID string

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%200%20%3E%20(property)%20outputs%20%3E%20(property)%20next%20%3E%20(property)%20elementId">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%200%20%3E%20(property)%20outputs%20%3E%20(property)%20next">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%200%20%3E%20(property)%20outputs">Link to this property</a>

Type DynamicRoutingNewDeploymentResponseElementsObjectType

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%200%20%3E%20(property)%20type">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%200">Link to this property</a>

<details>

<summary>

type DynamicRoutingNewDeploymentResponseElementsObject struct{…}

</summary>

ID string

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%201%20%3E%20(property)%20id">Link to this property</a>

<details>

<summary>

Outputs DynamicRoutingNewDeploymentResponseElementsObjectOutputs

</summary>

<details>

<summary>

False DynamicRoutingNewDeploymentResponseElementsObjectOutputsFalse

</summary>

ElementID string

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%201%20%3E%20(property)%20outputs%20%3E%20(property)%20false%20%3E%20(property)%20elementId">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%201%20%3E%20(property)%20outputs%20%3E%20(property)%20false">Link to this property</a>

<details>

<summary>

True DynamicRoutingNewDeploymentResponseElementsObjectOutputsTrue

</summary>

ElementID string

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%201%20%3E%20(property)%20outputs%20%3E%20(property)%20true%20%3E%20(property)%20elementId">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%201%20%3E%20(property)%20outputs%20%3E%20(property)%20true">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%201%20%3E%20(property)%20outputs">Link to this property</a>

<details>

<summary>

Properties DynamicRoutingNewDeploymentResponseElementsObjectProperties

</summary>

Conditions unknownOptional

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%201%20%3E%20(property)%20properties%20%3E%20(property)%20conditions">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%201%20%3E%20(property)%20properties">Link to this property</a>

Type DynamicRoutingNewDeploymentResponseElementsObjectType

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%201%20%3E%20(property)%20type">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%201">Link to this property</a>

<details>

<summary>

type DynamicRoutingNewDeploymentResponseElementsObject struct{…}

</summary>

ID string

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%202%20%3E%20(property)%20id">Link to this property</a>

<details>

<summary>

Outputs map\[string, DynamicRoutingNewDeploymentResponseElementsObjectOutput]

</summary>

ElementID string

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%202%20%3E%20(property)%20outputs%20%3E%20(items)%20%3E%20(property)%20elementId">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%202%20%3E%20(property)%20outputs">Link to this property</a>

Type DynamicRoutingNewDeploymentResponseElementsObjectType

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%202%20%3E%20(property)%20type">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%202">Link to this property</a>

<details>

<summary>

type DynamicRoutingNewDeploymentResponseElementsObject struct{…}

</summary>

ID string

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%203%20%3E%20(property)%20id">Link to this property</a>

<details>

<summary>

Outputs DynamicRoutingNewDeploymentResponseElementsObjectOutputs

</summary>

<details>

<summary>

Fallback DynamicRoutingNewDeploymentResponseElementsObjectOutputsFallback

</summary>

ElementID string

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%203%20%3E%20(property)%20outputs%20%3E%20(property)%20fallback%20%3E%20(property)%20elementId">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%203%20%3E%20(property)%20outputs%20%3E%20(property)%20fallback">Link to this property</a>

<details>

<summary>

Success DynamicRoutingNewDeploymentResponseElementsObjectOutputsSuccess

</summary>

ElementID string

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%203%20%3E%20(property)%20outputs%20%3E%20(property)%20success%20%3E%20(property)%20elementId">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%203%20%3E%20(property)%20outputs%20%3E%20(property)%20success">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%203%20%3E%20(property)%20outputs">Link to this property</a>

<details>

<summary>

Properties DynamicRoutingNewDeploymentResponseElementsObjectProperties

</summary>

Key string

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%203%20%3E%20(property)%20properties%20%3E%20(property)%20key">Link to this property</a>

Limit float64

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%203%20%3E%20(property)%20properties%20%3E%20(property)%20limit">Link to this property</a>

<details>

<summary>

LimitType DynamicRoutingNewDeploymentResponseElementsObjectPropertiesLimitType

</summary>

One of the following:

const DynamicRoutingNewDeploymentResponseElementsObjectPropertiesLimitTypeCount DynamicRoutingNewDeploymentResponseElementsObjectPropertiesLimitType = "count"

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%203%20%3E%20(property)%20properties%20%3E%20(property)%20limitType%20%3E%20(member)%200">Link to this property</a>

const DynamicRoutingNewDeploymentResponseElementsObjectPropertiesLimitTypeCost DynamicRoutingNewDeploymentResponseElementsObjectPropertiesLimitType = "cost"

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%203%20%3E%20(property)%20properties%20%3E%20(property)%20limitType%20%3E%20(member)%201">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%203%20%3E%20(property)%20properties%20%3E%20(property)%20limitType">Link to this property</a>

Window float64

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%203%20%3E%20(property)%20properties%20%3E%20(property)%20window">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%203%20%3E%20(property)%20properties">Link to this property</a>

Type DynamicRoutingNewDeploymentResponseElementsObjectType

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%203%20%3E%20(property)%20type">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%203">Link to this property</a>

<details>

<summary>

type DynamicRoutingNewDeploymentResponseElementsObject struct{…}

</summary>

ID string

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%204%20%3E%20(property)%20id">Link to this property</a>

<details>

<summary>

Outputs DynamicRoutingNewDeploymentResponseElementsObjectOutputs

</summary>

<details>

<summary>

Fallback DynamicRoutingNewDeploymentResponseElementsObjectOutputsFallback

</summary>

ElementID string

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%204%20%3E%20(property)%20outputs%20%3E%20(property)%20fallback%20%3E%20(property)%20elementId">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%204%20%3E%20(property)%20outputs%20%3E%20(property)%20fallback">Link to this property</a>

<details>

<summary>

Success DynamicRoutingNewDeploymentResponseElementsObjectOutputsSuccess

</summary>

ElementID string

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%204%20%3E%20(property)%20outputs%20%3E%20(property)%20success%20%3E%20(property)%20elementId">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%204%20%3E%20(property)%20outputs%20%3E%20(property)%20success">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%204%20%3E%20(property)%20outputs">Link to this property</a>

<details>

<summary>

Properties DynamicRoutingNewDeploymentResponseElementsObjectProperties

</summary>

Model string

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%204%20%3E%20(property)%20properties%20%3E%20(property)%20model">Link to this property</a>

Provider string

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%204%20%3E%20(property)%20properties%20%3E%20(property)%20provider">Link to this property</a>

Retries float64

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%204%20%3E%20(property)%20properties%20%3E%20(property)%20retries">Link to this property</a>

Timeout float64

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%204%20%3E%20(property)%20properties%20%3E%20(property)%20timeout">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%204%20%3E%20(property)%20properties">Link to this property</a>

Type DynamicRoutingNewDeploymentResponseElementsObjectType

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%204%20%3E%20(property)%20type">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%204">Link to this property</a>

<details>

<summary>

type DynamicRoutingNewDeploymentResponseElementsObject struct{…}

</summary>

ID string

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%205%20%3E%20(property)%20id">Link to this property</a>

<details>

<summary>

Outputs map\[string, DynamicRoutingNewDeploymentResponseElementsObjectOutput]

</summary>

ElementID string

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%205%20%3E%20(property)%20outputs%20%3E%20(items)%20%3E%20(property)%20elementId">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%205%20%3E%20(property)%20outputs">Link to this property</a>

Type DynamicRoutingNewDeploymentResponseElementsObjectType

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%205%20%3E%20(property)%20type">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements%20%3E%20(items)%20%3E%20(variant)%205">Link to this property</a>

</details>

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20elements">Link to this property</a>

GatewayID string

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20gateway_id">Link to this property</a>

ModifiedAt Time

formatdate-time

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20modified_at">Link to this property</a>

Name string

minLength1

<a href="#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)%20%3E%20(property)%20name">Link to this property</a>

</details>

[Link to this property](<#(resource)%20ai_gateway.dynamic_routing%20%3E%20(model)%20DynamicRoutingNewDeploymentResponse%20%3E%20(schema)>)

### Deploy a dynamic route version

Go

HTTPTypeScriptPythonGoTerraform

```
package main

import (
  "context"
  "fmt"

  "github.com/cloudflare/cloudflare-go"
  "github.com/cloudflare/cloudflare-go/ai_gateway"
  "github.com/cloudflare/cloudflare-go/option"
)

func main() {
  client := cloudflare.NewClient(
    option.WithAPIToken("Sn3lZJTBX6kkg7OdcBUAxOO963GEIyGQqnFTOFYY"),
  )
  response, err := client.AIGateway.DynamicRouting.NewDeployment(
    context.TODO(),
    "54442216",
    "54442216",
    ai_gateway.DynamicRoutingNewDeploymentParams{
      AccountID: cloudflare.F("0d37909e38d3e99c29fa2cd343ac421a"),
      VersionID: cloudflare.F("54442216"),
    },
  )
  if err != nil {
    panic(err.Error())
  }
  fmt.Printf("%+v\n", response.ID)
}
```

200 example

```
{
  "result": {
    "id": "id",
    "created_at": "2019-12-27T18:11:19.117Z",
    "elements": [
      {
        "id": "id",
        "outputs": {
          "next": {
            "elementId": "elementId"
          }
        },
        "type": "start"
      }
    ],
    "gateway_id": "gateway_id",
    "modified_at": "2019-12-27T18:11:19.117Z",
    "name": "x"
  },
  "success": true
}
```

##### Returns Examples

200 example

```
{
  "result": {
    "id": "id",
    "created_at": "2019-12-27T18:11:19.117Z",
    "elements": [
      {
        "id": "id",
        "outputs": {
          "next": {
            "elementId": "elementId"
          }
        },
        "type": "start"
      }
    ],
    "gateway_id": "gateway_id",
    "modified_at": "2019-12-27T18:11:19.117Z",
    "name": "x"
  },
  "success": true
}
```