1. Packages
  2. AzureDevOps
  3. API Docs
  4. getFeed
Azure DevOps v3.1.1 published on Monday, May 20, 2024 by Pulumi

azuredevops.getFeed

Explore with Pulumi AI

azuredevops logo
Azure DevOps v3.1.1 published on Monday, May 20, 2024 by Pulumi

    Use this data source to access information about existing Feed within a given project in Azure DevOps.

    Example Usage

    Basic Example

    import * as pulumi from "@pulumi/pulumi";
    import * as azuredevops from "@pulumi/azuredevops";
    
    const example = azuredevops.getFeed({
        name: "releases",
    });
    
    import pulumi
    import pulumi_azuredevops as azuredevops
    
    example = azuredevops.get_feed(name="releases")
    
    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 {
    		_, err := azuredevops.LookupFeed(ctx, &azuredevops.LookupFeedArgs{
    			Name: pulumi.StringRef("releases"),
    		}, nil)
    		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 = AzureDevOps.GetFeed.Invoke(new()
        {
            Name = "releases",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.azuredevops.AzuredevopsFunctions;
    import com.pulumi.azuredevops.inputs.GetFeedArgs;
    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) {
            final var example = AzuredevopsFunctions.getFeed(GetFeedArgs.builder()
                .name("releases")
                .build());
    
        }
    }
    
    variables:
      example:
        fn::invoke:
          Function: azuredevops:getFeed
          Arguments:
            name: releases
    

    Access feed within a project

    import * as pulumi from "@pulumi/pulumi";
    import * as azuredevops from "@pulumi/azuredevops";
    
    const example = azuredevops.getProject({
        name: "Example Project",
    });
    const exampleGetFeed = example.then(example => azuredevops.getFeed({
        name: "releases",
        projectId: example.id,
    }));
    
    import pulumi
    import pulumi_azuredevops as azuredevops
    
    example = azuredevops.get_project(name="Example Project")
    example_get_feed = azuredevops.get_feed(name="releases",
        project_id=example.id)
    
    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.LookupProject(ctx, &azuredevops.LookupProjectArgs{
    			Name: pulumi.StringRef("Example Project"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		_, err = azuredevops.LookupFeed(ctx, &azuredevops.LookupFeedArgs{
    			Name:      pulumi.StringRef("releases"),
    			ProjectId: pulumi.StringRef(example.Id),
    		}, nil)
    		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 = AzureDevOps.GetProject.Invoke(new()
        {
            Name = "Example Project",
        });
    
        var exampleGetFeed = AzureDevOps.GetFeed.Invoke(new()
        {
            Name = "releases",
            ProjectId = example.Apply(getProjectResult => getProjectResult.Id),
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.azuredevops.AzuredevopsFunctions;
    import com.pulumi.azuredevops.inputs.GetProjectArgs;
    import com.pulumi.azuredevops.inputs.GetFeedArgs;
    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) {
            final var example = AzuredevopsFunctions.getProject(GetProjectArgs.builder()
                .name("Example Project")
                .build());
    
            final var exampleGetFeed = AzuredevopsFunctions.getFeed(GetFeedArgs.builder()
                .name("releases")
                .projectId(example.applyValue(getProjectResult -> getProjectResult.id()))
                .build());
    
        }
    }
    
    variables:
      example:
        fn::invoke:
          Function: azuredevops:getProject
          Arguments:
            name: Example Project
      exampleGetFeed:
        fn::invoke:
          Function: azuredevops:getFeed
          Arguments:
            name: releases
            projectId: ${example.id}
    

    Using getFeed

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getFeed(args: GetFeedArgs, opts?: InvokeOptions): Promise<GetFeedResult>
    function getFeedOutput(args: GetFeedOutputArgs, opts?: InvokeOptions): Output<GetFeedResult>
    def get_feed(feed_id: Optional[str] = None,
                 name: Optional[str] = None,
                 project_id: Optional[str] = None,
                 opts: Optional[InvokeOptions] = None) -> GetFeedResult
    def get_feed_output(feed_id: Optional[pulumi.Input[str]] = None,
                 name: Optional[pulumi.Input[str]] = None,
                 project_id: Optional[pulumi.Input[str]] = None,
                 opts: Optional[InvokeOptions] = None) -> Output[GetFeedResult]
    func LookupFeed(ctx *Context, args *LookupFeedArgs, opts ...InvokeOption) (*LookupFeedResult, error)
    func LookupFeedOutput(ctx *Context, args *LookupFeedOutputArgs, opts ...InvokeOption) LookupFeedResultOutput

    > Note: This function is named LookupFeed in the Go SDK.

    public static class GetFeed 
    {
        public static Task<GetFeedResult> InvokeAsync(GetFeedArgs args, InvokeOptions? opts = null)
        public static Output<GetFeedResult> Invoke(GetFeedInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetFeedResult> getFeed(GetFeedArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: azuredevops:index/getFeed:getFeed
      arguments:
        # arguments dictionary

    The following arguments are supported:

    FeedId string

    ID of the Feed.

    Note Only one of name or feed_id can be set at the same time.

    Name string
    Name of the Feed.
    ProjectId string
    ID of the Project Feed is created in.
    FeedId string

    ID of the Feed.

    Note Only one of name or feed_id can be set at the same time.

    Name string
    Name of the Feed.
    ProjectId string
    ID of the Project Feed is created in.
    feedId String

    ID of the Feed.

    Note Only one of name or feed_id can be set at the same time.

    name String
    Name of the Feed.
    projectId String
    ID of the Project Feed is created in.
    feedId string

    ID of the Feed.

    Note Only one of name or feed_id can be set at the same time.

    name string
    Name of the Feed.
    projectId string
    ID of the Project Feed is created in.
    feed_id str

    ID of the Feed.

    Note Only one of name or feed_id can be set at the same time.

    name str
    Name of the Feed.
    project_id str
    ID of the Project Feed is created in.
    feedId String

    ID of the Feed.

    Note Only one of name or feed_id can be set at the same time.

    name String
    Name of the Feed.
    projectId String
    ID of the Project Feed is created in.

    getFeed Result

    The following output properties are available:

    Id string
    The provider-assigned unique ID for this managed resource.
    FeedId string
    The ID of the Feed.
    Name string
    The name of the Feed.
    ProjectId string
    The ID of the Project.
    Id string
    The provider-assigned unique ID for this managed resource.
    FeedId string
    The ID of the Feed.
    Name string
    The name of the Feed.
    ProjectId string
    The ID of the Project.
    id String
    The provider-assigned unique ID for this managed resource.
    feedId String
    The ID of the Feed.
    name String
    The name of the Feed.
    projectId String
    The ID of the Project.
    id string
    The provider-assigned unique ID for this managed resource.
    feedId string
    The ID of the Feed.
    name string
    The name of the Feed.
    projectId string
    The ID of the Project.
    id str
    The provider-assigned unique ID for this managed resource.
    feed_id str
    The ID of the Feed.
    name str
    The name of the Feed.
    project_id str
    The ID of the Project.
    id String
    The provider-assigned unique ID for this managed resource.
    feedId String
    The ID of the Feed.
    name String
    The name of the Feed.
    projectId String
    The ID of the Project.

    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.1.1 published on Monday, May 20, 2024 by Pulumi