diff --git a/specification/iotcentral/data-plane/Microsoft.IoTCentral/preview/2019-10-28-preview/examples/devicecredentials_get.json b/specification/iotcentral/data-plane/Microsoft.IoTCentral/preview/2019-10-28-preview/examples/devicecredentials_get.json index 451ef32d72c5..fca7fc82f2c1 100644 --- a/specification/iotcentral/data-plane/Microsoft.IoTCentral/preview/2019-10-28-preview/examples/devicecredentials_get.json +++ b/specification/iotcentral/data-plane/Microsoft.IoTCentral/preview/2019-10-28-preview/examples/devicecredentials_get.json @@ -9,7 +9,7 @@ "responses": { "200": { "body": { - "idScope": "0ne0005F266", + "idScope": "", "symmetricKey": { "primaryKey": "XaMfV3vryCQw963L2IALf1SdApQRzSIBQd13/fassqM=", "secondaryKey": "s+4uT31TRZJcTSGxZUPZb1yznjTicu4jr9tXNrg+xIQ=" diff --git a/specification/iotcentral/data-plane/Microsoft.IoTCentral/preview/2019-10-28-preview/examples/devices_attestations_set_symmetricKey.json b/specification/iotcentral/data-plane/Microsoft.IoTCentral/preview/2019-10-28-preview/examples/devices_attestations_set_symmetricKey.json new file mode 100644 index 000000000000..42fdabd7c518 --- /dev/null +++ b/specification/iotcentral/data-plane/Microsoft.IoTCentral/preview/2019-10-28-preview/examples/devices_attestations_set_symmetricKey.json @@ -0,0 +1,27 @@ +{ + "title": "Set device attestation - Symmetric key", + "description": "Creates or updates the symmetric key attestation for a device.", + "parameters": { + "centralDnsSuffixInPath": "azureiotcentral.com", + "subdomain": "appsubdomain", + "device_id": "CheckoutThermostat", + "body": { + "type": "SymmetricKeyAttestation", + "symmetricKey": { + "primaryKey": "XaMfV3vryCQw963L2IALf1SdApQRzSIBQd13/fassqM=", + "secondaryKey": "s+4uT31TRZJcTSGxZUPZb1yznjTicu4jr9tXNrg+xIQ=" + } + } + }, + "responses": { + "200": { + "body": { + "type": "SymmetricKeyAttestation", + "symmetricKey": { + "primaryKey": "XaMfV3vryCQw963L2IALf1SdApQRzSIBQd13/fassqM=", + "secondaryKey": "s+4uT31TRZJcTSGxZUPZb1yznjTicu4jr9tXNrg+xIQ=" + } + } + } + } +} diff --git a/specification/iotcentral/data-plane/Microsoft.IoTCentral/preview/2019-10-28-preview/examples/devices_attestations_set_tpm.json b/specification/iotcentral/data-plane/Microsoft.IoTCentral/preview/2019-10-28-preview/examples/devices_attestations_set_tpm.json new file mode 100644 index 000000000000..35fb1496150d --- /dev/null +++ b/specification/iotcentral/data-plane/Microsoft.IoTCentral/preview/2019-10-28-preview/examples/devices_attestations_set_tpm.json @@ -0,0 +1,25 @@ +{ + "title": "Set device attestation - TPM", + "description": "Creates or updates the TPM attestation for a device.", + "parameters": { + "centralDnsSuffixInPath": "azureiotcentral.com", + "subdomain": "appsubdomain", + "device_id": "CheckoutThermostat", + "body": { + "type": "TpmAttestation", + "tpm": { + "endorsementKey": "AToAAQALAAMAsgAgg3GXZ0SEs/gakMyNRqXXJP1S124GUgtk8qHaGzMUaaoABgCAAEMAEAgAAAAAAAEAxsj2gUScTk1UjuioeTlfGYZrrimExB+bScH75adUMRIi2UOMxG1kw4y+9RW/IVoMl4e620VxZad0ARX2gUqVjYO7KPVt3dyKhZS3dkcvfBisBhP1XH9B33VqHG9SHnbnQXdBUaCgKAfxome8UmBKfe+naTsE5fkvjb/do3/dD6l4sGBwFCnKRdln4XpM03zLpoHFao8zOwt8l/uP3qUIxmCYv9A7m69Ms+5/pCkTu/rK4mRDsfhZ0QLfbzVI6zQFOKF/rwsfBtFeWlWtcuJMKlXdD8TXWElTzgh7JS4qhFzreL0c1mI0GCj+Aws0usZh7dLIVPnlgZcBhgy1SSDQMQ==" + } + } + }, + "responses": { + "200": { + "body": { + "type": "TpmAttestation", + "tpm": { + "endorsementKey": "AToAAQALAAMAsgAgg3GXZ0SEs/gakMyNRqXXJP1S124GUgtk8qHaGzMUaaoABgCAAEMAEAgAAAAAAAEAxsj2gUScTk1UjuioeTlfGYZrrimExB+bScH75adUMRIi2UOMxG1kw4y+9RW/IVoMl4e620VxZad0ARX2gUqVjYO7KPVt3dyKhZS3dkcvfBisBhP1XH9B33VqHG9SHnbnQXdBUaCgKAfxome8UmBKfe+naTsE5fkvjb/do3/dD6l4sGBwFCnKRdln4XpM03zLpoHFao8zOwt8l/uP3qUIxmCYv9A7m69Ms+5/pCkTu/rK4mRDsfhZ0QLfbzVI6zQFOKF/rwsfBtFeWlWtcuJMKlXdD8TXWElTzgh7JS4qhFzreL0c1mI0GCj+Aws0usZh7dLIVPnlgZcBhgy1SSDQMQ==" + } + } + } + } +} diff --git a/specification/iotcentral/data-plane/Microsoft.IoTCentral/preview/2019-10-28-preview/examples/devices_attestations_set.json b/specification/iotcentral/data-plane/Microsoft.IoTCentral/preview/2019-10-28-preview/examples/devices_attestations_set_x509.json similarity index 85% rename from specification/iotcentral/data-plane/Microsoft.IoTCentral/preview/2019-10-28-preview/examples/devices_attestations_set.json rename to specification/iotcentral/data-plane/Microsoft.IoTCentral/preview/2019-10-28-preview/examples/devices_attestations_set_x509.json index e86eff41a42d..c468cbb516a1 100644 --- a/specification/iotcentral/data-plane/Microsoft.IoTCentral/preview/2019-10-28-preview/examples/devices_attestations_set.json +++ b/specification/iotcentral/data-plane/Microsoft.IoTCentral/preview/2019-10-28-preview/examples/devices_attestations_set_x509.json @@ -1,6 +1,6 @@ { - "title": "Set device attestation", - "description": "Creates or updates the attestation for a device.", + "title": "Set device attestation - X509", + "description": "Creates or updates the X509 attestation for a device.", "parameters": { "centralDnsSuffixInPath": "azureiotcentral.com", "subdomain": "appsubdomain", diff --git a/specification/iotcentral/data-plane/Microsoft.IoTCentral/preview/2019-10-28-preview/iotcentral.json b/specification/iotcentral/data-plane/Microsoft.IoTCentral/preview/2019-10-28-preview/iotcentral.json index 6fb9f5835b06..4603ceb86cb8 100644 --- a/specification/iotcentral/data-plane/Microsoft.IoTCentral/preview/2019-10-28-preview/iotcentral.json +++ b/specification/iotcentral/data-plane/Microsoft.IoTCentral/preview/2019-10-28-preview/iotcentral.json @@ -76,6 +76,7 @@ "discriminator": "type" }, "SymmetricKeyAttestation": { + "x-ms-discriminator-value": "SymmetricKeyAttestation", "allOf": [ { "$ref": "#/definitions/Attestation" @@ -95,6 +96,7 @@ ] }, "X509Attestation": { + "x-ms-discriminator-value": "X509Attestation", "allOf": [ { "$ref": "#/definitions/Attestation" @@ -114,6 +116,7 @@ ] }, "TpmAttestation": { + "x-ms-discriminator-value": "TpmAttestation", "allOf": [ { "$ref": "#/definitions/Attestation" @@ -1549,8 +1552,14 @@ } ], "x-ms-examples": { - "Create or update device attestation": { - "$ref": "./examples/devices_attestations_set.json" + "Create or update device attestation - Symmetric Key": { + "$ref": "./examples/devices_attestations_set_symmetricKey.json" + }, + "Create or update device attestation - X509": { + "$ref": "./examples/devices_attestations_set_x509.json" + }, + "Create or update device attestation - TPM": { + "$ref": "./examples/devices_attestations_set_tpm.json" } }, "responses": {