Overview
You can call this API to enable PrivateLink for a tenant.
Note
This API is not supported for Alibaba Cloud instances.
API details
Constraints
The caller must have an AccessKey for accessing the multi-cloud API. For information about how to obtain the AccessKey ID and AccessKey secret, see Manage AccessKeys.
Request path
POST /api/v2/instances/{instanceId}/tenants/{tenantId}/privatelink/service
Request parameters
| Name | Type | Required | Description | Example value |
|---|---|---|---|---|
| instanceId | String | Yes | The ID of the OceanBase Cloud instance. | ob317v4uif**** |
| tenantId | String | Yes | The ID of the tenant. | t33h8y08k**** |
| requestId | String | Yes | The request ID, which is used for tracing. | dc302d76-66b5-48d8-ab53-a035******** |
| userAccount | String | Yes | The user account information. | user123 |
| plServiceId | String | Yes | The ID of the PrivateLink service. | pls-xxxxx |
| serviceType | String | Yes | The service type. | OBProxy |
| isSharedPlService | Boolean | Yes | Indicates whether the PrivateLink service is shared. | false |
Response parameters
| Name | Type | Description | Example value |
|---|---|---|---|
| addressId | string | The ID of the address. | rs-private-intranet-vpc-XXXXXX-OBPROXY-INTRANET-XXXXXX |
| requestId | string | The request ID. | e448d60c-****-****-****-d33295124beb |
| success | string | Indicates whether the operation was successful. Valid values: |
true |
Examples
Request example
curl --digest -u '<Your AccessKey ID:AccessKey secret>' \
--request POST \
-H 'X-Ob-Project-Id: <Project ID>' \
-H 'Content-Type: application/json' \
--data '{"userAccount": "user123", "plServiceId": "pls-xxxxx", "serviceType": "OBProxy", "isSharedPlService": false}' \
'https://api-cloud.oceanbase.com/api/v2/instances/{instanceId}/tenants/{tenantId}/privatelink/service?requestId={requestId}'
Note
- A project ID uniquely identifies a project. For information about how to obtain the project ID of an instance, see Manage projects.
- Make sure that the project ID corresponding to the specified instanceId is consistent with the specified project ID.
Response example
JSON format
{
"data":{
"addressId":"rs-private-intranet-vpc-XXXXXX-OBPROXY-INTRANET-XXXXXX"
},
"requestId":"e448d60c-****-****-****-d33295124beb",
"success":true
}
