All Products
Search
Document Center

Resource Orchestration Service:ALIYUN::VPC::RouterInterface

Last Updated:Mar 28, 2026

The ALIYUN::VPC::RouterInterface resource creates a router interface.

Syntax

{
  "Type": "ALIYUN::VPC::RouterInterface",
  "Properties": {
    "OppositeRegionId": String,
    "Description": String,
    "HealthCheckSourceIp": String,
    "RouterType": String,
    "AccessPointId": String,
    "RouterId": String,
    "Role": String,
    "OppositeInterfaceOwnerId": String,
    "OppositeAccessPointId": String,
    "OppositeInterfaceId": String,
    "HealthCheckTargetIp": String,
    "OppositeRouterId": String,
    "Spec": String,
    "OppositeRouterType": String,
    "Name": String,
    "PricingCycle": String, 
    "Period": Number, 
    "AutoPay": Boolean, 
    "InstanceChargeType": String,
    "ResourceGroupId": String,
    "AutoRenew": Boolean,
    "FastLinkMode": Boolean
  }
}

Properties

Parameter

Type

Required

Update allowed

Description

Constraints

RouterId

String

Yes

No

The ID of the router to which the router interface belongs.

None.

Role

String

Yes

No

The role of the router interface in a connection. A router interface can be the initiator or acceptor.

Valid values:

  • InitiatingSide

    The value must be InitiatingSide if RouterType is set to VBR.

  • AcceptingSide

    The value must be AcceptingSide if OppositeRouterType is set to VBR.

RouterType

String

No

No

The type of router to which the router interface belongs.

Valid values:

  • VRouter: a VPC router.

  • VBR: a virtual border router (VBR).

AccessPointId

String

No

No

The ID of the access point.

If RouterType is set to VBR, this parameter is required and cannot be modified after creation. You cannot specify this parameter if RouterType is set to VRouter.

Spec

String

No

No

The specification of the router interface.

Available specifications and their corresponding bandwidths:

  • Mini.2: 2 Mbps

  • Mini.5: 5 Mbps

  • Small.1: 10 Mbps

  • Small.2: 20 Mbps

  • Small.5: 50 Mbps

  • Middle.1: 100 Mbps

  • Middle.2: 200 Mbps

  • Middle.5: 500 Mbps

  • Large.1: 1,000 Mbps

  • Large.2: 2,000 Mbps

  • Large.5: 5,000 Mbps

  • Xlarge.1: 10,000 Mbps

This parameter is required if Role is set to InitiatingSide.

If Role is set to AcceptingSide, this parameter defaults to Negative.

OppositeRegionId

String

No

No

The region where the peer router interface is located.

None.

OppositeInterfaceOwnerId

String

No

Yes

The ID of the Alibaba Cloud account that owns the peer router interface.

Defaults to the ID of the current account.

OppositeInterfaceId

String

No

Yes

The ID of the peer router interface.

None.

OppositeRouterId

String

No

Yes

The ID of the peer router.

None.

OppositeRouterType

String

No

Yes

The type of the peer router.

Valid values:

  • VRouter: a VPC router.

    The value must be VRouter if RouterType is set to VBR.

  • VBR: a virtual border router (VBR).

OppositeAccessPointId

String

No

No

The ID of the peer access point.

If OppositeRouterType is set to VBR, this parameter is required and cannot be modified after creation.

You cannot specify this parameter if OppositeRouterType is set to VRouter.

Note

If OppositeRouterType is set to VBR, the VBR specified by OppositeRouterId must be within the access point specified by OppositeAccessPointId.

Description

String

No

Yes

The description of the router interface.

The description must be 2 to 256 characters in length and cannot start withhttp:// orhttps://.

By default, this parameter is empty.

Name

String

No

Yes

The name of the router interface.

The name must be 2 to 128 characters in length. It must start with a letter or a Chinese character and cannot start withhttp:// orhttps://. The name can contain letters, Chinese characters, digits, periods (.), underscores (_), and hyphens (-).

ResourceGroupId

String

No

No

The ID of the resource group.

None.

AutoRenew

Boolean

No

No

Specifies whether to enable automatic renewal.

None.

FastLinkMode

Boolean

No

No

Specifies whether to create the VBR-to-VPC connection in fast connection mode.

The fast connection mode enables the system to automatically connect router interfaces that are created on the VBR and the VPC. Valid values:

  • true

  • false (default)

Note

This parameter takes effect only when RouterType is set to VBR and OppositeRouterType is set to VRouter.

  • If FastLinkMode is set to true, Role must be set to InitiatingSide, and the AccessPointId, OppositeRouterType, OppositeRouterId, and OppositeInterfaceOwnerId parameters are required.

HealthCheckSourceIp

String

No

No

The source IP address for health check packets. This parameter is used for health checks in leased line disaster recovery and ECMP scenarios.

This parameter is valid only for a router interface on a VPC router that has a peer on a VBR. The IP address must be an unused IP address in the VPC router's VPC. You must specify both HealthCheckSourceIp and HealthCheckTargetIp, or specify neither.

HealthCheckTargetIp

String

No

No

The destination IP address for health check packets. This parameter is used for health checks in leased line disaster recovery and ECMP scenarios.

This parameter is valid only for a router interface on a VPC router that has a peer on a VBR. You can use the IP address of the customer-premises equipment (CPE), which is the PeerGatewayIp on the peer VBR. You can also specify another IP address on the customer side. You must specify both HealthCheckSourceIp and HealthCheckTargetIp, or specify neither.

PricingCycle

String

No

No

The billing cycle of the subscription.

Valid values:

  • Month

  • Year

Period

Number

No

No

The subscription duration.

Valid values:

  • If PricingCycle is set to Month, the valid values are 1 to 9.

  • If PricingCycle is set to Year, the valid values are 1 to 3.

AutoPay

Boolean

No

No

Specifies whether to enable automatic payment.

Valid values:

  • true (default)

  • false

InstanceChargeType

String

No

No

The billing method of the router interface.

Valid values:

  • Postpaid: pay-as-you-go.

  • Prepaid: subscription.

Return values

Fn::GetAtt

RouterInterfaceId: The ID of the created router interface.

Examples

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  OppositeInterfaceId:
    Type: String
    Description: The ID of the peer router interface.
  RouterId:
    Type: String
    Description: The ID of the router on which the router interface is created.
  OppositeRouterId:
    Type: String
    Description: The ID of the peer router.
Resources:
  RouterInterface:
    Type: ALIYUN::VPC::RouterInterface
    Properties:
      OppositeInterfaceId:
        Ref: OppositeInterfaceId
      OppositeRouterId:
        Ref: OppositeRouterId
      OppositeInterfaceOwnerId:
        Ref: ALIYUN::TenantId
      OppositeRouterType: VRouter
      Description: Initiating Side
      RouterType: VRouter
      RouterId:
        Ref: RouterId
      Role: InitiatingSide
      Spec: Mini.2
      InstanceChargeType: PostPaid
Outputs:
  RouterInterfaceId:
    Description: The ID of the created RouterInterface.
    Value:
      Fn::GetAtt:
        - RouterInterface
        - RouterInterfaceId
{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "OppositeInterfaceId": {
      "Type": "String",
      "Description": "The ID of the peer router interface."
    },
    "RouterId": {
      "Type": "String",
      "Description": "The ID of the router on which the router interface is created."
    },
    "OppositeRouterId": {
      "Type": "String",
      "Description": "The ID of the peer router."
    }
  },
  "Resources": {
    "RouterInterface": {
      "Type": "ALIYUN::VPC::RouterInterface",
      "Properties": {
        "OppositeInterfaceId": {
          "Ref": "OppositeInterfaceId"
        },
        "OppositeRouterId": {
          "Ref": "OppositeRouterId"
        },
        "OppositeInterfaceOwnerId": {
          "Ref": "ALIYUN::TenantId"
        },
        "OppositeRouterType": "VRouter",
        "Description": "Initiating Side",
        "RouterType": "VRouter",
        "RouterId": {
          "Ref": "RouterId"
        },
        "Role": "InitiatingSide",
        "Spec": "Mini.2",
        "InstanceChargeType": "PostPaid"
      }
    }
  },
  "Outputs": {
    "RouterInterfaceId": {
      "Description": "The ID of the created RouterInterface.",
      "Value": {
        "Fn::GetAtt": [
          "RouterInterface",
          "RouterInterfaceId"
        ]
      }
    }
  }
}