UNPKG

@pulumi/azuredevops

Version:

A Pulumi package for creating and managing Azure DevOps.

147 lines (146 loc) 5.28 kB
import * as pulumi from "@pulumi/pulumi"; /** * Manages creation of the Feed Permission within Azure DevOps organization. * * ## Example Usage * * ### Create Feed Permission * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as azuredevops from "@pulumi/azuredevops"; * * const example = new azuredevops.Project("example", {name: "Example Project"}); * const exampleGroup = new azuredevops.Group("example", { * scope: example.id, * displayName: "Example group", * description: "Example description", * }); * const exampleFeed = new azuredevops.Feed("example", {name: "examplefeed"}); * const permission = new azuredevops.FeedPermission("permission", { * feedId: exampleFeed.id, * role: "reader", * identityDescriptor: exampleGroup.descriptor, * }); * ``` * * ## Relevant Links * * - [Azure DevOps Service REST API 7.0 - Feed Management](https://learn.microsoft.com/en-us/rest/api/azure/devops/artifacts/feed-management?view=azure-devops-rest-7.0) * * ## Import * * Azure DevOps Feed Permission can be imported using the `Project ID/Feed ID/Identity Descriptor` or `Feed ID/Identity Descriptor` e.g.: * * ```sh * $ pulumi import azuredevops:index/feedPermission:FeedPermission permission 00000000-0000-0000-0000-000000000000/00000000-0000-0000-0000-000000000000/vssgp.xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx * ``` * * or * * ```sh * $ pulumi import azuredevops:index/feedPermission:FeedPermission permission 00000000-0000-0000-0000-000000000000/vssgp.xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx * ``` */ export declare class FeedPermission extends pulumi.CustomResource { /** * Get an existing FeedPermission 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?: FeedPermissionState, opts?: pulumi.CustomResourceOptions): FeedPermission; /** * Returns true if the given object is an instance of FeedPermission. 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 FeedPermission; /** * The display name of the assignment */ readonly displayName: pulumi.Output<string | undefined>; /** * The ID of the Feed. */ readonly feedId: pulumi.Output<string>; /** * The Descriptor of identity you want to assign a role. */ readonly identityDescriptor: pulumi.Output<string>; /** * The ID of the identity. */ readonly identityId: pulumi.Output<string>; /** * The ID of the Project Feed is created in. If not specified, feed will be created at the organization level. */ readonly projectId: pulumi.Output<string | undefined>; /** * The role to be assigned. Possible values are: `reader`, `contributor`, `collaborator`, `administrator` */ readonly role: pulumi.Output<string>; /** * Create a FeedPermission 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: FeedPermissionArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering FeedPermission resources. */ export interface FeedPermissionState { /** * The display name of the assignment */ displayName?: pulumi.Input<string>; /** * The ID of the Feed. */ feedId?: pulumi.Input<string>; /** * The Descriptor of identity you want to assign a role. */ identityDescriptor?: pulumi.Input<string>; /** * The ID of the identity. */ identityId?: pulumi.Input<string>; /** * The ID of the Project Feed is created in. If not specified, feed will be created at the organization level. */ projectId?: pulumi.Input<string>; /** * The role to be assigned. Possible values are: `reader`, `contributor`, `collaborator`, `administrator` */ role?: pulumi.Input<string>; } /** * The set of arguments for constructing a FeedPermission resource. */ export interface FeedPermissionArgs { /** * The display name of the assignment */ displayName?: pulumi.Input<string>; /** * The ID of the Feed. */ feedId: pulumi.Input<string>; /** * The Descriptor of identity you want to assign a role. */ identityDescriptor: pulumi.Input<string>; /** * The ID of the Project Feed is created in. If not specified, feed will be created at the organization level. */ projectId?: pulumi.Input<string>; /** * The role to be assigned. Possible values are: `reader`, `contributor`, `collaborator`, `administrator` */ role: pulumi.Input<string>; }