@pulumi/github
Version:
A Pulumi package for creating and managing github cloud resources.
192 lines (191 loc) • 6.6 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
/**
* Provides a GitHub team resource.
*
* This resource allows you to add/remove teams from your organization. When applied,
* a new team will be created. When destroyed, that team will be removed.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as github from "@pulumi/github";
*
* // Add a team to the organization
* const someTeam = new github.Team("some_team", {
* name: "some-team",
* description: "Some cool team",
* privacy: "closed",
* });
* ```
*
* ## Import
*
* GitHub Teams can be imported using the GitHub team ID or name e.g.
*
* ```sh
* $ pulumi import github:index/team:Team core 1234567
* ```
*
* ```sh
* $ pulumi import github:index/team:Team core Administrators
* ```
*/
export declare class Team extends pulumi.CustomResource {
/**
* Get an existing Team 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?: TeamState, opts?: pulumi.CustomResourceOptions): Team;
/**
* Returns true if the given object is an instance of Team. 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 Team;
/**
* Adds a default maintainer to the team. Defaults to `false` and adds the creating user to the team when `true`.
*/
readonly createDefaultMaintainer: pulumi.Output<boolean | undefined>;
/**
* A description of the team.
*/
readonly description: pulumi.Output<string | undefined>;
readonly etag: pulumi.Output<string>;
/**
* The LDAP Distinguished Name of the group where membership will be synchronized. Only available in GitHub Enterprise Server.
*/
readonly ldapDn: pulumi.Output<string | undefined>;
readonly membersCount: pulumi.Output<number>;
/**
* The name of the team.
*/
readonly name: pulumi.Output<string>;
/**
* The Node ID of the created team.
*/
readonly nodeId: pulumi.Output<string>;
/**
* The ID or slug of the parent team, if this is a nested team.
*/
readonly parentTeamId: pulumi.Output<string | undefined>;
/**
* The id of the parent team read in Github.
*/
readonly parentTeamReadId: pulumi.Output<string>;
/**
* The id of the parent team read in Github.
*/
readonly parentTeamReadSlug: pulumi.Output<string>;
/**
* The level of privacy for the team. Must be one of `secret` or `closed`.
* Defaults to `secret`.
*/
readonly privacy: pulumi.Output<string | undefined>;
/**
* The slug of the created team, which may or may not differ from `name`,
* depending on whether `name` contains "URL-unsafe" characters.
* Useful when referencing the team in [`github.BranchProtection`](https://www.terraform.io/docs/providers/github/r/branch_protection.html).
*/
readonly slug: pulumi.Output<string>;
/**
* Create a Team 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?: TeamArgs, opts?: pulumi.CustomResourceOptions);
}
/**
* Input properties used for looking up and filtering Team resources.
*/
export interface TeamState {
/**
* Adds a default maintainer to the team. Defaults to `false` and adds the creating user to the team when `true`.
*/
createDefaultMaintainer?: pulumi.Input<boolean>;
/**
* A description of the team.
*/
description?: pulumi.Input<string>;
etag?: pulumi.Input<string>;
/**
* The LDAP Distinguished Name of the group where membership will be synchronized. Only available in GitHub Enterprise Server.
*/
ldapDn?: pulumi.Input<string>;
membersCount?: pulumi.Input<number>;
/**
* The name of the team.
*/
name?: pulumi.Input<string>;
/**
* The Node ID of the created team.
*/
nodeId?: pulumi.Input<string>;
/**
* The ID or slug of the parent team, if this is a nested team.
*/
parentTeamId?: pulumi.Input<string>;
/**
* The id of the parent team read in Github.
*/
parentTeamReadId?: pulumi.Input<string>;
/**
* The id of the parent team read in Github.
*/
parentTeamReadSlug?: pulumi.Input<string>;
/**
* The level of privacy for the team. Must be one of `secret` or `closed`.
* Defaults to `secret`.
*/
privacy?: pulumi.Input<string>;
/**
* The slug of the created team, which may or may not differ from `name`,
* depending on whether `name` contains "URL-unsafe" characters.
* Useful when referencing the team in [`github.BranchProtection`](https://www.terraform.io/docs/providers/github/r/branch_protection.html).
*/
slug?: pulumi.Input<string>;
}
/**
* The set of arguments for constructing a Team resource.
*/
export interface TeamArgs {
/**
* Adds a default maintainer to the team. Defaults to `false` and adds the creating user to the team when `true`.
*/
createDefaultMaintainer?: pulumi.Input<boolean>;
/**
* A description of the team.
*/
description?: pulumi.Input<string>;
/**
* The LDAP Distinguished Name of the group where membership will be synchronized. Only available in GitHub Enterprise Server.
*/
ldapDn?: pulumi.Input<string>;
/**
* The name of the team.
*/
name?: pulumi.Input<string>;
/**
* The ID or slug of the parent team, if this is a nested team.
*/
parentTeamId?: pulumi.Input<string>;
/**
* The id of the parent team read in Github.
*/
parentTeamReadId?: pulumi.Input<string>;
/**
* The id of the parent team read in Github.
*/
parentTeamReadSlug?: pulumi.Input<string>;
/**
* The level of privacy for the team. Must be one of `secret` or `closed`.
* Defaults to `secret`.
*/
privacy?: pulumi.Input<string>;
}