-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add new 1.1-preview version for IoT Central (#15257)
* Add new 2.0-preview.1 version for IoT Central * fix typo on enum value * rollback 1.0 changes, applied 2.0-preview.1 * fix typo * remove non-used examples * fix style * update version from 2.0-preview.1 to 1.1-preview * update code review comments, fix patch consumes with json-patch support, fix examples for fileupload * add nextLink to collection of orgs * fix typo * fix wrong position of paging * fix the paging * add . to description * update default to use enum for api-version
- Loading branch information
1 parent
bb530ad
commit fbb7ba7
Showing
61 changed files
with
5,624 additions
and
2 deletions.
There are no files selected for viewing
39 changes: 39 additions & 0 deletions
39
...central/data-plane/Microsoft.IoTCentral/preview/1.1-preview/examples/apitoken_create.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
{ | ||
"title": "Get API tokens in your application", | ||
"description": "Get a list of API tokens in your application.", | ||
"parameters": { | ||
"baseDomain": "azureiotcentral.com", | ||
"subdomain": "appsubdomain", | ||
"tokenId": "testtoken", | ||
"api-version": "1.1-preview", | ||
"body": { | ||
"roles": [ | ||
{ | ||
"role": "ca310b8d-2f4a-44e0-a36e-957c202cd8d4" | ||
}, | ||
{ | ||
"role": "c495eb57-eb18-489e-9802-62c474e5645c", | ||
"organization": "seattle" | ||
} | ||
] | ||
} | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"id": "testtoken", | ||
"roles": [ | ||
{ | ||
"role": "ca310b8d-2f4a-44e0-a36e-957c202cd8d4" | ||
}, | ||
{ | ||
"role": "c495eb57-eb18-489e-9802-62c474e5645c", | ||
"organization": "seattle" | ||
} | ||
], | ||
"expiry": "2020-10-18T18:30:40.227Z", | ||
"token": "SharedAccessSignature sr=..." | ||
} | ||
} | ||
} | ||
} |
13 changes: 13 additions & 0 deletions
13
...central/data-plane/Microsoft.IoTCentral/preview/1.1-preview/examples/apitoken_delete.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
{ | ||
"title": "Delete API token", | ||
"description": "Delete an API token using its name.", | ||
"parameters": { | ||
"baseDomain": "azureiotcentral.com", | ||
"subdomain": "appsubdomain", | ||
"tokenId": "testtoken", | ||
"api-version": "1.1-preview" | ||
}, | ||
"responses": { | ||
"204": {} | ||
} | ||
} |
24 changes: 24 additions & 0 deletions
24
...iotcentral/data-plane/Microsoft.IoTCentral/preview/1.1-preview/examples/apitoken_get.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
{ | ||
"title": "Get an API token in your application", | ||
"description": "Get an API token by Id in your application.", | ||
"parameters": { | ||
"baseDomain": "azureiotcentral.com", | ||
"subdomain": "appsubdomain", | ||
"tokenId": "testtoken", | ||
"api-version": "1.1-preview" | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"id": "testtoken", | ||
"roles": [ | ||
{ | ||
"role": "c495eb57-eb18-489e-9802-62c474e5645c", | ||
"organization": "seattle" | ||
} | ||
], | ||
"expiry": "2020-10-18T18:30:40.227Z" | ||
} | ||
} | ||
} | ||
} |
30 changes: 30 additions & 0 deletions
30
...otcentral/data-plane/Microsoft.IoTCentral/preview/1.1-preview/examples/apitoken_list.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
{ | ||
"title": "List API tokens in your application", | ||
"description": "Get a list of API tokens in your application.", | ||
"parameters": { | ||
"baseDomain": "azureiotcentral.com", | ||
"subdomain": "appsubdomain", | ||
"api-version": "1.1-preview" | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"value": [ | ||
{ | ||
"id": "testtoken", | ||
"roles": [ | ||
{ | ||
"role": "ca310b8d-2f4a-44e0-a36e-957c202cd8d4" | ||
}, | ||
{ | ||
"role": "c495eb57-eb18-489e-9802-62c474e5645c", | ||
"organization": "seattle" | ||
} | ||
], | ||
"expiry": "2020-10-18T18:30:40.227Z" | ||
} | ||
] | ||
} | ||
} | ||
} | ||
} |
21 changes: 21 additions & 0 deletions
21
...l/data-plane/Microsoft.IoTCentral/preview/1.1-preview/examples/devicecredentials_get.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
{ | ||
"title": "Get device credentials", | ||
"description": "Get the device credentials of a created device. Returns the app's scope Id and device SAS key", | ||
"parameters": { | ||
"baseDomain": "azureiotcentral.com", | ||
"subdomain": "appsubdomain", | ||
"deviceId": "Checkout4", | ||
"api-version": "1.1-preview" | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"idScope": "<ID scope>", | ||
"symmetricKey": { | ||
"primaryKey": "<primary key>", | ||
"secondaryKey": "<secondary key>" | ||
} | ||
} | ||
} | ||
} | ||
} |
39 changes: 39 additions & 0 deletions
39
...ntral/data-plane/Microsoft.IoTCentral/preview/1.1-preview/examples/devicegroups_list.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
{ | ||
"title": "DeviceGroup List", | ||
"description": "List all device groups in your application.", | ||
"parameters": { | ||
"baseDomain": "azureiotcentral.com", | ||
"subdomain": "appsubdomain", | ||
"api-version": "1.1-preview" | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"value": [ | ||
{ | ||
"id": "475cad48-b7ff-4a09-b51e-1a9021385453", | ||
"displayName": "DeviceGroupEntry1", | ||
"organizations": [ | ||
"seattle" | ||
] | ||
}, | ||
{ | ||
"id": "c2d5ae1d-2cb7-4f58-bf44-5e816aba0a0e", | ||
"displayName": "DeviceGroupEntry2", | ||
"organizations": [ | ||
"redmond" | ||
] | ||
}, | ||
{ | ||
"id": "241ad72b-32aa-4216-aabe-91b240582c8d", | ||
"displayName": "DeviceGroupEntry3" | ||
}, | ||
{ | ||
"id": "241ad72b-32aa-4216-aabe-91b240582c8d", | ||
"displayName": "DeviceGroupEntry4" | ||
} | ||
] | ||
} | ||
} | ||
} | ||
} |
13 changes: 13 additions & 0 deletions
13
...-plane/Microsoft.IoTCentral/preview/1.1-preview/examples/devices_attestations_delete.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
{ | ||
"title": "Delete device attestation", | ||
"description": "Deletes the attestation for a device.", | ||
"parameters": { | ||
"baseDomain": "azureiotcentral.com", | ||
"subdomain": "appsubdomain", | ||
"deviceId": "Checkout4", | ||
"api-version": "1.1-preview" | ||
}, | ||
"responses": { | ||
"204": {} | ||
} | ||
} |
26 changes: 26 additions & 0 deletions
26
...ata-plane/Microsoft.IoTCentral/preview/1.1-preview/examples/devices_attestations_get.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
{ | ||
"title": "Get device attestation", | ||
"description": "Gets the attestation for a device.", | ||
"parameters": { | ||
"baseDomain": "azureiotcentral.com", | ||
"subdomain": "appsubdomain", | ||
"deviceId": "CheckoutThermostat", | ||
"api-version": "1.1-preview" | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"type": "x509", | ||
"x509": { | ||
"clientCertificates": { | ||
"primary": { | ||
"info": { | ||
"sha1Thumbprint": "<thumbprint>" | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} |
28 changes: 28 additions & 0 deletions
28
...rosoft.IoTCentral/preview/1.1-preview/examples/devices_attestations_set_symmetricKey.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
{ | ||
"title": "Set device attestation - Symmetric key", | ||
"description": "Creates or updates the symmetric key attestation for a device.", | ||
"parameters": { | ||
"baseDomain": "azureiotcentral.com", | ||
"subdomain": "appsubdomain", | ||
"deviceId": "CheckoutThermostat", | ||
"api-version": "1.1-preview", | ||
"body": { | ||
"type": "symmetricKey", | ||
"symmetricKey": { | ||
"primaryKey": "<primary key>", | ||
"secondaryKey": "<secondary key>" | ||
} | ||
} | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"type": "symmetricKey", | ||
"symmetricKey": { | ||
"primaryKey": "<primary key>", | ||
"secondaryKey": "<secondary key>" | ||
} | ||
} | ||
} | ||
} | ||
} |
26 changes: 26 additions & 0 deletions
26
...plane/Microsoft.IoTCentral/preview/1.1-preview/examples/devices_attestations_set_tpm.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
{ | ||
"title": "Set device attestation - TPM", | ||
"description": "Creates or updates the TPM attestation for a device.", | ||
"parameters": { | ||
"baseDomain": "azureiotcentral.com", | ||
"subdomain": "appsubdomain", | ||
"deviceId": "CheckoutThermostat", | ||
"api-version": "1.1-preview", | ||
"body": { | ||
"type": "tpm", | ||
"tpm": { | ||
"endorsementKey": "<endorsement key>" | ||
} | ||
} | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"type": "tpm", | ||
"tpm": { | ||
"endorsementKey": "<endorsement key>" | ||
} | ||
} | ||
} | ||
} | ||
} |
36 changes: 36 additions & 0 deletions
36
...lane/Microsoft.IoTCentral/preview/1.1-preview/examples/devices_attestations_set_x509.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
{ | ||
"title": "Set device attestation - X509", | ||
"description": "Creates or updates the X509 attestation for a device.", | ||
"parameters": { | ||
"baseDomain": "azureiotcentral.com", | ||
"subdomain": "appsubdomain", | ||
"deviceId": "CheckoutThermostat", | ||
"api-version": "1.1-preview", | ||
"body": { | ||
"type": "x509", | ||
"x509": { | ||
"clientCertificates": { | ||
"primary": { | ||
"certificate": "<string representation of the certificate>" | ||
} | ||
} | ||
} | ||
} | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"type": "x509", | ||
"x509": { | ||
"clientCertificates": { | ||
"primary": { | ||
"info": { | ||
"sha1Thumbprint": "<thumbprint>" | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} |
22 changes: 22 additions & 0 deletions
22
...l/data-plane/Microsoft.IoTCentral/preview/1.1-preview/examples/devices_commands_send.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
{ | ||
"title": "Send command", | ||
"description": "Send a command to a device.", | ||
"parameters": { | ||
"baseDomain": "azureiotcentral.com", | ||
"subdomain": "appsubdomain", | ||
"deviceId": "mx1", | ||
"componentName": "Thermostat_1o", | ||
"commandName": "CoolDown", | ||
"api-version": "1.1-preview", | ||
"body": { | ||
"request": { | ||
"tempVal": 30 | ||
} | ||
} | ||
}, | ||
"responses": { | ||
"201": { | ||
"body": {} | ||
} | ||
} | ||
} |
26 changes: 26 additions & 0 deletions
26
...-plane/Microsoft.IoTCentral/preview/1.1-preview/examples/devices_commandshistory_get.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
{ | ||
"title": "Get command history", | ||
"description": "Get the most recent invocation of a command of a device.", | ||
"parameters": { | ||
"baseDomain": "azureiotcentral.com", | ||
"subdomain": "appsubdomain", | ||
"deviceId": "mx1", | ||
"componentName": "Thermostat_1o", | ||
"commandName": "CoolDown", | ||
"api-version": "1.1-preview" | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"value": [ | ||
{ | ||
"request": 20, | ||
"id": "4e17dd2e-7bf2-458d-8466-19bc6fc9b642", | ||
"response": 58.795679629034694, | ||
"responseCode": 200 | ||
} | ||
] | ||
} | ||
} | ||
} | ||
} |
32 changes: 32 additions & 0 deletions
32
.../data-plane/Microsoft.IoTCentral/preview/1.1-preview/examples/devices_components_get.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
{ | ||
"title": "Get components from a device", | ||
"description": "Get the list of components in a device.", | ||
"parameters": { | ||
"baseDomain": "azureiotcentral.com", | ||
"subdomain": "appsubdomain", | ||
"deviceId": "device1", | ||
"api-version": "1.1-preview" | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"value": [ | ||
{ | ||
"@id": "<id>", | ||
"@type": [ | ||
"Component" | ||
], | ||
"name": "LocationTracking" | ||
}, | ||
{ | ||
"@id": "<id>", | ||
"@type": [ | ||
"Component" | ||
], | ||
"name": "EnvironmentSensing" | ||
} | ||
] | ||
} | ||
} | ||
} | ||
} |
Oops, something went wrong.