AWS Native is in preview. AWS Classic is fully supported.
aws-native.logs.getAccountPolicy
Explore with Pulumi AI
AWS Native is in preview. AWS Classic is fully supported.
The AWS::Logs::AccountPolicy resource specifies a CloudWatch Logs AccountPolicy.
Using getAccountPolicy
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getAccountPolicy(args: GetAccountPolicyArgs, opts?: InvokeOptions): Promise<GetAccountPolicyResult>
function getAccountPolicyOutput(args: GetAccountPolicyOutputArgs, opts?: InvokeOptions): Output<GetAccountPolicyResult>
def get_account_policy(account_id: Optional[str] = None,
policy_name: Optional[str] = None,
policy_type: Optional[AccountPolicyPolicyType] = None,
opts: Optional[InvokeOptions] = None) -> GetAccountPolicyResult
def get_account_policy_output(account_id: Optional[pulumi.Input[str]] = None,
policy_name: Optional[pulumi.Input[str]] = None,
policy_type: Optional[pulumi.Input[AccountPolicyPolicyType]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetAccountPolicyResult]
func LookupAccountPolicy(ctx *Context, args *LookupAccountPolicyArgs, opts ...InvokeOption) (*LookupAccountPolicyResult, error)
func LookupAccountPolicyOutput(ctx *Context, args *LookupAccountPolicyOutputArgs, opts ...InvokeOption) LookupAccountPolicyResultOutput
> Note: This function is named LookupAccountPolicy
in the Go SDK.
public static class GetAccountPolicy
{
public static Task<GetAccountPolicyResult> InvokeAsync(GetAccountPolicyArgs args, InvokeOptions? opts = null)
public static Output<GetAccountPolicyResult> Invoke(GetAccountPolicyInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetAccountPolicyResult> getAccountPolicy(GetAccountPolicyArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: aws-native:logs:getAccountPolicy
arguments:
# arguments dictionary
The following arguments are supported:
- Account
Id string - User account id
- Policy
Name string - The name of the account policy
- Policy
Type Pulumi.Aws Native. Logs. Account Policy Policy Type - Type of the policy.
- Account
Id string - User account id
- Policy
Name string - The name of the account policy
- Policy
Type AccountPolicy Policy Type - Type of the policy.
- account
Id String - User account id
- policy
Name String - The name of the account policy
- policy
Type AccountPolicy Policy Type - Type of the policy.
- account
Id string - User account id
- policy
Name string - The name of the account policy
- policy
Type AccountPolicy Policy Type - Type of the policy.
- account_
id str - User account id
- policy_
name str - The name of the account policy
- policy_
type AccountPolicy Policy Type - Type of the policy.
- account
Id String - User account id
- policy
Name String - The name of the account policy
- policy
Type "DATA_PROTECTION_POLICY" | "SUBSCRIPTION_FILTER_POLICY" - Type of the policy.
getAccountPolicy Result
The following output properties are available:
- Account
Id string - User account id
- Policy
Document string The body of the policy document you want to use for this topic.
You can only add one policy per PolicyType.
The policy must be in JSON string format.
Length Constraints: Maximum length of 30720
- Scope
Pulumi.
Aws Native. Logs. Account Policy Scope - Scope for policy application
- Selection
Criteria string - Log group selection criteria to apply policy only to a subset of log groups. SelectionCriteria string can be up to 25KB and cloudwatchlogs determines the length of selectionCriteria by using its UTF-8 bytes
- Account
Id string - User account id
- Policy
Document string The body of the policy document you want to use for this topic.
You can only add one policy per PolicyType.
The policy must be in JSON string format.
Length Constraints: Maximum length of 30720
- Scope
Account
Policy Scope - Scope for policy application
- Selection
Criteria string - Log group selection criteria to apply policy only to a subset of log groups. SelectionCriteria string can be up to 25KB and cloudwatchlogs determines the length of selectionCriteria by using its UTF-8 bytes
- account
Id String - User account id
- policy
Document String The body of the policy document you want to use for this topic.
You can only add one policy per PolicyType.
The policy must be in JSON string format.
Length Constraints: Maximum length of 30720
- scope
Account
Policy Scope - Scope for policy application
- selection
Criteria String - Log group selection criteria to apply policy only to a subset of log groups. SelectionCriteria string can be up to 25KB and cloudwatchlogs determines the length of selectionCriteria by using its UTF-8 bytes
- account
Id string - User account id
- policy
Document string The body of the policy document you want to use for this topic.
You can only add one policy per PolicyType.
The policy must be in JSON string format.
Length Constraints: Maximum length of 30720
- scope
Account
Policy Scope - Scope for policy application
- selection
Criteria string - Log group selection criteria to apply policy only to a subset of log groups. SelectionCriteria string can be up to 25KB and cloudwatchlogs determines the length of selectionCriteria by using its UTF-8 bytes
- account_
id str - User account id
- policy_
document str The body of the policy document you want to use for this topic.
You can only add one policy per PolicyType.
The policy must be in JSON string format.
Length Constraints: Maximum length of 30720
- scope
Account
Policy Scope - Scope for policy application
- selection_
criteria str - Log group selection criteria to apply policy only to a subset of log groups. SelectionCriteria string can be up to 25KB and cloudwatchlogs determines the length of selectionCriteria by using its UTF-8 bytes
- account
Id String - User account id
- policy
Document String The body of the policy document you want to use for this topic.
You can only add one policy per PolicyType.
The policy must be in JSON string format.
Length Constraints: Maximum length of 30720
- scope "ALL"
- Scope for policy application
- selection
Criteria String - Log group selection criteria to apply policy only to a subset of log groups. SelectionCriteria string can be up to 25KB and cloudwatchlogs determines the length of selectionCriteria by using its UTF-8 bytes
Supporting Types
AccountPolicyPolicyType
AccountPolicyScope
Package Details
- Repository
- AWS Native pulumi/pulumi-aws-native
- License
- Apache-2.0
AWS Native is in preview. AWS Classic is fully supported.