1. Packages
  2. Azuredevops Provider
  3. API Docs
  4. WikiPage
Azure DevOps v3.4.0 published on Wednesday, Oct 30, 2024 by Pulumi

azuredevops.WikiPage

Explore with Pulumi AI

azuredevops logo
Azure DevOps v3.4.0 published on Wednesday, Oct 30, 2024 by Pulumi

    Manages Wiki pages within Azure DevOps project.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as azuredevops from "@pulumi/azuredevops";
    
    const example = new azuredevops.Project("example", {
        name: "Example Project",
        description: "Managed by Terraform",
    });
    const exampleWiki = new azuredevops.Wiki("example", {
        name: "Example project wiki ",
        projectId: example.id,
        type: "projectWiki",
    });
    const exampleWikiPage = new azuredevops.WikiPage("example", {
        projectId: example.id,
        wikiId: exampleWiki.id,
        path: "/page",
        content: "content",
    });
    
    import pulumi
    import pulumi_azuredevops as azuredevops
    
    example = azuredevops.Project("example",
        name="Example Project",
        description="Managed by Terraform")
    example_wiki = azuredevops.Wiki("example",
        name="Example project wiki ",
        project_id=example.id,
        type="projectWiki")
    example_wiki_page = azuredevops.WikiPage("example",
        project_id=example.id,
        wiki_id=example_wiki.id,
        path="/page",
        content="content")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-azuredevops/sdk/v3/go/azuredevops"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		example, err := azuredevops.NewProject(ctx, "example", &azuredevops.ProjectArgs{
    			Name:        pulumi.String("Example Project"),
    			Description: pulumi.String("Managed by Terraform"),
    		})
    		if err != nil {
    			return err
    		}
    		exampleWiki, err := azuredevops.NewWiki(ctx, "example", &azuredevops.WikiArgs{
    			Name:      pulumi.String("Example project wiki "),
    			ProjectId: example.ID(),
    			Type:      pulumi.String("projectWiki"),
    		})
    		if err != nil {
    			return err
    		}
    		_, err = azuredevops.NewWikiPage(ctx, "example", &azuredevops.WikiPageArgs{
    			ProjectId: example.ID(),
    			WikiId:    exampleWiki.ID(),
    			Path:      pulumi.String("/page"),
    			Content:   pulumi.String("content"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using AzureDevOps = Pulumi.AzureDevOps;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new AzureDevOps.Project("example", new()
        {
            Name = "Example Project",
            Description = "Managed by Terraform",
        });
    
        var exampleWiki = new AzureDevOps.Wiki("example", new()
        {
            Name = "Example project wiki ",
            ProjectId = example.Id,
            Type = "projectWiki",
        });
    
        var exampleWikiPage = new AzureDevOps.WikiPage("example", new()
        {
            ProjectId = example.Id,
            WikiId = exampleWiki.Id,
            Path = "/page",
            Content = "content",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.azuredevops.Project;
    import com.pulumi.azuredevops.ProjectArgs;
    import com.pulumi.azuredevops.Wiki;
    import com.pulumi.azuredevops.WikiArgs;
    import com.pulumi.azuredevops.WikiPage;
    import com.pulumi.azuredevops.WikiPageArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var example = new Project("example", ProjectArgs.builder()
                .name("Example Project")
                .description("Managed by Terraform")
                .build());
    
            var exampleWiki = new Wiki("exampleWiki", WikiArgs.builder()
                .name("Example project wiki ")
                .projectId(example.id())
                .type("projectWiki")
                .build());
    
            var exampleWikiPage = new WikiPage("exampleWikiPage", WikiPageArgs.builder()
                .projectId(example.id())
                .wikiId(exampleWiki.id())
                .path("/page")
                .content("content")
                .build());
    
        }
    }
    
    resources:
      example:
        type: azuredevops:Project
        properties:
          name: Example Project
          description: Managed by Terraform
      exampleWiki:
        type: azuredevops:Wiki
        name: example
        properties:
          name: 'Example project wiki '
          projectId: ${example.id}
          type: projectWiki
      exampleWikiPage:
        type: azuredevops:WikiPage
        name: example
        properties:
          projectId: ${example.id}
          wikiId: ${exampleWiki.id}
          path: /page
          content: content
    

    Create WikiPage Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new WikiPage(name: string, args: WikiPageArgs, opts?: CustomResourceOptions);
    @overload
    def WikiPage(resource_name: str,
                 args: WikiPageArgs,
                 opts: Optional[ResourceOptions] = None)
    
    @overload
    def WikiPage(resource_name: str,
                 opts: Optional[ResourceOptions] = None,
                 content: Optional[str] = None,
                 path: Optional[str] = None,
                 project_id: Optional[str] = None,
                 wiki_id: Optional[str] = None,
                 etag: Optional[str] = None)
    func NewWikiPage(ctx *Context, name string, args WikiPageArgs, opts ...ResourceOption) (*WikiPage, error)
    public WikiPage(string name, WikiPageArgs args, CustomResourceOptions? opts = null)
    public WikiPage(String name, WikiPageArgs args)
    public WikiPage(String name, WikiPageArgs args, CustomResourceOptions options)
    
    type: azuredevops:WikiPage
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args WikiPageArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args WikiPageArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args WikiPageArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args WikiPageArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args WikiPageArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var wikiPageResource = new AzureDevOps.WikiPage("wikiPageResource", new()
    {
        Content = "string",
        Path = "string",
        ProjectId = "string",
        WikiId = "string",
        Etag = "string",
    });
    
    example, err := azuredevops.NewWikiPage(ctx, "wikiPageResource", &azuredevops.WikiPageArgs{
    	Content:   pulumi.String("string"),
    	Path:      pulumi.String("string"),
    	ProjectId: pulumi.String("string"),
    	WikiId:    pulumi.String("string"),
    	Etag:      pulumi.String("string"),
    })
    
    var wikiPageResource = new WikiPage("wikiPageResource", WikiPageArgs.builder()
        .content("string")
        .path("string")
        .projectId("string")
        .wikiId("string")
        .etag("string")
        .build());
    
    wiki_page_resource = azuredevops.WikiPage("wikiPageResource",
        content="string",
        path="string",
        project_id="string",
        wiki_id="string",
        etag="string")
    
    const wikiPageResource = new azuredevops.WikiPage("wikiPageResource", {
        content: "string",
        path: "string",
        projectId: "string",
        wikiId: "string",
        etag: "string",
    });
    
    type: azuredevops:WikiPage
    properties:
        content: string
        etag: string
        path: string
        projectId: string
        wikiId: string
    

    WikiPage Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The WikiPage resource accepts the following input properties:

    Content string
    The content of the wiki page.
    Path string
    The path of the wiki page.
    ProjectId string
    The ID of the Project.
    WikiId string
    The ID of the Wiki.
    Etag string
    Content string
    The content of the wiki page.
    Path string
    The path of the wiki page.
    ProjectId string
    The ID of the Project.
    WikiId string
    The ID of the Wiki.
    Etag string
    content String
    The content of the wiki page.
    path String
    The path of the wiki page.
    projectId String
    The ID of the Project.
    wikiId String
    The ID of the Wiki.
    etag String
    content string
    The content of the wiki page.
    path string
    The path of the wiki page.
    projectId string
    The ID of the Project.
    wikiId string
    The ID of the Wiki.
    etag string
    content str
    The content of the wiki page.
    path str
    The path of the wiki page.
    project_id str
    The ID of the Project.
    wiki_id str
    The ID of the Wiki.
    etag str
    content String
    The content of the wiki page.
    path String
    The path of the wiki page.
    projectId String
    The ID of the Project.
    wikiId String
    The ID of the Wiki.
    etag String

    Outputs

    All input properties are implicitly available as output properties. Additionally, the WikiPage resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing WikiPage Resource

    Get an existing WikiPage resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: WikiPageState, opts?: CustomResourceOptions): WikiPage
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            content: Optional[str] = None,
            etag: Optional[str] = None,
            path: Optional[str] = None,
            project_id: Optional[str] = None,
            wiki_id: Optional[str] = None) -> WikiPage
    func GetWikiPage(ctx *Context, name string, id IDInput, state *WikiPageState, opts ...ResourceOption) (*WikiPage, error)
    public static WikiPage Get(string name, Input<string> id, WikiPageState? state, CustomResourceOptions? opts = null)
    public static WikiPage get(String name, Output<String> id, WikiPageState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    Content string
    The content of the wiki page.
    Etag string
    Path string
    The path of the wiki page.
    ProjectId string
    The ID of the Project.
    WikiId string
    The ID of the Wiki.
    Content string
    The content of the wiki page.
    Etag string
    Path string
    The path of the wiki page.
    ProjectId string
    The ID of the Project.
    WikiId string
    The ID of the Wiki.
    content String
    The content of the wiki page.
    etag String
    path String
    The path of the wiki page.
    projectId String
    The ID of the Project.
    wikiId String
    The ID of the Wiki.
    content string
    The content of the wiki page.
    etag string
    path string
    The path of the wiki page.
    projectId string
    The ID of the Project.
    wikiId string
    The ID of the Wiki.
    content str
    The content of the wiki page.
    etag str
    path str
    The path of the wiki page.
    project_id str
    The ID of the Project.
    wiki_id str
    The ID of the Wiki.
    content String
    The content of the wiki page.
    etag String
    path String
    The path of the wiki page.
    projectId String
    The ID of the Project.
    wikiId String
    The ID of the Wiki.

    Package Details

    Repository
    Azure DevOps pulumi/pulumi-azuredevops
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the azuredevops Terraform Provider.
    azuredevops logo
    Azure DevOps v3.4.0 published on Wednesday, Oct 30, 2024 by Pulumi