@pulumiverse/sentry
Version:
A Pulumi package for creating and managing Sentry resources.
93 lines • 3.83 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.SentryTeam = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("./utilities");
/**
* Sentry Team resource.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as sentry from "@pulumiverse/sentry";
*
* // Create a team
* const _default = new sentry.SentryTeam("default", {
* organization: "my-organization",
* name: "my-team",
* slug: "my-team",
* });
* ```
*
* ## Import
*
* import using the organization and team slugs from the URL:
*
* https://sentry.io/settings/[org-slug]/teams/[team-slug]/members/
*
* ```sh
* $ pulumi import sentry:index/sentryTeam:SentryTeam default org-slug/team-slug
* ```
*/
class SentryTeam extends pulumi.CustomResource {
/**
* Get an existing SentryTeam 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, id, state, opts) {
return new SentryTeam(name, state, Object.assign(Object.assign({}, opts), { id: id }));
}
/**
* Returns true if the given object is an instance of SentryTeam. This is designed to work even
* when multiple copies of the Pulumi SDK have been loaded into the same process.
*/
static isInstance(obj) {
if (obj === undefined || obj === null) {
return false;
}
return obj['__pulumiType'] === SentryTeam.__pulumiType;
}
constructor(name, argsOrState, opts) {
let resourceInputs = {};
opts = opts || {};
if (opts.id) {
const state = argsOrState;
resourceInputs["hasAccess"] = state ? state.hasAccess : undefined;
resourceInputs["internalId"] = state ? state.internalId : undefined;
resourceInputs["isMember"] = state ? state.isMember : undefined;
resourceInputs["isPending"] = state ? state.isPending : undefined;
resourceInputs["name"] = state ? state.name : undefined;
resourceInputs["organization"] = state ? state.organization : undefined;
resourceInputs["slug"] = state ? state.slug : undefined;
resourceInputs["teamId"] = state ? state.teamId : undefined;
}
else {
const args = argsOrState;
if ((!args || args.organization === undefined) && !opts.urn) {
throw new Error("Missing required property 'organization'");
}
resourceInputs["name"] = args ? args.name : undefined;
resourceInputs["organization"] = args ? args.organization : undefined;
resourceInputs["slug"] = args ? args.slug : undefined;
resourceInputs["hasAccess"] = undefined /*out*/;
resourceInputs["internalId"] = undefined /*out*/;
resourceInputs["isMember"] = undefined /*out*/;
resourceInputs["isPending"] = undefined /*out*/;
resourceInputs["teamId"] = undefined /*out*/;
}
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
super(SentryTeam.__pulumiType, name, resourceInputs, opts);
}
}
exports.SentryTeam = SentryTeam;
/** @internal */
SentryTeam.__pulumiType = 'sentry:index/sentryTeam:SentryTeam';
//# sourceMappingURL=sentryTeam.js.map