swap_environment_cnames(**kwargs)¶Swaps the CNAMEs of two environments.
See also: AWS API Documentation
Request Syntax
response = client.swap_environment_cnames(
    SourceEnvironmentId='string',
    SourceEnvironmentName='string',
    DestinationEnvironmentId='string',
    DestinationEnvironmentName='string'
)
The ID of the source environment.
Condition: You must specify at least the SourceEnvironmentID or the SourceEnvironmentName . You may also specify both. If you specify the SourceEnvironmentId , you must specify the DestinationEnvironmentId .
The name of the source environment.
Condition: You must specify at least the SourceEnvironmentID or the SourceEnvironmentName . You may also specify both. If you specify the SourceEnvironmentName , you must specify the DestinationEnvironmentName .
The ID of the destination environment.
Condition: You must specify at least the DestinationEnvironmentID or the DestinationEnvironmentName . You may also specify both. You must specify the SourceEnvironmentId with the DestinationEnvironmentId .
The name of the destination environment.
Condition: You must specify at least the DestinationEnvironmentID or the DestinationEnvironmentName . You may also specify both. You must specify the SourceEnvironmentName with the DestinationEnvironmentName .
None
Examples
The following operation swaps the assigned subdomains of two environments:
response = client.swap_environment_cnames(
    DestinationEnvironmentName='my-env-green',
    SourceEnvironmentName='my-env-blue',
)
print(response)
Expected Output:
{
    'ResponseMetadata': {
        '...': '...',
    },
}