1. Packages
  2. Ibm Provider
  3. API Docs
  4. getLogsView
ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud

ibm.getLogsView

Explore with Pulumi AI

ibm logo
ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud

    Provides a read-only data source to retrieve information about a logs_view. 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 logsViewInstance = ibm.getLogsView({
        instanceId: ibm_logs_view.logs_view_instance.instance_id,
        region: ibm_logs_view.logs_view_instance.region,
        logsViewId: ibm_logs_view.logs_view_instance.view_id,
    });
    
    import pulumi
    import pulumi_ibm as ibm
    
    logs_view_instance = ibm.get_logs_view(instance_id=ibm_logs_view["logs_view_instance"]["instance_id"],
        region=ibm_logs_view["logs_view_instance"]["region"],
        logs_view_id=ibm_logs_view["logs_view_instance"]["view_id"])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/ibm/ibm"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := ibm.LookupLogsView(ctx, &ibm.LookupLogsViewArgs{
    			InstanceId: ibm_logs_view.Logs_view_instance.Instance_id,
    			Region:     pulumi.StringRef(ibm_logs_view.Logs_view_instance.Region),
    			LogsViewId: ibm_logs_view.Logs_view_instance.View_id,
    		}, 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 logsViewInstance = Ibm.GetLogsView.Invoke(new()
        {
            InstanceId = ibm_logs_view.Logs_view_instance.Instance_id,
            Region = ibm_logs_view.Logs_view_instance.Region,
            LogsViewId = ibm_logs_view.Logs_view_instance.View_id,
        });
    
    });
    
    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.GetLogsViewArgs;
    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 logsViewInstance = IbmFunctions.getLogsView(GetLogsViewArgs.builder()
                .instanceId(ibm_logs_view.logs_view_instance().instance_id())
                .region(ibm_logs_view.logs_view_instance().region())
                .logsViewId(ibm_logs_view.logs_view_instance().view_id())
                .build());
    
        }
    }
    
    variables:
      logsViewInstance:
        fn::invoke:
          function: ibm:getLogsView
          arguments:
            instanceId: ${ibm_logs_view.logs_view_instance.instance_id}
            region: ${ibm_logs_view.logs_view_instance.region}
            logsViewId: ${ibm_logs_view.logs_view_instance.view_id}
    

    Using getLogsView

    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 getLogsView(args: GetLogsViewArgs, opts?: InvokeOptions): Promise<GetLogsViewResult>
    function getLogsViewOutput(args: GetLogsViewOutputArgs, opts?: InvokeOptions): Output<GetLogsViewResult>
    def get_logs_view(endpoint_type: Optional[str] = None,
                      id: Optional[str] = None,
                      instance_id: Optional[str] = None,
                      logs_view_id: Optional[float] = None,
                      region: Optional[str] = None,
                      opts: Optional[InvokeOptions] = None) -> GetLogsViewResult
    def get_logs_view_output(endpoint_type: Optional[pulumi.Input[str]] = None,
                      id: Optional[pulumi.Input[str]] = None,
                      instance_id: Optional[pulumi.Input[str]] = None,
                      logs_view_id: Optional[pulumi.Input[float]] = None,
                      region: Optional[pulumi.Input[str]] = None,
                      opts: Optional[InvokeOptions] = None) -> Output[GetLogsViewResult]
    func LookupLogsView(ctx *Context, args *LookupLogsViewArgs, opts ...InvokeOption) (*LookupLogsViewResult, error)
    func LookupLogsViewOutput(ctx *Context, args *LookupLogsViewOutputArgs, opts ...InvokeOption) LookupLogsViewResultOutput

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

    public static class GetLogsView 
    {
        public static Task<GetLogsViewResult> InvokeAsync(GetLogsViewArgs args, InvokeOptions? opts = null)
        public static Output<GetLogsViewResult> Invoke(GetLogsViewInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetLogsViewResult> getLogsView(GetLogsViewArgs args, InvokeOptions options)
    public static Output<GetLogsViewResult> getLogsView(GetLogsViewArgs args, InvokeOptions options)
    
    fn::invoke:
      function: ibm:index/getLogsView:getLogsView
      arguments:
        # arguments dictionary

    The following arguments are supported:

    InstanceId string
    Cloud Logs Instance GUID.
    LogsViewId double
    View id.
    EndpointType string
    Id string
    The unique identifier of the logs_view.
    Region string
    Cloud Logs Instance Region.
    InstanceId string
    Cloud Logs Instance GUID.
    LogsViewId float64
    View id.
    EndpointType string
    Id string
    The unique identifier of the logs_view.
    Region string
    Cloud Logs Instance Region.
    instanceId String
    Cloud Logs Instance GUID.
    logsViewId Double
    View id.
    endpointType String
    id String
    The unique identifier of the logs_view.
    region String
    Cloud Logs Instance Region.
    instanceId string
    Cloud Logs Instance GUID.
    logsViewId number
    View id.
    endpointType string
    id string
    The unique identifier of the logs_view.
    region string
    Cloud Logs Instance Region.
    instance_id str
    Cloud Logs Instance GUID.
    logs_view_id float
    View id.
    endpoint_type str
    id str
    The unique identifier of the logs_view.
    region str
    Cloud Logs Instance Region.
    instanceId String
    Cloud Logs Instance GUID.
    logsViewId Number
    View id.
    endpointType String
    id String
    The unique identifier of the logs_view.
    region String
    Cloud Logs Instance Region.

    getLogsView Result

    The following output properties are available:

    Filters List<GetLogsViewFilter>
    (List) Selected filters.

    • Constraints: The maximum length is 4096 items. The minimum length is 1 item. Nested schema for filters:
    FolderId string
    (String) View folder ID.

    • 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
    The unique identifier of the logs_view.
    InstanceId string
    LogsViewId double
    Name string
    (String) View name.

    • 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}]+$.
    Region string
    SearchQueries List<GetLogsViewSearchQuery>
    (List) View search query. Nested schema for search_query:
    TimeSelections List<GetLogsViewTimeSelection>
    (List) View time selection. Nested schema for time_selection:
    EndpointType string
    Filters []GetLogsViewFilter
    (List) Selected filters.

    • Constraints: The maximum length is 4096 items. The minimum length is 1 item. Nested schema for filters:
    FolderId string
    (String) View folder ID.

    • 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
    The unique identifier of the logs_view.
    InstanceId string
    LogsViewId float64
    Name string
    (String) View name.

    • 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}]+$.
    Region string
    SearchQueries []GetLogsViewSearchQuery
    (List) View search query. Nested schema for search_query:
    TimeSelections []GetLogsViewTimeSelection
    (List) View time selection. Nested schema for time_selection:
    EndpointType string
    filters List<GetLogsViewFilter>
    (List) Selected filters.

    • Constraints: The maximum length is 4096 items. The minimum length is 1 item. Nested schema for filters:
    folderId String
    (String) View folder ID.

    • 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
    The unique identifier of the logs_view.
    instanceId String
    logsViewId Double
    name String
    (String) View name.

    • 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}]+$.
    region String
    searchQueries List<GetLogsViewSearchQuery>
    (List) View search query. Nested schema for search_query:
    timeSelections List<GetLogsViewTimeSelection>
    (List) View time selection. Nested schema for time_selection:
    endpointType String
    filters GetLogsViewFilter[]
    (List) Selected filters.

    • Constraints: The maximum length is 4096 items. The minimum length is 1 item. Nested schema for filters:
    folderId string
    (String) View folder ID.

    • 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
    The unique identifier of the logs_view.
    instanceId string
    logsViewId number
    name string
    (String) View name.

    • 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}]+$.
    region string
    searchQueries GetLogsViewSearchQuery[]
    (List) View search query. Nested schema for search_query:
    timeSelections GetLogsViewTimeSelection[]
    (List) View time selection. Nested schema for time_selection:
    endpointType string
    filters Sequence[GetLogsViewFilter]
    (List) Selected filters.

    • Constraints: The maximum length is 4096 items. The minimum length is 1 item. Nested schema for filters:
    folder_id str
    (String) View folder ID.

    • 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
    The unique identifier of the logs_view.
    instance_id str
    logs_view_id float
    name str
    (String) View name.

    • 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}]+$.
    region str
    search_queries Sequence[GetLogsViewSearchQuery]
    (List) View search query. Nested schema for search_query:
    time_selections Sequence[GetLogsViewTimeSelection]
    (List) View time selection. Nested schema for time_selection:
    endpoint_type str
    filters List<Property Map>
    (List) Selected filters.

    • Constraints: The maximum length is 4096 items. The minimum length is 1 item. Nested schema for filters:
    folderId String
    (String) View folder ID.

    • 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
    The unique identifier of the logs_view.
    instanceId String
    logsViewId Number
    name String
    (String) View name.

    • 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}]+$.
    region String
    searchQueries List<Property Map>
    (List) View search query. Nested schema for search_query:
    timeSelections List<Property Map>
    (List) View time selection. Nested schema for time_selection:
    endpointType String

    Supporting Types

    GetLogsViewFilter

    Filters List<GetLogsViewFilterFilter>
    (List) Selected filters.

    • Constraints: The maximum length is 4096 items. The minimum length is 1 item. Nested schema for filters:
    Filters []GetLogsViewFilterFilter
    (List) Selected filters.

    • Constraints: The maximum length is 4096 items. The minimum length is 1 item. Nested schema for filters:
    filters List<GetLogsViewFilterFilter>
    (List) Selected filters.

    • Constraints: The maximum length is 4096 items. The minimum length is 1 item. Nested schema for filters:
    filters GetLogsViewFilterFilter[]
    (List) Selected filters.

    • Constraints: The maximum length is 4096 items. The minimum length is 1 item. Nested schema for filters:
    filters Sequence[GetLogsViewFilterFilter]
    (List) Selected filters.

    • Constraints: The maximum length is 4096 items. The minimum length is 1 item. Nested schema for filters:
    filters List<Property Map>
    (List) Selected filters.

    • Constraints: The maximum length is 4096 items. The minimum length is 1 item. Nested schema for filters:

    GetLogsViewFilterFilter

    Name string
    (String) View name.

    • 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}]+$.
    SelectedValues Dictionary<string, string>
    (Map) Filter selected values.
    Name string
    (String) View name.

    • 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}]+$.
    SelectedValues map[string]string
    (Map) Filter selected values.
    name String
    (String) View name.

    • 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}]+$.
    selectedValues Map<String,String>
    (Map) Filter selected values.
    name string
    (String) View name.

    • 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}]+$.
    selectedValues {[key: string]: string}
    (Map) Filter selected values.
    name str
    (String) View name.

    • 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}]+$.
    selected_values Mapping[str, str]
    (Map) Filter selected values.
    name String
    (String) View name.

    • 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}]+$.
    selectedValues Map<String>
    (Map) Filter selected values.

    GetLogsViewSearchQuery

    Query string
    (String) View search query.

    • 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}]+$.
    Query string
    (String) View search query.

    • 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}]+$.
    query String
    (String) View search query.

    • 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}]+$.
    query string
    (String) View search query.

    • 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}]+$.
    query str
    (String) View search query.

    • 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}]+$.
    query String
    (String) View search query.

    • 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}]+$.

    GetLogsViewTimeSelection

    CustomSelections List<GetLogsViewTimeSelectionCustomSelection>
    (List) Custom time selection. Nested schema for custom_selection:
    QuickSelections List<GetLogsViewTimeSelectionQuickSelection>
    (List) Quick time selection. Nested schema for quick_selection:
    CustomSelections []GetLogsViewTimeSelectionCustomSelection
    (List) Custom time selection. Nested schema for custom_selection:
    QuickSelections []GetLogsViewTimeSelectionQuickSelection
    (List) Quick time selection. Nested schema for quick_selection:
    customSelections List<GetLogsViewTimeSelectionCustomSelection>
    (List) Custom time selection. Nested schema for custom_selection:
    quickSelections List<GetLogsViewTimeSelectionQuickSelection>
    (List) Quick time selection. Nested schema for quick_selection:
    customSelections GetLogsViewTimeSelectionCustomSelection[]
    (List) Custom time selection. Nested schema for custom_selection:
    quickSelections GetLogsViewTimeSelectionQuickSelection[]
    (List) Quick time selection. Nested schema for quick_selection:
    custom_selections Sequence[GetLogsViewTimeSelectionCustomSelection]
    (List) Custom time selection. Nested schema for custom_selection:
    quick_selections Sequence[GetLogsViewTimeSelectionQuickSelection]
    (List) Quick time selection. Nested schema for quick_selection:
    customSelections List<Property Map>
    (List) Custom time selection. Nested schema for custom_selection:
    quickSelections List<Property Map>
    (List) Quick time selection. Nested schema for quick_selection:

    GetLogsViewTimeSelectionCustomSelection

    FromTime string
    (String) Custom time selection start timestamp.
    ToTime string
    (String) Custom time selection end timestamp.
    FromTime string
    (String) Custom time selection start timestamp.
    ToTime string
    (String) Custom time selection end timestamp.
    fromTime String
    (String) Custom time selection start timestamp.
    toTime String
    (String) Custom time selection end timestamp.
    fromTime string
    (String) Custom time selection start timestamp.
    toTime string
    (String) Custom time selection end timestamp.
    from_time str
    (String) Custom time selection start timestamp.
    to_time str
    (String) Custom time selection end timestamp.
    fromTime String
    (String) Custom time selection start timestamp.
    toTime String
    (String) Custom time selection end timestamp.

    GetLogsViewTimeSelectionQuickSelection

    Caption string
    (String) Quick time selection caption.

    • 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}]+$.
    Seconds double
    (Integer) Quick time selection amount of seconds.

    • Constraints: The maximum value is 4294967295. The minimum value is 0.
    Caption string
    (String) Quick time selection caption.

    • 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}]+$.
    Seconds float64
    (Integer) Quick time selection amount of seconds.

    • Constraints: The maximum value is 4294967295. The minimum value is 0.
    caption String
    (String) Quick time selection caption.

    • 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}]+$.
    seconds Double
    (Integer) Quick time selection amount of seconds.

    • Constraints: The maximum value is 4294967295. The minimum value is 0.
    caption string
    (String) Quick time selection caption.

    • 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}]+$.
    seconds number
    (Integer) Quick time selection amount of seconds.

    • Constraints: The maximum value is 4294967295. The minimum value is 0.
    caption str
    (String) Quick time selection caption.

    • 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}]+$.
    seconds float
    (Integer) Quick time selection amount of seconds.

    • Constraints: The maximum value is 4294967295. The minimum value is 0.
    caption String
    (String) Quick time selection caption.

    • 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}]+$.
    seconds Number
    (Integer) Quick time selection amount of seconds.

    • Constraints: The maximum value is 4294967295. The minimum value is 0.

    Package Details

    Repository
    ibm ibm-cloud/terraform-provider-ibm
    License
    Notes
    This Pulumi package is based on the ibm Terraform Provider.
    ibm logo
    ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud