HEX
Server: Apache
System: Linux vps-cdc32557.vps.ovh.ca 5.15.0-156-generic #166-Ubuntu SMP Sat Aug 9 00:02:46 UTC 2025 x86_64
User: hanode (1017)
PHP: 7.4.33
Disabled: pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare,
Upload Files
File: //lib/python3/dist-packages/awscli/examples/ec2/reject-transit-gateway-vpc-attachments.rst
**To reject a transit gateway VPC attachment**

The following ``reject-transit-gateway-vpc-attachment`` example rejects the specified transit gateway VPC attachment. ::

    aws ec2 reject-transit-gateway-vpc-attachment \
        --transit-gateway-attachment-id tgw-attach-0a34fe6b4fEXAMPLE

Output::

    {
        "TransitGatewayVpcAttachment": {
            "TransitGatewayAttachmentId": "tgw-attach-0a34fe6b4fEXAMPLE",
            "TransitGatewayId": "tgw-0262a0e521EXAMPLE",
            "VpcId": "vpc-07e8ffd50fEXAMPLE",
            "VpcOwnerId": "111122223333",
            "State": "pending",
            "SubnetIds": [
                "subnet-0752213d59EXAMPLE"
            ],
            "CreationTime": "2019-07-10T17:33:46.000Z",
            "Options": {
                "DnsSupport": "enable",
                "Ipv6Support": "disable"
            }
        }
    }

For more information, see `Transit gateway attachments to a VPC <https://docs.aws.amazon.com/vpc/latest/tgw/tgw-vpc-attachments.html>`__ in the *Transit Gateways Guide*.