CreateExpressConnectRouterAssociation - 专线网关(ECR)关联资源

专线网关ECR(Express Connect Router)关联专有网络(VPC)或者转发路由器(TR)。

调试

您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。

调试

授权信息

下表是API对应的授权信息,可以在RAM权限策略语句的Action元素中使用,用来给RAM用户或RAM角色授予调用此API的权限。具体说明如下:

  • 操作:是指具体的权限点。

  • 访问级别:是指每个操作的访问级别,取值为写入(Write)、读取(Read)或列出(List)。

  • 资源类型:是指操作中支持授权的资源类型。具体说明如下:

    • 对于必选的资源类型,用前面加 * 表示。

    • 对于不支持资源级授权的操作,用全部资源表示。

  • 条件关键字:是指云产品自身定义的条件关键字。

  • 关联操作:是指成功执行操作所需要的其他权限。操作者必须同时具备关联操作的权限,操作才能成功。

操作

访问级别

资源类型

条件关键字

关联操作

expressconnectrouter:CreateExpressConnectRouterAssociation

create

*ExpressConnectRouter

acs:expressconnectrouter::{#accountId}:expressconnectrouter/{#EcrId}

请求参数

名称

类型

必填

描述

示例值

EcrId

string

专线网关实例 ID。

ecr-mezk2idmsd0vx2****

AssociationRegionId

string

关联资源所属的地域。

cn-hangzhou

TransitRouterOwnerId

integer

转发路由器实例所属阿里云账号(主账号)ID。默认值为当前登录的阿里云账号 ID。

说明

如果您要加载跨账号的网络实例,本参数必填。

189159362009****

TransitRouterId

string

转发路由器 ID。

tr-2ze4i71c6be454e2l****

CenId

string

云企业网实例 ID。

cen-of3o1the3i4gwb****

VpcOwnerId

integer

VPC 实例所属阿里云账号(主账号)ID。默认为当前登录的阿里云账号 ID。

说明

如果您要加载跨账号的网络实例,本参数必填。

132193271328****

VpcId

string

VPC 实例 ID。

vpc-bp1h37fchc6jmfyln****

AllowedPrefixes

array

允许的前缀路由列表。

string

允许的前缀路由。

192.0.20.0/24

CreateAttachment

boolean

ECR 绑定 TR 时是否发起关联。取值:

  • true:不需要在转发路由器侧发起关联。

  • false:需要在转发路由器侧发起关联。

true

DryRun

boolean

是否只预检此次请求。取值:

  • true:发送检查请求,不会修改服务资源。

  • false(默认值):发送正常请求。

false

ClientToken

string

客户端 Token,用于保证请求的幂等性。

从您的客户端生成一个参数值,确保不同请求间该参数值唯一。ClientToken 只支持 ASCII 字符。

说明

若您未指定,则系统自动使用 API 请求的 RequestId 作为 ClientToken 标识。每次 API 请求的 RequestId 不一样。

02fb3da4-130e-11e9-8e44-00****

AllowedPrefixesMode

string

前缀路由模式,取值:

  • MatchMode: 匹配模式, 仅发布配置的路由网段到 IDC,对原有发布的明细路由进行回撤。

  • IncrementalMode: 增量模式, 发布配置的路由网段到 IDC 的同时对原有发布落在配置的路由网段内的明细路由进行回撤,未落在配置的网段内的明细路由保持发布。

MatchMode

Description

string

关联资源的描述信息。长度为 0~128 个字符。

test

返回参数

名称

类型

描述

示例值

object

RpcResponse

RequestId

string

请求 ID。

05130E79-588D-5C40-A718-C4863A59****

Success

boolean

是否调用成功。取值:

  • True:成功。

  • False:失败。

True

Code

string

判断调用是否成功。返回值为 200 表示加载成功,返回其他值表示加载失败,失败原因参见错误码。

200

Message

string

操作返回信息。

OK

HttpStatusCode

integer

HTTP 状态码。

200

DynamicCode

string

动态错误码。

IllegalParamFormat.EcrId

DynamicMessage

string

动态错误信息,用于替换返回参数 ErrMessage 错误信息中的%s

说明

如果 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. 单个专线网关实例可绑定的VPC数量已达到配额上限,请联系您的商务经理申请更大的配额数量
400 QuotaExceeded.TrCountPerEcr The number of TR bound to the ECR exceeds the quota. 单个专线网关实例可绑定的TR数量已达到配额上限,请联系您的商务经理申请更大的配额数量
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. Cen实例不存在
400 ResourceNotFound.TrId TRId not found. TR实例不存在
400 Conflict.ASNOfVBR ASN already used by other VBR. 当前VBR BgpGroup localAsnECR asn不一致,请调整一致后重新绑定。
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. 当前输入的Cen实例ID格式不正确
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. 指定的 TR 资源已经关联到专线网关 ECR, 请核对后重试。
400 ResourceAlreadyExist.VpcId The specified resource of VpcId already exists. 指定的 VPC 资源已经关联到专线网关 ECR, 请核对后重试。
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.
404 ResourceNotFound.EcrId EcrId not found. ECR实例不存在

访问错误中心查看更多错误码。

变更历史

更多信息,参考变更详情