1. Packages
  2. Dbtcloud Provider
  3. API Docs
  4. getAzureDevOpsRepository
dbt Cloud v0.1.25 published on Friday, Nov 8, 2024 by Pulumi

dbtcloud.getAzureDevOpsRepository

Explore with Pulumi AI

dbtcloud logo
dbt Cloud v0.1.25 published on Friday, Nov 8, 2024 by Pulumi

    Use this data source to retrieve the ID and details of an Azure Dev Ops repository based on its name and the ID of the Azure Dev Ops project it belongs to.

    This data source requires connecting with a user token and doesn’t work with a service token.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as dbtcloud from "@pulumi/dbtcloud";
    
    const myAdoRepository = dbtcloud.getAzureDevOpsRepository({
        name: "my-repo-name",
        azureDevOpsProjectId: myAdoProject.id,
    });
    
    import pulumi
    import pulumi_dbtcloud as dbtcloud
    
    my_ado_repository = dbtcloud.get_azure_dev_ops_repository(name="my-repo-name",
        azure_dev_ops_project_id=my_ado_project["id"])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-dbtcloud/sdk/go/dbtcloud"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := dbtcloud.GetAzureDevOpsRepository(ctx, &dbtcloud.GetAzureDevOpsRepositoryArgs{
    			Name:                 "my-repo-name",
    			AzureDevOpsProjectId: myAdoProject.Id,
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using DbtCloud = Pulumi.DbtCloud;
    
    return await Deployment.RunAsync(() => 
    {
        var myAdoRepository = DbtCloud.GetAzureDevOpsRepository.Invoke(new()
        {
            Name = "my-repo-name",
            AzureDevOpsProjectId = myAdoProject.Id,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.dbtcloud.DbtcloudFunctions;
    import com.pulumi.dbtcloud.inputs.GetAzureDevOpsRepositoryArgs;
    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 myAdoRepository = DbtcloudFunctions.getAzureDevOpsRepository(GetAzureDevOpsRepositoryArgs.builder()
                .name("my-repo-name")
                .azureDevOpsProjectId(myAdoProject.id())
                .build());
    
        }
    }
    
    variables:
      myAdoRepository:
        fn::invoke:
          Function: dbtcloud:getAzureDevOpsRepository
          Arguments:
            name: my-repo-name
            azureDevOpsProjectId: ${myAdoProject.id}
    

    Using getAzureDevOpsRepository

    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 getAzureDevOpsRepository(args: GetAzureDevOpsRepositoryArgs, opts?: InvokeOptions): Promise<GetAzureDevOpsRepositoryResult>
    function getAzureDevOpsRepositoryOutput(args: GetAzureDevOpsRepositoryOutputArgs, opts?: InvokeOptions): Output<GetAzureDevOpsRepositoryResult>
    def get_azure_dev_ops_repository(azure_dev_ops_project_id: Optional[str] = None,
                                     name: Optional[str] = None,
                                     opts: Optional[InvokeOptions] = None) -> GetAzureDevOpsRepositoryResult
    def get_azure_dev_ops_repository_output(azure_dev_ops_project_id: Optional[pulumi.Input[str]] = None,
                                     name: Optional[pulumi.Input[str]] = None,
                                     opts: Optional[InvokeOptions] = None) -> Output[GetAzureDevOpsRepositoryResult]
    func GetAzureDevOpsRepository(ctx *Context, args *GetAzureDevOpsRepositoryArgs, opts ...InvokeOption) (*GetAzureDevOpsRepositoryResult, error)
    func GetAzureDevOpsRepositoryOutput(ctx *Context, args *GetAzureDevOpsRepositoryOutputArgs, opts ...InvokeOption) GetAzureDevOpsRepositoryResultOutput

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

    public static class GetAzureDevOpsRepository 
    {
        public static Task<GetAzureDevOpsRepositoryResult> InvokeAsync(GetAzureDevOpsRepositoryArgs args, InvokeOptions? opts = null)
        public static Output<GetAzureDevOpsRepositoryResult> Invoke(GetAzureDevOpsRepositoryInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetAzureDevOpsRepositoryResult> getAzureDevOpsRepository(GetAzureDevOpsRepositoryArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: dbtcloud:index/getAzureDevOpsRepository:getAzureDevOpsRepository
      arguments:
        # arguments dictionary

    The following arguments are supported:

    AzureDevOpsProjectId string
    The internal Azure Dev Ops ID of the ADO Project. Can be retrieved using the data source dbtcloudazuredevopsproject and the project name
    Name string
    The name of the ADO repository
    AzureDevOpsProjectId string
    The internal Azure Dev Ops ID of the ADO Project. Can be retrieved using the data source dbtcloudazuredevopsproject and the project name
    Name string
    The name of the ADO repository
    azureDevOpsProjectId String
    The internal Azure Dev Ops ID of the ADO Project. Can be retrieved using the data source dbtcloudazuredevopsproject and the project name
    name String
    The name of the ADO repository
    azureDevOpsProjectId string
    The internal Azure Dev Ops ID of the ADO Project. Can be retrieved using the data source dbtcloudazuredevopsproject and the project name
    name string
    The name of the ADO repository
    azure_dev_ops_project_id str
    The internal Azure Dev Ops ID of the ADO Project. Can be retrieved using the data source dbtcloudazuredevopsproject and the project name
    name str
    The name of the ADO repository
    azureDevOpsProjectId String
    The internal Azure Dev Ops ID of the ADO Project. Can be retrieved using the data source dbtcloudazuredevopsproject and the project name
    name String
    The name of the ADO repository

    getAzureDevOpsRepository Result

    The following output properties are available:

    AzureDevOpsProjectId string
    The internal Azure Dev Ops ID of the ADO Project. Can be retrieved using the data source dbtcloudazuredevopsproject and the project name
    DefaultBranch string
    The default branch of the ADO repository
    DetailsUrl string
    The URL of the ADO repository showing details about the repository and its attributes
    Id string
    The internal Azure Dev Ops ID of the ADO Repository
    Name string
    The name of the ADO repository
    RemoteUrl string
    The HTTP URL of the ADO repository used to connect to dbt Cloud
    WebUrl string
    The URL of the ADO repository accessible in the browser
    AzureDevOpsProjectId string
    The internal Azure Dev Ops ID of the ADO Project. Can be retrieved using the data source dbtcloudazuredevopsproject and the project name
    DefaultBranch string
    The default branch of the ADO repository
    DetailsUrl string
    The URL of the ADO repository showing details about the repository and its attributes
    Id string
    The internal Azure Dev Ops ID of the ADO Repository
    Name string
    The name of the ADO repository
    RemoteUrl string
    The HTTP URL of the ADO repository used to connect to dbt Cloud
    WebUrl string
    The URL of the ADO repository accessible in the browser
    azureDevOpsProjectId String
    The internal Azure Dev Ops ID of the ADO Project. Can be retrieved using the data source dbtcloudazuredevopsproject and the project name
    defaultBranch String
    The default branch of the ADO repository
    detailsUrl String
    The URL of the ADO repository showing details about the repository and its attributes
    id String
    The internal Azure Dev Ops ID of the ADO Repository
    name String
    The name of the ADO repository
    remoteUrl String
    The HTTP URL of the ADO repository used to connect to dbt Cloud
    webUrl String
    The URL of the ADO repository accessible in the browser
    azureDevOpsProjectId string
    The internal Azure Dev Ops ID of the ADO Project. Can be retrieved using the data source dbtcloudazuredevopsproject and the project name
    defaultBranch string
    The default branch of the ADO repository
    detailsUrl string
    The URL of the ADO repository showing details about the repository and its attributes
    id string
    The internal Azure Dev Ops ID of the ADO Repository
    name string
    The name of the ADO repository
    remoteUrl string
    The HTTP URL of the ADO repository used to connect to dbt Cloud
    webUrl string
    The URL of the ADO repository accessible in the browser
    azure_dev_ops_project_id str
    The internal Azure Dev Ops ID of the ADO Project. Can be retrieved using the data source dbtcloudazuredevopsproject and the project name
    default_branch str
    The default branch of the ADO repository
    details_url str
    The URL of the ADO repository showing details about the repository and its attributes
    id str
    The internal Azure Dev Ops ID of the ADO Repository
    name str
    The name of the ADO repository
    remote_url str
    The HTTP URL of the ADO repository used to connect to dbt Cloud
    web_url str
    The URL of the ADO repository accessible in the browser
    azureDevOpsProjectId String
    The internal Azure Dev Ops ID of the ADO Project. Can be retrieved using the data source dbtcloudazuredevopsproject and the project name
    defaultBranch String
    The default branch of the ADO repository
    detailsUrl String
    The URL of the ADO repository showing details about the repository and its attributes
    id String
    The internal Azure Dev Ops ID of the ADO Repository
    name String
    The name of the ADO repository
    remoteUrl String
    The HTTP URL of the ADO repository used to connect to dbt Cloud
    webUrl String
    The URL of the ADO repository accessible in the browser

    Package Details

    Repository
    dbtcloud pulumi/pulumi-dbtcloud
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the dbtcloud Terraform Provider.
    dbtcloud logo
    dbt Cloud v0.1.25 published on Friday, Nov 8, 2024 by Pulumi