1. Packages
  2. Alibaba Cloud Provider
  3. API Docs
  4. privatelink
  5. getVpcEndpointConnections
Alibaba Cloud v3.76.0 published on Tuesday, Apr 8, 2025 by Pulumi

alicloud.privatelink.getVpcEndpointConnections

Explore with Pulumi AI

This data source provides the Privatelink Vpc Endpoint Connections of the current Alibaba Cloud user.

NOTE: Available since v1.110.0.

Example Usage

Basic Usage

import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";

const example = alicloud.privatelink.getVpcEndpointConnections({
    serviceId: "example_value",
    status: "Connected",
});
export const firstPrivatelinkVpcEndpointConnectionId = example.then(example => example.connections?.[0]?.id);
Copy
import pulumi
import pulumi_alicloud as alicloud

example = alicloud.privatelink.get_vpc_endpoint_connections(service_id="example_value",
    status="Connected")
pulumi.export("firstPrivatelinkVpcEndpointConnectionId", example.connections[0].id)
Copy
package main

import (
	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/privatelink"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		example, err := privatelink.GetVpcEndpointConnections(ctx, &privatelink.GetVpcEndpointConnectionsArgs{
			ServiceId: "example_value",
			Status:    pulumi.StringRef("Connected"),
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("firstPrivatelinkVpcEndpointConnectionId", example.Connections[0].Id)
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;

return await Deployment.RunAsync(() => 
{
    var example = AliCloud.PrivateLink.GetVpcEndpointConnections.Invoke(new()
    {
        ServiceId = "example_value",
        Status = "Connected",
    });

    return new Dictionary<string, object?>
    {
        ["firstPrivatelinkVpcEndpointConnectionId"] = example.Apply(getVpcEndpointConnectionsResult => getVpcEndpointConnectionsResult.Connections[0]?.Id),
    };
});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.privatelink.PrivatelinkFunctions;
import com.pulumi.alicloud.privatelink.inputs.GetVpcEndpointConnectionsArgs;
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 = PrivatelinkFunctions.getVpcEndpointConnections(GetVpcEndpointConnectionsArgs.builder()
            .serviceId("example_value")
            .status("Connected")
            .build());

        ctx.export("firstPrivatelinkVpcEndpointConnectionId", example.applyValue(getVpcEndpointConnectionsResult -> getVpcEndpointConnectionsResult.connections()[0].id()));
    }
}
Copy
variables:
  example:
    fn::invoke:
      function: alicloud:privatelink:getVpcEndpointConnections
      arguments:
        serviceId: example_value
        status: Connected
outputs:
  firstPrivatelinkVpcEndpointConnectionId: ${example.connections[0].id}
Copy

Using getVpcEndpointConnections

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 getVpcEndpointConnections(args: GetVpcEndpointConnectionsArgs, opts?: InvokeOptions): Promise<GetVpcEndpointConnectionsResult>
function getVpcEndpointConnectionsOutput(args: GetVpcEndpointConnectionsOutputArgs, opts?: InvokeOptions): Output<GetVpcEndpointConnectionsResult>
Copy
def get_vpc_endpoint_connections(endpoint_id: Optional[str] = None,
                                 endpoint_owner_id: Optional[int] = None,
                                 output_file: Optional[str] = None,
                                 service_id: Optional[str] = None,
                                 status: Optional[str] = None,
                                 opts: Optional[InvokeOptions] = None) -> GetVpcEndpointConnectionsResult
def get_vpc_endpoint_connections_output(endpoint_id: Optional[pulumi.Input[str]] = None,
                                 endpoint_owner_id: Optional[pulumi.Input[int]] = None,
                                 output_file: Optional[pulumi.Input[str]] = None,
                                 service_id: Optional[pulumi.Input[str]] = None,
                                 status: Optional[pulumi.Input[str]] = None,
                                 opts: Optional[InvokeOptions] = None) -> Output[GetVpcEndpointConnectionsResult]
Copy
func GetVpcEndpointConnections(ctx *Context, args *GetVpcEndpointConnectionsArgs, opts ...InvokeOption) (*GetVpcEndpointConnectionsResult, error)
func GetVpcEndpointConnectionsOutput(ctx *Context, args *GetVpcEndpointConnectionsOutputArgs, opts ...InvokeOption) GetVpcEndpointConnectionsResultOutput
Copy

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

public static class GetVpcEndpointConnections 
{
    public static Task<GetVpcEndpointConnectionsResult> InvokeAsync(GetVpcEndpointConnectionsArgs args, InvokeOptions? opts = null)
    public static Output<GetVpcEndpointConnectionsResult> Invoke(GetVpcEndpointConnectionsInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<GetVpcEndpointConnectionsResult> getVpcEndpointConnections(GetVpcEndpointConnectionsArgs args, InvokeOptions options)
public static Output<GetVpcEndpointConnectionsResult> getVpcEndpointConnections(GetVpcEndpointConnectionsArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: alicloud:privatelink/getVpcEndpointConnections:getVpcEndpointConnections
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

ServiceId
This property is required.
Changes to this property will trigger replacement.
string
The ID of the Vpc Endpoint Service.
EndpointId Changes to this property will trigger replacement. string
The ID of the Vpc Endpoint.
EndpointOwnerId Changes to this property will trigger replacement. int
The endpoint owner id.
OutputFile string
File name where to save data source results (after running pulumi preview).
Status Changes to this property will trigger replacement. string
The status of Vpc Endpoint Connection. Valid Values: Connected, Connecting, Deleted, Deleting, Disconnected, Disconnecting, Pending and ServiceDeleted.
ServiceId
This property is required.
Changes to this property will trigger replacement.
string
The ID of the Vpc Endpoint Service.
EndpointId Changes to this property will trigger replacement. string
The ID of the Vpc Endpoint.
EndpointOwnerId Changes to this property will trigger replacement. int
The endpoint owner id.
OutputFile string
File name where to save data source results (after running pulumi preview).
Status Changes to this property will trigger replacement. string
The status of Vpc Endpoint Connection. Valid Values: Connected, Connecting, Deleted, Deleting, Disconnected, Disconnecting, Pending and ServiceDeleted.
serviceId
This property is required.
Changes to this property will trigger replacement.
String
The ID of the Vpc Endpoint Service.
endpointId Changes to this property will trigger replacement. String
The ID of the Vpc Endpoint.
endpointOwnerId Changes to this property will trigger replacement. Integer
The endpoint owner id.
outputFile String
File name where to save data source results (after running pulumi preview).
status Changes to this property will trigger replacement. String
The status of Vpc Endpoint Connection. Valid Values: Connected, Connecting, Deleted, Deleting, Disconnected, Disconnecting, Pending and ServiceDeleted.
serviceId
This property is required.
Changes to this property will trigger replacement.
string
The ID of the Vpc Endpoint Service.
endpointId Changes to this property will trigger replacement. string
The ID of the Vpc Endpoint.
endpointOwnerId Changes to this property will trigger replacement. number
The endpoint owner id.
outputFile string
File name where to save data source results (after running pulumi preview).
status Changes to this property will trigger replacement. string
The status of Vpc Endpoint Connection. Valid Values: Connected, Connecting, Deleted, Deleting, Disconnected, Disconnecting, Pending and ServiceDeleted.
service_id
This property is required.
Changes to this property will trigger replacement.
str
The ID of the Vpc Endpoint Service.
endpoint_id Changes to this property will trigger replacement. str
The ID of the Vpc Endpoint.
endpoint_owner_id Changes to this property will trigger replacement. int
The endpoint owner id.
output_file str
File name where to save data source results (after running pulumi preview).
status Changes to this property will trigger replacement. str
The status of Vpc Endpoint Connection. Valid Values: Connected, Connecting, Deleted, Deleting, Disconnected, Disconnecting, Pending and ServiceDeleted.
serviceId
This property is required.
Changes to this property will trigger replacement.
String
The ID of the Vpc Endpoint Service.
endpointId Changes to this property will trigger replacement. String
The ID of the Vpc Endpoint.
endpointOwnerId Changes to this property will trigger replacement. Number
The endpoint owner id.
outputFile String
File name where to save data source results (after running pulumi preview).
status Changes to this property will trigger replacement. String
The status of Vpc Endpoint Connection. Valid Values: Connected, Connecting, Deleted, Deleting, Disconnected, Disconnecting, Pending and ServiceDeleted.

getVpcEndpointConnections Result

The following output properties are available:

Connections List<Pulumi.AliCloud.PrivateLink.Outputs.GetVpcEndpointConnectionsConnection>
A list of Privatelink Vpc Endpoint Connections. Each element contains the following attributes:
Id string
The provider-assigned unique ID for this managed resource.
Ids List<string>
A list of Vpc Endpoint Connection IDs.
ServiceId string
EndpointId string
The ID of the Vpc Endpoint.
EndpointOwnerId int
OutputFile string
Status string
The status of Vpc Endpoint Connection.
Connections []GetVpcEndpointConnectionsConnection
A list of Privatelink Vpc Endpoint Connections. Each element contains the following attributes:
Id string
The provider-assigned unique ID for this managed resource.
Ids []string
A list of Vpc Endpoint Connection IDs.
ServiceId string
EndpointId string
The ID of the Vpc Endpoint.
EndpointOwnerId int
OutputFile string
Status string
The status of Vpc Endpoint Connection.
connections List<GetVpcEndpointConnectionsConnection>
A list of Privatelink Vpc Endpoint Connections. Each element contains the following attributes:
id String
The provider-assigned unique ID for this managed resource.
ids List<String>
A list of Vpc Endpoint Connection IDs.
serviceId String
endpointId String
The ID of the Vpc Endpoint.
endpointOwnerId Integer
outputFile String
status String
The status of Vpc Endpoint Connection.
connections GetVpcEndpointConnectionsConnection[]
A list of Privatelink Vpc Endpoint Connections. Each element contains the following attributes:
id string
The provider-assigned unique ID for this managed resource.
ids string[]
A list of Vpc Endpoint Connection IDs.
serviceId string
endpointId string
The ID of the Vpc Endpoint.
endpointOwnerId number
outputFile string
status string
The status of Vpc Endpoint Connection.
connections Sequence[GetVpcEndpointConnectionsConnection]
A list of Privatelink Vpc Endpoint Connections. Each element contains the following attributes:
id str
The provider-assigned unique ID for this managed resource.
ids Sequence[str]
A list of Vpc Endpoint Connection IDs.
service_id str
endpoint_id str
The ID of the Vpc Endpoint.
endpoint_owner_id int
output_file str
status str
The status of Vpc Endpoint Connection.
connections List<Property Map>
A list of Privatelink Vpc Endpoint Connections. Each element contains the following attributes:
id String
The provider-assigned unique ID for this managed resource.
ids List<String>
A list of Vpc Endpoint Connection IDs.
serviceId String
endpointId String
The ID of the Vpc Endpoint.
endpointOwnerId Number
outputFile String
status String
The status of Vpc Endpoint Connection.

Supporting Types

GetVpcEndpointConnectionsConnection

Bandwidth This property is required. int
The Bandwidth.
EndpointId This property is required. string
The ID of the Vpc Endpoint.
Id This property is required. string
The ID of the Vpc Endpoint Connection.
Status This property is required. string
The status of Vpc Endpoint Connection. Valid Values: Connected, Connecting, Deleted, Deleting, Disconnected, Disconnecting, Pending and ServiceDeleted.
Bandwidth This property is required. int
The Bandwidth.
EndpointId This property is required. string
The ID of the Vpc Endpoint.
Id This property is required. string
The ID of the Vpc Endpoint Connection.
Status This property is required. string
The status of Vpc Endpoint Connection. Valid Values: Connected, Connecting, Deleted, Deleting, Disconnected, Disconnecting, Pending and ServiceDeleted.
bandwidth This property is required. Integer
The Bandwidth.
endpointId This property is required. String
The ID of the Vpc Endpoint.
id This property is required. String
The ID of the Vpc Endpoint Connection.
status This property is required. String
The status of Vpc Endpoint Connection. Valid Values: Connected, Connecting, Deleted, Deleting, Disconnected, Disconnecting, Pending and ServiceDeleted.
bandwidth This property is required. number
The Bandwidth.
endpointId This property is required. string
The ID of the Vpc Endpoint.
id This property is required. string
The ID of the Vpc Endpoint Connection.
status This property is required. string
The status of Vpc Endpoint Connection. Valid Values: Connected, Connecting, Deleted, Deleting, Disconnected, Disconnecting, Pending and ServiceDeleted.
bandwidth This property is required. int
The Bandwidth.
endpoint_id This property is required. str
The ID of the Vpc Endpoint.
id This property is required. str
The ID of the Vpc Endpoint Connection.
status This property is required. str
The status of Vpc Endpoint Connection. Valid Values: Connected, Connecting, Deleted, Deleting, Disconnected, Disconnecting, Pending and ServiceDeleted.
bandwidth This property is required. Number
The Bandwidth.
endpointId This property is required. String
The ID of the Vpc Endpoint.
id This property is required. String
The ID of the Vpc Endpoint Connection.
status This property is required. String
The status of Vpc Endpoint Connection. Valid Values: Connected, Connecting, Deleted, Deleting, Disconnected, Disconnecting, Pending and ServiceDeleted.

Package Details

Repository
Alibaba Cloud pulumi/pulumi-alicloud
License
Apache-2.0
Notes
This Pulumi package is based on the alicloud Terraform Provider.