你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

Peer Asns - Create Or Update

创建一个新的对等 ASN,或者更新给定订阅下具有指定名称的现有对等 ASN。

PUT https://management.azure.com/subscriptions/{subscriptionId}/providers/Microsoft.Peering/peerAsns/{peerAsnName}?api-version=2021-01-01

URI 参数

名称 必需 类型 说明
peerAsnName
path True

string

对等 ASN 名称。

subscriptionId
path True

string

Azure 订阅 ID。

api-version
query True

string

客户端 API 版本。

请求正文

名称 类型 说明
properties.peerAsn

integer

自治系统编号 (对等方的 ASN) 。

properties.peerContactDetail

ContactDetail[]

对等方的联系人详细信息。

properties.peerName

string

对等方的名称。

properties.validationState

validationState

与对等方关联的 ASN 的验证状态。

响应

名称 类型 说明
200 OK

PeerAsn

确定

201 Created

PeerAsn

创建

Other Status Codes

ErrorResponse

描述操作失败原因的错误响应。

安全性

azure_auth

Azure Active Directory OAuth2 Flow。

Type: oauth2
Flow: implicit
Authorization URL: https://login.microsoftonline.com/common/oauth2/authorize

Scopes

名称 说明
user_impersonation 模拟用户帐户

示例

Create a peer ASN

Sample Request

PUT https://management.azure.com/subscriptions/subId/providers/Microsoft.Peering/peerAsns/peerAsnName?api-version=2021-01-01

{
  "properties": {
    "peerAsn": 65000,
    "peerContactDetail": [
      {
        "role": "Noc",
        "email": "noc@contoso.com",
        "phone": "+1 (234) 567-8999"
      },
      {
        "role": "Policy",
        "email": "abc@contoso.com",
        "phone": "+1 (234) 567-8900"
      },
      {
        "role": "Technical",
        "email": "xyz@contoso.com",
        "phone": "+1 (234) 567-8900"
      }
    ],
    "peerName": "Contoso"
  }
}

Sample Response

{
  "properties": {
    "peerAsn": 65000,
    "peerContactDetail": [
      {
        "role": "Noc",
        "email": "noc@contoso.com",
        "phone": "+1 (234) 567-8999"
      },
      {
        "role": "Policy",
        "email": "abc@contoso.com",
        "phone": "+1 (234) 567-8900"
      },
      {
        "role": "Technical",
        "email": "xyz@contoso.com",
        "phone": "+1 (234) 567-8900"
      }
    ],
    "peerName": "Contoso",
    "validationState": "Pending"
  },
  "name": "peerAsnName",
  "id": "/subscriptions/subId/providers/Microsoft.Peering/peerAsns/peerAsnName",
  "type": "Microsoft.Peering/peerAsns"
}
{
  "properties": {
    "peerAsn": 65000,
    "peerContactDetail": [
      {
        "role": "Noc",
        "email": "noc@contoso.com",
        "phone": "+1 (234) 567-8999"
      },
      {
        "role": "Policy",
        "email": "abc@contoso.com",
        "phone": "+1 (234) 567-8900"
      },
      {
        "role": "Technical",
        "email": "xyz@contoso.com",
        "phone": "+1 (234) 567-8900"
      }
    ],
    "peerName": "Contoso",
    "validationState": "Pending"
  },
  "name": "peerAsnName",
  "id": "/subscriptions/subId/providers/Microsoft.Peering/peerAsns/peerAsnName",
  "type": "Microsoft.Peering/peerAsns"
}

定义

名称 说明
ContactDetail

联系人详细信息类。

ErrorDetail

描述操作失败原因的错误详细信息。

ErrorResponse

指示操作失败原因的错误响应。

PeerAsn

与对等方 ASN 相关的基本信息。

role

联系人的角色。

validationState

与对等方关联的 ASN 的验证状态。

ContactDetail

联系人详细信息类。

名称 类型 说明
email

string

联系人的电子邮件地址。

phone

string

联系人的电话号码。

role

role

联系人的角色。

ErrorDetail

描述操作失败原因的错误详细信息。

名称 类型 说明
code

string

错误代码。

message

string

错误消息。

ErrorResponse

指示操作失败原因的错误响应。

名称 类型 说明
error

ErrorDetail

描述操作失败原因的错误详细信息。

PeerAsn

与对等方 ASN 相关的基本信息。

名称 类型 说明
id

string

资源的 ID。

name

string

资源的名称。

properties.errorMessage

string

验证状态的错误消息

properties.peerAsn

integer

自治系统编号 (对等方的 ASN) 。

properties.peerContactDetail

ContactDetail[]

对等方的联系人详细信息。

properties.peerName

string

对等方的名称。

properties.validationState

validationState

与对等方关联的 ASN 的验证状态。

type

string

资源类型。

role

联系人的角色。

名称 类型 说明
Escalation

string

Noc

string

Other

string

Policy

string

Service

string

Technical

string

validationState

与对等方关联的 ASN 的验证状态。

名称 类型 说明
Approved

string

Failed

string

None

string

Pending

string