All Products
Search
Document Center

Cloud Enterprise Network:PublishRouteEntries

Last Updated:Jun 10, 2026

Anda dapat memanggil operasi PublishRouteEntries untuk mengiklankan rute dari virtual private cloud (VPC) atau virtual border router (VBR) ke Instans CEN (Cloud Enterprise Network). Jika tidak terjadi konflik rute, instans jaringan lain yang terhubung ke Instans CEN dapat mempelajari rute yang diiklankan.

Deskripsi operasi

The following table lists the default advertising status for different types of routes in CEN. You can call the PublishRouteEntries operation to advertise routes that are not advertised to CEN by default.

RouteInstance of the routeAdvertised to CEN by default
Route to an ECS instanceVPCNo
Route to a VPN GatewayVPCNo
Route to a high availability (HA) virtual IP addressVPCNo
Route to a router interfaceVPCNo
Route to an Elastic Network Interface (ENI)VPCNo
Route to an IPv6 GatewayVPCNo
Route to a NAT GatewayVPCNo
VPC system routeVPCYes
Route to a data centerVBRYes
Border Gateway Protocol (BGP) routeVBRYes

Coba sekarang

Coba API ini di OpenAPI Explorer tanpa perlu penandatanganan manual. Panggilan yang berhasil akan secara otomatis menghasilkan contoh kode SDK sesuai dengan parameter Anda. Unduh kode tersebut dengan kredensial bawaan yang aman untuk penggunaan lokal.

Test

RAM authorization

Tabel berikut menjelaskan otorisasi yang diperlukan untuk memanggil API ini. Anda dapat menentukannya dalam kebijakan Resource Access Management (RAM). Kolom pada tabel dijelaskan sebagai berikut:

  • Action: Aksi yang dapat digunakan dalam elemen Action pada pernyataan kebijakan izin RAM untuk memberikan izin guna melakukan operasi tersebut.

  • API: API yang dapat Anda panggil untuk melakukan aksi tersebut.

  • Access level: Tingkat akses yang telah ditentukan untuk setiap API. Nilai yang valid: create, list, get, update, dan delete.

  • Resource type: Jenis resource yang mendukung otorisasi untuk melakukan aksi tersebut. Ini menunjukkan apakah aksi tersebut mendukung izin tingkat resource. Resource yang ditentukan harus kompatibel dengan aksi tersebut. Jika tidak, kebijakan tersebut tidak akan berlaku.

    • Untuk API dengan izin tingkat resource, jenis resource yang diperlukan ditandai dengan tanda bintang (*). Tentukan Nama Sumber Daya Alibaba Cloud (ARN) yang sesuai dalam elemen Resource pada kebijakan.

    • Untuk API tanpa izin tingkat resource, ditampilkan sebagai All Resources. Gunakan tanda bintang (*) dalam elemen Resource pada kebijakan.

  • Condition key: Kunci kondisi yang didefinisikan oleh layanan. Kunci ini memungkinkan kontrol granular, berlaku baik hanya untuk aksi maupun untuk aksi yang terkait dengan resource tertentu. Selain kunci kondisi spesifik layanan, Alibaba Cloud menyediakan serangkaian common condition keys yang berlaku di semua layanan yang didukung RAM.

  • Dependent action: Aksi dependen yang diperlukan untuk menjalankan aksi tersebut. Untuk menyelesaikan aksi tersebut, pengguna RAM atau role RAM harus memiliki izin untuk melakukan semua aksi dependen.

Action

Access level

Resource type

Condition key

Dependent action

cen:PublishRouteEntries

update

*CenInstance

acs:cen:*:{#accountId}:ceninstance/{#ceninstanceId}

*virtualborderrouter

acs:vpc:*:{#accountId}:virtualborderrouter/{#virtualborderrouterId}

*VPC

acs:vpc:*:{#accountId}:vpc/{#vpcId}

None None

Parameter permintaan

Parameter

Type

Required

Description

Example

CenId

string

Yes

ID Instans CEN.

cen-7qthudw0ll6jmc****

ChildInstanceId

string

Yes

ID instans jaringan.

vpc-rj9gt5nll27onu****

ChildInstanceType

string

Yes

Tipe instans jaringan. Nilai valid:

  • VPC: virtual private cloud.

  • VBR: virtual border router.

VPC

ChildInstanceRegionId

string

Yes

ID Wilayah tempat instans jaringan di-deploy.

Anda dapat memanggil operasi DescribeChildInstanceRegions untuk mengkueri ID wilayah.

us-west-1

ChildInstanceRouteTableId

string

Yes

ID tabel rute instans jaringan.

vtb-bp174d1gje7****

DestinationCidrBlock

string

Yes

Blok CIDR tujuan dari rute yang ingin Anda iklankan.

172.16.1.0/24

Elemen respons

Element

Type

Description

Example

object

RequestId

string

The request ID.

FBDB18D8-E91E-4978-8D6C-6E2E3EE10133

Contoh

Respons sukses

JSONformat

{
  "RequestId": "FBDB18D8-E91E-4978-8D6C-6E2E3EE10133"
}

Kode kesalahan

HTTP status code

Error code

Error message

Description

400 ParameterIllegal.AliUid The parameter of aliUid is illegal.
400 InvalidOperation.UnsupportnexthopType The nexthop type is unsupported The error message returned because the next hop type does not support this operation.
400 InvalidOperation.NotFoundRoute The specified route does not exist. The error message returned because the route does not exist.
400 ParameterIllegal.CenInstanceId The parameter of CEN instance id is illegal.
400 ParameterIllegal.ChildInstanceRegionId The parameter of child instance region id is illegal.
400 ParameterIllegal.ChildInstanceType The parameter of child instance type is illegal.
400 InvalidOperation.UnsupportRouteTableType The route table type is unsupported The error message returned because the specified route table type does not support this operation.
400 InvalidParameter Invalid parameter. The error message returned because the parameter is set to an invalid value.
400 Unauthorized The AccessKeyId is unauthorized. The error message returned because you do not have the permissions to perform this operation.
404 Instance.NotExist The instance is not exist. The error message returned because the specified instance does not exist.
409 InvalidOperation.ChildInstanceStatus The child-instance is not in a valid state for the operation.
409 InvalidOperation.CenInstanceStatus The CEN instance is not in a valid state for the operation. The error message returned because the status of the CEN instance does not support this operation.

Lihat Error Codes untuk daftar lengkap.

Catatan rilis

Lihat Release Notes untuk daftar lengkap.