Skip to content

Commit 86408a8

Browse files
authored
Adding 2021-06-21 TURN API version (Azure#14955)
1 parent e793a8c commit 86408a8

File tree

5 files changed

+196
-0
lines changed

5 files changed

+196
-0
lines changed

custom-words.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1224,6 +1224,7 @@ Netfilter
12241224
networkruleset
12251225
networkrulesets
12261226
networkstatus
1227+
networktraversal
12271228
networkwatcher
12281229
newpassword
12291230
newrelapp

specification/communication/data-plane/Turn/preview/2021-02-22-preview1/CommunicationTurn.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,9 @@
106106
"name": "api-version",
107107
"description": "Version of API to invoke.",
108108
"required": true,
109+
"enum": [
110+
"2021-02-22-preview1"
111+
],
109112
"type": "string"
110113
}
111114
},
Lines changed: 157 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,157 @@
1+
{
2+
"swagger": "2.0",
3+
"info": {
4+
"title": "CommunicationNetworkingClient",
5+
"description": "Azure Communication Networking Service",
6+
"version": "2021-06-21-preview"
7+
},
8+
"paths": {
9+
"/networktraversal/:issueRelayConfiguration": {
10+
"post": {
11+
"tags": [
12+
"Turn"
13+
],
14+
"summary": "Issue a configuration for an STUN/TURN server for an existing identity.",
15+
"operationId": "CommunicationNetworkTraversal_IssueRelayConfiguration",
16+
"consumes": [
17+
"application/json"
18+
],
19+
"produces": [
20+
"application/json"
21+
],
22+
"parameters": [
23+
{
24+
"$ref": "#/parameters/ApiVersionParameter"
25+
},
26+
{
27+
"in": "body",
28+
"name": "body",
29+
"required": true,
30+
"schema": {
31+
"$ref": "#/definitions/CommunicationRelayConfigurationRequest"
32+
}
33+
}
34+
],
35+
"responses": {
36+
"200": {
37+
"description": "Success",
38+
"schema": {
39+
"$ref": "#/definitions/CommunicationRelayConfiguration"
40+
}
41+
},
42+
"default": {
43+
"description": "Error",
44+
"schema": {
45+
"$ref": "../../../Common/stable/2021-03-07/common.json#/definitions/CommunicationErrorResponse"
46+
}
47+
}
48+
},
49+
"x-ms-examples": {
50+
"Issue Relay Configuration": {
51+
"$ref": "./examples/IssueRelayConfiguration.json"
52+
}
53+
}
54+
}
55+
}
56+
},
57+
"definitions": {
58+
"CommunicationRelayConfigurationRequest": {
59+
"description": "Request for a CommunicationRelayConfiguration.",
60+
"required": [
61+
"id"
62+
],
63+
"type": "object",
64+
"properties": {
65+
"id": {
66+
"description": "An existing ACS identity.",
67+
"type": "string"
68+
}
69+
}
70+
},
71+
"CommunicationIceServer": {
72+
"description": "An instance of a STUN/TURN server with credentials to be used for ICE negotiation.",
73+
"required": [
74+
"credential",
75+
"urls",
76+
"username"
77+
],
78+
"type": "object",
79+
"properties": {
80+
"urls": {
81+
"description": "List of STUN/TURN server URLs.",
82+
"type": "array",
83+
"items": {
84+
"type": "string"
85+
}
86+
},
87+
"username": {
88+
"description": "User account name which uniquely identifies the credentials.",
89+
"type": "string"
90+
},
91+
"credential": {
92+
"description": "Credential for the server.",
93+
"type": "string"
94+
}
95+
}
96+
},
97+
"CommunicationRelayConfiguration": {
98+
"description": "A relay configuration containing the STUN/TURN URLs and credentials.",
99+
"required": [
100+
"expiresOn",
101+
"iceServers"
102+
],
103+
"type": "object",
104+
"properties": {
105+
"expiresOn": {
106+
"format": "date-time",
107+
"description": "The date for which the username and credentials are not longer valid.",
108+
"type": "string"
109+
},
110+
"iceServers": {
111+
"description": "An array representing the credentials and the STUN/TURN server URLs for use in ICE negotiations.",
112+
"type": "array",
113+
"items": {
114+
"$ref": "#/definitions/CommunicationIceServer"
115+
}
116+
}
117+
}
118+
}
119+
},
120+
"parameters": {
121+
"ApiVersionParameter": {
122+
"in": "query",
123+
"name": "api-version",
124+
"description": "Version of API to invoke.",
125+
"required": true,
126+
"enum": [
127+
"2021-06-21-preview"
128+
],
129+
"type": "string"
130+
}
131+
},
132+
"securityDefinitions": {
133+
"azure_auth": {
134+
"type": "oauth2",
135+
"flow": "implicit",
136+
"authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize",
137+
"scopes": {
138+
"user_impersonation": "impersonate your user account"
139+
}
140+
}
141+
},
142+
"x-ms-parameterized-host": {
143+
"hostTemplate": "{endpoint}",
144+
"useSchemePrefix": false,
145+
"parameters": [
146+
{
147+
"name": "endpoint",
148+
"description": "The communication resource, for example https://my-resource.communication.azure.com",
149+
"required": true,
150+
"type": "string",
151+
"in": "path",
152+
"x-ms-skip-url-encoding": true,
153+
"x-ms-parameter-location": "client"
154+
}
155+
]
156+
}
157+
}
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
{
2+
"parameters": {
3+
"api-version": "2021-06-21-preview",
4+
"content-type": "application/json",
5+
"body": {
6+
"id": "8:acs:2dee53b4-368b-45b4-ab52-8493fb117652_00000005-14a2-493b-8a72-5a3a0d000081"
7+
},
8+
"endpoint": "https://my-resource.communication.azure.com"
9+
},
10+
"responses": {
11+
"200": {
12+
"body": {
13+
"expiresOn": "2020-09-10T21:39:39.3244584+00:00",
14+
"iceServers": [
15+
{
16+
"urls": [
17+
"turn:131.107.255.255:3478"
18+
],
19+
"username": "AgAAJNOeygwB1uVGvuwAVMHV4PLhYDgY66Fg1dUZvQ4AAAAEhXrhc8uJFjOK8lxEsZk3KIpWxc0=",
20+
"credential": "9rl8ablFWj6/aqSuPLgLykLZKqw="
21+
}
22+
]
23+
}
24+
}
25+
}
26+
}

specification/communication/data-plane/Turn/readme.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,15 @@ title:
4040
Azure Communication Services
4141
```
4242

43+
### Tag: package-2021-06-21-preview
44+
45+
These settings apply only when `--tag=package-2021-06-21-preview` is specified on the command line.
46+
47+
```yaml $(tag) == 'package-2021-06-21-preview'
48+
input-file:
49+
- preview/2021-06-21-preview/CommunicationTurn.json
50+
```
51+
4352
---
4453

4554
# Code Generation

0 commit comments

Comments
 (0)