Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

traffic policy api reference and examples update #877

Merged
merged 1 commit into from
Aug 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
69 changes: 69 additions & 0 deletions docs/api/resources/edge-route-traffic-policy-module.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
import EdgeRouteTrafficPolicyModuleDeleteRequest from "./examples/_edge_route_traffic_policy_module_delete_request.md";
import EdgeRouteTrafficPolicyModuleDeleteResponse from "./examples/_edge_route_traffic_policy_module_delete_response.md";
import EdgeRouteTrafficPolicyModuleGetRequest from "./examples/_edge_route_traffic_policy_module_get_request.md";
import EdgeRouteTrafficPolicyModuleGetResponse from "./examples/_edge_route_traffic_policy_module_get_response.md";
import EdgeRouteTrafficPolicyModuleReplaceRequest from "./examples/_edge_route_traffic_policy_module_replace_request.md";
import EdgeRouteTrafficPolicyModuleReplaceResponse from "./examples/_edge_route_traffic_policy_module_replace_response.md";

# Edge Route Traffic Policy Module

## Replace HTTPS Edge Route Traffic Policy Module

### Request

PUT /edges/https/\{edge_id\}/routes/\{id\}/traffic_policy

<EdgeRouteTrafficPolicyModuleReplaceRequest />

#### Parameters

| Name | Type | Description |
| --------- | ------- | -------------------------------------------------------------------------------------------------- |
| `enabled` | boolean | `true` if the module will be applied to traffic, `false` to disable. default `true` if unspecified |
| `value` | string | the traffic policy that should be applied to the traffic on your endpoint. |

### Response

Returns a 200 response on success

<EdgeRouteTrafficPolicyModuleReplaceResponse />

#### Fields

| Name | Type | Description |
| --------- | ------- | -------------------------------------------------------------------------------------------------- |
| `enabled` | boolean | `true` if the module will be applied to traffic, `false` to disable. default `true` if unspecified |
| `value` | string | the traffic policy that should be applied to the traffic on your endpoint. |

## Get HTTPS Edge Route Traffic Policy Module

### Request

GET /edges/https/\{edge_id\}/routes/\{id\}/traffic_policy

<EdgeRouteTrafficPolicyModuleGetRequest />

### Response

Returns a 200 response on success

<EdgeRouteTrafficPolicyModuleGetResponse />

#### Fields

| Name | Type | Description |
| --------- | ------- | -------------------------------------------------------------------------------------------------- |
| `enabled` | boolean | `true` if the module will be applied to traffic, `false` to disable. default `true` if unspecified |
| `value` | string | the traffic policy that should be applied to the traffic on your endpoint. |

## Delete HTTPS Edge Route Traffic Policy Module

### Request

DELETE /edges/https/\{edge_id\}/routes/\{id\}/traffic_policy

<EdgeRouteTrafficPolicyModuleDeleteRequest />

### Response

Returns a 204 response with no body on success
140 changes: 30 additions & 110 deletions docs/api/resources/edges-https-routes.mdx

Large diffs are not rendered by default.

112 changes: 24 additions & 88 deletions docs/api/resources/edges-https.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ Returns a 201 response on success
| `oidc` | [EndpointOIDC](#endpointoidc-fields) | oidc module configuration or `null` |
| `websocket_tcp_converter` | [EndpointWebsocketTCPConverter](#endpointwebsockettcpconverter-fields) | websocket to tcp adapter configuration or `null` |
| `user_agent_filter` | [EndpointUserAgentFilter](#endpointuseragentfilter-fields) | |
| `policy` | [EndpointPolicy](#endpointpolicy-fields) | the traffic policy associated with this edge or null |
| `traffic_policy` | [EndpointTrafficPolicy](#endpointtrafficpolicy-fields) | the traffic policy associated with this edge or null |

#### EndpointBackend fields

Expand Down Expand Up @@ -323,28 +323,12 @@ Returns a 201 response on success
| `allow` | List&lt;string&gt; | |
| `deny` | List&lt;string&gt; | |

#### EndpointPolicy fields
#### EndpointTrafficPolicy fields

| Name | Type | Description |
| ---------- | ------------------------------------ | -------------------------------------------------------------------------------------------------- |
| `enabled` | boolean | `true` if the module will be applied to traffic, `false` to disable. default `true` if unspecified |
| `inbound` | [EndpointRule](#endpointrule-fields) | the inbound rules of the traffic policy. |
| `outbound` | [EndpointRule](#endpointrule-fields) | the outbound rules on the traffic policy. |

#### EndpointRule fields

| Name | Type | Description |
| ------------- | ---------------------------------------- | --------------------------------------------------------------- |
| `expressions` | List&lt;string&gt; | cel expressions that filter traffic the policy rule applies to. |
| `actions` | [EndpointAction](#endpointaction-fields) | the set of actions on a policy rule. |
| `name` | string | the name of the rule that is part of the traffic policy. |

#### EndpointAction fields

| Name | Type | Description |
| -------- | ------ | ---------------------------------------------------- |
| `type` | string | the type of action on the policy rule. |
| `config` | object | the configuration for the action on the policy rule. |
| Name | Type | Description |
| --------- | ------- | -------------------------------------------------------------------------------------------------- |
| `enabled` | boolean | `true` if the module will be applied to traffic, `false` to disable. default `true` if unspecified |
| `value` | string | the traffic policy that should be applied to the traffic on your endpoint. |

## Get HTTPS Edge

Expand Down Expand Up @@ -422,7 +406,7 @@ Returns a 200 response on success
| `oidc` | [EndpointOIDC](#endpointoidc-fields) | oidc module configuration or `null` |
| `websocket_tcp_converter` | [EndpointWebsocketTCPConverter](#endpointwebsockettcpconverter-fields) | websocket to tcp adapter configuration or `null` |
| `user_agent_filter` | [EndpointUserAgentFilter](#endpointuseragentfilter-fields) | |
| `policy` | [EndpointPolicy](#endpointpolicy-fields) | the traffic policy associated with this edge or null |
| `traffic_policy` | [EndpointTrafficPolicy](#endpointtrafficpolicy-fields) | the traffic policy associated with this edge or null |

#### EndpointBackend fields

Expand Down Expand Up @@ -634,28 +618,12 @@ Returns a 200 response on success
| `allow` | List&lt;string&gt; | |
| `deny` | List&lt;string&gt; | |

#### EndpointPolicy fields
#### EndpointTrafficPolicy fields

| Name | Type | Description |
| ---------- | ------------------------------------ | -------------------------------------------------------------------------------------------------- |
| `enabled` | boolean | `true` if the module will be applied to traffic, `false` to disable. default `true` if unspecified |
| `inbound` | [EndpointRule](#endpointrule-fields) | the inbound rules of the traffic policy. |
| `outbound` | [EndpointRule](#endpointrule-fields) | the outbound rules on the traffic policy. |

#### EndpointRule fields

| Name | Type | Description |
| ------------- | ---------------------------------------- | --------------------------------------------------------------- |
| `expressions` | List&lt;string&gt; | cel expressions that filter traffic the policy rule applies to. |
| `actions` | [EndpointAction](#endpointaction-fields) | the set of actions on a policy rule. |
| `name` | string | the name of the rule that is part of the traffic policy. |

#### EndpointAction fields

| Name | Type | Description |
| -------- | ------ | ---------------------------------------------------- |
| `type` | string | the type of action on the policy rule. |
| `config` | object | the configuration for the action on the policy rule. |
| Name | Type | Description |
| --------- | ------- | -------------------------------------------------------------------------------------------------- |
| `enabled` | boolean | `true` if the module will be applied to traffic, `false` to disable. default `true` if unspecified |
| `value` | string | the traffic policy that should be applied to the traffic on your endpoint. |

## List HTTPS Edges

Expand Down Expand Up @@ -741,7 +709,7 @@ Returns a 200 response on success
| `oidc` | [EndpointOIDC](#endpointoidc-fields) | oidc module configuration or `null` |
| `websocket_tcp_converter` | [EndpointWebsocketTCPConverter](#endpointwebsockettcpconverter-fields) | websocket to tcp adapter configuration or `null` |
| `user_agent_filter` | [EndpointUserAgentFilter](#endpointuseragentfilter-fields) | |
| `policy` | [EndpointPolicy](#endpointpolicy-fields) | the traffic policy associated with this edge or null |
| `traffic_policy` | [EndpointTrafficPolicy](#endpointtrafficpolicy-fields) | the traffic policy associated with this edge or null |

#### EndpointBackend fields

Expand Down Expand Up @@ -953,28 +921,12 @@ Returns a 200 response on success
| `allow` | List&lt;string&gt; | |
| `deny` | List&lt;string&gt; | |

#### EndpointPolicy fields
#### EndpointTrafficPolicy fields

| Name | Type | Description |
| ---------- | ------------------------------------ | -------------------------------------------------------------------------------------------------- |
| `enabled` | boolean | `true` if the module will be applied to traffic, `false` to disable. default `true` if unspecified |
| `inbound` | [EndpointRule](#endpointrule-fields) | the inbound rules of the traffic policy. |
| `outbound` | [EndpointRule](#endpointrule-fields) | the outbound rules on the traffic policy. |

#### EndpointRule fields

| Name | Type | Description |
| ------------- | ---------------------------------------- | --------------------------------------------------------------- |
| `expressions` | List&lt;string&gt; | cel expressions that filter traffic the policy rule applies to. |
| `actions` | [EndpointAction](#endpointaction-fields) | the set of actions on a policy rule. |
| `name` | string | the name of the rule that is part of the traffic policy. |

#### EndpointAction fields

| Name | Type | Description |
| -------- | ------ | ---------------------------------------------------- |
| `type` | string | the type of action on the policy rule. |
| `config` | object | the configuration for the action on the policy rule. |
| Name | Type | Description |
| --------- | ------- | -------------------------------------------------------------------------------------------------- |
| `enabled` | boolean | `true` if the module will be applied to traffic, `false` to disable. default `true` if unspecified |
| `value` | string | the traffic policy that should be applied to the traffic on your endpoint. |

## Update HTTPS Edge

Expand Down Expand Up @@ -1077,7 +1029,7 @@ Returns a 200 response on success
| `oidc` | [EndpointOIDC](#endpointoidc-fields) | oidc module configuration or `null` |
| `websocket_tcp_converter` | [EndpointWebsocketTCPConverter](#endpointwebsockettcpconverter-fields) | websocket to tcp adapter configuration or `null` |
| `user_agent_filter` | [EndpointUserAgentFilter](#endpointuseragentfilter-fields) | |
| `policy` | [EndpointPolicy](#endpointpolicy-fields) | the traffic policy associated with this edge or null |
| `traffic_policy` | [EndpointTrafficPolicy](#endpointtrafficpolicy-fields) | the traffic policy associated with this edge or null |

#### EndpointBackend fields

Expand Down Expand Up @@ -1289,28 +1241,12 @@ Returns a 200 response on success
| `allow` | List&lt;string&gt; | |
| `deny` | List&lt;string&gt; | |

#### EndpointPolicy fields
#### EndpointTrafficPolicy fields

| Name | Type | Description |
| ---------- | ------------------------------------ | -------------------------------------------------------------------------------------------------- |
| `enabled` | boolean | `true` if the module will be applied to traffic, `false` to disable. default `true` if unspecified |
| `inbound` | [EndpointRule](#endpointrule-fields) | the inbound rules of the traffic policy. |
| `outbound` | [EndpointRule](#endpointrule-fields) | the outbound rules on the traffic policy. |

#### EndpointRule fields

| Name | Type | Description |
| ------------- | ---------------------------------------- | --------------------------------------------------------------- |
| `expressions` | List&lt;string&gt; | cel expressions that filter traffic the policy rule applies to. |
| `actions` | [EndpointAction](#endpointaction-fields) | the set of actions on a policy rule. |
| `name` | string | the name of the rule that is part of the traffic policy. |

#### EndpointAction fields

| Name | Type | Description |
| -------- | ------ | ---------------------------------------------------- |
| `type` | string | the type of action on the policy rule. |
| `config` | object | the configuration for the action on the policy rule. |
| Name | Type | Description |
| --------- | ------- | -------------------------------------------------------------------------------------------------- |
| `enabled` | boolean | `true` if the module will be applied to traffic, `false` to disable. default `true` if unspecified |
| `value` | string | the traffic policy that should be applied to the traffic on your endpoint. |

## Delete HTTPS Edge

Expand Down
Loading