1. Packages
  2. Packages
  3. Ibm Provider
  4. API Docs
  5. getLogsPolicy
Viewing docs for ibm 2.2.2
published on Wednesday, May 27, 2026 by ibm-cloud
Viewing docs for ibm 2.2.2
published on Wednesday, May 27, 2026 by ibm-cloud

    Provides a read-only data source to retrieve information about a logs_policy. You can then reference the fields of the data source in other resources within the same configuration by using interpolation syntax.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as ibm from "@pulumi/ibm";
    
    const logsPolicyInstance = ibm.getLogsPolicy({
        instanceId: logsPolicyInstanceIbmLogsPolicy.instanceId,
        region: logsPolicyInstanceIbmLogsPolicy.region,
        logsPolicyId: logsPolicyInstanceIbmLogsPolicy.policyId,
    });
    
    import pulumi
    import pulumi_ibm as ibm
    
    logs_policy_instance = ibm.get_logs_policy(instance_id=logs_policy_instance_ibm_logs_policy["instanceId"],
        region=logs_policy_instance_ibm_logs_policy["region"],
        logs_policy_id=logs_policy_instance_ibm_logs_policy["policyId"])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/ibm/v2/ibm"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := ibm.LookupLogsPolicy(ctx, &ibm.LookupLogsPolicyArgs{
    			InstanceId:   logsPolicyInstanceIbmLogsPolicy.InstanceId,
    			Region:       pulumi.StringRef(logsPolicyInstanceIbmLogsPolicy.Region),
    			LogsPolicyId: logsPolicyInstanceIbmLogsPolicy.PolicyId,
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Ibm = Pulumi.Ibm;
    
    return await Deployment.RunAsync(() => 
    {
        var logsPolicyInstance = Ibm.GetLogsPolicy.Invoke(new()
        {
            InstanceId = logsPolicyInstanceIbmLogsPolicy.InstanceId,
            Region = logsPolicyInstanceIbmLogsPolicy.Region,
            LogsPolicyId = logsPolicyInstanceIbmLogsPolicy.PolicyId,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.ibm.IbmFunctions;
    import com.pulumi.ibm.inputs.GetLogsPolicyArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            final var logsPolicyInstance = IbmFunctions.getLogsPolicy(GetLogsPolicyArgs.builder()
                .instanceId(logsPolicyInstanceIbmLogsPolicy.instanceId())
                .region(logsPolicyInstanceIbmLogsPolicy.region())
                .logsPolicyId(logsPolicyInstanceIbmLogsPolicy.policyId())
                .build());
    
        }
    }
    
    variables:
      logsPolicyInstance:
        fn::invoke:
          function: ibm:getLogsPolicy
          arguments:
            instanceId: ${logsPolicyInstanceIbmLogsPolicy.instanceId}
            region: ${logsPolicyInstanceIbmLogsPolicy.region}
            logsPolicyId: ${logsPolicyInstanceIbmLogsPolicy.policyId}
    
    Example coming soon!
    

    Using getLogsPolicy

    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 getLogsPolicy(args: GetLogsPolicyArgs, opts?: InvokeOptions): Promise<GetLogsPolicyResult>
    function getLogsPolicyOutput(args: GetLogsPolicyOutputArgs, opts?: InvokeOptions): Output<GetLogsPolicyResult>
    def get_logs_policy(endpoint_type: Optional[str] = None,
                        id: Optional[str] = None,
                        instance_id: Optional[str] = None,
                        logs_policy_id: Optional[str] = None,
                        region: Optional[str] = None,
                        opts: Optional[InvokeOptions] = None) -> GetLogsPolicyResult
    def get_logs_policy_output(endpoint_type: pulumi.Input[Optional[str]] = None,
                        id: pulumi.Input[Optional[str]] = None,
                        instance_id: pulumi.Input[Optional[str]] = None,
                        logs_policy_id: pulumi.Input[Optional[str]] = None,
                        region: pulumi.Input[Optional[str]] = None,
                        opts: Optional[InvokeOptions] = None) -> Output[GetLogsPolicyResult]
    func LookupLogsPolicy(ctx *Context, args *LookupLogsPolicyArgs, opts ...InvokeOption) (*LookupLogsPolicyResult, error)
    func LookupLogsPolicyOutput(ctx *Context, args *LookupLogsPolicyOutputArgs, opts ...InvokeOption) LookupLogsPolicyResultOutput

    > Note: This function is named LookupLogsPolicy in the Go SDK.

    public static class GetLogsPolicy 
    {
        public static Task<GetLogsPolicyResult> InvokeAsync(GetLogsPolicyArgs args, InvokeOptions? opts = null)
        public static Output<GetLogsPolicyResult> Invoke(GetLogsPolicyInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetLogsPolicyResult> getLogsPolicy(GetLogsPolicyArgs args, InvokeOptions options)
    public static Output<GetLogsPolicyResult> getLogsPolicy(GetLogsPolicyArgs args, InvokeOptions options)
    
    fn::invoke:
      function: ibm:index/getLogsPolicy:getLogsPolicy
      arguments:
        # arguments dictionary
    data "ibm_getlogspolicy" "name" {
        # arguments
    }

    The following arguments are supported:

    InstanceId string
    Cloud Logs Instance GUID.
    LogsPolicyId string
    ID of policy.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    EndpointType string
    Id string
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    Region string
    Cloud Logs Instance Region.
    InstanceId string
    Cloud Logs Instance GUID.
    LogsPolicyId string
    ID of policy.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    EndpointType string
    Id string
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    Region string
    Cloud Logs Instance Region.
    instance_id string
    Cloud Logs Instance GUID.
    logs_policy_id string
    ID of policy.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    endpoint_type string
    id string
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    region string
    Cloud Logs Instance Region.
    instanceId String
    Cloud Logs Instance GUID.
    logsPolicyId String
    ID of policy.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    endpointType String
    id String
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    region String
    Cloud Logs Instance Region.
    instanceId string
    Cloud Logs Instance GUID.
    logsPolicyId string
    ID of policy.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    endpointType string
    id string
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    region string
    Cloud Logs Instance Region.
    instance_id str
    Cloud Logs Instance GUID.
    logs_policy_id str
    ID of policy.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    endpoint_type str
    id str
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    region str
    Cloud Logs Instance Region.
    instanceId String
    Cloud Logs Instance GUID.
    logsPolicyId String
    ID of policy.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    endpointType String
    id String
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    region String
    Cloud Logs Instance Region.

    getLogsPolicy Result

    The following output properties are available:

    ApplicationRules List<GetLogsPolicyApplicationRule>
    (List) Rule for matching the application name. Nested schema for application_rule:
    ArchiveRetentionTag string
    (String) Archive retention tag. Required when retention tags are active. Cannot be set when retention tags are not active.

    • Constraints: The maximum length is 255 characters. The minimum length is 1 character. The value must match regular expression /^[a-zA-Z0-9_-]+$/.
    ArchiveRetentions List<GetLogsPolicyArchiveRetention>
    (List) Deprecated: This field is deprecated and will be removed in a future version. Use archive_retention_tag instead. Archive retention definition. Nested schema for archive_retention:

    Deprecated: Deprecated

    Befores List<GetLogsPolicyBefore>
    (List) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies. Nested schema for before:
    CompanyId double
    (Integer) Company ID.

    • Constraints: The maximum value is 2147483647. The minimum value is 0.
    CreatedAt string
    (String) Created at date at utc+0.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^"\\d{4}-\\d{2}-\\d{2} \\d{2}:\\d{2}:\\d{2}"$/.
    Deleted bool
    (Boolean) Soft deletion flag.
    Description string
    (String) Description of policy.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}0-9_\\-\\s]+$/.
    Enabled bool
    (Boolean) Flag to enable or disable a policy. This flag is supported only while updating a policy, since the policies are always enabled during creation.
    Id string
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    InstanceId string
    LogRules List<GetLogsPolicyLogRule>
    (List) Log rules. Nested schema for log_rules:
    LogsPolicyId string
    Name string
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    Order double
    (Integer) Order of policy in relation to other policies.

    • Constraints: The maximum value is 2147483647. The minimum value is 0.
    Priority string
    (String) The data pipeline sources that match the policy rules will continue to be processed by Cloud Logs.

    • Constraints: Allowable values are: type_unspecified, type_block, type_low, type_medium, type_high.
    Region string
    SubsystemRules List<GetLogsPolicySubsystemRule>
    (List) Rule for matching the application name. Nested schema for subsystem_rule:
    UpdatedAt string
    (String) Updated at date at utc+0.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^"\\d{4}-\\d{2}-\\d{2} \\d{2}:\\d{2}:\\d{2}"$/.
    EndpointType string
    ApplicationRules []GetLogsPolicyApplicationRule
    (List) Rule for matching the application name. Nested schema for application_rule:
    ArchiveRetentionTag string
    (String) Archive retention tag. Required when retention tags are active. Cannot be set when retention tags are not active.

    • Constraints: The maximum length is 255 characters. The minimum length is 1 character. The value must match regular expression /^[a-zA-Z0-9_-]+$/.
    ArchiveRetentions []GetLogsPolicyArchiveRetention
    (List) Deprecated: This field is deprecated and will be removed in a future version. Use archive_retention_tag instead. Archive retention definition. Nested schema for archive_retention:

    Deprecated: Deprecated

    Befores []GetLogsPolicyBefore
    (List) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies. Nested schema for before:
    CompanyId float64
    (Integer) Company ID.

    • Constraints: The maximum value is 2147483647. The minimum value is 0.
    CreatedAt string
    (String) Created at date at utc+0.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^"\\d{4}-\\d{2}-\\d{2} \\d{2}:\\d{2}:\\d{2}"$/.
    Deleted bool
    (Boolean) Soft deletion flag.
    Description string
    (String) Description of policy.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}0-9_\\-\\s]+$/.
    Enabled bool
    (Boolean) Flag to enable or disable a policy. This flag is supported only while updating a policy, since the policies are always enabled during creation.
    Id string
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    InstanceId string
    LogRules []GetLogsPolicyLogRule
    (List) Log rules. Nested schema for log_rules:
    LogsPolicyId string
    Name string
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    Order float64
    (Integer) Order of policy in relation to other policies.

    • Constraints: The maximum value is 2147483647. The minimum value is 0.
    Priority string
    (String) The data pipeline sources that match the policy rules will continue to be processed by Cloud Logs.

    • Constraints: Allowable values are: type_unspecified, type_block, type_low, type_medium, type_high.
    Region string
    SubsystemRules []GetLogsPolicySubsystemRule
    (List) Rule for matching the application name. Nested schema for subsystem_rule:
    UpdatedAt string
    (String) Updated at date at utc+0.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^"\\d{4}-\\d{2}-\\d{2} \\d{2}:\\d{2}:\\d{2}"$/.
    EndpointType string
    application_rules list(object)
    (List) Rule for matching the application name. Nested schema for application_rule:
    archive_retention_tag string
    (String) Archive retention tag. Required when retention tags are active. Cannot be set when retention tags are not active.

    • Constraints: The maximum length is 255 characters. The minimum length is 1 character. The value must match regular expression /^[a-zA-Z0-9_-]+$/.
    archive_retentions list(object)
    (List) Deprecated: This field is deprecated and will be removed in a future version. Use archive_retention_tag instead. Archive retention definition. Nested schema for archive_retention:

    Deprecated: Deprecated

    befores list(object)
    (List) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies. Nested schema for before:
    company_id number
    (Integer) Company ID.

    • Constraints: The maximum value is 2147483647. The minimum value is 0.
    created_at string
    (String) Created at date at utc+0.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^"\\d{4}-\\d{2}-\\d{2} \\d{2}:\\d{2}:\\d{2}"$/.
    deleted bool
    (Boolean) Soft deletion flag.
    description string
    (String) Description of policy.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}0-9_\\-\\s]+$/.
    enabled bool
    (Boolean) Flag to enable or disable a policy. This flag is supported only while updating a policy, since the policies are always enabled during creation.
    id string
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    instance_id string
    log_rules list(object)
    (List) Log rules. Nested schema for log_rules:
    logs_policy_id string
    name string
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    order number
    (Integer) Order of policy in relation to other policies.

    • Constraints: The maximum value is 2147483647. The minimum value is 0.
    priority string
    (String) The data pipeline sources that match the policy rules will continue to be processed by Cloud Logs.

    • Constraints: Allowable values are: type_unspecified, type_block, type_low, type_medium, type_high.
    region string
    subsystem_rules list(object)
    (List) Rule for matching the application name. Nested schema for subsystem_rule:
    updated_at string
    (String) Updated at date at utc+0.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^"\\d{4}-\\d{2}-\\d{2} \\d{2}:\\d{2}:\\d{2}"$/.
    endpoint_type string
    applicationRules List<GetLogsPolicyApplicationRule>
    (List) Rule for matching the application name. Nested schema for application_rule:
    archiveRetentionTag String
    (String) Archive retention tag. Required when retention tags are active. Cannot be set when retention tags are not active.

    • Constraints: The maximum length is 255 characters. The minimum length is 1 character. The value must match regular expression /^[a-zA-Z0-9_-]+$/.
    archiveRetentions List<GetLogsPolicyArchiveRetention>
    (List) Deprecated: This field is deprecated and will be removed in a future version. Use archive_retention_tag instead. Archive retention definition. Nested schema for archive_retention:

    Deprecated: Deprecated

    befores List<GetLogsPolicyBefore>
    (List) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies. Nested schema for before:
    companyId Double
    (Integer) Company ID.

    • Constraints: The maximum value is 2147483647. The minimum value is 0.
    createdAt String
    (String) Created at date at utc+0.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^"\\d{4}-\\d{2}-\\d{2} \\d{2}:\\d{2}:\\d{2}"$/.
    deleted Boolean
    (Boolean) Soft deletion flag.
    description String
    (String) Description of policy.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}0-9_\\-\\s]+$/.
    enabled Boolean
    (Boolean) Flag to enable or disable a policy. This flag is supported only while updating a policy, since the policies are always enabled during creation.
    id String
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    instanceId String
    logRules List<GetLogsPolicyLogRule>
    (List) Log rules. Nested schema for log_rules:
    logsPolicyId String
    name String
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    order Double
    (Integer) Order of policy in relation to other policies.

    • Constraints: The maximum value is 2147483647. The minimum value is 0.
    priority String
    (String) The data pipeline sources that match the policy rules will continue to be processed by Cloud Logs.

    • Constraints: Allowable values are: type_unspecified, type_block, type_low, type_medium, type_high.
    region String
    subsystemRules List<GetLogsPolicySubsystemRule>
    (List) Rule for matching the application name. Nested schema for subsystem_rule:
    updatedAt String
    (String) Updated at date at utc+0.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^"\\d{4}-\\d{2}-\\d{2} \\d{2}:\\d{2}:\\d{2}"$/.
    endpointType String
    applicationRules GetLogsPolicyApplicationRule[]
    (List) Rule for matching the application name. Nested schema for application_rule:
    archiveRetentionTag string
    (String) Archive retention tag. Required when retention tags are active. Cannot be set when retention tags are not active.

    • Constraints: The maximum length is 255 characters. The minimum length is 1 character. The value must match regular expression /^[a-zA-Z0-9_-]+$/.
    archiveRetentions GetLogsPolicyArchiveRetention[]
    (List) Deprecated: This field is deprecated and will be removed in a future version. Use archive_retention_tag instead. Archive retention definition. Nested schema for archive_retention:

    Deprecated: Deprecated

    befores GetLogsPolicyBefore[]
    (List) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies. Nested schema for before:
    companyId number
    (Integer) Company ID.

    • Constraints: The maximum value is 2147483647. The minimum value is 0.
    createdAt string
    (String) Created at date at utc+0.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^"\\d{4}-\\d{2}-\\d{2} \\d{2}:\\d{2}:\\d{2}"$/.
    deleted boolean
    (Boolean) Soft deletion flag.
    description string
    (String) Description of policy.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}0-9_\\-\\s]+$/.
    enabled boolean
    (Boolean) Flag to enable or disable a policy. This flag is supported only while updating a policy, since the policies are always enabled during creation.
    id string
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    instanceId string
    logRules GetLogsPolicyLogRule[]
    (List) Log rules. Nested schema for log_rules:
    logsPolicyId string
    name string
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    order number
    (Integer) Order of policy in relation to other policies.

    • Constraints: The maximum value is 2147483647. The minimum value is 0.
    priority string
    (String) The data pipeline sources that match the policy rules will continue to be processed by Cloud Logs.

    • Constraints: Allowable values are: type_unspecified, type_block, type_low, type_medium, type_high.
    region string
    subsystemRules GetLogsPolicySubsystemRule[]
    (List) Rule for matching the application name. Nested schema for subsystem_rule:
    updatedAt string
    (String) Updated at date at utc+0.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^"\\d{4}-\\d{2}-\\d{2} \\d{2}:\\d{2}:\\d{2}"$/.
    endpointType string
    application_rules Sequence[GetLogsPolicyApplicationRule]
    (List) Rule for matching the application name. Nested schema for application_rule:
    archive_retention_tag str
    (String) Archive retention tag. Required when retention tags are active. Cannot be set when retention tags are not active.

    • Constraints: The maximum length is 255 characters. The minimum length is 1 character. The value must match regular expression /^[a-zA-Z0-9_-]+$/.
    archive_retentions Sequence[GetLogsPolicyArchiveRetention]
    (List) Deprecated: This field is deprecated and will be removed in a future version. Use archive_retention_tag instead. Archive retention definition. Nested schema for archive_retention:

    Deprecated: Deprecated

    befores Sequence[GetLogsPolicyBefore]
    (List) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies. Nested schema for before:
    company_id float
    (Integer) Company ID.

    • Constraints: The maximum value is 2147483647. The minimum value is 0.
    created_at str
    (String) Created at date at utc+0.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^"\\d{4}-\\d{2}-\\d{2} \\d{2}:\\d{2}:\\d{2}"$/.
    deleted bool
    (Boolean) Soft deletion flag.
    description str
    (String) Description of policy.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}0-9_\\-\\s]+$/.
    enabled bool
    (Boolean) Flag to enable or disable a policy. This flag is supported only while updating a policy, since the policies are always enabled during creation.
    id str
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    instance_id str
    log_rules Sequence[GetLogsPolicyLogRule]
    (List) Log rules. Nested schema for log_rules:
    logs_policy_id str
    name str
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    order float
    (Integer) Order of policy in relation to other policies.

    • Constraints: The maximum value is 2147483647. The minimum value is 0.
    priority str
    (String) The data pipeline sources that match the policy rules will continue to be processed by Cloud Logs.

    • Constraints: Allowable values are: type_unspecified, type_block, type_low, type_medium, type_high.
    region str
    subsystem_rules Sequence[GetLogsPolicySubsystemRule]
    (List) Rule for matching the application name. Nested schema for subsystem_rule:
    updated_at str
    (String) Updated at date at utc+0.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^"\\d{4}-\\d{2}-\\d{2} \\d{2}:\\d{2}:\\d{2}"$/.
    endpoint_type str
    applicationRules List<Property Map>
    (List) Rule for matching the application name. Nested schema for application_rule:
    archiveRetentionTag String
    (String) Archive retention tag. Required when retention tags are active. Cannot be set when retention tags are not active.

    • Constraints: The maximum length is 255 characters. The minimum length is 1 character. The value must match regular expression /^[a-zA-Z0-9_-]+$/.
    archiveRetentions List<Property Map>
    (List) Deprecated: This field is deprecated and will be removed in a future version. Use archive_retention_tag instead. Archive retention definition. Nested schema for archive_retention:

    Deprecated: Deprecated

    befores List<Property Map>
    (List) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies. Nested schema for before:
    companyId Number
    (Integer) Company ID.

    • Constraints: The maximum value is 2147483647. The minimum value is 0.
    createdAt String
    (String) Created at date at utc+0.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^"\\d{4}-\\d{2}-\\d{2} \\d{2}:\\d{2}:\\d{2}"$/.
    deleted Boolean
    (Boolean) Soft deletion flag.
    description String
    (String) Description of policy.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}0-9_\\-\\s]+$/.
    enabled Boolean
    (Boolean) Flag to enable or disable a policy. This flag is supported only while updating a policy, since the policies are always enabled during creation.
    id String
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    instanceId String
    logRules List<Property Map>
    (List) Log rules. Nested schema for log_rules:
    logsPolicyId String
    name String
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    order Number
    (Integer) Order of policy in relation to other policies.

    • Constraints: The maximum value is 2147483647. The minimum value is 0.
    priority String
    (String) The data pipeline sources that match the policy rules will continue to be processed by Cloud Logs.

    • Constraints: Allowable values are: type_unspecified, type_block, type_low, type_medium, type_high.
    region String
    subsystemRules List<Property Map>
    (List) Rule for matching the application name. Nested schema for subsystem_rule:
    updatedAt String
    (String) Updated at date at utc+0.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^"\\d{4}-\\d{2}-\\d{2} \\d{2}:\\d{2}:\\d{2}"$/.
    endpointType String

    Supporting Types

    GetLogsPolicyApplicationRule

    Name string
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    RuleTypeId string
    (String) Identifier of the rule.

    • Constraints: Allowable values are: unspecified, is, is_not, start_with, includes.
    Name string
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    RuleTypeId string
    (String) Identifier of the rule.

    • Constraints: Allowable values are: unspecified, is, is_not, start_with, includes.
    name string
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    rule_type_id string
    (String) Identifier of the rule.

    • Constraints: Allowable values are: unspecified, is, is_not, start_with, includes.
    name String
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    ruleTypeId String
    (String) Identifier of the rule.

    • Constraints: Allowable values are: unspecified, is, is_not, start_with, includes.
    name string
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    ruleTypeId string
    (String) Identifier of the rule.

    • Constraints: Allowable values are: unspecified, is, is_not, start_with, includes.
    name str
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    rule_type_id str
    (String) Identifier of the rule.

    • Constraints: Allowable values are: unspecified, is, is_not, start_with, includes.
    name String
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    ruleTypeId String
    (String) Identifier of the rule.

    • Constraints: Allowable values are: unspecified, is, is_not, start_with, includes.

    GetLogsPolicyArchiveRetention

    Id string
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    Id string
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    id string
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    id String
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    id string
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    id str
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    id String
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.

    GetLogsPolicyBefore

    Id string
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    Name string
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    Id string
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    Name string
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    id string
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    name string
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    id String
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    name String
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    id string
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    name string
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    id str
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    name str
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    id String
    (String) The policy will be inserted immediately before the existing policy with this ID. If unspecified, the policy will be inserted after all existing policies.

    • Constraints: The maximum length is 36 characters. The minimum length is 36 characters. The value must match regular expression /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.
    name String
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.

    GetLogsPolicyLogRule

    Severities List<string>
    (List) The source severities to be used when matching.

    • Constraints: Allowable list items are: debug, verbose, info, warning, error, critical. The maximum length is 4096 items. The minimum length is 0 items.
    Severities []string
    (List) The source severities to be used when matching.

    • Constraints: Allowable list items are: debug, verbose, info, warning, error, critical. The maximum length is 4096 items. The minimum length is 0 items.
    severities list(string)
    (List) The source severities to be used when matching.

    • Constraints: Allowable list items are: debug, verbose, info, warning, error, critical. The maximum length is 4096 items. The minimum length is 0 items.
    severities List<String>
    (List) The source severities to be used when matching.

    • Constraints: Allowable list items are: debug, verbose, info, warning, error, critical. The maximum length is 4096 items. The minimum length is 0 items.
    severities string[]
    (List) The source severities to be used when matching.

    • Constraints: Allowable list items are: debug, verbose, info, warning, error, critical. The maximum length is 4096 items. The minimum length is 0 items.
    severities Sequence[str]
    (List) The source severities to be used when matching.

    • Constraints: Allowable list items are: debug, verbose, info, warning, error, critical. The maximum length is 4096 items. The minimum length is 0 items.
    severities List<String>
    (List) The source severities to be used when matching.

    • Constraints: Allowable list items are: debug, verbose, info, warning, error, critical. The maximum length is 4096 items. The minimum length is 0 items.

    GetLogsPolicySubsystemRule

    Name string
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    RuleTypeId string
    (String) Identifier of the rule.

    • Constraints: Allowable values are: unspecified, is, is_not, start_with, includes.
    Name string
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    RuleTypeId string
    (String) Identifier of the rule.

    • Constraints: Allowable values are: unspecified, is, is_not, start_with, includes.
    name string
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    rule_type_id string
    (String) Identifier of the rule.

    • Constraints: Allowable values are: unspecified, is, is_not, start_with, includes.
    name String
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    ruleTypeId String
    (String) Identifier of the rule.

    • Constraints: Allowable values are: unspecified, is, is_not, start_with, includes.
    name string
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    ruleTypeId string
    (String) Identifier of the rule.

    • Constraints: Allowable values are: unspecified, is, is_not, start_with, includes.
    name str
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    rule_type_id str
    (String) Identifier of the rule.

    • Constraints: Allowable values are: unspecified, is, is_not, start_with, includes.
    name String
    (String) Name of the rule. Multiple values can be provided as comma separated string of values.

    • Constraints: The maximum length is 4096 characters. The minimum length is 1 character. The value must match regular expression /^[\\p{L}\\p{N}\\p{P}\\p{Z}\\p{S}\\p{M}]+$/.
    ruleTypeId String
    (String) Identifier of the rule.

    • Constraints: Allowable values are: unspecified, is, is_not, start_with, includes.

    Package Details

    Repository
    ibm ibm-cloud/terraform-provider-ibm
    License
    Notes
    This Pulumi package is based on the ibm Terraform Provider.
    Viewing docs for ibm 2.2.2
    published on Wednesday, May 27, 2026 by ibm-cloud

      Try Pulumi Cloud free.
      Your team will thank you.

      Start free trial