1. Packages
  2. Ibm Provider
  3. API Docs
  4. getLogsView
ibm 1.77.1 published on Monday, Apr 14, 2025 by ibm-cloud

ibm.getLogsView

Explore with Pulumi AI

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,
});
Copy
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"])
Copy
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
	})
}
Copy
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,
    });

});
Copy
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());

    }
}
Copy
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}
Copy

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>
Copy
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]
Copy
func LookupLogsView(ctx *Context, args *LookupLogsViewArgs, opts ...InvokeOption) (*LookupLogsViewResult, error)
func LookupLogsViewOutput(ctx *Context, args *LookupLogsViewOutputArgs, opts ...InvokeOption) LookupLogsViewResultOutput
Copy

> 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)
}
Copy
public static CompletableFuture<GetLogsViewResult> getLogsView(GetLogsViewArgs args, InvokeOptions options)
public static Output<GetLogsViewResult> getLogsView(GetLogsViewArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: ibm:index/getLogsView:getLogsView
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

InstanceId This property is required. string
Cloud Logs Instance GUID.
LogsViewId This property is required. double
View id.
EndpointType string
Id string
The unique identifier of the logs_view.
Region string
Cloud Logs Instance Region.
InstanceId This property is required. string
Cloud Logs Instance GUID.
LogsViewId This property is required. float64
View id.
EndpointType string
Id string
The unique identifier of the logs_view.
Region string
Cloud Logs Instance Region.
instanceId This property is required. String
Cloud Logs Instance GUID.
logsViewId This property is required. Double
View id.
endpointType String
id String
The unique identifier of the logs_view.
region String
Cloud Logs Instance Region.
instanceId This property is required. string
Cloud Logs Instance GUID.
logsViewId This property is required. number
View id.
endpointType string
id string
The unique identifier of the logs_view.
region string
Cloud Logs Instance Region.
instance_id This property is required. str
Cloud Logs Instance GUID.
logs_view_id This property is required. float
View id.
endpoint_type str
id str
The unique identifier of the logs_view.
region str
Cloud Logs Instance Region.
instanceId This property is required. String
Cloud Logs Instance GUID.
logsViewId This property is required. 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 This property is required. List<GetLogsViewFilterFilter>
(List) Selected filters.

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

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

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

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

  • Constraints: The maximum length is 4096 items. The minimum length is 1 item. Nested schema for filters:
filters This property is required. 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 This property is required. 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 This property is required. Dictionary<string, string>
(Map) Filter selected values.
Name This property is required. 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 This property is required. map[string]string
(Map) Filter selected values.
name This property is required. 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 This property is required. Map<String,String>
(Map) Filter selected values.
name This property is required. 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 This property is required. {[key: string]: string}
(Map) Filter selected values.
name This property is required. 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 This property is required. Mapping[str, str]
(Map) Filter selected values.
name This property is required. 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 This property is required. Map<String>
(Map) Filter selected values.

GetLogsViewSearchQuery

Query This property is required. 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 This property is required. 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 This property is required. 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 This property is required. 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 This property is required. 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 This property is required. 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 This property is required. List<GetLogsViewTimeSelectionCustomSelection>
(List) Custom time selection. Nested schema for custom_selection:
QuickSelections This property is required. List<GetLogsViewTimeSelectionQuickSelection>
(List) Quick time selection. Nested schema for quick_selection:
CustomSelections This property is required. []GetLogsViewTimeSelectionCustomSelection
(List) Custom time selection. Nested schema for custom_selection:
QuickSelections This property is required. []GetLogsViewTimeSelectionQuickSelection
(List) Quick time selection. Nested schema for quick_selection:
customSelections This property is required. List<GetLogsViewTimeSelectionCustomSelection>
(List) Custom time selection. Nested schema for custom_selection:
quickSelections This property is required. List<GetLogsViewTimeSelectionQuickSelection>
(List) Quick time selection. Nested schema for quick_selection:
customSelections This property is required. GetLogsViewTimeSelectionCustomSelection[]
(List) Custom time selection. Nested schema for custom_selection:
quickSelections This property is required. GetLogsViewTimeSelectionQuickSelection[]
(List) Quick time selection. Nested schema for quick_selection:
custom_selections This property is required. Sequence[GetLogsViewTimeSelectionCustomSelection]
(List) Custom time selection. Nested schema for custom_selection:
quick_selections This property is required. Sequence[GetLogsViewTimeSelectionQuickSelection]
(List) Quick time selection. Nested schema for quick_selection:
customSelections This property is required. List<Property Map>
(List) Custom time selection. Nested schema for custom_selection:
quickSelections This property is required. List<Property Map>
(List) Quick time selection. Nested schema for quick_selection:

GetLogsViewTimeSelectionCustomSelection

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

GetLogsViewTimeSelectionQuickSelection

Caption This property is required. 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 This property is required. double
(Integer) Quick time selection amount of seconds.

  • Constraints: The maximum value is 4294967295. The minimum value is 0.
Caption This property is required. 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 This property is required. float64
(Integer) Quick time selection amount of seconds.

  • Constraints: The maximum value is 4294967295. The minimum value is 0.
caption This property is required. 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 This property is required. Double
(Integer) Quick time selection amount of seconds.

  • Constraints: The maximum value is 4294967295. The minimum value is 0.
caption This property is required. 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 This property is required. number
(Integer) Quick time selection amount of seconds.

  • Constraints: The maximum value is 4294967295. The minimum value is 0.
caption This property is required. 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 This property is required. float
(Integer) Quick time selection amount of seconds.

  • Constraints: The maximum value is 4294967295. The minimum value is 0.
caption This property is required. 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 This property is required. 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.