@pulumiverse/dynatrace
Version:
A Pulumi package for creating and managing Dynatrace cloud resources.
56 lines • 2.21 kB
JavaScript
;
// *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
Object.defineProperty(exports, "__esModule", { value: true });
exports.getApiTokenOutput = exports.getApiToken = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("./utilities");
/**
* The API token data source allows a single access token to be retrieved by its name, note the token value is not included in the response.
*
* If multiple tokens match the given name, the first result will be retrieved. To retrieve multiple tokens of the same name, please utilize the `dynatrace.getApiTokens` data source.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as dynatrace from "@pulumi/dynatrace";
*
* const exampleApiToken = dynatrace.getApiToken({
* name: "Terraform",
* });
* export const example = exampleApiToken;
* ```
*/
function getApiToken(args, opts) {
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {});
return pulumi.runtime.invoke("dynatrace:index/getApiToken:getApiToken", {
"name": args.name,
}, opts);
}
exports.getApiToken = getApiToken;
/**
* The API token data source allows a single access token to be retrieved by its name, note the token value is not included in the response.
*
* If multiple tokens match the given name, the first result will be retrieved. To retrieve multiple tokens of the same name, please utilize the `dynatrace.getApiTokens` data source.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as dynatrace from "@pulumi/dynatrace";
*
* const exampleApiToken = dynatrace.getApiToken({
* name: "Terraform",
* });
* export const example = exampleApiToken;
* ```
*/
function getApiTokenOutput(args, opts) {
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {});
return pulumi.runtime.invokeOutput("dynatrace:index/getApiToken:getApiToken", {
"name": args.name,
}, opts);
}
exports.getApiTokenOutput = getApiTokenOutput;
//# sourceMappingURL=getApiToken.js.map