CloudWatchLogsClient.describe_account_policies
rboto-cloudwatch-logs==0.4.0 · Service index · Types
Model summary (excerpt): Returns a list of all CloudWatch Logs account policies in the account. To use this operation, you must be signed on with the correct permissions depending on the type of policy that you are retrieving information for. To see data protection policies, you must have the logs:GetDataProtectionPolicy and logs:DescribeAccountPolicies permissions. To see subscription filter policies, you must have...
Install and imports
from rboto import CloudWatchLogsClient
from collections.abc import Sequence
from rboto_cloudwatch_logs.types import (
DescribeAccountPoliciesOutput,
PolicyType,
)
Signature
async def describe_account_policies(
*,
policy_type: PolicyType,
policy_name: str | None = None,
account_identifiers: Sequence[str] | None = None,
next_token: str | None = None,
) -> DescribeAccountPoliciesOutput: ...
Arguments without defaults are required. None omits an optional request argument. Static types do not validate resource existence, permissions, lengths, ranges, or conditional service requirements.
Arguments
| Argument | Required | Model notes (excerpt) |
|---|---|---|
policy_type |
Yes | Use this parameter to limit the returned policies to only the policies that match the policy type that you specify. |
policy_name |
No | Use this parameter to limit the returned policies to only the policy with the name that you specify. |
account_identifiers |
No | If you are using an account that is set up as a monitoring account for CloudWatch unified cross-account observability, you can use this to specify the account ID of a source account. If you do, the operation returns the account policy for the specified account. Currently, you can specify only one account ID in this parameter. If you omit this parameter, only the policy in the current account... |
next_token |
No | The token for the next set of items to return. (You received this token from a previous call.) |
Output
DescribeAccountPoliciesOutput.
Read-only native attributes, accessed as response.field. Collection getters materialize Python values; to_dict() recursively materializes a mapping. Streams are consumed once.
| Field | Type | Presence | References |
|---|---|---|---|
account_policies |
list[AccountPolicyOutput] | None |
Always present | AccountPolicyOutput |
next_token |
str | None |
Always present | — |
| None means a value can be absent. Output mappings include every declared key; optional input keys may be omitted. Unknown output enum/union variants are not automatically valid inputs.
Related types
DescribeAccountPoliciesOutput, PolicyType
Follow these links for nested inputs and outputs; recursive types link back to the same type page.
Pagination and streaming
No generated paginator for this operation.
No output stream.
Errors
Import from rboto_cloudwatch_logs.exceptions:
InvalidParameterError, OperationAbortedError, ResourceNotFoundError, ServiceUnavailableError.
Other service failures use the service base error; credential, transport and timeout failures use shared errors.