1. Packages
  2. Azuredevops Provider
  3. API Docs
  4. getServiceendpointNpm
Azure DevOps v3.3.0 published on Wednesday, Sep 4, 2024 by Pulumi

azuredevops.getServiceendpointNpm

Explore with Pulumi AI

azuredevops logo
Azure DevOps v3.3.0 published on Wednesday, Sep 4, 2024 by Pulumi

    Use this data source to access information about an existing NPM Service Endpoint.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as azuredevops from "@pulumi/azuredevops";
    
    const example = azuredevops.getServiceendpointNpm({
        projectId: exampleAzuredevopsProject.id,
        serviceEndpointName: "Example npm",
    });
    export const serviceEndpointId = example.then(example => example.id);
    
    import pulumi
    import pulumi_azuredevops as azuredevops
    
    example = azuredevops.get_serviceendpoint_npm(project_id=example_azuredevops_project["id"],
        service_endpoint_name="Example npm")
    pulumi.export("serviceEndpointId", 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.GetServiceendpointNpm(ctx, &azuredevops.GetServiceendpointNpmArgs{
    			ProjectId:           exampleAzuredevopsProject.Id,
    			ServiceEndpointName: pulumi.StringRef("Example npm"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		ctx.Export("serviceEndpointId", example.Id)
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using AzureDevOps = Pulumi.AzureDevOps;
    
    return await Deployment.RunAsync(() => 
    {
        var example = AzureDevOps.GetServiceendpointNpm.Invoke(new()
        {
            ProjectId = exampleAzuredevopsProject.Id,
            ServiceEndpointName = "Example npm",
        });
    
        return new Dictionary<string, object?>
        {
            ["serviceEndpointId"] = example.Apply(getServiceendpointNpmResult => getServiceendpointNpmResult.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.GetServiceendpointNpmArgs;
    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.getServiceendpointNpm(GetServiceendpointNpmArgs.builder()
                .projectId(exampleAzuredevopsProject.id())
                .serviceEndpointName("Example npm")
                .build());
    
            ctx.export("serviceEndpointId", example.applyValue(getServiceendpointNpmResult -> getServiceendpointNpmResult.id()));
        }
    }
    
    variables:
      example:
        fn::invoke:
          Function: azuredevops:getServiceendpointNpm
          Arguments:
            projectId: ${exampleAzuredevopsProject.id}
            serviceEndpointName: Example npm
    outputs:
      serviceEndpointId: ${example.id}
    

    Using getServiceendpointNpm

    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 getServiceendpointNpm(args: GetServiceendpointNpmArgs, opts?: InvokeOptions): Promise<GetServiceendpointNpmResult>
    function getServiceendpointNpmOutput(args: GetServiceendpointNpmOutputArgs, opts?: InvokeOptions): Output<GetServiceendpointNpmResult>
    def get_serviceendpoint_npm(project_id: Optional[str] = None,
                                service_endpoint_id: Optional[str] = None,
                                service_endpoint_name: Optional[str] = None,
                                opts: Optional[InvokeOptions] = None) -> GetServiceendpointNpmResult
    def get_serviceendpoint_npm_output(project_id: Optional[pulumi.Input[str]] = None,
                                service_endpoint_id: Optional[pulumi.Input[str]] = None,
                                service_endpoint_name: Optional[pulumi.Input[str]] = None,
                                opts: Optional[InvokeOptions] = None) -> Output[GetServiceendpointNpmResult]
    func GetServiceendpointNpm(ctx *Context, args *GetServiceendpointNpmArgs, opts ...InvokeOption) (*GetServiceendpointNpmResult, error)
    func GetServiceendpointNpmOutput(ctx *Context, args *GetServiceendpointNpmOutputArgs, opts ...InvokeOption) GetServiceendpointNpmResultOutput

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

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

    The following arguments are supported:

    ProjectId string
    The ID of the project.
    ServiceEndpointId string
    the ID of the Service Endpoint.
    ServiceEndpointName string

    the Name of the Service Endpoint.

    NOTE: One of either service_endpoint_id or service_endpoint_name must be specified.

    ProjectId string
    The ID of the project.
    ServiceEndpointId string
    the ID of the Service Endpoint.
    ServiceEndpointName string

    the Name of the Service Endpoint.

    NOTE: One of either service_endpoint_id or service_endpoint_name must be specified.

    projectId String
    The ID of the project.
    serviceEndpointId String
    the ID of the Service Endpoint.
    serviceEndpointName String

    the Name of the Service Endpoint.

    NOTE: One of either service_endpoint_id or service_endpoint_name must be specified.

    projectId string
    The ID of the project.
    serviceEndpointId string
    the ID of the Service Endpoint.
    serviceEndpointName string

    the Name of the Service Endpoint.

    NOTE: One of either service_endpoint_id or service_endpoint_name must be specified.

    project_id str
    The ID of the project.
    service_endpoint_id str
    the ID of the Service Endpoint.
    service_endpoint_name str

    the Name of the Service Endpoint.

    NOTE: One of either service_endpoint_id or service_endpoint_name must be specified.

    projectId String
    The ID of the project.
    serviceEndpointId String
    the ID of the Service Endpoint.
    serviceEndpointName String

    the Name of the Service Endpoint.

    NOTE: One of either service_endpoint_id or service_endpoint_name must be specified.

    getServiceendpointNpm Result

    The following output properties are available:

    Authorization Dictionary<string, string>
    Specifies the Authorization Scheme Map.
    Description string
    Specifies the description of the Service Endpoint.
    Id string
    The provider-assigned unique ID for this managed resource.
    ProjectId string
    ServiceEndpointId string
    ServiceEndpointName string
    Url string
    Specifies the URL of the npm registry to connect with.
    Authorization map[string]string
    Specifies the Authorization Scheme Map.
    Description string
    Specifies the description of the Service Endpoint.
    Id string
    The provider-assigned unique ID for this managed resource.
    ProjectId string
    ServiceEndpointId string
    ServiceEndpointName string
    Url string
    Specifies the URL of the npm registry to connect with.
    authorization Map<String,String>
    Specifies the Authorization Scheme Map.
    description String
    Specifies the description of the Service Endpoint.
    id String
    The provider-assigned unique ID for this managed resource.
    projectId String
    serviceEndpointId String
    serviceEndpointName String
    url String
    Specifies the URL of the npm registry to connect with.
    authorization {[key: string]: string}
    Specifies the Authorization Scheme Map.
    description string
    Specifies the description of the Service Endpoint.
    id string
    The provider-assigned unique ID for this managed resource.
    projectId string
    serviceEndpointId string
    serviceEndpointName string
    url string
    Specifies the URL of the npm registry to connect with.
    authorization Mapping[str, str]
    Specifies the Authorization Scheme Map.
    description str
    Specifies the description of the Service Endpoint.
    id str
    The provider-assigned unique ID for this managed resource.
    project_id str
    service_endpoint_id str
    service_endpoint_name str
    url str
    Specifies the URL of the npm registry to connect with.
    authorization Map<String>
    Specifies the Authorization Scheme Map.
    description String
    Specifies the description of the Service Endpoint.
    id String
    The provider-assigned unique ID for this managed resource.
    projectId String
    serviceEndpointId String
    serviceEndpointName String
    url String
    Specifies the URL of the npm registry to connect with.

    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.3.0 published on Wednesday, Sep 4, 2024 by Pulumi