ElastiCache.Client.
describe_cache_security_groups
(**kwargs)¶Returns a list of cache security group descriptions. If a cache security group name is specified, the list contains only the description of that group. This applicable only when you have ElastiCache in Classic setup
See also: AWS API Documentation
Request Syntax
response = client.describe_cache_security_groups(
CacheSecurityGroupName='string',
MaxRecords=123,
Marker='string'
)
The maximum number of records to include in the response. If more records exist than the specified MaxRecords
value, a marker is included in the response so that the remaining results can be retrieved.
Default: 100
Constraints: minimum 20; maximum 100.
MaxRecords
.dict
Response Syntax
{
'Marker': 'string',
'CacheSecurityGroups': [
{
'OwnerId': 'string',
'CacheSecurityGroupName': 'string',
'Description': 'string',
'EC2SecurityGroups': [
{
'Status': 'string',
'EC2SecurityGroupName': 'string',
'EC2SecurityGroupOwnerId': 'string'
},
],
'ARN': 'string'
},
]
}
Response Structure
(dict) --
Represents the output of a DescribeCacheSecurityGroups
operation.
Marker (string) --
Provides an identifier to allow retrieval of paginated results.
CacheSecurityGroups (list) --
A list of cache security groups. Each element in the list contains detailed information about one group.
(dict) --
Represents the output of one of the following operations:
AuthorizeCacheSecurityGroupIngress
CreateCacheSecurityGroup
RevokeCacheSecurityGroupIngress
OwnerId (string) --
The Amazon account ID of the cache security group owner.
CacheSecurityGroupName (string) --
The name of the cache security group.
Description (string) --
The description of the cache security group.
EC2SecurityGroups (list) --
A list of Amazon EC2 security groups that are associated with this cache security group.
(dict) --
Provides ownership and status information for an Amazon EC2 security group.
Status (string) --
The status of the Amazon EC2 security group.
EC2SecurityGroupName (string) --
The name of the Amazon EC2 security group.
EC2SecurityGroupOwnerId (string) --
The Amazon account ID of the Amazon EC2 security group owner.
ARN (string) --
The ARN of the cache security group,
Exceptions
ElastiCache.Client.exceptions.CacheSecurityGroupNotFoundFault
ElastiCache.Client.exceptions.InvalidParameterValueException
ElastiCache.Client.exceptions.InvalidParameterCombinationException
Examples
Returns a list of cache security group descriptions. If a cache security group name is specified, the list contains only the description of that group.
response = client.describe_cache_security_groups(
CacheSecurityGroupName='my-sec-group',
)
print(response)
Expected Output:
{
'ResponseMetadata': {
'...': '...',
},
}