> For the complete documentation index, see [llms.txt](https://docs.console.zenlayer.com/api-reference/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.console.zenlayer.com/api-reference/networking/sdn/private-connect/describeprivateconnects.md).

# DescribePrivateConnects

## 1. API Description

This API (DescribePrivateConnects) is used to get Private Connects

## 2. Input Parameters

The following request parameter list only provides API request parameters.

| Parameter Name       | Required | Type                                                                                    | Description                                                                                                                 |
| -------------------- | -------- | --------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------- |
| privateConnectIds    | No       | Array of String                                                                         | List of Private Connect IDs. Up to 100 IDs supported per query.                                                             |
| privateConnectName   | No       | String                                                                                  | Private Connect name. Supports fuzzy matching.                                                                              |
| connectivityStatus   | No       | [ConnectivityStatus](/api-reference/networking/sdn/datastructure.md#connectivitystatus) | Filter by connectivity status.                                                                                              |
| privateConnectStatus | No       | [BusinessStatus](/api-reference/networking/sdn/datastructure.md#businessstatus)         | Filter by Private Connect business status.                                                                                  |
| endpointTypes        | No       | Array of [EndpointType](/api-reference/networking/sdn/datastructure.md#endpointtype)    | Filter by endpoint type.                                                                                                    |
| resourceGroupId      | No       | String                                                                                  | <p>Resource group ID.</p><p>If not specified, Private Connects in all resource groups visible to the user are returned.</p> |
| pageSize             | No       | Integer                                                                                 | Page size to return. Default: 20, maximum: 1000.                                                                            |
| pageNum              | No       | Integer                                                                                 | <p>Page number to return. Default: 1.</p><p>Default value: 1</p>                                                            |
| tagKeys              | No       | Array of String                                                                         | <p>Search by tag keys.</p><p>Up to 20 tag keys.</p>                                                                         |
| tags                 | No       | Array of [Tag](/api-reference/networking/sdn/datastructure.md#tag)                      | <p>Search by tags.</p><p>Up to 20 tags.</p>                                                                                 |

## 3. Output Parameters

| Parameter Name | Type                                                                                     | Description                                                                                                           |
| -------------- | ---------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------- |
| requestId      | String                                                                                   | <p>The unique request ID, which is returned for each request.</p><p>RequestId is required for locating a problem.</p> |
| totalCount     | Integer                                                                                  | Total number of Private Connects matching the criteria.                                                               |
| dataSet        | Array of [PrivateConnect](/api-reference/networking/sdn/datastructure.md#privateconnect) | List of Private Connects.                                                                                             |

## 4. Code Example

{% tabs %}
{% tab title="Example" %}
**1. Get the list of Private Connects.**

```json
POST /api/v2/sdn HTTP/1.1
Host: console.zenlayer.com
Content-Type: application/json
X-ZC-Action: DescribePrivateConnects
<Common Request Params>

Request:
{}

Response:
{   
  "requestId": "TDB181167-C39F-4C3E-8E88-B8FDE755FDC0",
  "response": {
     "requestId": "T98044459-95B2-477E-9A2F-00253A70CC6E",
     "dataSet": [
         {
            "endpointA":{
                "endpointType":"PORT",
                "dataCenter":{
                    "dcId":"SIN1",
                    "cityName":"Singapore",
                    "areaName":"Asia Pacific",
                    "dcName":"Equinix_SG1",
                    "dcAddress":"20 Ayer Rajah Crescent, Ayer Rajah Industrial Park, Singapore 139964",
                    "countryName":"Singapore"
                },
                "vlanId":"1001",
                "endpointId":"endpoint A id",
                "endpointName":"portName",
                "connectivityStatus":"ACTIVE"
            },
            "resourceGroupName":"Default Resource Group",
            "createTime":"2023-01-01T00:00:00Z",
            "privateConnectStatus":"RUNNING",
            "privateConnectName":"private-name",
            "endpointZ":{
                "endpointType":"PORT",
                "dataCenter":{
                    "dcId":"SIN1",
                    "cityName":"Singapore",
                    "areaName":"Asia Pacific",
                    "dcName":"Equinix_SG1",
                    "dcAddress":"20 Ayer Rajah Crescent, Ayer Rajah Industrial Park, Singapore 139964",
                    "countryName":"Singapore"
                },
                "vlanId":1002,
                "endpointId":"endpoint z id",
                "endpointName":"SIN1-10G",
                "connectivityStatus":"ACTIVE"
            },
            "resourceGroupId":"resource-group-id",
            "privateConnectId":"private-connect-id",
            "connectivityStatus":"ACTIVE",
            "bandwidthMbps":10
        }
     ],
     "totalCount": 1
  }
}
```

{% endtab %}
{% endtabs %}

## 5. Developer Resources

Zenlayer Cloud API 2.0 integrates [SDKs](/api-reference/api-introduction/toolkit/api-sdk.md)，to make it easier for you to call APIs. More programming languages will be supported.

## 6. Error Codes

The following only lists the error codes related to the API business logic. For other error codes, see [Common Error Codes](/api-reference/api-introduction/instruction/commonerrorcode.md).

| HTTP Status Code | Error Code | Description |
| ---------------- | ---------- | ----------- |
