Share via


EnrollmentGroupsClient.GetAttestationAsync(String, CancellationToken) Method

Definition

Get an enrollment group's attestation information.

public System.Threading.Tasks.Task<Microsoft.Azure.Devices.Provisioning.Service.AttestationMechanism> GetAttestationAsync (string enrollmentGroupId, System.Threading.CancellationToken cancellationToken = default);
member this.GetAttestationAsync : string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Azure.Devices.Provisioning.Service.AttestationMechanism>
Public Function GetAttestationAsync (enrollmentGroupId As String, Optional cancellationToken As CancellationToken = Nothing) As Task(Of AttestationMechanism)

Parameters

enrollmentGroupId
String

The Id of the enrollment group.

cancellationToken
CancellationToken

The cancellation token.

Returns

The attestation mechanism of the enrollment group.

Exceptions

Microsoft.Azure.Devices.Provisioning.Service.DeviceProvisioningServiceException

If the service was not able to retrieve the enrollment group attestation information for the provided enrollmentGroupId.

If the provided enrollmentGroupId is null.

If the provided enrollmentGroupId is empty or white space.

If the service was not able to retrieve the enrollment group attestation information for the provided enrollmentGroupId.

If the provided cancellationToken has requested cancellation.

Applies to