vw_vpc_endpoints
Creates, updates, deletes, gets or lists a vw_vpc_endpoints resource.
Overview
| Name | vw_vpc_endpoints |
| Type | View |
| Id | databricks_account.provisioning.vw_vpc_endpoints |
Fields
The following fields are returned by this view:
| Name | Datatype | Description |
|---|---|---|
account_id | string | Databricks account ID used to scope the query. |
vpc_endpoint_id | string | Unique Databricks identifier for the VPC endpoint configuration. |
vpc_endpoint_name | string | Human-readable name of the VPC endpoint configuration. |
region | string | Cloud region where the VPC endpoint is deployed. |
state | string | Current state of the VPC endpoint (e.g. available, pending, rejected). |
use_case | string | Traffic type this endpoint handles (e.g. dataplane-relay, workspace-access). |
aws_account_id | string | AWS account ID that owns the VPC endpoint (AWS only). |
aws_endpoint_service_id | string | ID of the AWS endpoint service this VPC endpoint connects to (AWS only). |
aws_vpc_endpoint_id | string | AWS VPC endpoint ID (AWS only). |
gcp_project_id | string | GCP project ID containing the PSC endpoint (GCP only). |
gcp_psc_endpoint_name | string | Name of the GCP Private Service Connect endpoint (GCP only). |
gcp_endpoint_region | string | GCP region where the PSC endpoint is deployed (GCP only). |
gcp_psc_connection_id | string | Connection ID of the GCP PSC endpoint (GCP only). |
gcp_service_attachment_id | string | ID of the GCP service attachment the PSC endpoint connects to (GCP only). |
cloud_type | string | Derived cloud provider for this VPC endpoint - one of AWS, GCP, or UNKNOWN. |
Required Parameters
The following parameters are required by this view:
| Name | Datatype | Description |
|---|---|---|
account_id | string | Databricks account ID used to scope the query. |
SELECT Examples
SELECT
account_id,
vpc_endpoint_id,
vpc_endpoint_name,
region,
state,
use_case,
aws_account_id,
aws_endpoint_service_id,
aws_vpc_endpoint_id,
gcp_project_id,
gcp_psc_endpoint_name,
gcp_endpoint_region,
gcp_psc_connection_id,
gcp_service_attachment_id,
cloud_type
FROM databricks_account.provisioning.vw_vpc_endpoints
WHERE account_id = '{{ account_id }}';
SQL Definition
- Sqlite3
- Postgres
SELECT
v.account_id,
v.vpc_endpoint_id,
v.vpc_endpoint_name,
v.region,
v.state,
v.use_case,
v.aws_account_id,
v.aws_endpoint_service_id,
v.aws_vpc_endpoint_id,
JSON_EXTRACT(v.gcp_vpc_endpoint_info, '$.project_id') AS gcp_project_id,
JSON_EXTRACT(v.gcp_vpc_endpoint_info, '$.psc_endpoint_name') AS gcp_psc_endpoint_name,
JSON_EXTRACT(v.gcp_vpc_endpoint_info, '$.endpoint_region') AS gcp_endpoint_region,
JSON_EXTRACT(v.gcp_vpc_endpoint_info, '$.psc_connection_id') AS gcp_psc_connection_id,
JSON_EXTRACT(v.gcp_vpc_endpoint_info, '$.service_attachment_id') AS gcp_service_attachment_id,
CASE
WHEN v.aws_vpc_endpoint_id IS NOT NULL THEN 'AWS'
WHEN v.gcp_vpc_endpoint_info IS NOT NULL THEN 'GCP'
ELSE 'UNKNOWN'
END AS cloud_type
FROM databricks_account.provisioning.vpc_endpoints v
WHERE account_id = '{{ account_id }}'
SELECT
v.account_id,
v.vpc_endpoint_id,
v.vpc_endpoint_name,
v.region,
v.state,
v.use_case,
v.aws_account_id,
v.aws_endpoint_service_id,
v.aws_vpc_endpoint_id,
v.gcp_vpc_endpoint_info->>'project_id' AS gcp_project_id,
v.gcp_vpc_endpoint_info->>'psc_endpoint_name' AS gcp_psc_endpoint_name,
v.gcp_vpc_endpoint_info->>'endpoint_region' AS gcp_endpoint_region,
v.gcp_vpc_endpoint_info->>'psc_connection_id' AS gcp_psc_connection_id,
v.gcp_vpc_endpoint_info->>'service_attachment_id' AS gcp_service_attachment_id,
CASE
WHEN v.aws_vpc_endpoint_id IS NOT NULL THEN 'AWS'
WHEN v.gcp_vpc_endpoint_info IS NOT NULL THEN 'GCP'
ELSE 'UNKNOWN'
END AS cloud_type
FROM databricks_account.provisioning.vpc_endpoints v
WHERE account_id = '{{ account_id }}'