專線閘道器 ECR(Express Connect Router)關聯專有網路(VPC)或轉發路由器(TR)。
調試
您可以在OpenAPI Explorer中直接運行該介面,免去您計算簽名的困擾。運行成功後,OpenAPI Explorer可以自動產生SDK程式碼範例。
調試
授權資訊
|
操作 |
存取層級 |
資源類型 |
條件關鍵字 |
關聯操作 |
|
expressconnectrouter:CreateExpressConnectRouterAssociation |
create |
*ExpressConnectRouter
|
無 | 無 |
請求參數
|
名稱 |
類型 |
必填 |
描述 |
樣本值 |
| EcrId |
string |
是 |
專線閘道器執行個體 ID。 |
ecr-mezk2idmsd0vx2**** |
| AssociationRegionId |
string |
是 |
關聯資源所屬的地域。 |
cn-hangzhou |
| TransitRouterOwnerId |
integer |
否 |
轉發路由器執行個體所屬阿里雲帳號(主帳號)ID。預設值為目前登入的阿里雲帳號 ID。 說明
如果您要載入跨帳號的網路執行個體,本參數為必填。 |
189159362009**** |
| TransitRouterId |
string |
否 |
轉發路由器 ID。 說明
TransitRouterId 和 VpcId 參數二者互斥且必須提供其一。需先透過 Cbn(2017-09-12) 產品的 CreateTransitRouter API 建立轉發路由器並取得 TransitRouterId。 |
tr-2ze4i71c6be454e2l**** |
| CenId |
string |
否 |
雲企業網執行個體 ID。 說明
指定 TransitRouterId 時 CenId 為必填,需先透過 Cbn(2017-09-12) 產品的 CreateCen 建立 CEN 執行個體並取得 CenId。 |
cen-of3o1the3i4gwb**** |
| VpcOwnerId |
integer |
否 |
VPC 執行個體所屬阿里雲帳號(主帳號)ID。預設為目前登入的阿里雲帳號 ID。 說明
如果您要載入跨帳號的網路執行個體,本參數為必填。 |
132193271328**** |
| VpcId |
string |
否 |
VPC 執行個體 ID。 說明
VpcId 和 TransitRouterId 參數二者互斥且必須提供其一。 需先透過 Vpc(2016-04-28) 產品的 CreateVpc API 建立 VPC 並取得 VpcId。 |
vpc-bp1h37fchc6jmfyln**** |
| AllowedPrefixes |
array |
否 |
允許的前綴路由清單。 |
|
|
string |
否 |
允許的前綴路由。 |
192.0.20.0/24 |
|
| CreateAttachment |
boolean |
否 |
ECR 綁定 TR 時是否發起關聯。取值:
|
true |
| DryRun |
boolean |
否 |
是否僅預檢此次請求。取值:
|
false |
| ClientToken |
string |
否 |
用戶端 Token,用於保證請求的冪等性。 從您的用戶端產生一個參數值,確保不同請求間該參數值唯一。ClientToken 僅支援 ASCII 字元。 說明
若您未指定,則系統自動使用 API 請求的 RequestId 作為 ClientToken 識別碼。每次 API 請求的 RequestId 不一樣。 |
02fb3da4-130e-11e9-8e44-00**** |
| AllowedPrefixesMode |
string |
否 |
前綴路由模式,取值:
|
MatchMode |
| Description |
string |
否 |
關聯資源的描述資訊。長度為 0~128 個字元。 |
test |
| Tag |
array<object> |
否 |
標籤清單。 最多可以綁定 20 個標籤。 |
|
|
object |
否 |
|||
| Key |
string |
否 |
資源的標籤鍵。一旦傳入該值,則不允許為空字串。最多支援 128 個字元,不能以 |
TestKey |
| Value |
string |
否 |
資源的標籤值。可以為空字串,最多支援 128 個字元,不能包含 |
TestValue |
返回參數
|
名稱 |
類型 |
描述 |
樣本值 |
|
object |
RpcResponse |
||
| RequestId |
string |
請求 ID。 |
05130E79-588D-5C40-A718-C4863A59**** |
| Success |
boolean |
是否呼叫成功。取值:
|
True |
| Code |
string |
判斷呼叫是否成功。返回值為 200 表示載入成功,返回其他值表示載入失敗,失敗原因請參見錯誤碼。 |
200 |
| Message |
string |
操作返回資訊。 |
OK |
| HttpStatusCode |
integer |
HTTP 狀態碼。 |
200 |
| DynamicCode |
string |
動態錯誤碼。 |
IllegalParamFormat.EcrId |
| DynamicMessage |
string |
動態錯誤訊息,用於替換返回參數 ErrMessage 錯誤訊息中的 說明
如果 ErrMessage 返回 The Value of Input Parameter %s is not valid,且 DynamicMessage 返回 DtsJobId,則表示所傳入的請求參數 DtsJobId 不合法。 |
The param format of EcrId **** is illegal. |
| AccessDeniedDetail |
string |
存取被拒絕詳細資訊。 |
Authentication is failed for **** |
| AssociationId |
string |
專線閘道器與 VPC 或 TR 的關聯 ID。 |
ecr-assoc-9p2qxx5phpca2m**** |
樣本
正常返回樣本
JSON格式
{
"RequestId": "05130E79-588D-5C40-A718-C4863A59****",
"Success": true,
"Code": "200",
"Message": "OK",
"HttpStatusCode": 200,
"DynamicCode": "IllegalParamFormat.EcrId\n",
"DynamicMessage": "The param format of EcrId **** is illegal.\n",
"AccessDeniedDetail": "Authentication is failed for ****\n",
"AssociationId": "ecr-assoc-9p2qxx5phpca2m****"
}
錯誤碼
|
HTTP status code |
錯誤碼 |
錯誤資訊 |
描述 |
|---|---|---|---|
| 400 | IncorrectStatus.Ecr | Ecr Status does not allow current operation. | |
| 400 | OperationDenied.ForceDeleting | The current instance is being deleted. | |
| 400 | UnsupportedRegion | Feature not supported in specified region. | |
| 400 | QuotaExceeded.VpcCountPerEcr | The number of VPC bound to the ECR exceeds the quota. | |
| 400 | QuotaExceeded.TrCountPerEcr | The number of TR bound to the ECR exceeds the quota. | |
| 400 | IllegalParamFormat.AllowedPrefixes | The prefix parameter format is invalid. Procedure. | |
| 400 | OperationDenied.NotGrantedByNodeOwner | The node owner is not authorized. | |
| 400 | OperationFailed.CdtNotOpened | The Cdt function is disabled. | |
| 400 | OperationFailed.CdtCrossBoarderNotOpened | The Cdt cross-border transmission function is disabled. | |
| 400 | OperationFailed.CrossBorderNotAllowed | There is no qualification for creating cross-border links. | |
| 400 | ResourceNotFound.CenId | CenId not found. | |
| 400 | ResourceNotFound.TrId | TRId not found. | |
| 400 | Conflict.ASNOfVBR | ASN already used by other VBR. | |
| 400 | MissingParam.%s | The param of %s is missing. | |
| 400 | IllegalParamFormat.%s | The param format of %s is illegal. | |
| 400 | IllegalParamFormat.CenId | The format of the entered Cen instance ID is incorrect. | |
| 400 | OperationDenied.CrossBidAssociating | Cross-border binding of resources is subject to compliance constraints. | |
| 400 | ExclusiveParam.TransitRouterIdAndVpcId | A private network instance cannot be bound to a forwarding router instance at the same time. | |
| 400 | IllegalParamSize.AllowedPrefixes | The number of prefix routes exceeded the quota. | |
| 400 | OperationDenied.CrossAccountAttaching | If the forwarding router is bound to another account, perform this operation on the same account. | |
| 400 | OperationDenied.AttachmentInCurrentRegionExisted | Only one forwarding router can be bound to an area. | |
| 400 | Conflict.Lock | There are other unfinished operations. | |
| 400 | OperationFailed.CallingVpcYaochi | The system is abnormal. Please try again later. | |
| 400 | ResourceAlreadyExist.TransitRouterId | The specified resource of transit router already exists. | |
| 400 | ResourceAlreadyExist.VpcId | The specified resource of VpcId already exists. | |
| 400 | Conflict.AllowedPrefixes | The allowed route prefixes [%s] is conflict. | |
| 400 | UnsupportedFeature.JumboFrame | The region where the sub-instance is located does not support the jumbo frame feature and cannot be attached to the express connect router. | |
| 400 | InternalErrorTemp | The request processing has failed due to some unknown error. | |
| 404 | ResourceNotFound.EcrId | EcrId not found. |
訪問錯誤中心查看更多錯誤碼。
變更歷史
更多資訊,參考變更詳情。