Dynatrace v0.21.0 published on Sunday, Nov 17, 2024 by Pulumiverse
dynatrace.getDocuments
Explore with Pulumi AI
Dynatrace SaaS only
To utilize this resource, please define the environment variables
DT_CLIENT_ID
,DT_CLIENT_SECRET
,DT_ACCOUNT_ID
with an OAuth client including the following permission: View documents (document:documents:read
).
type
(String) The type of documents to query for. Leave empty if you want to query for all kinds of documents.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as dynatrace from "@pulumi/dynatrace";
const all-dashboard-and-notebooks = dynatrace.getDocuments({});
const all-dashboards = dynatrace.getDocuments({
type: "dashboard",
});
const all-notebooks = dynatrace.getDocuments({
type: "notebook",
});
import pulumi
import pulumi_dynatrace as dynatrace
all_dashboard_and_notebooks = dynatrace.get_documents()
all_dashboards = dynatrace.get_documents(type="dashboard")
all_notebooks = dynatrace.get_documents(type="notebook")
package main
import (
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/pulumiverse/pulumi-dynatrace/sdk/go/dynatrace"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := dynatrace.GetDocuments(ctx, &dynatrace.GetDocumentsArgs{}, nil)
if err != nil {
return err
}
_, err = dynatrace.GetDocuments(ctx, &dynatrace.GetDocumentsArgs{
Type: pulumi.StringRef("dashboard"),
}, nil)
if err != nil {
return err
}
_, err = dynatrace.GetDocuments(ctx, &dynatrace.GetDocumentsArgs{
Type: pulumi.StringRef("notebook"),
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Dynatrace = Pulumi.Dynatrace;
return await Deployment.RunAsync(() =>
{
var all_dashboard_and_notebooks = Dynatrace.GetDocuments.Invoke();
var all_dashboards = Dynatrace.GetDocuments.Invoke(new()
{
Type = "dashboard",
});
var all_notebooks = Dynatrace.GetDocuments.Invoke(new()
{
Type = "notebook",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.dynatrace.DynatraceFunctions;
import com.pulumi.dynatrace.inputs.GetDocumentsArgs;
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 all-dashboard-and-notebooks = DynatraceFunctions.getDocuments();
final var all-dashboards = DynatraceFunctions.getDocuments(GetDocumentsArgs.builder()
.type("dashboard")
.build());
final var all-notebooks = DynatraceFunctions.getDocuments(GetDocumentsArgs.builder()
.type("notebook")
.build());
}
}
variables:
all-dashboard-and-notebooks:
fn::invoke:
Function: dynatrace:getDocuments
Arguments: {}
all-dashboards:
fn::invoke:
Function: dynatrace:getDocuments
Arguments:
type: dashboard
all-notebooks:
fn::invoke:
Function: dynatrace:getDocuments
Arguments:
type: notebook
Using getDocuments
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 getDocuments(args: GetDocumentsArgs, opts?: InvokeOptions): Promise<GetDocumentsResult>
function getDocumentsOutput(args: GetDocumentsOutputArgs, opts?: InvokeOptions): Output<GetDocumentsResult>
def get_documents(type: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetDocumentsResult
def get_documents_output(type: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetDocumentsResult]
func GetDocuments(ctx *Context, args *GetDocumentsArgs, opts ...InvokeOption) (*GetDocumentsResult, error)
func GetDocumentsOutput(ctx *Context, args *GetDocumentsOutputArgs, opts ...InvokeOption) GetDocumentsResultOutput
> Note: This function is named GetDocuments
in the Go SDK.
public static class GetDocuments
{
public static Task<GetDocumentsResult> InvokeAsync(GetDocumentsArgs args, InvokeOptions? opts = null)
public static Output<GetDocumentsResult> Invoke(GetDocumentsInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetDocumentsResult> getDocuments(GetDocumentsArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: dynatrace:index/getDocuments:getDocuments
arguments:
# arguments dictionary
The following arguments are supported:
- Type string
- The type of documents to query for. Leave empty if you want to query for all kinds of documents. Possible values are
dashboard
ornotebook
- Type string
- The type of documents to query for. Leave empty if you want to query for all kinds of documents. Possible values are
dashboard
ornotebook
- type String
- The type of documents to query for. Leave empty if you want to query for all kinds of documents. Possible values are
dashboard
ornotebook
- type string
- The type of documents to query for. Leave empty if you want to query for all kinds of documents. Possible values are
dashboard
ornotebook
- type str
- The type of documents to query for. Leave empty if you want to query for all kinds of documents. Possible values are
dashboard
ornotebook
- type String
- The type of documents to query for. Leave empty if you want to query for all kinds of documents. Possible values are
dashboard
ornotebook
getDocuments Result
The following output properties are available:
- Id string
- The provider-assigned unique ID for this managed resource.
- Values
List<Pulumiverse.
Dynatrace. Outputs. Get Documents Value> - Type string
- The type of documents to query for. Leave empty if you want to query for all kinds of documents. Possible values are
dashboard
ornotebook
- Id string
- The provider-assigned unique ID for this managed resource.
- Values
[]Get
Documents Value - Type string
- The type of documents to query for. Leave empty if you want to query for all kinds of documents. Possible values are
dashboard
ornotebook
- id String
- The provider-assigned unique ID for this managed resource.
- values
List<Get
Documents Value> - type String
- The type of documents to query for. Leave empty if you want to query for all kinds of documents. Possible values are
dashboard
ornotebook
- id string
- The provider-assigned unique ID for this managed resource.
- values
Get
Documents Value[] - type string
- The type of documents to query for. Leave empty if you want to query for all kinds of documents. Possible values are
dashboard
ornotebook
- id str
- The provider-assigned unique ID for this managed resource.
- values
Sequence[Get
Documents Value] - type str
- The type of documents to query for. Leave empty if you want to query for all kinds of documents. Possible values are
dashboard
ornotebook
- id String
- The provider-assigned unique ID for this managed resource.
- values List<Property Map>
- type String
- The type of documents to query for. Leave empty if you want to query for all kinds of documents. Possible values are
dashboard
ornotebook
Supporting Types
GetDocumentsValue
- Id string
- The unique identifier of the document.
- Name string
- The name of the document.
- Owner string
- The owner of the document. This could be a user or a group that has ownership rights over the document.
- Type string
- The type of the document. This could be a specific format or category the document belongs to.
- Id string
- The unique identifier of the document.
- Name string
- The name of the document.
- Owner string
- The owner of the document. This could be a user or a group that has ownership rights over the document.
- Type string
- The type of the document. This could be a specific format or category the document belongs to.
- id String
- The unique identifier of the document.
- name String
- The name of the document.
- owner String
- The owner of the document. This could be a user or a group that has ownership rights over the document.
- type String
- The type of the document. This could be a specific format or category the document belongs to.
- id string
- The unique identifier of the document.
- name string
- The name of the document.
- owner string
- The owner of the document. This could be a user or a group that has ownership rights over the document.
- type string
- The type of the document. This could be a specific format or category the document belongs to.
- id String
- The unique identifier of the document.
- name String
- The name of the document.
- owner String
- The owner of the document. This could be a user or a group that has ownership rights over the document.
- type String
- The type of the document. This could be a specific format or category the document belongs to.
Package Details
- Repository
- dynatrace pulumiverse/pulumi-dynatrace
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
dynatrace
Terraform Provider.