delete-route
Description
Deletes an existing route.
See also: AWS API Documentation
Synopsis
delete-route
--mesh-name <value>
[--mesh-owner <value>]
--route-name <value>
--virtual-router-name <value>
[--cli-input-json | --cli-input-yaml]
[--generate-cli-skeleton <value>]
[--debug]
[--endpoint-url <value>]
[--no-verify-ssl]
[--no-paginate]
[--output <value>]
[--query <value>]
[--profile <value>]
[--region <value>]
[--version <value>]
[--color <value>]
[--no-sign-request]
[--ca-bundle <value>]
[--cli-read-timeout <value>]
[--cli-connect-timeout <value>]
[--cli-binary-format <value>]
[--no-cli-pager]
[--cli-auto-prompt]
[--no-cli-auto-prompt]
Options
--mesh-name (string)
--mesh-owner (string)
--route-name (string)
--virtual-router-name (string)
--cli-input-json | --cli-input-yaml (string) Reads arguments from the JSON string provided. The JSON string follows the format provided by --generate-cli-skeleton. If other arguments are provided on the command line, those values will override the JSON-provided values. It is not possible to pass arbitrary binary values using a JSON-provided value as the string will be taken literally. This may not be specified along with --cli-input-yaml.
--generate-cli-skeleton (string) Prints a JSON skeleton to standard output without sending an API request. If provided with no value or the value input, prints a sample input JSON that can be used as an argument for --cli-input-json. Similarly, if provided yaml-input it will print a sample input YAML that can be used with --cli-input-yaml. If provided with the value output, it validates the command inputs and returns a sample output JSON for that command. The generated JSON skeleton is not stable between versions of the AWS CLI and there are no backwards compatibility guarantees in the JSON skeleton generated.
Global Options
--debug (boolean)
Turn on debug logging.
--endpoint-url (string)
Override command’s default URL with the given URL.
--no-verify-ssl (boolean)
By default, the AWS CLI uses SSL when communicating with AWS services. For each SSL connection, the AWS CLI will verify SSL certificates. This option overrides the default behavior of verifying SSL certificates.
--no-paginate (boolean)
Disable automatic pagination. If automatic pagination is disabled, the AWS CLI will only make one call, for the first page of results.
--output (string)
The formatting style for command output.
- json
- text
- table
- yaml
- yaml-stream
--query (string)
A JMESPath query to use in filtering the response data.
--profile (string)
Use a specific profile from your credential file.
--region (string)
The region to use. Overrides config/env settings.
--version (string)
Display the version of this tool.
--color (string)
Turn on/off color output.
- on
- off
- auto
--no-sign-request (boolean)
Do not sign requests. Credentials will not be loaded if this argument is provided.
--ca-bundle (string)
The CA certificate bundle to use when verifying SSL certificates. Overrides config/env settings.
--cli-read-timeout (int)
The maximum socket read time in seconds. If the value is set to 0, the socket read will be blocking and not timeout. The default value is 60 seconds.
--cli-connect-timeout (int)
The maximum socket connect time in seconds. If the value is set to 0, the socket connect will be blocking and not timeout. The default value is 60 seconds.
--cli-binary-format (string)
The formatting style to be used for binary blobs. The default format is base64. The base64 format expects binary blobs to be provided as a base64 encoded string. The raw-in-base64-out format preserves compatibility with AWS CLI V1 behavior and binary values must be passed literally. When providing contents from a file that map to a binary blob fileb:// will always be treated as binary and use the file contents directly regardless of the cli-binary-format setting. When using file:// the file contents will need to properly formatted for the configured cli-binary-format.
- base64
- raw-in-base64-out
--no-cli-pager (boolean)
Disable cli pager for output.
--cli-auto-prompt (boolean)
Automatically prompt for CLI input parameters.
--no-cli-auto-prompt (boolean)
Disable automatically prompt for CLI input parameters.
Examples
Note
To use the following examples, you must have the AWS CLI installed and configured. See the Getting started guide in the AWS CLI User Guide for more information.
Unless otherwise stated, all examples have unix-like quotation rules. These examples will need to be adapted to your terminal’s quoting rules. See Using quotation marks with strings in the AWS CLI User Guide .
To delete a route
The following delete-route example deletes the specified route.
aws appmesh delete-route \
--mesh-name app1 \
--virtual-router-name vrServiceB \
--route-name toVnServiceB-weighted
Output:
{
"route": {
"meshName": "app1",
"metadata": {
"arn": "arn:aws:appmesh:us-east-1:123456789012:mesh/app1/virtualRouter/vrServiceB/route/toVnServiceB-weighted",
"createdAt": 1563811384.015,
"lastUpdatedAt": 1563823915.936,
"uid": "a1b2c3d4-5678-90ab-cdef-11111EXAMPLE",
"version": 3
},
"routeName": "toVnServiceB-weighted",
"spec": {
"httpRoute": {
"action": {
"weightedTargets": [
{
"virtualNode": "vnServiceBv1",
"weight": 80
},
{
"virtualNode": "vnServiceBv2",
"weight": 20
}
]
},
"match": {
"prefix": "/"
}
}
},
"status": {
"status": "DELETED"
},
"virtualRouterName": "vrServiceB"
}
}
For more information, see Routes in the AWS App Mesh User Guide.
Output
route -> (structure)
The route that was deleted.
meshName -> (string)
metadata -> (structure)
The associated metadata for the route.
arn -> (string)
createdAt -> (timestamp)
lastUpdatedAt -> (timestamp)
meshOwner -> (string)
resourceOwner -> (string)
uid -> (string)
version -> (long)
routeName -> (string)
spec -> (structure)
The specifications of the route.
grpcRoute -> (structure)
An object that represents the specification of a gRPC route.
action -> (structure)
An object that represents the action to take if a match is determined.
weightedTargets -> (list)
An object that represents the targets that traffic is routed to when a request matches the route.
(structure)
An object that represents a target and its relative weight. Traffic is distributed across targets according to their relative weight. For example, a weighted target with a relative weight of 50 receives five times as much traffic as one with a relative weight of 10. The total weight for all targets combined must be less than or equal to 100.
port -> (integer)
virtualNode -> (string)
weight -> (integer)
match -> (structure)
An object that represents the criteria for determining a request match.
metadata -> (list)
An object that represents the data to match from the request.
(structure)
An object that represents the match metadata for the route.
invert -> (boolean)
True to match anything except the match criteria. The default value is False .match -> (tagged union structure)
An object that represents the data to match from the request.
Note
This is a Tagged Union structure. Only one of the following top level keys can be set:exact, prefix, range, regex, suffix.exact -> (string)
prefix -> (string)
range -> (structure)
An object that represents the range of values to match on.
end -> (long)
start -> (long)
regex -> (string)
suffix -> (string)
name -> (string)
methodName -> (string)
serviceName .port -> (integer)
serviceName -> (string)
retryPolicy -> (structure)
An object that represents a retry policy.
grpcRetryEvents -> (list)
Specify at least one of the valid values.
(string)
httpRetryEvents -> (list)
Specify at least one of the following values.
- server-error – HTTP status codes 500, 501, 502, 503, 504, 505, 506, 507, 508, 510, and 511
- gateway-error – HTTP status codes 502, 503, and 504
- client-error – HTTP status code 409
- stream-error – Retry on refused stream
(string)
maxRetries -> (long)
perRetryTimeout -> (structure)
The timeout for each retry attempt.
unit -> (string)
value -> (long)
tcpRetryEvents -> (list)
Specify a valid value. The event occurs before any processing of a request has started and is encountered when the upstream is temporarily or permanently unavailable.
(string)
timeout -> (structure)
An object that represents types of timeouts.
idle -> (structure)
An object that represents an idle timeout. An idle timeout bounds the amount of time that a connection may be idle. The default value is none.
unit -> (string)
value -> (long)
perRequest -> (structure)
An object that represents a per request timeout. The default value is 15 seconds. If you set a higher timeout, then make sure that the higher value is set for each App Mesh resource in a conversation. For example, if a virtual node backend uses a virtual router provider to route to another virtual node, then the timeout should be greater than 15 seconds for the source and destination virtual node and the route.
unit -> (string)
value -> (long)
http2Route -> (structure)
An object that represents the specification of an HTTP/2 route.
action -> (structure)
An object that represents the action to take if a match is determined.
weightedTargets -> (list)
An object that represents the targets that traffic is routed to when a request matches the route.
(structure)
An object that represents a target and its relative weight. Traffic is distributed across targets according to their relative weight. For example, a weighted target with a relative weight of 50 receives five times as much traffic as one with a relative weight of 10. The total weight for all targets combined must be less than or equal to 100.
port -> (integer)
virtualNode -> (string)
weight -> (integer)
match -> (structure)
An object that represents the criteria for determining a request match.
headers -> (list)
The client request headers to match on.
(structure)
An object that represents the HTTP header in the request.
invert -> (boolean)
True to match anything except the match criteria. The default value is False .match -> (tagged union structure)
The HeaderMatchMethod object.
Note
This is a Tagged Union structure. Only one of the following top level keys can be set:exact, prefix, range, regex, suffix.exact -> (string)
prefix -> (string)
range -> (structure)
An object that represents the range of values to match on.
end -> (long)
start -> (long)
regex -> (string)
suffix -> (string)
name -> (string)
method -> (string)
path -> (structure)
The client request path to match on.
exact -> (string)
regex -> (string)
port -> (integer)
prefix -> (string)
/ , which by itself matches all requests to the virtual service name. You can also match for path-based routing of requests. For example, if your virtual service name is my-service.local and you want the route to match requests to my-service.local/metrics , your prefix should be /metrics .queryParameters -> (list)
The client request query parameters to match on.
(structure)
An object that represents the query parameter in the request.
match -> (structure)
The query parameter to match on.
exact -> (string)
name -> (string)
scheme -> (string)
retryPolicy -> (structure)
An object that represents a retry policy.
httpRetryEvents -> (list)
Specify at least one of the following values.
- server-error – HTTP status codes 500, 501, 502, 503, 504, 505, 506, 507, 508, 510, and 511
- gateway-error – HTTP status codes 502, 503, and 504
- client-error – HTTP status code 409
- stream-error – Retry on refused stream
(string)
maxRetries -> (long)
perRetryTimeout -> (structure)
The timeout for each retry attempt.
unit -> (string)
value -> (long)
tcpRetryEvents -> (list)
Specify a valid value. The event occurs before any processing of a request has started and is encountered when the upstream is temporarily or permanently unavailable.
(string)
timeout -> (structure)
An object that represents types of timeouts.
idle -> (structure)
An object that represents an idle timeout. An idle timeout bounds the amount of time that a connection may be idle. The default value is none.
unit -> (string)
value -> (long)
perRequest -> (structure)
An object that represents a per request timeout. The default value is 15 seconds. If you set a higher timeout, then make sure that the higher value is set for each App Mesh resource in a conversation. For example, if a virtual node backend uses a virtual router provider to route to another virtual node, then the timeout should be greater than 15 seconds for the source and destination virtual node and the route.
unit -> (string)
value -> (long)
httpRoute -> (structure)
An object that represents the specification of an HTTP route.
action -> (structure)
An object that represents the action to take if a match is determined.
weightedTargets -> (list)
An object that represents the targets that traffic is routed to when a request matches the route.
(structure)
An object that represents a target and its relative weight. Traffic is distributed across targets according to their relative weight. For example, a weighted target with a relative weight of 50 receives five times as much traffic as one with a relative weight of 10. The total weight for all targets combined must be less than or equal to 100.
port -> (integer)
virtualNode -> (string)
weight -> (integer)
match -> (structure)
An object that represents the criteria for determining a request match.
headers -> (list)
The client request headers to match on.
(structure)
An object that represents the HTTP header in the request.
invert -> (boolean)
True to match anything except the match criteria. The default value is False .match -> (tagged union structure)
The HeaderMatchMethod object.
Note
This is a Tagged Union structure. Only one of the following top level keys can be set:exact, prefix, range, regex, suffix.exact -> (string)
prefix -> (string)
range -> (structure)
An object that represents the range of values to match on.
end -> (long)
start -> (long)
regex -> (string)
suffix -> (string)
name -> (string)
method -> (string)
path -> (structure)
The client request path to match on.
exact -> (string)
regex -> (string)
port -> (integer)
prefix -> (string)
/ , which by itself matches all requests to the virtual service name. You can also match for path-based routing of requests. For example, if your virtual service name is my-service.local and you want the route to match requests to my-service.local/metrics , your prefix should be /metrics .queryParameters -> (list)
The client request query parameters to match on.
(structure)
An object that represents the query parameter in the request.
match -> (structure)
The query parameter to match on.
exact -> (string)
name -> (string)
scheme -> (string)
retryPolicy -> (structure)
An object that represents a retry policy.
httpRetryEvents -> (list)
Specify at least one of the following values.
- server-error – HTTP status codes 500, 501, 502, 503, 504, 505, 506, 507, 508, 510, and 511
- gateway-error – HTTP status codes 502, 503, and 504
- client-error – HTTP status code 409
- stream-error – Retry on refused stream
(string)
maxRetries -> (long)
perRetryTimeout -> (structure)
The timeout for each retry attempt.
unit -> (string)
value -> (long)
tcpRetryEvents -> (list)
Specify a valid value. The event occurs before any processing of a request has started and is encountered when the upstream is temporarily or permanently unavailable.
(string)
timeout -> (structure)
An object that represents types of timeouts.
idle -> (structure)
An object that represents an idle timeout. An idle timeout bounds the amount of time that a connection may be idle. The default value is none.
unit -> (string)
value -> (long)
perRequest -> (structure)
An object that represents a per request timeout. The default value is 15 seconds. If you set a higher timeout, then make sure that the higher value is set for each App Mesh resource in a conversation. For example, if a virtual node backend uses a virtual router provider to route to another virtual node, then the timeout should be greater than 15 seconds for the source and destination virtual node and the route.
unit -> (string)
value -> (long)
priority -> (integer)
tcpRoute -> (structure)
An object that represents the specification of a TCP route.
action -> (structure)
The action to take if a match is determined.
weightedTargets -> (list)
An object that represents the targets that traffic is routed to when a request matches the route.
(structure)
An object that represents a target and its relative weight. Traffic is distributed across targets according to their relative weight. For example, a weighted target with a relative weight of 50 receives five times as much traffic as one with a relative weight of 10. The total weight for all targets combined must be less than or equal to 100.
port -> (integer)
virtualNode -> (string)
weight -> (integer)
match -> (structure)
An object that represents the criteria for determining a request match.
port -> (integer)
timeout -> (structure)
An object that represents types of timeouts.
idle -> (structure)
An object that represents an idle timeout. An idle timeout bounds the amount of time that a connection may be idle. The default value is none.
unit -> (string)
value -> (long)
status -> (structure)
The status of the route.
status -> (string)
virtualRouterName -> (string)
© Copyright 2025, Amazon Web Services. Created using Sphinx.