describe_resource_policies

CloudWatchLogs.Client.describe_resource_policies(**kwargs)

Lists the resource policies in this account.

See also: AWS API Documentation

Request Syntax

response = client.describe_resource_policies(
    nextToken='string',
    limit=123
)
Parameters
  • nextToken (string) -- The token for the next set of items to return. The token expires after 24 hours.
  • limit (integer) -- The maximum number of resource policies to be displayed with one call of this API.
Return type

dict

Returns

Response Syntax

{
    'resourcePolicies': [
        {
            'policyName': 'string',
            'policyDocument': 'string',
            'lastUpdatedTime': 123
        },
    ],
    'nextToken': 'string'
}

Response Structure

  • (dict) --

    • resourcePolicies (list) --

      The resource policies that exist in this account.

      • (dict) --

        A policy enabling one or more entities to put logs to a log group in this account.

        • policyName (string) --

          The name of the resource policy.

        • policyDocument (string) --

          The details of the policy.

        • lastUpdatedTime (integer) --

          Timestamp showing when this policy was last updated, expressed as the number of milliseconds after Jan 1, 1970 00:00:00 UTC .

    • nextToken (string) --

      The token for the next set of items to return. The token expires after 24 hours.

Exceptions

  • CloudWatchLogs.Client.exceptions.InvalidParameterException
  • CloudWatchLogs.Client.exceptions.ServiceUnavailableException