ネットワークリソースプールの追加
ネットワークリソースプールは、IPv4ループバックアドレス、インターフェイスIPアドレス、セグメント識別子(SID)、BGPクラスタIDなど、ネットワーク内のデバイスに割り当てられるネットワークリソースの値を定義します。
ネットワークリソースの自動設定が有効になっている場合、ルーティングディレクターはデバイスプロファイルとインターフェイスプロファイルのネットワークリソースに値を割り当てます。
リソース共有元は、次の方法で作成できます。
-
JSON ファイルのアップロード。 「JSON形式でのデバイスオンボーディング用のネットワークリソースプールのアップロード」を参照してください。
-
値を手動で入力する。 「リソースインスタンスの追加」を参照してください。
-
REST API を使用する。 「REST API を使用したネットワーク リソース プールの追加」を参照してください。
JSON形式でのデバイスオンボーディング用のネットワークリソースプールのアップロード
デバイスオンボーディング用のネットワークリソースプールをJSON形式でアップロードするには、次の手順を実行します。
リソースプールを定義した後、デバイスプロファイルとインターフェイスプロファイルをルーティングディレクターに追加できます。詳細については 、「デバイスプロファイルの追加 」および 「インターフェイスプロファイルの追加 」を参照してください。
REST APIを使用したネットワークリソースプールの追加
REST API を使用してネットワーク リソース プールを作成するには、Postman などのツールを使用してルーティング ディレクターに API リクエストを行う方法に精通している必要があります。すべての REST API ドキュメントと OpenAPI 定義を表示するには、GUI で ヘルプ () > API ドキュメント に移動します。すべてのサービスオーケストレーションAPIは、「 サービスオーケストレーション」 セクションで定義されています。
リソース インスタンスは特定の種類のサービス インスタンスであるため、リソース インスタンスを作成、変更、および削除するための関連 API は、次の Order API です。
-
サービスオーダのアップロード
-
サービスインスタンスワークフローの実行
-
サービスインスタンスの取得
-
SIの注文履歴の取得
配置時に使用された結果のリソースを表示するには、配置 API の Get Network Resources を使用する必要があります。
このトピックでは、Postman を使用したペイロードを含む API の使用例について説明します。
ネットワークリソースのリソースプールを作成するには、次のパラメータの値が必要になります。
-
ルーティング ディレクターが動作している環境の URL。
-
リソースプールを追加する組織のID。
-
組織にアクセスするためのユーザー名。
-
組織にアクセスするためのパスワード。
リソースプールを作成するには、次のようにします。
この手順では、Postman を使用して REST API を実行する方法について詳しく説明します。他のツールを使用して REST API を実行することもできます。
サンプルファイル
この項では、ネットワーク・リソース・プールの定義に使用できる環境ファイル、収集ファイル、およびREST APIのリストのサンプルを提供します。
- サンプル Postman 環境ファイル
- デバイスオンボーディング用のサンプルPostmanコレクションファイル
- IPv4 アドレスプールを作成するためのサンプル REST API
- BGP クラスタ ID プールを作成するための REST API のサンプル
- サービス オーケストレーション用のサンプル Postman コレクション ファイル
- L3VPNおよびL2VPNサービスのトポロジリソースを作成するためのサンプルREST API
- L3VPN、L2VPN、および L2 回線サービスの VPN リソースを作成するためのサンプル REST API
サンプル Postman 環境ファイル
以下は、サンプルの Postman 環境ファイルです。
{
"id": "dae981a2-da91-4d6f-9094-87e6ea05003c",
"name": "00-00-pa",
"values": [
{
"key": "server",
"value": "web-ui-vip-address",
"enabled": true
},
{
"key": "port",
"value": "443",
"enabled": true
},
{
"key": "Password",
"value": "abc123",
"type": "secret",
"enabled": true
},
{
"key": "User",
"value": "user@abc.com",
"enabled": true
},
{
"key": "ORG",
"value": "34a55586-2baf-4cce-b2e0-0b293b223af1",
"type": "default",
"enabled": true
},
{
"key": "SITE_ID",
"value": "",
"type": "any",
"enabled": true
}
],
"_postman_variable_scope": "environment",
"_postman_exported_at": "2023-04-20T12:04:35.537Z",
"_postman_exported_using": "Postman/10.12.13"
デバイスオンボーディング用のサンプルPostmanコレクションファイル
以下は、IPv4 アドレスと BGP クラスター ID の値を定義するためのサンプルの Postman コレクション ファイルです。
{
"info": {
"_postman_id": "7a32e6b1-d4ca-4166-9a9f-3777c2ae6ce4",
"name": "Resource Profile creation",
"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json",
"_exporter_id": "829664"
},
"item": [
{
"name": "01-Who am I and get orgs",
"event": [
{
"listen": "prerequest",
"script": {
"exec": [
"var x=CryptoJS.enc.Utf8.parse(postman.getEnvironmentVariable(\"User\")+\":\"+postman.getEnvironmentVariable(\"Password\"));",
"var authHeader=CryptoJS.enc.Base64.stringify(x);",
"pm.request.headers.add({key: \"Authorization\", value: \"Basic \"+authHeader});",
""
],
"type": "text/javascript"
}
},
{
"listen": "test",
"script": {
"exec": [
"var jsonData = JSON.parse(responseBody);",
"postman.setEnvironmentVariable(\"ORG\", jsonData.privileges[0].org_id);"
],
"type": "text/javascript"
}
}
],
"request": {
"method": "GET",
"header": [],
"url": {
"raw": "https://{{server}}:{{port}}/api/v1/self",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"api",
"v1",
"self"
]
}
},
"response": []
},
{
"name": "02-pick-site",
"event": [
{
"listen": "prerequest",
"script": {
"exec": [
"var x=CryptoJS.enc.Utf8.parse(postman.getEnvironmentVariable(\"User\")+\":\"+postman.getEnvironmentVariable(\"Password\"));",
"var authHeader=CryptoJS.enc.Base64.stringify(x);",
"pm.request.headers.add({key: \"Authorization\", value: \"Basic \"+authHeader});",
""
],
"type": "text/javascript"
}
},
{
"listen": "test",
"script": {
"exec": [
"var jsonData = JSON.parse(responseBody);",
"postman.setEnvironmentVariable(\"SITE_ID\", jsonData[0].id);"
],
"type": "text/javascript"
}
}
],
"request": {
"method": "GET",
"header": [],
"url": {
"raw": "https://{{server}}:{{port}}/api/v1/orgs/{{ORG}}/sites",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"api",
"v1",
"orgs",
"{{ORG}}",
"sites"
]
}
},
"response": []
},
{
"name": "03-Create L3 Addr",
"event": [
{
"listen": "prerequest",
"script": {
"exec": [
"var x=CryptoJS.enc.Utf8.parse(postman.getEnvironmentVariable(\"User\")+\":\"+postman.getEnvironmentVariable(\"Password\"));",
"var authHeader=CryptoJS.enc.Base64.stringify(x);",
"pm.request.headers.add({key: \"Authorization\", value: \"Basic \"+authHeader});",
""
],
"type": "text/javascript"
}
},
{
"listen": "test",
"script": {
"exec": [
""
],
"type": "text/javascript"
}
}
],
"request": {
"method": "POST",
"header": [],
"body": {
"mode": "raw",
"raw": "{\n \"customer_id\": \"network-operator\",\n \"design_id\": \"l3-addr\",\n \"instance_id\": \"l3-stuff\",\n \"operation\": \"create\",\n \"l3_addr\": {\n \"loopbacks\": [\n {\n \"name\": \"range-192\",\n \"prefix\": \"10.1.192.0/18\"\n },\n {\n \"name\": \"range-2\",\n \"prefix\": \"10.2.2.0/24\"\n },\n {\n \"name\": \"range-3\",\n \"prefix\": \"10.3.3.0/24\"\n }\n ],\n \"ipv4_prefixes\": [\n {\n \"name\": \"pool-11\",\n \"prefix\": \"10.11.11.0/24\"\n },\n {\n \"name\": \"pool-12\",\n \"prefix\": \"10.12.12.0/24\"\n },\n {\n \"name\": \"pool-13\",\n \"prefix\": \"10.13.13.0/24\"\n },\n {\n \"name\": \"pool-14\",\n \"prefix\": \"10.14.14.0/24\"\n },\n {\n \"name\": \"pool-15\",\n \"prefix\": \"10.15.15.0/24\"\n },\n {\n \"name\": \"pool-16\",\n \"prefix\": \"10.16.16.0/24\"\n },\n {\n \"name\": \"pool-17\",\n \"prefix\": \"10.17.17.0/24\"\n },\n {\n \"name\": \"pool-18\",\n \"prefix\": \"10.18.18.0/24\"\n },\n {\n \"name\": \"pool-19\",\n \"prefix\": \"10.19.19.0/24\"\n },\n {\n \"name\": \"pool-20\",\n \"prefix\": \"10.20.20.0/24\"\n},\n {\n \"name\": \"pool-21\",\n \"prefix\": \"10.21.21.0/24\"\n },\n {\n \"name\": \"pool-22\",\n \"prefix\": \"10.22.22.0/24\"\n },\n {\n \"name\": \"pool-23\",\n \"prefix\": \"10.23.23.0/24\"\n },\n {\n \"name\": \"pool-24\",\n \"prefix\": \"10.24.24.0/24\"\n },\n {\n \"name\": \"pool-25\",\n \"prefix\": \"10.25.25.0/24\"\n },\n {\n \"name\": \"pool-26\",\n \"prefix\": \"10.26.26.0/24\"\n },\n {\n \"name\": \"pool-27\",\n \"prefix\": \"10.27.27.0/24\"\n },\n {\n \"name\": \"pool-28\",\n \"prefix\": \"10.28.28.0/24\"\n },\n {\n \"name\": \"pool-29\",\n \"prefix\": \"10.29.29.0/24\"\n },\n {\n \"name\": \"pool-30\",\n \"prefix\": \"10.30.30.0/24\"\n },\n {\n\"name\": \"pool-31\",\n\"prefix\": \"10.31.31.0/24\"\n },\n {\n \"name\": \"pool-32\",\n \"prefix\": \"10.32.32.0/24\"\n },\n {\n \"name\": \"pool-33\",\n \"prefix\": \"10.33.33.0/24\"\n }\n]\n}\n}\n",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"order"
]
}
},
"response": []
},
{
"name": "04-Exec L3 Addr",
"event": [
{
"listen": "prerequest",
"script": {
"exec": [
"var x=CryptoJS.enc.Utf8.parse(postman.getEnvironmentVariable(\"User\")+\":\"+postman.getEnvironmentVariable(\"Password\"));",
"var authHeader=CryptoJS.enc.Base64.stringify(x);",
"pm.request.headers.add({key: \"Authorization\", value: \"Basic \"+authHeader});",
""
],
"type": "text/javascript"
}
},
{
"listen": "test",
"script": {
"exec": [
""
],
"type": "text/javascript"
}
}
],
"request": {
"method": "POST",
"header": [],
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order/customers/network-operator/instances/l3-addr/exec",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"order",
"customers",
"network-operator",
"instances",
"l3-addr",
"exec"
]
}
},
"response": []
},
{
"name": "05-Create Routing Resources",
"event": [
{
"listen": "prerequest",
"script": {
"exec": [
"var x=CryptoJS.enc.Utf8.parse(postman.getEnvironmentVariable(\"User\")+\":\"+postman.getEnvironmentVariable(\"Password\"));",
"var authHeader=CryptoJS.enc.Base64.stringify(x);",
"pm.request.headers.add({key: \"Authorization\", value: \"Basic \"+authHeader});",
""
],
"type": "text/javascript"
}
},
{
"listen": "test",
"script": {
"exec": [
""
],
"type": "text/javascript"
}
}
],
"request": {
"method": "POST",
"header": [],
"body": {
"mode": "raw",
"raw": "{\n \"customer_id\": \"network-operator\",\n \"design_id\": \"routing\",\n \"instance_id\": \"routing-stuff\",\n \"operation\": \"create\",\n \"routing\": {\n \"autonomous_system\": [\n {\n \"name\": 65200,\n \"count\": 1024\n }\n ],\n \"spring\": {\n \"sids\": {\n \"size\": 1000\n }\n },\n \"route_reflector\": {\n \"clusters\": [\n {\n \"cluster\": \"10.1.1.1\"\n },\n {\n \"cluster\": \"10.2.2.2\"\n },\n {\n \"cluster\": \"10.3.3.3\"\n }\n ]\n }\n }\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"order"
]
}
},
"response": []
},
{
"name": "06-Exec Routing Resources",
"event": [
{
"listen": "prerequest",
"script": {
"exec": [
"var x=CryptoJS.enc.Utf8.parse(postman.getEnvironmentVariable(\"User\")+\":\"+postman.getEnvironmentVariable(\"Password\"));",
"var authHeader=CryptoJS.enc.Base64.stringify(x);",
"pm.request.headers.add({key: \"Authorization\", value: \"Basic \"+authHeader});",
""
],
"type": "text/javascript"
}
},
{
"listen": "test",
"script": {
"exec": [
""
],
"type": "text/javascript"
}
}
],
"request": {
"method": "POST",
"header": [],
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order/customers/network-operator/instances/routing-stuff/exec",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"order",
"customers",
"network-operator",
"instances",
"routing-stuff",
"exec"
]
}
},
"response": []
},
{
"name": "07-Verify Resources",
"event": [
{
"listen": "prerequest",
"script": {
"exec": [
"var x=CryptoJS.enc.Utf8.parse(postman.getEnvironmentVariable(\"User\")+\":\"+postman.getEnvironmentVariable(\"Password\"));",
"var authHeader=CryptoJS.enc.Base64.stringify(x);",
"pm.request.headers.add({key: \"Authorization\", value: \"Basic \"+authHeader});",
""
],
"type": "text/javascript"
}
},
{
"listen": "test",
"script": {
"exec": [
""
],
"type": "text/javascript"
}
}
],
"request": {
"method": "GET",
"header": [],
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/placement/network-elements",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"placement",
"network-elements"
]
}
},
"response": []
}
]
}
表 1 は、オンボード デバイス用のサンプル Postman コレクション ファイル内の API の一覧です。
| コレクション ファイルの | REST API | 記述 | リファレンス
|---|---|---|
| 組織の詳細を取得する |
組織にアクセスするための資格情報と組織の詳細を取得します。 |
01 -私は誰ですか、組織を取得する |
| サイトを取得 |
デバイスをインストールしてオンボードするサイトを取得します。 |
02-ピックサイト |
| L3アドレスを追加します。「IPv4 アドレスプールを作成するための REST API のサンプル」を参照してください |
レイヤー 3(L3)アドレス グループを作成します。 |
03 - L3アドレスの作成 |
| Post L3アドレス |
L3 アドレス グループをデータベースに保存します。 |
04-exec L3アドレス |
| ルーティングリソースを追加する。 BGP クラスタ ID プールを作成するための REST API のサンプルを参照してください。 |
BGP クラスタ グループを作成します。 |
05 - ルーティングリソースの作成 |
| ルーティング後のリソース |
BGP クラスタ グループをデータベースに保存します。 |
06-execルーティングリソース |
| リソースの入手 |
検証用に作成された L3 アドレス グループと BGP クラスタを取得します。 |
07-リソースの確認 |
IPv4 アドレスプールを作成するためのサンプル REST API
JSON ファイルの operation フィールドには、次の値を指定できます。
-
create:新しいネットワーク リソースが存在しない場合は作成します。ただし、リソースが既に存在する場合は、JSON ファイルで指定された新しいネットワーク リソースが既存のネットワーク リソースに追加されます。
-
変更—既存のネットワークリソースを、JSON ファイルを介して渡された値で上書きします。
-
delete:JSON ファイルで指定されたネットワーク リソースを削除します。
以下は、IPv4 アドレス リソース プールを作成するための REST API のサンプルです。
https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order"
{
"customer_id": "network-operator",
"design_id": "l3-addr"
"instance_id": "l3-addr",
"operation": "create",
"org_id": "<ORG>",
"l3_addr": {
"loopbacks": [{
"name": "range-192",
"prefix": "10.10.192.0/18"
}]
"ipv4_prefixes": [{
"name": "pool-11",
"prefix": "10.10.11.0/24
},
{
"name": "pool-12",
"prefix": "10.10.12.0/24"
}
]
}
}
BGP クラスタ ID プールを作成するための REST API のサンプル
JSON ファイルの operation フィールドには、次の値を指定できます。
-
create:新しいネットワーク リソースが存在しない場合は作成します。ただし、リソースが既に存在する場合は、JSON ファイルで指定された新しいネットワーク リソースが既存のネットワーク リソースに追加されます。
-
変更—既存のネットワークリソースを、JSON ファイルを介して渡された値で上書きします。
-
delete:JSON ファイルで指定されたネットワーク リソースを削除します。
以下は、BGP クラスター ID リソース プールを作成するための REST API のサンプルです。
"https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order"
{
"customer_id": "network-operator",
"design_id": "routing",
"instance_id": "routing-stuff",
"operation": "create",
"routing": {
"autonomous_system": [
{
"name": 65200,
"count": 1024
}
],
"spring": {
"sids": {
"size": 1000
}
},
"route_reflector": {
"clusters": [
{
"cluster": "192.168.1.1"
},
{
"cluster": "192.168.2.2"
},
{
"cluster": "192.168.3.3"
}
]
}
}
}
サービス オーケストレーション用のサンプル Postman コレクション ファイル
次に、ネットワークに L3VPN サービスをプロビジョニングするための Postman コレクション ファイルの例を示します。
{
"info": {
"_postman_id": "1bdacde8-64c9-4aaa-ae31-325aef127e44",
"name": "Service Orchestration - L3VPN",
"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json",
"_exporter_id": "829664"
},
"item": [
{
"name": "Create Topology - Step 1.1",
"request": {
"auth": {
"type": "basic",
"basic": [
{
"key": "password",
"value": "{{Password}}",
"type": "string"
},
{
"key": "username",
"value": "{{User}}",
"type": "string"
}
]
},
"method": "POST",
"header": [],
"body": {
"mode": "raw",
"raw": "{\n \"customer_id\": \"l3vpn-topology-cid\",\n \"design_id\": \"topo\",\n \"instance_id\": \"l3vpn-topology-iid\",\n \"operation\": \"create\",\n \"topo\": {\n \"pop\": [\n {\n \"name\": \"6745739c-50dc-40b6-8ba1-72683d199362\",\n \"pe\": [\n {\n \"name\": \"00000000-0000-0000-1000-8828fb0ef680\",\n \"access\": [\n {\n \"name\": \"et-0/0/5\",\n \"type\": \"ethernet\",\n \"speed\": 10000,\n \"ce\": \"ce1\"\n }\n ],\n \"bandwidth\": 40000000,\n \"routes\": 100000,\n \"mac_addrs\": 1000000\n }\n ],\n \"postal_code_matches\": [\n {\n \"name\": \"SVL\",\n \"regex\": \"10...\"\n }\n ]\n },\n {\n \"name\": \"5e88fd56-7d15-4b92-965b-5fe6daf92f9d\",\n \"pe\": [\n {\n \"name\": \"00000000-0000-0000-1000-8828fb0f6e80\",\n \"access\": [\n {\n \"name\": \"et-0/0/5\",\n \"type\": \"ethernet\",\n \"speed\": 10000,\n \"ce\": \"ce2\"\n }\n ],\n \"bandwidth\": 40000000,\n \"routes\": 100000,\n \"mac_addrs\": 1000000\n }\n ],\n \"postal_code_matches\": [\n {\n \"name\": \"BNG\",\n \"regex\": \"20...\"\n }\n ]\n },\n {\n \"name\": \"627164c6-92a5-47f1-a0b1-eb2bf5bda04b\",\n \"pe\": [\n {\n \"name\": \"00000000-0000-0000-1000-485a0d56d018\",\n \"access\": [\n {\n \"name\": \"xe-0/0/0:1\",\n \"type\": \"ethernet\",\n \"speed\": 10000,\n \"ce\": \"ce4\"\n }\n ],\n \"bandwidth\": 40000000,\n \"routes\": 100000,\n \"mac_addrs\": 1000000\n }\n ],\n \"postal_code_matches\": [\n {\n \"name\": \"LAX\",\n \"regex\": \"30...\"\n }\n ]\n }\n ]\n }\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"order"
]
}
},
"response": []
},
{
"name": "EXEC Topology Step 1.2",
"request": {
"auth": {
"type": "basic",
"basic": [
{
"key": "password",
"value": "{{Password}}",
"type": "string"
},
{
"key": "username",
"value": "{{User}}",
"type": "string"
}
]
},
"method": "POST",
"header": [],
"body": {
"mode": "raw",
"raw": ""
},
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order/customers/l3vpn-topology-cid/instances/l3vpn-topology-iid/exec",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"order",
"customers",
"l3vpn-topology-cid",
"instances",
"l3vpn-topology-iid",
"exec"
]
}
},
"response": []
},
{
"name": "Create vpn resources Step 2.1",
"request": {
"auth": {
"type": "basic",
"basic": [
{
"key": "password",
"value": "{{Password}}",
"type": "string"
},
{
"key": "username",
"value": "{{User}}",
"type": "string"
}
]
},
"method": "POST",
"header": [],
"body": {
"mode": "raw",
"raw": "{\n \"customer_id\": \"L3VPN-vpn\",\n \"design_id\": \"vpn\",\n \"instance_id\": \"vpn\",\n \"operation\": \"create\",\n \"vpn\": {\n \"route_distinguisher\": [\n {\n \"count\": 1024,\n \"name\": 1234\n },\n {\n \"count\": 1024,\n \"name\": 1235\n }\n ],\n \"route_target\": [\n {\n \"count\": 1024,\n \"name\": 1234\n },\n {\n \"count\": 1024,\n \"name\": 1235\n }\n ]\n }\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"order"
]
}
},
"response": []
},
{
"name": "EXEC vpn resources Step 2.2",
"request": {
"auth": {
"type": "basic",
"basic": [
{
"key": "password",
"value": "{{Password}}",
"type": "string"
},
{
"key": "username",
"value": "{{User}}",
"type": "string"
}
]
},
"method": "POST",
"header": [],
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order/customers/L3VPN-vpn/instances/vpn/exec",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"order",
"customers",
"L3VPN-vpn",
"instances",
"vpn",
"exec"
]
}
},
"response": []
},
{
"name": "Check Placement Resources 3 Copy",
"request": {
"auth": {
"type": "basic",
"basic": [
{
"key": "password",
"value": "{{Password}}",
"type": "string"
},
{
"key": "username",
"value": "{{User}}",
"type": "string"
}
]
},
"method": "GET",
"header": [],
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/placement/network-elements",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"placement",
"network-elements"
]
}
},
"response": []
}
]
}
表 2 は、サンプル・コレクション・ファイル内の API をリストしています。
| REST API |
形容 |
コレクション ファイル内の参照 |
|---|---|---|
| トポロジー・リソースのアップロード・サービス・オーダー |
L3VPNサービスをプロビジョニングするためのトポロジーネットワークリソースプールを作成します。 |
トポロジの作成 - ステップ 1.1 |
| トポロジー・リソース・サービス・オーダーの実行 |
トポロジーリソースプールをルーティングディレクターデータベースにアップロードします。 |
EXEC トポロジ ステップ 1.2 |
| VPNリソースのアップロードサービス注文 |
L3VPN サービスをプロビジョニングするための VPN リソースプールを作成します。 |
VPN リソースを作成する ステップ 2.1 |
| VPNリソースサービス注文の実行 |
VPNリソースプールをルーティングディレクターデータベースにアップロードします。 |
EXEC VPN リソース ステップ 2.2 |
| 配置するネットワークリソースの表示 | 使用可能なネットワーク リソースを表示して、L3VPN サービスの配置設定を割り当てます。 |
配置リソースの確認 3 コピー |
以下は、ネットワークに L2VPN サービスをプロビジョニングするための Postman コレクション ファイルのサンプルです。
{
"info": {
"_postman_id": "dcbeeaea-1cac-4edf-a601-a1836fb8b1af",
"name": "L2VPN Documentation",
"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json",
"_exporter_id": "30272935"
},
"item": [
{
"name": "L2VPN SO Upload",
"request": {
"auth": {
"type": "basic",
"basic": [
{
"key": "password",
"value": "{{Password}}",
"type": "string"
},
{
"key": "username",
"value": "{{User}}",
"type": "string"
}
]
},
"method": "POST",
"header": [],
"body": {
"mode": "raw",
"raw": "{\n \"customer_id\": \"l2vpn-so-cid\",\n \"instance_id\": \"l2vpn-so-iid\",\n \"design_id\": \"l2vpn\",\n \"operation\": \"create\",\n \"l2vpn_svc\": {\n \"vpn_services\": {\n \"vpn_service\": [\n {\n \"vpn_id\": \"l2vpn-1\",\n \"vpn_svc_type\": \"pbb-evpn\",\n \"customer_name\": \"l2vpn-so-cid\",\n \"svc_topo\": \"any-to-any\"\n }\n ]\n },\n \"sites\": {\n \"site\": [\n {\n \"site_id\": \"PE1\",\n \"site_vpn_flavor\": \"site-vpn-flavor-single\",\n \"devices\": {\n \"device\": [\n {\n \"device_id\": \"ce1\",\n \"location\": \"SVL\"\n }\n ]\n },\n \"locations\": {\n \"location\": [\n {\n \"location_id\": \"SVL\",\n \"address\": \"10 Technology Park Dr\",\n \"postal_code\": \"10321\",\n \"state\": \"NY\",\n \"city\": \"New York City\",\n \"country_code\": \"US\"\n }\n ]\n },\n \"mac_loop_prevention\": {\n \"frequency\": 6,\n \"retry_timer\": 60\n },\n \"site_network_accesses\": {\n \"site_network_access\": [\n {\n \"network_access_id\": \"CE1-1\",\n \"device_reference\": \"ce1\",\n \"bearer\": {\n \"requested_type\": {\n \"type\": \"ethernet\",\n \"strict\": true\n }\n },\n \"connection\": {\n \"eth_inf_type\": \"tagged\",\n \"tagged_interface\": {\n \"type\": \"dot1q\",\n \"dot1q_vlan_tagged\": {\n \"tg_type\": \"c-vlan\",\n \"cvlan_id\": 200\n }\n },\n \"untagged_interface\": {\n \"speed\": 10000,\n \"lldp\": true,\n \"oam_802.3ah_link\": {\n \"enabled\": true\n }\n }\n },\n \"vpn_attachment\": {\n \"vpn_id\": \"l2vpn-1\"\n },\n \"service\": {\n \"svc_bandwidth\": {\n \"bandwidth\": [\n {\n \"direction\": \"input-bw\",\n \"cir\": 100000,\n \"cbs\": 100000\n },\n {\n \"direction\": \"output-bw\",\n \"cir\": 100000,\n \"cbs\": 100000\n }\n ]\n }\n },\n \"mac_addr_limit\": {\n \"limit_number\": 500,\n \"action\": \"drop\"\n }\n }\n ]\n }\n },\n {\n \"site_id\": \"PE2\",\n \"site_vpn_flavor\": \"site-vpn-flavor-single\",\n \"devices\": {\n \"device\": [\n {\n \"device_id\": \"ce2\",\n \"location\": \"BNG\"\n }\n ]\n },\n \"locations\": {\n \"location\": [\n {\n \"location_id\": \"BNG\",\n \"address\": \"123 Bengaluru\",\n \"postal_code\": \"20321\",\n \"state\": \"Karnataka\",\n \"city\": \"Bengaluru\",\n \"country_code\": \"IN\"\n }\n ]\n },\n \"mac_loop_prevention\": {\n \"frequency\": 6,\n \"retry_timer\": 60\n },\n \"site_network_accesses\": {\n \"site_network_access\": [\n {\n \"network_access_id\": \"CE2-1\",\n \"device_reference\": \"ce2\",\n \"bearer\": {\n \"requested_type\": {\n \"type\": \"ethernet\",\n \"strict\": true\n }\n },\n \"connection\": {\n \"eth_inf_type\": \"tagged\",\n \"tagged_interface\": {\n \"type\": \"dot1q\",\n \"dot1q_vlan_tagged\": {\n \"tg_type\": \"c-vlan\",\n \"cvlan_id\": 200\n }\n },\n \"untagged_interface\": {\n \"speed\": 10000,\n \"lldp\": true,\n \"oam_802.3ah_link\": {\n \"enabled\": true\n }\n }\n },\n \"vpn_attachment\": {\n \"vpn_id\": \"l2vpn-1\"\n },\n \"service\": {\n \"svc_bandwidth\": {\n \"bandwidth\": [\n {\n \"direction\": \"input-bw\",\n \"cir\": 100000,\n \"cbs\": 100000\n },\n {\n \"direction\": \"output-bw\",\n \"cir\": 100000,\n \"cbs\": 100000\n }\n ]\n }\n },\n \"mac_addr_limit\": {\n \"limit_number\": 500,\n \"action\": \"drop\"\n }\n }\n ]\n }\n }\n ]\n }\n }\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"order"
]
}
},
"response": []
},
{
"name": "L2VPN SO Exec",
"request": {
"auth": {
"type": "basic",
"basic": [
{
"key": "password",
"value": "{{Password}}",
"type": "string"
},
{
"key": "username",
"value": "{{User}}",
"type": "string"
}
]
},
"method": "POST",
"header": [],
"body": {
"mode": "raw",
"raw": "",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order/customers/l2vpn-so-cid/instances/l2vpn-so-iid/exec",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"order",
"customers",
"l2vpn-so-cid",
"instances",
"l2vpn-so-iid",
"exec"
]
}
},
"response": []
},
{
"name": "VPN SO Upload",
"request": {
"auth": {
"type": "basic",
"basic": [
{
"key": "password",
"value": "{{Password}}",
"type": "string"
},
{
"key": "username",
"value": "{{User}}",
"type": "string"
}
]
},
"method": "POST",
"header": [],
"body": {
"mode": "raw",
"raw": "{\n \"customer_id\": \"l2vpn-so-cid\",\n \"design_id\": \"vpn\",\n \"instance_id\": \"l2vpn-vpn-iid\",\n \"operation\": \"create\",\n \"vpn\": {\n \"route_distinguisher\": [\n {\n \"name\": 1000,\n \"count\": 1024\n },\n {\n \"name\": 2000,\n \"count\": 1024\n }\n ],\n \"route_target\": [\n {\n \"name\": 500,\n \"count\": 1024\n },\n {\n \"name\": 600,\n \"count\": 1024\n }\n ]\n }\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"order"
]
}
},
"response": []
},
{
"name": "VPN SO Exec",
"request": {
"auth": {
"type": "basic",
"basic": [
{
"key": "password",
"value": "{{Password}}",
"type": "string"
},
{
"key": "username",
"value": "{{User}}",
"type": "string"
}
]
},
"method": "POST",
"header": [],
"body": {
"mode": "raw",
"raw": "",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order/customers/l2vpn-so-cid/instances/l2vpn-vpn-iid/exec",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"order",
"customers",
"l2vpn-so-cid",
"instances",
"l2vpn-vpn-iid",
"exec"
]
}
},
"response": []
},
{
"name": "L2 Resource Upload",
"request": {
"auth": {
"type": "basic",
"basic": [
{
"key": "password",
"value": "{{Password}}",
"type": "string"
},
{
"key": "username",
"value": "{{User}}",
"type": "string"
}
]
},
"method": "POST",
"header": [],
"body": {
"mode": "raw",
"raw": "{\n \"customer_id\": \"l2vpn-so-cid\",\n \"design_id\": \"l2-addr\",\n \"instance_id\": \"l2-stuff\",\n \"operation\": \"create\",\n \"l2_addr\": {\n \"lacp\": {\n \"system_id\": [\n {\n \"name\": \"00:00:00:00:00\",\n \"count\": 254\n },\n {\n \"name\": \"00:00:00:00:01\",\n \"count\": 254\n }\n ],\n \"admin_key\": [\n {\n \"start\": 200,\n \"size\": 10\n }\n ]\n },\n \"evpn_esi\": [\n {\n \"name\": \"00:00:00:00:00:00:00:00:00\",\n \"count\": 254\n },\n {\n \"name\": \"00:00:00:00:00:00:00:00:01\",\n \"count\": 254\n }\n ]\n }\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"order"
]
}
},
"response": []
},
{
"name": "L2 Resource Exec",
"request": {
"auth": {
"type": "basic",
"basic": [
{
"key": "password",
"value": "{{Password}}",
"type": "string"
},
{
"key": "username",
"value": "{{User}}",
"type": "string"
}
]
},
"method": "POST",
"header": [],
"body": {
"mode": "raw",
"raw": "",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order/customers/l2vpn-so-cid/instances/l2-stuff/exec",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"order",
"customers",
"l2vpn-so-cid",
"instances",
"l2-stuff",
"exec"
]
}
},
"response": []
},
{
"name": "Topology SO Upload",
"request": {
"auth": {
"type": "basic",
"basic": [
{
"key": "password",
"value": "{{Password}}",
"type": "string"
},
{
"key": "username",
"value": "{{User}}",
"type": "string"
}
]
},
"method": "POST",
"header": [],
"body": {
"mode": "raw",
"raw": "{\n \"customer_id\": \"l2vpn-so-cid\",\n \"design_id\": \"topo\",\n \"instance_id\": \"l2vpn-topo-iid\",\n \"operation\": \"create\",\n \"topo\": {\n \"pop\": [\n {\n \"name\": \"76025add-2f0a-4959-857f-a323c9a4e2d2\",\n \"pe\": [\n {\n \"name\": \"00000000-0000-0000-1000-74e798609000\",\n \"access\": [\n {\n \"name\": \"et-0/0/14\",\n \"type\": \"ethernet\",\n \"speed\": 10000,\n \"ce\": \"ce1\",\n \"vlans\": {\n \"start\": 200,\n \"size\": 10\n }\n }\n ],\n \"bandwidth\": \"2000000\",\n \"routes\": \"1000\",\n \"mac_addrs\": \"1000\"\n }\n ],\n \"postal_code_matches\": [\n {\n \"name\": \"SVL\",\n \"regex\": \"10...\"\n }\n ]\n },\n {\n \"name\": \"9070a569-3650-4b50-9451-5acdbd8ccf41\",\n \"pe\": [\n {\n \"name\": \"00000000-0000-0000-1000-d4996c5731e8\",\n \"access\": [\n {\n \"name\": \"xe-1/0/3\",\n \"type\": \"ethernet\",\n \"speed\": 10000,\n \"ce\": \"ce2\",\n \"vlans\": {\n \"start\": 200,\n \"size\": 10\n }\n }\n ],\n \"bandwidth\": \"1000000\",\n \"routes\": \"1000\",\n \"mac_addrs\": \"1000\"\n }\n \n ],\n \"postal_code_matches\": [\n {\n \"name\": \"BNG\",\n \"regex\": \"20...\"\n }\n ]\n }\n ]\n }\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"order"
]
}
},
"response": []
},
{
"name": "Topology SO Exec",
"request": {
"auth": {
"type": "basic",
"basic": [
{
"key": "password",
"value": "{{Password}}",
"type": "string"
},
{
"key": "username",
"value": "{{User}}",
"type": "string"
}
]
},
"method": "POST",
"header": [],
"body": {
"mode": "raw",
"raw": "",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order/customers/l2vpn-so-cid/instances/l2vpn-topo-iid/exec",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"order",
"customers",
"l2vpn-so-cid",
"instances",
"l2vpn-topo-iid",
"exec"
]
}
},
"response": []
}
]
}
表 3 は、サンプル収集ファイル内の API をリストしています。
| REST API |
形容 |
コレクション ファイル内の参照 |
|---|---|---|
| L2VPNサービス注文のアップロード |
L2VPN サービス注文をルーティングディレクターデータベースにアップロードまたは保存します。 |
L2VPN SOアップロード |
| L2VPN サービス注文を実行する |
L2VPN サービス注文のプロビジョニングワークフローを有効にします。 |
L2VPN SO Exec |
| VPNリソースのアップロードサービス注文 |
L2VPN サービスをプロビジョニングするための VPN リソースプールを作成します。 | VPN SOアップロード |
| VPNリソースサービス注文の実行 |
VPNリソースプールをルーティングディレクターデータベースにアップロードします。これらのリソースは、L2VPN サービスのプロビジョニング時に割り当てられます。 |
VPN SO エグゼクティブ |
| L2アドレスリソースサービスオーダのアップロード |
L2VPN サービスをプロビジョニングするための L2 アドレス リソース プールを作成します。 |
L2リソースのアップロード |
| L2アドレスリソースサービスオーダの実行 |
L2アドレス リソースプールをルーティングディレクターデータベースにアップロードします。これらのリソースは、L2VPN サービスのプロビジョニング時に割り当てられます。 |
L2 Resource Exec |
| トポロジー・リソースのアップロード・サービス・オーダー |
L2VPN サービスをプロビジョニングするためのトポロジーリソースプールを作成します。 |
トポロジSOアップロード |
| トポロジー・リソース・サービス・オーダーの実行 |
トポロジーリソースプールをルーティングディレクターデータベースにアップロードします。これらのリソースは、L2VPN サービスのプロビジョニング時に割り当てられます。 |
トポロジ SO Exec |
次に、ネットワークに L2 回線サービスをプロビジョニングするための Postman コレクション ファイルの例を示します。
{
"info": {
"_postman_id": "f5eabd22-790c-4cfc-9f28-6f7a35644b06",
"name": "L2VPN NSM",
"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json",
"_exporter_id": "16733671"
},
"item": [
{
"name": "Create L2VPN Instance",
"request": {
"auth": {
"type": "basic",
"basic": [
{
"key": "password",
"value": "{{password}}",
"type": "string"
},
{
"key": "username",
"value": "{{user}}",
"type": "string"
}
]
},
"method": "POST",
"header": [],
"body": {
"mode": "raw",
"raw": "{\n \"customer_id\": \"Widget\",\n \"design_id\": \"l2vpn-nsm\",\n \"instance_id\": \"Widget\",\n \"l2vpn_ntw\": {\n \"vpn_services\": {\n \"vpn_service\": [\n {\n \"vpn_id\": \"test-vpn\",\n \"vpn_name\": \"test-vpn\",\n \"vpn_svc_type\": \"vpws\",\n \"customer_name\": \"Widget\",\n \"underlay_transport\": {\n \"transport_instance_id\": \"lsp1\",\n \"instance_type\": \"lsp\"\n },\n \"active_assurance\": {\n \"vc_id\": 101\n },\n \"vpn_nodes\": {\n \"vpn_node\": [\n {\n \"vpn_node_id\": \"yang-node-1\",\n \"ne_id\": \"00000000-0000-0000-1000-0c599c132d70\",\n \"active_assurance\": {\n \"interface\": \"et-0/0/12:0\",\n \"vlan\": 100,\n \"agent\": {\n \"name\": \"ESX18\",\n \"interface\": \"ens1f3.100\"\n }\n },\n \"signaling_options\": [\n {\n \"type\": \"ldp-signaling\",\n \"t_ldp_pwe_type\": \"vpws-type\",\n \"ac_pw_list\": [\n {\n \"peer_addr\": \"10.255.13.171\",\n \"vc_id\": 100\n }\n ]\n }\n ],\n \"vpn_network_accesses\": {\n \"vpn_network_access\": [\n {\n \"id\": \"CE1\",\n \"description\": \"CE1 description\",\n \"port_id\": \"et-0/0/30:0\",\n \"connection\": {\n \"encapsulation\": {\n \"dot1q\": {\n \"c_vlan_id\": 520\n },\n \"l2_access_type\": \"dot1q\"\n }\n },\n \"service\": {\n \"svc_input_bandwidth\": {\n \"input_bandwidth\": [\n {\n \"cbs\": 10000,\n \"cir\": 500000,\n \"type\": \"bw-per-port\"\n }\n ]\n },\n \"svc_output_bandwidth\": {\n \"output_bandwidth\": [\n {\n \"cbs\": 10000,\n \"cir\": 700000,\n \"type\": \"bw-per-port\"\n }\n ]\n }\n }\n }\n ]\n }\n },\n {\n \"vpn_node_id\": \"yang-node-2\",\n \"ne_id\": \"00000000-0000-0000-1000-407f5f32f140\",\n \"active_assurance\": {\n \"interface\": \"et-0/0/22:0\",\n \"vlan\": 100,\n \"agent\": {\n \"name\": \"ESX19\",\n \"interface\": \"ens1f2.100\"\n }\n },\n \"signaling_options\": [\n {\n \"type\": \"ldp-signaling\",\n \"t_ldp_pwe_type\": \"vpws-type\",\n \"ac_pw_list\": [\n {\n \"peer_addr\": \"10.255.1.167\",\n \"vc_id\": 100\n }\n ]\n }\n ],\n \"vpn_network_accesses\": {\n \"vpn_network_access\": [\n {\n \"id\": \"CE2\",\n \"description\": \"CE2 description\",\n \"port_id\": \"et-0/0/1:0\",\n \"connection\": {\n \"encapsulation\": {\n \"dot1q\": {\n \"c_vlan_id\": 520\n },\n \"l2_access_type\": \"dot1q\"\n }\n },\n \"service\": {\n \"svc_input_bandwidth\": {\n \"input_bandwidth\": [\n {\n \"cbs\": 10000,\n \"cir\": 500000,\n \"type\": \"bw-per-port\"\n }\n ]\n },\n \"svc_output_bandwidth\": {\n \"output_bandwidth\": [\n {\n \"cbs\": 10000,\n \"cir\": 700000,\n \"type\": \"bw-per-port\"\n }\n ]\n }\n }\n }\n ]\n }\n }\n ]\n }\n }\n ]\n }\n },\n \"fh_config\": {\n \"type\": \"service_order\"\n },\n \"operation\": \"create\"\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"order"
]
}
},
"response": []
},
{
"name": "Exec L2VPN Instance",
"request": {
"auth": {
"type": "basic",
"basic": [
{
"key": "password",
"value": "{{password}}",
"type": "string"
},
{
"key": "username",
"value": "{{user}}",
"type": "string"
}
]
},
"method": "POST",
"header": [],
"body": {
"mode": "raw",
"raw": "",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order/customers/Widget/instances/Widget/exec",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"order",
"customers",
"Widget",
"instances",
"Widget",
"exec"
]
}
},
"response": []
},
{
"name": "Get L2VPN Instance",
"protocolProfileBehavior": {
"disableBodyPruning": true
},
"request": {
"auth": {
"type": "basic",
"basic": [
{
"key": "password",
"value": "{{password}}",
"type": "string"
},
{
"key": "username",
"value": "{{user}}",
"type": "string"
}
]
},
"method": "GET",
"header": [],
"body": {
"mode": "raw",
"raw": "",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order/customers/Widget/instances/Widget",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"order",
"customers",
"Widget",
"instances",
"Widget"
]
}
},
"response": []
},
{
"name": "Delete L2VPN Instance",
"request": {
"auth": {
"type": "basic",
"basic": [
{
"key": "password",
"value": "{{password}}",
"type": "string"
},
{
"key": "username",
"value": "{{user}}",
"type": "string"
}
]
},
"method": "POST",
"header": [],
"body": {
"mode": "raw",
"raw": "{\n \"customer_id\": \"Widget\",\n \"design_id\": \"l2vpn-nsm\",\n \"instance_id\": \"Widget\",\n \"l2vpn_ntw\": {},\n \"fh_config\": {\n \"type\": \"service_order\"\n },\n \"operation\": \"delete\"\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"order"
]
}
},
"response": []
},
{
"name": "Create VPN Resources",
"event": [
{
"listen": "prerequest",
"script": {
"exec": [
"var x=CryptoJS.enc.Utf8.parse(postman.getEnvironmentVariable(\"User\")+\":\"+postman.getEnvironmentVariable(\"Password\"));",
"var authHeader=CryptoJS.enc.Base64.stringify(x);",
"pm.request.headers.add({key: \"Authorization\", value: \"Basic \"+authHeader});"
],
"type": "text/javascript"
}
}
],
"request": {
"auth": {
"type": "noauth"
},
"method": "POST",
"header": [],
"body": {
"mode": "raw",
"raw": "{\n \"customer_id\": \"network-operator\",\n \"design_id\": \"vpn\",\n \"fh_config\": {\n \"type\": \"service_order\"\n },\n \"instance_id\": \"rds-and-rts\",\n \"operation\": \"create\",\n \"vpn\": {\n \"route_distinguisher\": [\n {\n \"count\": 1024,\n \"name\": 1234\n },\n {\n \"count\": 1024,\n \"name\": 1235\n }\n ],\n \"route_target\": [\n {\n \"count\": 1024,\n \"name\": 1234\n },\n {\n \"count\": 1024,\n \"name\": 1235\n }\n ],\n \"community\": [\n {\n \"name\": \"target:64500\",\n \"count\": 10000\n }\n ],\n \"virtual_circuit_id\": [\n {\n \"start\": 1,\n \"count\": 10000\n }\n ]\n }\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"order"
]
}
},
"response": []
},
{
"name": "Exec VPN Resources",
"request": {
"auth": {
"type": "basic",
"basic": [
{
"key": "password",
"value": "{{password}}",
"type": "string"
},
{
"key": "username",
"value": "{{user}}",
"type": "string"
}
]
},
"method": "POST",
"header": [],
"body": {
"mode": "raw",
"raw": "{\n \"customer_id\": \"internal\",\n \"design_id\": \"l2vpn\",\n \"instance_id\": \"l2vpn\",\n \"l2vpn_svc\": {\n \"sites\": {\n \"site\": [\n { \n \"devices\": {\n \"device\": [\n {\n \"device_id\": \"CE4\",\n \"location\": \"LAX\"\n }\n ]\n },\n \"locations\": {\n \"location\": [\n {\n \"address\": \"123 Rodeo Drive\",\n \"city\": \"Beverly Hills\",\n \"country_code\": \"US\",\n \"location_id\": \"LAX\",\n \"postal_code\": \"90210\",\n \"state\": \"CA\"\n }\n ]\n },\n \"mac_loop_prevention\": {\n \"frequency\": 6,\n \"retry_timer\": 10\n },\n \"site_id\": \"Head Office\",\n \"site_network_accesses\": {\n \"site_network_access\": [\n {\n \"access_diversity\": {\n \"constraints\": {\n \"constraint\": [\n {\n \"constraint_type\": \"pe-diverse\",\n \"target\": {\n \"group\": [\n {\n \"group_id\": \"CE4-DG\"\n }\n ]\n }\n }\n ]\n },\n \"groups\": {\n \"group\": [\n {\n \"group_id\": \"CE4-DG\"\n }\n ]\n }\n },\n \"availability\": {\n \"all_active\": [\n null\n ]\n },\n \"bearer\": {\n \"requested_type\": {\n \"strict\": true,\n \"type\": \"ethernet\"\n }\n },\n \"connection\": {\n \"eth_inf_type\": \"tagged\",\n \"lag_interfaces\": {\n \"lag_interface\": [\n {\n \"index\": \"CE4-LAG1\",\n \"lacp\": {\n \"enabled\": true,\n \"member_links\": {\n \"member_link\": [\n {\n \"name\": \"CE4-LAG1-link1\",\n \"oam_802.3ah_link\": {\n \"enabled\": true\n },\n \"speed\": 40000\n }\n ]\n }\n }\n }\n ]\n },\n \"tagged_interface\": {\n \"dot1q_vlan_tagged\": {\n \"cvlan_id\": 200,\n \"tg_type\": \"c-vlan\"\n },\n \"type\": \"dot1q\"\n }\n },\n \"device_reference\": \"CE4\",\n \"mac_addr_limit\": {\n \"action\": \"drop\",\n \"limit_number\": 500\n },\n \"network_access_id\": \"CE4-1\",\n \"service\": {\n \"svc_bandwidth\": {\n \"bandwidth\": [\n {\n \"cbs\": \"10000\",\n \"cir\": \"700000\",\n \"direction\": \"input-bw\"\n },\n {\n \"cbs\": \"10000\",\n \"cir\": \"500000\",\n \"direction\": \"output-bw\"\n }\n ]\n }\n },\n \"vpn_attachment\": {\n \"vpn_id\": \"Sales-EVPN\"\n }\n },\n {\n \"access_diversity\": {\n \"constraints\": {\n \"constraint\": [\n {\n \"constraint_type\": \"pe-diverse\",\n \"target\": {\n \"group\": [\n {\n \"group_id\": \"CE4-DG\"\n }\n ]\n }\n }\n ]\n },\n \"groups\": {\n \"group\": [\n {\n \"group_id\": \"CE4-DG\"\n }\n ]\n }\n },\n \"availability\": {\n \"all_active\": [\n null\n ]\n },\n \"bearer\": {\n \"requested_type\": {\n \"strict\": true,\n \"type\": \"ethernet\"\n }\n },\n \"connection\": {\n \"eth_inf_type\": \"tagged\",\n \"lag_interfaces\": {\n \"lag_interface\": [\n {\n \"index\": \"CE4-LAG1\",\n \"lacp\": {\n \"enabled\": true,\n \"member_links\": {\n \"member_link\": [\n {\n \"name\": \"CE4-LAG1-link2\",\n \"oam_802.3ah_link\": {\n \"enabled\": true\n },\n \"speed\": 40000\n }\n ]\n }\n }\n }\n ]\n },\n \"tagged_interface\": {\n \"dot1q_vlan_tagged\": {\n \"cvlan_id\": 200,\n \"tg_type\": \"c-vlan\"\n },\n \"type\": \"dot1q\"\n }\n },\n \"device_reference\": \"CE4\",\n \"mac_addr_limit\": {\n \"action\": \"drop\",\n \"limit_number\": 500\n },\n \"network_access_id\": \"CE4-2\",\n \"service\": {\n \"svc_bandwidth\": {\n \"bandwidth\": [\n {\n \"cbs\": \"10000\",\n \"cir\": \"700000\",\n \"direction\": \"input-bw\"\n },\n {\n \"cbs\": \"10000\",\n \"cir\": \"500000\",\n \"direction\": \"output-bw\"\n }\n ]\n }\n },\n \"vpn_attachment\": {\n \"vpn_id\": \"Sales-EVPN\"\n }\n }\n ]\n },\n \"site_vpn_flavor\": \"site-vpn-flavor-single\"\n },\n {\n \"devices\": {\n \"device\": [\n {\n \"device_id\": \"CE6\",\n \"location\": \"LAX\"\n }\n ]\n },\n \"locations\": {\n \"location\": [\n {\n \"address\": \"123 Rodeo Drive\",\n \"city\": \"Beverly Hills\",\n \"country_code\": \"US\",\n \"location_id\": \"LAX\",\n \"postal_code\": \"90210\",\n \"state\": \"CA\"\n }\n ]\n },\n \"mac_loop_prevention\": {\n \"frequency\": 6,\n \"retry_timer\": 10\n },\n \"site_id\": \"LAX depot\",\n \"site_network_accesses\": {\n \"site_network_access\": [\n {\n \"bearer\": {\n \"requested_type\": {\n \"strict\": true,\n \"type\": \"ethernet\"\n }\n },\n \"connection\": {\n \"eth_inf_type\": \"tagged\",\n \"tagged_interface\": {\n \"dot1q_vlan_tagged\": {\n \"cvlan_id\": 102,\n \"tg_type\": \"c-vlan\"\n },\n \"type\": \"dot1q\"\n },\n \"untagged_interface\": {\n \"lldp\": true,\n \"oam_802.3ah_link\": {\n \"enabled\": true\n },\n \"speed\": 40000\n }\n },\n \"device_reference\": \"CE6\",\n \"mac_addr_limit\": {\n \"action\": \"drop\",\n \"limit_number\": 500\n },\n \"network_access_id\": \"CE6-1\",\n \"service\": {\n \"svc_bandwidth\": {\n \"bandwidth\": [\n {\n \"cbs\": \"10000\",\n \"cir\": \"700000\",\n \"direction\": \"input-bw\"\n },\n {\n \"cbs\": \"10000\",\n \"cir\": \"500000\",\n \"direction\": \"output-bw\"\n }\n ]\n }\n },\n \"vpn_attachment\": {\n \"vpn_id\": \"Sales-EVPN\"\n }\n }\n ]\n },\n \"site_vpn_flavor\": \"site-vpn-flavor-single\"\n },\n {\n \"devices\": {\n \"device\": [\n {\n \"device_id\": \"CE2\",\n \"location\": \"NYC1\"\n }\n ]\n },\n \"locations\": {\n \"location\": [\n {\n \"address\": \"2922 Broadway Ave\",\n \"city\": \"New York City\",\n \"country_code\": \"US\",\n \"location_id\": \"NYC1\",\n \"postal_code\": \"10001\",\n \"state\": \"NY\"\n }\n ]\n },\n \"mac_loop_prevention\": {\n \"frequency\": 6,\n \"retry_timer\": 10\n },\n \"site_id\": \"Manufacturing\",\n \"site_network_accesses\": {\n \"site_network_access\": [\n {\n \"access_diversity\": {\n \"constraints\": {\n \"constraint\": [\n {\n \"constraint_type\": \"pe-diverse\",\n \"target\": {\n \"group\": [\n {\n \"group_id\": \"CE2-DG\"\n }\n ]\n }\n }\n ]\n },\n \"groups\": {\n \"group\": [\n {\n \"group_id\": \"CE2-DG\"\n }\n ]\n }\n },\n \"availability\": {\n \"access_priority\": 1000,\n \"single_active\": [\n null\n ]\n },\n \"bearer\": {\n \"requested_type\": {\n \"strict\": true,\n \"type\": \"ethernet\"\n }\n },\n \"connection\": {\n \"eth_inf_type\": \"tagged\",\n \"lag_interfaces\": {\n \"lag_interface\": [\n {\n \"index\": \"CE2-LAG1\",\n \"lacp\": {\n \"enabled\": true,\n \"lldp\": true,\n \"member_links\": {\n \"member_link\": [\n {\n \"name\": \"CE2-LAG1-link1\",\n \"oam_802.3ah_link\": {\n \"enabled\": true\n },\n \"speed\": 40000\n }\n ]\n }\n }\n }\n ]\n },\n \"tagged_interface\": {\n \"dot1q_vlan_tagged\": {\n \"cvlan_id\": 100,\n \"tg_type\": \"c-vlan\"\n },\n \"type\": \"dot1q\"\n }\n },\n \"device_reference\": \"CE2\",\n \"mac_addr_limit\": {\n \"action\": \"drop\",\n \"limit_number\": 500\n },\n \"network_access_id\": \"CE2-1\",\n \"service\": {\n \"svc_bandwidth\": {\n \"bandwidth\": [\n {\n \"cbs\": \"10000\",\n \"cir\": \"700000\",\n \"direction\": \"input-bw\"\n },\n {\n \"cbs\": \"10000\",\n \"cir\": \"500000\",\n \"direction\": \"output-bw\"\n }\n ]\n }\n },\n \"vpn_attachment\": {\n \"vpn_id\": \"Sales-EVPN\"\n }\n },\n {\n \"access_diversity\": {\n \"constraints\": {\n \"constraint\": [\n {\n \"constraint_type\": \"pe-diverse\",\n \"target\": {\n \"group\": [\n {\n \"group_id\": \"CE2-DG\"\n }\n ]\n }\n }\n ]\n },\n \"groups\": {\n \"group\": [\n {\n \"group_id\": \"CE2-DG\"\n }\n ]\n }\n },\n \"availability\": {\n \"access_priority\": 500,\n \"single_active\": [\n null\n ]\n },\n \"bearer\": {\n \"requested_type\": {\n \"strict\": true,\n \"type\": \"ethernet\"\n }\n },\n \"connection\": {\n \"eth_inf_type\": \"tagged\",\n \"lag_interfaces\": {\n \"lag_interface\": [\n {\n \"index\": \"CE2-LAG1\",\n \"lacp\": {\n \"enabled\": true,\n \"member_links\": {\n \"member_link\": [\n {\n \"name\": \"CE2-LAG1-link2\",\n \"oam_802.3ah_link\": {\n \"enabled\": true\n },\n \"speed\": 40000\n }\n ]\n }\n }\n }\n ]\n },\n \"tagged_interface\": {\n \"dot1q_vlan_tagged\": {\n \"cvlan_id\": 100,\n \"tg_type\": \"c-vlan\"\n },\n \"type\": \"dot1q\"\n }\n },\n \"device_reference\": \"CE2\",\n \"mac_addr_limit\": {\n \"action\": \"drop\",\n \"limit_number\": 500\n },\n \"network_access_id\": \"CE2-2\",\n \"service\": {\n \"svc_bandwidth\": {\n \"bandwidth\": [\n {\n \"cbs\": \"10000\",\n \"cir\": \"700000\",\n \"direction\": \"input-bw\"\n },\n {\n \"cbs\": \"10000\",\n \"cir\": \"500000\",\n \"direction\": \"output-bw\"\n }\n ]\n }\n },\n \"vpn_attachment\": {\n \"vpn_id\": \"Sales-EVPN\"\n }\n }\n ]\n },\n \"site_vpn_flavor\": \"site-vpn-flavor-single\"\n }\n ]\n },\n \"vpn_services\": {\n \"vpn_service\": [\n {\n \"customer_name\": \"Widget\",\n \"svc_topo\": \"any-to-any\",\n \"vpn_id\": \"Sales-EVPN\",\n \"vpn_svc_type\": \"pbb-evpn\"\n }\n ]\n }\n },\n \"fh_config\": {\n \"status\": \"placed\",\n \"type\": \"service_order\"\n },\n \"operation\": \"create\"\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order/customers/network-operator/instances/rds-and-rts/exec",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"order",
"customers",
"network-operator",
"instances",
"rds-and-rts",
"exec"
]
}
},
"response": []
},
{
"name": "Get VPN Resources",
"protocolProfileBehavior": {
"disableBodyPruning": true
},
"request": {
"auth": {
"type": "basic",
"basic": [
{
"key": "password",
"value": "{{password}}",
"type": "string"
},
{
"key": "username",
"value": "{{user}}",
"type": "string"
}
]
},
"method": "GET",
"header": [],
"body": {
"mode": "raw",
"raw": "{\n \"customer_id\": \"internal\",\n \"design_id\": \"l2vpn\",\n \"instance_id\": \"l2vpn\",\n \"l2vpn_svc\": {\n \"sites\": {\n \"site\": [\n { \n \"devices\": {\n \"device\": [\n {\n \"device_id\": \"CE4\",\n \"location\": \"LAX\"\n }\n ]\n },\n \"locations\": {\n \"location\": [\n {\n \"address\": \"123 Rodeo Drive\",\n \"city\": \"Beverly Hills\",\n \"country_code\": \"US\",\n \"location_id\": \"LAX\",\n \"postal_code\": \"90210\",\n \"state\": \"CA\"\n }\n ]\n },\n \"mac_loop_prevention\": {\n \"frequency\": 6,\n \"retry_timer\": 10\n },\n \"site_id\": \"Head Office\",\n \"site_network_accesses\": {\n \"site_network_access\": [\n {\n \"access_diversity\": {\n \"constraints\": {\n \"constraint\": [\n {\n \"constraint_type\": \"pe-diverse\",\n \"target\": {\n \"group\": [\n {\n \"group_id\": \"CE4-DG\"\n }\n ]\n }\n }\n ]\n },\n \"groups\": {\n \"group\": [\n {\n \"group_id\": \"CE4-DG\"\n }\n ]\n }\n },\n \"availability\": {\n \"all_active\": [\n null\n ]\n },\n \"bearer\": {\n \"requested_type\": {\n \"strict\": true,\n \"type\": \"ethernet\"\n }\n },\n \"connection\": {\n \"eth_inf_type\": \"tagged\",\n \"lag_interfaces\": {\n \"lag_interface\": [\n {\n \"index\": \"CE4-LAG1\",\n \"lacp\": {\n \"enabled\": true,\n \"member_links\": {\n \"member_link\": [\n {\n \"name\": \"CE4-LAG1-link1\",\n \"oam_802.3ah_link\": {\n \"enabled\": true\n },\n \"speed\": 40000\n }\n ]\n }\n }\n }\n ]\n },\n \"tagged_interface\": {\n \"dot1q_vlan_tagged\": {\n \"cvlan_id\": 200,\n \"tg_type\": \"c-vlan\"\n },\n \"type\": \"dot1q\"\n }\n },\n \"device_reference\": \"CE4\",\n \"mac_addr_limit\": {\n \"action\": \"drop\",\n \"limit_number\": 500\n },\n \"network_access_id\": \"CE4-1\",\n \"service\": {\n \"svc_bandwidth\": {\n \"bandwidth\": [\n {\n \"cbs\": \"10000\",\n \"cir\": \"700000\",\n \"direction\": \"input-bw\"\n },\n {\n \"cbs\": \"10000\",\n \"cir\": \"500000\",\n \"direction\": \"output-bw\"\n }\n ]\n }\n },\n \"vpn_attachment\": {\n \"vpn_id\": \"Sales-EVPN\"\n }\n },\n {\n \"access_diversity\": {\n \"constraints\": {\n \"constraint\": [\n {\n \"constraint_type\": \"pe-diverse\",\n \"target\": {\n \"group\": [\n {\n \"group_id\": \"CE4-DG\"\n }\n ]\n }\n }\n ]\n },\n \"groups\": {\n \"group\": [\n {\n \"group_id\": \"CE4-DG\"\n }\n ]\n }\n },\n \"availability\": {\n \"all_active\": [\n null\n ]\n },\n \"bearer\": {\n \"requested_type\": {\n \"strict\": true,\n \"type\": \"ethernet\"\n }\n },\n \"connection\": {\n \"eth_inf_type\": \"tagged\",\n \"lag_interfaces\": {\n \"lag_interface\": [\n {\n \"index\": \"CE4-LAG1\",\n \"lacp\": {\n \"enabled\": true,\n \"member_links\": {\n \"member_link\": [\n {\n \"name\": \"CE4-LAG1-link2\",\n \"oam_802.3ah_link\": {\n \"enabled\": true\n },\n \"speed\": 40000\n }\n ]\n }\n }\n }\n ]\n },\n \"tagged_interface\": {\n \"dot1q_vlan_tagged\": {\n \"cvlan_id\": 200,\n \"tg_type\": \"c-vlan\"\n },\n \"type\": \"dot1q\"\n }\n },\n \"device_reference\": \"CE4\",\n \"mac_addr_limit\": {\n \"action\": \"drop\",\n \"limit_number\": 500\n },\n \"network_access_id\": \"CE4-2\",\n \"service\": {\n \"svc_bandwidth\": {\n \"bandwidth\": [\n {\n \"cbs\": \"10000\",\n \"cir\": \"700000\",\n \"direction\": \"input-bw\"\n },\n {\n \"cbs\": \"10000\",\n \"cir\": \"500000\",\n \"direction\": \"output-bw\"\n }\n ]\n }\n },\n \"vpn_attachment\": {\n \"vpn_id\": \"Sales-EVPN\"\n }\n }\n ]\n },\n \"site_vpn_flavor\": \"site-vpn-flavor-single\"\n },\n {\n \"devices\": {\n \"device\": [\n {\n \"device_id\": \"CE6\",\n \"location\": \"LAX\"\n }\n ]\n },\n \"locations\": {\n \"location\": [\n {\n \"address\": \"123 Rodeo Drive\",\n \"city\": \"Beverly Hills\",\n \"country_code\": \"US\",\n \"location_id\": \"LAX\",\n \"postal_code\": \"90210\",\n \"state\": \"CA\"\n }\n ]\n },\n \"mac_loop_prevention\": {\n \"frequency\": 6,\n \"retry_timer\": 10\n },\n \"site_id\": \"LAX depot\",\n \"site_network_accesses\": {\n \"site_network_access\": [\n {\n \"bearer\": {\n \"requested_type\": {\n \"strict\": true,\n \"type\": \"ethernet\"\n }\n },\n \"connection\": {\n \"eth_inf_type\": \"tagged\",\n \"tagged_interface\": {\n \"dot1q_vlan_tagged\": {\n \"cvlan_id\": 102,\n \"tg_type\": \"c-vlan\"\n },\n \"type\": \"dot1q\"\n },\n \"untagged_interface\": {\n \"lldp\": true,\n \"oam_802.3ah_link\": {\n \"enabled\": true\n },\n \"speed\": 40000\n }\n },\n \"device_reference\": \"CE6\",\n \"mac_addr_limit\": {\n \"action\": \"drop\",\n \"limit_number\": 500\n },\n \"network_access_id\": \"CE6-1\",\n \"service\": {\n \"svc_bandwidth\": {\n \"bandwidth\": [\n {\n \"cbs\": \"10000\",\n \"cir\": \"700000\",\n \"direction\": \"input-bw\"\n },\n {\n \"cbs\": \"10000\",\n \"cir\": \"500000\",\n \"direction\": \"output-bw\"\n }\n ]\n }\n },\n \"vpn_attachment\": {\n \"vpn_id\": \"Sales-EVPN\"\n }\n }\n ]\n },\n \"site_vpn_flavor\": \"site-vpn-flavor-single\"\n },\n {\n \"devices\": {\n \"device\": [\n {\n \"device_id\": \"CE2\",\n \"location\": \"NYC1\"\n }\n ]\n },\n \"locations\": {\n \"location\": [\n {\n \"address\": \"2922 Broadway Ave\",\n \"city\": \"New York City\",\n \"country_code\": \"US\",\n \"location_id\": \"NYC1\",\n \"postal_code\": \"10001\",\n \"state\": \"NY\"\n }\n ]\n },\n \"mac_loop_prevention\": {\n \"frequency\": 6,\n \"retry_timer\": 10\n },\n \"site_id\": \"Manufacturing\",\n \"site_network_accesses\": {\n \"site_network_access\": [\n {\n \"access_diversity\": {\n \"constraints\": {\n \"constraint\": [\n {\n \"constraint_type\": \"pe-diverse\",\n \"target\": {\n \"group\": [\n {\n \"group_id\": \"CE2-DG\"\n }\n ]\n }\n }\n ]\n },\n \"groups\": {\n \"group\": [\n {\n \"group_id\": \"CE2-DG\"\n }\n ]\n }\n },\n \"availability\": {\n \"access_priority\": 1000,\n \"single_active\": [\n null\n ]\n },\n \"bearer\": {\n \"requested_type\": {\n \"strict\": true,\n \"type\": \"ethernet\"\n }\n },\n \"connection\": {\n \"eth_inf_type\": \"tagged\",\n \"lag_interfaces\": {\n \"lag_interface\": [\n {\n \"index\": \"CE2-LAG1\",\n \"lacp\": {\n \"enabled\": true,\n \"lldp\": true,\n \"member_links\": {\n \"member_link\": [\n {\n \"name\": \"CE2-LAG1-link1\",\n \"oam_802.3ah_link\": {\n \"enabled\": true\n },\n \"speed\": 40000\n }\n ]\n }\n }\n }\n ]\n },\n \"tagged_interface\": {\n \"dot1q_vlan_tagged\": {\n \"cvlan_id\": 100,\n \"tg_type\": \"c-vlan\"\n },\n \"type\": \"dot1q\"\n }\n },\n \"device_reference\": \"CE2\",\n \"mac_addr_limit\": {\n \"action\": \"drop\",\n \"limit_number\": 500\n },\n \"network_access_id\": \"CE2-1\",\n \"service\": {\n \"svc_bandwidth\": {\n \"bandwidth\": [\n {\n \"cbs\": \"10000\",\n \"cir\": \"700000\",\n \"direction\": \"input-bw\"\n },\n {\n \"cbs\": \"10000\",\n \"cir\": \"500000\",\n \"direction\": \"output-bw\"\n }\n ]\n }\n },\n \"vpn_attachment\": {\n \"vpn_id\": \"Sales-EVPN\"\n }\n },\n {\n \"access_diversity\": {\n \"constraints\": {\n \"constraint\": [\n {\n \"constraint_type\": \"pe-diverse\",\n \"target\": {\n \"group\": [\n {\n \"group_id\": \"CE2-DG\"\n }\n ]\n }\n }\n ]\n },\n \"groups\": {\n \"group\": [\n {\n \"group_id\": \"CE2-DG\"\n }\n ]\n }\n },\n \"availability\": {\n \"access_priority\": 500,\n \"single_active\": [\n null\n ]\n },\n \"bearer\": {\n \"requested_type\": {\n \"strict\": true,\n \"type\": \"ethernet\"\n }\n },\n \"connection\": {\n \"eth_inf_type\": \"tagged\",\n \"lag_interfaces\": {\n \"lag_interface\": [\n {\n \"index\": \"CE2-LAG1\",\n \"lacp\": {\n \"enabled\": true,\n \"member_links\": {\n \"member_link\": [\n {\n \"name\": \"CE2-LAG1-link2\",\n \"oam_802.3ah_link\": {\n \"enabled\": true\n },\n \"speed\": 40000\n }\n ]\n }\n }\n }\n ]\n },\n \"tagged_interface\": {\n \"dot1q_vlan_tagged\": {\n \"cvlan_id\": 100,\n \"tg_type\": \"c-vlan\"\n },\n \"type\": \"dot1q\"\n }\n },\n \"device_reference\": \"CE2\",\n \"mac_addr_limit\": {\n \"action\": \"drop\",\n \"limit_number\": 500\n },\n \"network_access_id\": \"CE2-2\",\n \"service\": {\n \"svc_bandwidth\": {\n \"bandwidth\": [\n {\n \"cbs\": \"10000\",\n \"cir\": \"700000\",\n \"direction\": \"input-bw\"\n },\n {\n \"cbs\": \"10000\",\n \"cir\": \"500000\",\n \"direction\": \"output-bw\"\n }\n ]\n }\n },\n \"vpn_attachment\": {\n \"vpn_id\": \"Sales-EVPN\"\n }\n }\n ]\n },\n \"site_vpn_flavor\": \"site-vpn-flavor-single\"\n }\n ]\n },\n \"vpn_services\": {\n \"vpn_service\": [\n {\n \"customer_name\": \"Widget\",\n \"svc_topo\": \"any-to-any\",\n \"vpn_id\": \"Sales-EVPN\",\n \"vpn_svc_type\": \"pbb-evpn\"\n }\n ]\n }\n },\n \"fh_config\": {\n \"type\": \"service_order\"\n },\n \"operation\": \"delete\"\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order/customers/Widget/instances/Widget",
"protocol": "https",
"host": [
"{{server}}"
],
"port": "{{port}}",
"path": [
"service-orchestration",
"api",
"v1",
"orgs",
"{{ORG}}",
"order",
"customers",
"Widget",
"instances",
"Widget"
]
}
},
"response": []
}
]
}
表 4 は、サンプル・コレクション・ファイル内の API をリストしています。
| REST API |
形容 |
コレクション ファイル内の参照 |
|---|---|---|
| L2回線サービスインスタンスの作成 |
L2回線サービスインスタンスを作成します。 |
L2VPNインスタンスの作成 |
| L2回線サービスインスタンスの実行 |
L2回線サービスインスタンスのプロビジョニングワークフローを有効にします。 |
Exec L2VPN インスタンス |
| L2回線プロビジョニングステータスの表示 |
L2回線サービスインスタンスのプロビジョニング状況を表示します。 |
L2VPNインスタンスの取得 |
| L2回線サービスインスタンスの削除 |
L2回線サービスインスタンスの削除ワークフローを有効にします。 |
L2VPNインスタンスの削除 |
| VPNリソースプールの作成 |
L2回線サービスをプロビジョニングするためのVPNリソースプールを作成します。 |
VPNリソースの作成 |
| VPNリソースインスタンスの実行 |
VPNリソースプールをルーティングディレクターデータベースにアップロードします。これらのリソースは、L2回線サービスのプロビジョニング時に割り当てられます。 |
Exec VPNリソース |
| L2回線サービスプロビジョニング用のVPNリソースの取得 |
L2回線サービスのプロビジョニングにVPNリソースプールで使用可能なリソースを表示します。 |
VPNリソースの入手 |
L3VPNおよびL2VPNサービスのトポロジリソースを作成するためのサンプルREST API
JSON ファイルの operation フィールドには、次の値を指定できます。
-
create:新しいネットワーク リソースが存在しない場合は作成します。ただし、リソースが既に存在する場合は、JSON ファイルで指定された新しいネットワーク リソースが既存のネットワーク リソースに追加されます。
-
変更—既存のネットワークリソースを、JSON ファイルを介して渡された値で上書きします。
-
delete:JSON ファイルで指定されたネットワーク リソースを削除します。
次に、L3VPN および L2VPN サービスのトポロジーリソースプールを作成するための REST API の例を示します。
https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order
# This file is a sample and not valid JSON. To use it, please:
# 1. Remove all comments. (Comments begin with #)
# 2. Change the file extension to .json.
{
"customer_id": "network-operator",
"design_id": "topo",
"instance_id": "topology",
"operation": "create",
"topo": {
"pop": [
{
"name": "e57ce4ee-9ef7-4e3c-a15d-66ab16d8f247", #this can be fetched from the sites page, see point 1 below (Site ID)
"pe": [
{
"access": [
{
"ce": "ce1", #this is CE device reference
"name": "ge-0/0/3", #this is the PE interface that connects to the CE device
"speed": "100000",
"type": "ethernet"
}
],
"bandwidth": "40000000000",
"mac_addrs": "1000000",
"name": "00000000-0000-0000-1000-2c6bf5efb500", #this can be fetched from the inventory page, see point 2 below (Device ID)
"routes": "1000000"
}
],
"postal_code_matches": [
{
"name": "M1", #User defined string, has to be unique within POPs
"regex": "94..." #this is the regex for the postal codes this POP will accept
}
]
},
{
"name": "3f6ae91b-02f8-4bf3-9d4c-8cbeaf832b2c",
"pe": [
{
"access": [
{
"ce": "ce2",
"name": "ge-0/0/3",
"speed": "100000",
"type": "ethernet"
},
{
"ce": "ce1",
"name": "ge-0/0/4",
"speed": "100000",
"type": "ethernet"
}
],
"bandwidth": "40000000000",
"mac_addrs": "1000000",
"name": "00000000-0000-0000-1000-2c6bf5598200",
"routes": "1000000"
}
],
# postal_code_matches are optional
"postal_code_matches": [
{
"name": "M4",
"regex": "91..."
}
]
}
]
}
}
# 1. To get site ID, go to Inventory>Sites. If you don't see the ID column, click on the three dots above the table>Show/Hide columns and enable ID.
# 2. To get device ID, go to Inventory>Network Inventory. If you don't see the ID column, click on the three dots above the table>Show/Hide columns and enable ID.
L3VPN、L2VPN、および L2 回線サービスの VPN リソースを作成するためのサンプル REST API
JSON ファイルの operation フィールドには、次の値を指定できます。
-
create:新しいネットワーク リソースが存在しない場合は作成します。ただし、リソースが既に存在する場合は、JSON ファイルで指定された新しいネットワーク リソースが既存のネットワーク リソースに追加されます。
-
変更—既存のネットワークリソースを、JSON ファイルを介して渡された値で上書きします。
-
delete:JSON ファイルで指定されたネットワーク リソースを削除します。
次に、L3VPN、L2VPN、および L2 回線サービスの VPN リソース プールを作成するための REST API の例を示します。
https://{{server}}:{{port}}/service-orchestration/api/v1/orgs/{{ORG}}/order
{
"customer_id": "network-operator",
"design_id": "vpn",
"instance_id": "rds-and-rts",
"operation": "create",
"vpn": {
"route_distinguisher": [
{
"count": 1024,
"name": 1234
}
],
"route_target": [
{
"count": 1024,
"name": 1234
},
{
"count": 1024,
"name": 1235
}
],
"community": [
{
"name": "target:64500",
"count": 10000
}
],
"virtual_circuit_id": [
{
"start": 1,
"count": 10000
}
]