@pulumi/azuredevops
Version:
A Pulumi package for creating and managing Azure DevOps.
238 lines (237 loc) • 9.82 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
import * as inputs from "./types/input";
import * as outputs from "./types/output";
/**
* Manages a group within a page and section for a work item type.
*
* ## Example Usage
*
* ### Basic Group
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as azuredevops from "@pulumi/azuredevops";
*
* const example = new azuredevops.WorkitemtrackingprocessProcess("example", {
* name: "example-process",
* parentProcessTypeId: "adcc42ab-9882-485e-a3ed-7678f01f66bc",
* });
* const exampleWorkitemtrackingprocessWorkitemtype = new azuredevops.WorkitemtrackingprocessWorkitemtype("example", {
* processId: example.id,
* name: "example",
* description: "Example work item type",
* color: "#FF5733",
* icon: "icon_clipboard",
* });
* const exampleWorkitemtrackingprocessGroup = new azuredevops.WorkitemtrackingprocessGroup("example", {
* processId: example.id,
* workItemTypeReferenceName: exampleWorkitemtrackingprocessWorkitemtype.referenceName,
* pageId: exampleWorkitemtrackingprocessWorkitemtype.pages.apply(pages => pages[0].id),
* sectionId: exampleWorkitemtrackingprocessWorkitemtype.pages.apply(pages => pages[0].sections?.[0]?.id),
* label: "Custom Group",
* });
* ```
*
* ### Group with Controls
*
* This example creates a group with multiple controls, including an HTML field control (System.Description) which can only be added when creating the group.
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as azuredevops from "@pulumi/azuredevops";
*
* const example = new azuredevops.WorkitemtrackingprocessGroup("example", {
* processId: exampleAzuredevopsWorkitemtrackingprocessProcess.id,
* workItemTypeReferenceName: exampleAzuredevopsWorkitemtrackingprocessWorkitemtype.referenceName,
* pageId: exampleAzuredevopsWorkitemtrackingprocessWorkitemtype.pages[0].id,
* sectionId: exampleAzuredevopsWorkitemtrackingprocessWorkitemtype.pages[0].sections[0].id,
* label: "Details Group",
* controls: [
* {
* id: "System.Description",
* label: "Description",
* },
* {
* id: "System.Title",
* label: "Title",
* },
* ],
* });
* ```
*
* ### Group with Contribution Control (Extension)
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as azuredevops from "@pulumi/azuredevops";
*
* const multivalue = new azuredevops.Extension("multivalue", {
* publisherId: "ms-devlabs",
* extensionId: "vsts-extensions-multivalue-control",
* });
* const example = new azuredevops.WorkitemtrackingprocessGroup("example", {
* processId: exampleAzuredevopsWorkitemtrackingprocessProcess.id,
* workItemTypeReferenceName: exampleAzuredevopsWorkitemtrackingprocessWorkitemtype.referenceName,
* pageId: exampleAzuredevopsWorkitemtrackingprocessWorkitemtype.pages[0].id,
* sectionId: exampleAzuredevopsWorkitemtrackingprocessWorkitemtype.pages[0].sections[0].id,
* label: "Extension Group",
* controls: [{
* id: "ms-devlabs.vsts-extensions-multivalue-control.multivalue-form-control",
* isContribution: true,
* contribution: {
* contributionId: "ms-devlabs.vsts-extensions-multivalue-control.multivalue-form-control",
* height: 50,
* inputs: {
* FieldName: "System.Tags",
* Values: "Option1;Option2;Option3",
* },
* },
* }],
* }, {
* dependsOn: [multivalue],
* });
* ```
*
* ## Relevant Links
*
* - [Azure DevOps Service REST API 7.1 - Groups](https://learn.microsoft.com/en-us/rest/api/azure/devops/processes/groups?view=azure-devops-rest-7.1)
*
* ## Import
*
* Groups can be imported using the complete resource id `process_id/work_item_type_reference_name/page_id/section_id/group_id`, e.g.
*
* ```sh
* $ pulumi import azuredevops:index/workitemtrackingprocessGroup:WorkitemtrackingprocessGroup example 00000000-0000-0000-0000-000000000000/MyProcess.CustomWorkItemType/page-id/section-id/group-id
* ```
*/
export declare class WorkitemtrackingprocessGroup extends pulumi.CustomResource {
/**
* Get an existing WorkitemtrackingprocessGroup 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?: WorkitemtrackingprocessGroupState, opts?: pulumi.CustomResourceOptions): WorkitemtrackingprocessGroup;
/**
* Returns true if the given object is an instance of WorkitemtrackingprocessGroup. 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 WorkitemtrackingprocessGroup;
/**
* Controls to be created with the group. Required for HTML controls which cannot be added to existing groups. This is mutally exclusive with 'azuredevops_workitemtrackingprocess_control' resources. A `control` block as defined below.
*/
readonly controls: pulumi.Output<outputs.WorkitemtrackingprocessGroupControl[]>;
/**
* Label for the group.
*/
readonly label: pulumi.Output<string>;
/**
* Order in which the group should appear in the section.
*/
readonly order: pulumi.Output<number>;
/**
* The ID of the page to add the group to. Changing this moves the group to the new page.
*/
readonly pageId: pulumi.Output<string>;
/**
* The ID of the process. Changing this forces a new group to be created.
*/
readonly processId: pulumi.Output<string>;
/**
* The ID of the section to add the group to. Changing this moves the group to the new section.
*/
readonly sectionId: pulumi.Output<string>;
/**
* A value indicating if the group should be visible or not. Default: `true`
*/
readonly visible: pulumi.Output<boolean | undefined>;
/**
* The reference name of the work item type. Changing this forces a new group to be created.
*/
readonly workItemTypeReferenceName: pulumi.Output<string>;
/**
* Create a WorkitemtrackingprocessGroup 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: WorkitemtrackingprocessGroupArgs, opts?: pulumi.CustomResourceOptions);
}
/**
* Input properties used for looking up and filtering WorkitemtrackingprocessGroup resources.
*/
export interface WorkitemtrackingprocessGroupState {
/**
* Controls to be created with the group. Required for HTML controls which cannot be added to existing groups. This is mutally exclusive with 'azuredevops_workitemtrackingprocess_control' resources. A `control` block as defined below.
*/
controls?: pulumi.Input<pulumi.Input<inputs.WorkitemtrackingprocessGroupControl>[]>;
/**
* Label for the group.
*/
label?: pulumi.Input<string>;
/**
* Order in which the group should appear in the section.
*/
order?: pulumi.Input<number>;
/**
* The ID of the page to add the group to. Changing this moves the group to the new page.
*/
pageId?: pulumi.Input<string>;
/**
* The ID of the process. Changing this forces a new group to be created.
*/
processId?: pulumi.Input<string>;
/**
* The ID of the section to add the group to. Changing this moves the group to the new section.
*/
sectionId?: pulumi.Input<string>;
/**
* A value indicating if the group should be visible or not. Default: `true`
*/
visible?: pulumi.Input<boolean>;
/**
* The reference name of the work item type. Changing this forces a new group to be created.
*/
workItemTypeReferenceName?: pulumi.Input<string>;
}
/**
* The set of arguments for constructing a WorkitemtrackingprocessGroup resource.
*/
export interface WorkitemtrackingprocessGroupArgs {
/**
* Controls to be created with the group. Required for HTML controls which cannot be added to existing groups. This is mutally exclusive with 'azuredevops_workitemtrackingprocess_control' resources. A `control` block as defined below.
*/
controls?: pulumi.Input<pulumi.Input<inputs.WorkitemtrackingprocessGroupControl>[]>;
/**
* Label for the group.
*/
label: pulumi.Input<string>;
/**
* Order in which the group should appear in the section.
*/
order?: pulumi.Input<number>;
/**
* The ID of the page to add the group to. Changing this moves the group to the new page.
*/
pageId: pulumi.Input<string>;
/**
* The ID of the process. Changing this forces a new group to be created.
*/
processId: pulumi.Input<string>;
/**
* The ID of the section to add the group to. Changing this moves the group to the new section.
*/
sectionId: pulumi.Input<string>;
/**
* A value indicating if the group should be visible or not. Default: `true`
*/
visible?: pulumi.Input<boolean>;
/**
* The reference name of the work item type. Changing this forces a new group to be created.
*/
workItemTypeReferenceName: pulumi.Input<string>;
}