@pulumiverse/grafana
Version:
A Pulumi package for creating and managing grafana.
225 lines (224 loc) • 7.48 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
import * as inputs from "../types/input";
import * as outputs from "../types/output";
/**
* **Note:** This resource is available only with Grafana Enterprise 7.+.
*
* * [Official documentation](https://grafana.com/docs/grafana/latest/dashboards/create-reports/)
* * [HTTP API](https://grafana.com/docs/grafana/latest/developers/http_api/reporting/)
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as grafana from "@pulumiverse/grafana";
*
* const test = new grafana.oss.Dashboard("test", {
* configJson: `{
* "uid": "report-dashboard",
* "title": "report-dashboard"
* }
* `,
* message: "inital commit.",
* });
* const testReport = new grafana.enterprise.Report("test", {
* name: "my report",
* recipients: ["some@email.com"],
* dashboards: [{
* uid: test.uid,
* }],
* schedule: {
* frequency: "hourly",
* },
* });
* ```
*
* ## Import
*
* ```sh
* $ pulumi import grafana:enterprise/report:Report name "{{ id }}"
* ```
*
* ```sh
* $ pulumi import grafana:enterprise/report:Report name "{{ orgID }}:{{ id }}"
* ```
*/
export declare class Report extends pulumi.CustomResource {
/**
* Get an existing Report resource's state with the given name, ID, and optional extra
* properties used to qualify the lookup.
*
* @param name The _unique_ name of the resulting resource.
* @param id The _unique_ provider ID of the resource to lookup.
* @param state Any extra arguments used during the lookup.
* @param opts Optional settings to control the behavior of the CustomResource.
*/
static get(name: string, id: pulumi.Input<pulumi.ID>, state?: ReportState, opts?: pulumi.CustomResourceOptions): Report;
/**
* Returns true if the given object is an instance of Report. This is designed to work even
* when multiple copies of the Pulumi SDK have been loaded into the same process.
*/
static isInstance(obj: any): obj is Report;
/**
* List of dashboards to render into the report
*/
readonly dashboards: pulumi.Output<outputs.enterprise.ReportDashboard[] | undefined>;
/**
* Specifies what kind of attachment to generate for the report. Allowed values: `pdf`, `csv`, `image`.
*/
readonly formats: pulumi.Output<string[] | undefined>;
/**
* Whether to include a link to the dashboard in the report. Defaults to `true`.
*/
readonly includeDashboardLink: pulumi.Output<boolean | undefined>;
/**
* Whether to include a CSV file of table panel data. Defaults to `false`.
*/
readonly includeTableCsv: pulumi.Output<boolean | undefined>;
/**
* Layout of the report. Allowed values: `simple`, `grid`. Defaults to `grid`.
*/
readonly layout: pulumi.Output<string | undefined>;
/**
* Message to be sent in the report.
*/
readonly message: pulumi.Output<string | undefined>;
/**
* Name of the report.
*/
readonly name: pulumi.Output<string>;
/**
* The Organization ID. If not set, the Org ID defined in the provider block will be used.
*/
readonly orgId: pulumi.Output<string | undefined>;
/**
* Orientation of the report. Allowed values: `landscape`, `portrait`. Defaults to `landscape`.
*/
readonly orientation: pulumi.Output<string | undefined>;
/**
* List of recipients of the report.
*/
readonly recipients: pulumi.Output<string[]>;
/**
* Reply-to email address of the report.
*/
readonly replyTo: pulumi.Output<string | undefined>;
/**
* Schedule of the report.
*/
readonly schedule: pulumi.Output<outputs.enterprise.ReportSchedule>;
/**
* Create a Report resource with the given unique name, arguments, and options.
*
* @param name The _unique_ name of the resource.
* @param args The arguments to use to populate this resource's properties.
* @param opts A bag of options that control this resource's behavior.
*/
constructor(name: string, args: ReportArgs, opts?: pulumi.CustomResourceOptions);
}
/**
* Input properties used for looking up and filtering Report resources.
*/
export interface ReportState {
/**
* List of dashboards to render into the report
*/
dashboards?: pulumi.Input<pulumi.Input<inputs.enterprise.ReportDashboard>[]>;
/**
* Specifies what kind of attachment to generate for the report. Allowed values: `pdf`, `csv`, `image`.
*/
formats?: pulumi.Input<pulumi.Input<string>[]>;
/**
* Whether to include a link to the dashboard in the report. Defaults to `true`.
*/
includeDashboardLink?: pulumi.Input<boolean>;
/**
* Whether to include a CSV file of table panel data. Defaults to `false`.
*/
includeTableCsv?: pulumi.Input<boolean>;
/**
* Layout of the report. Allowed values: `simple`, `grid`. Defaults to `grid`.
*/
layout?: pulumi.Input<string>;
/**
* Message to be sent in the report.
*/
message?: pulumi.Input<string>;
/**
* Name of the report.
*/
name?: pulumi.Input<string>;
/**
* The Organization ID. If not set, the Org ID defined in the provider block will be used.
*/
orgId?: pulumi.Input<string>;
/**
* Orientation of the report. Allowed values: `landscape`, `portrait`. Defaults to `landscape`.
*/
orientation?: pulumi.Input<string>;
/**
* List of recipients of the report.
*/
recipients?: pulumi.Input<pulumi.Input<string>[]>;
/**
* Reply-to email address of the report.
*/
replyTo?: pulumi.Input<string>;
/**
* Schedule of the report.
*/
schedule?: pulumi.Input<inputs.enterprise.ReportSchedule>;
}
/**
* The set of arguments for constructing a Report resource.
*/
export interface ReportArgs {
/**
* List of dashboards to render into the report
*/
dashboards?: pulumi.Input<pulumi.Input<inputs.enterprise.ReportDashboard>[]>;
/**
* Specifies what kind of attachment to generate for the report. Allowed values: `pdf`, `csv`, `image`.
*/
formats?: pulumi.Input<pulumi.Input<string>[]>;
/**
* Whether to include a link to the dashboard in the report. Defaults to `true`.
*/
includeDashboardLink?: pulumi.Input<boolean>;
/**
* Whether to include a CSV file of table panel data. Defaults to `false`.
*/
includeTableCsv?: pulumi.Input<boolean>;
/**
* Layout of the report. Allowed values: `simple`, `grid`. Defaults to `grid`.
*/
layout?: pulumi.Input<string>;
/**
* Message to be sent in the report.
*/
message?: pulumi.Input<string>;
/**
* Name of the report.
*/
name?: pulumi.Input<string>;
/**
* The Organization ID. If not set, the Org ID defined in the provider block will be used.
*/
orgId?: pulumi.Input<string>;
/**
* Orientation of the report. Allowed values: `landscape`, `portrait`. Defaults to `landscape`.
*/
orientation?: pulumi.Input<string>;
/**
* List of recipients of the report.
*/
recipients: pulumi.Input<pulumi.Input<string>[]>;
/**
* Reply-to email address of the report.
*/
replyTo?: pulumi.Input<string>;
/**
* Schedule of the report.
*/
schedule: pulumi.Input<inputs.enterprise.ReportSchedule>;
}