#### [Abblix\.Oidc\.Server](https://www.abblix.com/en/docs/api/abblix-oidc-server 'index')
### [Abblix\.Oidc\.Server\.Features\.DeviceAuthorization](https://www.abblix.com/en/docs/api/abblix-oidc-server/Abblix.Oidc.Server.Features.DeviceAuthorization 'Abblix\.Oidc\.Server\.Features\.DeviceAuthorization')

## DeviceAuthorizationRequest Class

Represents a stored device authorization request as defined in RFC 8628\.
This record is used to persist the state of a device authorization flow
between the initial request and when the user completes authentication\.

```csharp
public record DeviceAuthorizationRequest : System.IEquatable<Abblix.Oidc.Server.Features.DeviceAuthorization.DeviceAuthorizationRequest>
```

Inheritance [System\.Object](https://learn.microsoft.com/en-us/dotnet/api/system.object 'System\.Object') → DeviceAuthorizationRequest

Implements [System\.IEquatable&lt;](https://learn.microsoft.com/en-us/dotnet/api/system.iequatable-1 'System\.IEquatable\`1')[DeviceAuthorizationRequest](https://www.abblix.com/en/docs/api/abblix-oidc-server/Abblix.Oidc.Server.Features.DeviceAuthorization.DeviceAuthorizationRequest 'Abblix\.Oidc\.Server\.Features\.DeviceAuthorization\.DeviceAuthorizationRequest')[&gt;](https://learn.microsoft.com/en-us/dotnet/api/system.iequatable-1 'System\.IEquatable\`1')
### Constructors

## DeviceAuthorizationRequest\(string, string\[\], Uri\[\], string\) Constructor {#Abblix.Oidc.Server.Features.DeviceAuthorization.DeviceAuthorizationRequest.DeviceAuthorizationRequest(string,string[],System.Uri[],string)}

Represents a stored device authorization request as defined in RFC 8628\.
This record is used to persist the state of a device authorization flow
between the initial request and when the user completes authentication\.

```csharp
public DeviceAuthorizationRequest(string ClientId, string[] Scope, System.Uri[]? Resources, string UserCode);
```
#### Parameters

###### `ClientId` [System\.String](https://learn.microsoft.com/en-us/dotnet/api/system.string 'System\.String') {#Abblix.Oidc.Server.Features.DeviceAuthorization.DeviceAuthorizationRequest.DeviceAuthorizationRequest(string,string[],System.Uri[],string).ClientId}

The client identifier that initiated the device authorization request\.

###### `Scope` [System\.String](https://learn.microsoft.com/en-us/dotnet/api/system.string 'System\.String')[\[\]](https://learn.microsoft.com/en-us/dotnet/api/system.array 'System\.Array') {#Abblix.Oidc.Server.Features.DeviceAuthorization.DeviceAuthorizationRequest.DeviceAuthorizationRequest(string,string[],System.Uri[],string).Scope}

The requested scopes for the authorization\.

###### `Resources` [System\.Uri](https://learn.microsoft.com/en-us/dotnet/api/system.uri 'System\.Uri')[\[\]](https://learn.microsoft.com/en-us/dotnet/api/system.array 'System\.Array') {#Abblix.Oidc.Server.Features.DeviceAuthorization.DeviceAuthorizationRequest.DeviceAuthorizationRequest(string,string[],System.Uri[],string).Resources}

The requested resources \(RFC 8707\) for the authorization\.

###### `UserCode` [System\.String](https://learn.microsoft.com/en-us/dotnet/api/system.string 'System\.String') {#Abblix.Oidc.Server.Features.DeviceAuthorization.DeviceAuthorizationRequest.DeviceAuthorizationRequest(string,string[],System.Uri[],string).UserCode}

The user\-friendly code displayed to the user for verification\.
### Properties

## DeviceAuthorizationRequest\.AuthorizationDetails Property {#Abblix.Oidc.Server.Features.DeviceAuthorization.DeviceAuthorizationRequest.AuthorizationDetails}

RFC 9396 §3 Rich Authorization Requests array carried from the original
`/device_authorization` request\. The host's user\-verification step reads this
\(via [ValidUserCode](https://www.abblix.com/en/docs/api/abblix-oidc-server/Abblix.Oidc.Server.Features.DeviceAuthorization.ValidUserCode 'Abblix\.Oidc\.Server\.Features\.DeviceAuthorization\.ValidUserCode')\) to render structured consent, then threads it into
the [AuthorizedGrant](https://www.abblix.com/en/docs/api/abblix-oidc-server/Abblix.Oidc.Server.Features.DeviceAuthorization.DeviceAuthorizationRequest#Abblix.Oidc.Server.Features.DeviceAuthorization.DeviceAuthorizationRequest.AuthorizedGrant 'Abblix\.Oidc\.Server\.Features\.DeviceAuthorization\.DeviceAuthorizationRequest\.AuthorizedGrant')'s `AuthorizationContext` when approving;
the eventual access token issued via the device\-code grant emits the claim byte\-exact\.

```csharp
public System.Text.Json.Nodes.JsonArray? AuthorizationDetails { get; set; }
```

#### Property Value
[System\.Text\.Json\.Nodes\.JsonArray](https://learn.microsoft.com/en-us/dotnet/api/system.text.json.nodes.jsonarray 'System\.Text\.Json\.Nodes\.JsonArray')

## DeviceAuthorizationRequest\.AuthorizedGrant Property {#Abblix.Oidc.Server.Features.DeviceAuthorization.DeviceAuthorizationRequest.AuthorizedGrant}

The authorized grant containing the user's authentication session and authorization context\.
This is set when the user successfully authorizes the device\.

```csharp
public Abblix.Oidc.Server.Endpoints.Token.Interfaces.AuthorizedGrant? AuthorizedGrant { get; set; }
```

#### Property Value
[AuthorizedGrant](https://www.abblix.com/en/docs/api/abblix-oidc-server/Abblix.Oidc.Server.Endpoints.Token.Interfaces.AuthorizedGrant 'Abblix\.Oidc\.Server\.Endpoints\.Token\.Interfaces\.AuthorizedGrant')

## DeviceAuthorizationRequest\.ClientId Property {#Abblix.Oidc.Server.Features.DeviceAuthorization.DeviceAuthorizationRequest.ClientId}

The client identifier that initiated the device authorization request\.

```csharp
public string ClientId { get; init; }
```

#### Property Value
[System\.String](https://learn.microsoft.com/en-us/dotnet/api/system.string 'System\.String')

## DeviceAuthorizationRequest\.ExpiresAt Property {#Abblix.Oidc.Server.Features.DeviceAuthorization.DeviceAuthorizationRequest.ExpiresAt}

The absolute time when this device authorization request expires \(RFC 8628 §3\.2 fixed lifetime\)\.
Seeded by the storage on `StoreAsync` and used to cap the refreshed cache TTL at the remaining
lifetime, so regular polling cannot extend the code\.

```csharp
public System.DateTimeOffset ExpiresAt { get; set; }
```

#### Property Value
[System\.DateTimeOffset](https://learn.microsoft.com/en-us/dotnet/api/system.datetimeoffset 'System\.DateTimeOffset')

## DeviceAuthorizationRequest\.NextPollAt Property {#Abblix.Oidc.Server.Features.DeviceAuthorization.DeviceAuthorizationRequest.NextPollAt}

Specifies the next time the client should poll for updates regarding the authorization request\.
This helps manage the timing of polling requests and enforces rate limiting\.

```csharp
public System.Nullable<System.DateTimeOffset> NextPollAt { get; set; }
```

#### Property Value
[System\.Nullable&lt;](https://learn.microsoft.com/en-us/dotnet/api/system.nullable-1 'System\.Nullable\`1')[System\.DateTimeOffset](https://learn.microsoft.com/en-us/dotnet/api/system.datetimeoffset 'System\.DateTimeOffset')[&gt;](https://learn.microsoft.com/en-us/dotnet/api/system.nullable-1 'System\.Nullable\`1')

## DeviceAuthorizationRequest\.Resources Property {#Abblix.Oidc.Server.Features.DeviceAuthorization.DeviceAuthorizationRequest.Resources}

The requested resources \(RFC 8707\) for the authorization\.

```csharp
public System.Uri[]? Resources { get; init; }
```

#### Property Value
[System\.Uri](https://learn.microsoft.com/en-us/dotnet/api/system.uri 'System\.Uri')[\[\]](https://learn.microsoft.com/en-us/dotnet/api/system.array 'System\.Array')

## DeviceAuthorizationRequest\.Scope Property {#Abblix.Oidc.Server.Features.DeviceAuthorization.DeviceAuthorizationRequest.Scope}

The requested scopes for the authorization\.

```csharp
public string[] Scope { get; init; }
```

#### Property Value
[System\.String](https://learn.microsoft.com/en-us/dotnet/api/system.string 'System\.String')[\[\]](https://learn.microsoft.com/en-us/dotnet/api/system.array 'System\.Array')

## DeviceAuthorizationRequest\.Status Property {#Abblix.Oidc.Server.Features.DeviceAuthorization.DeviceAuthorizationRequest.Status}

Indicates the current status of the device authorization request\.
Defaults to Pending, reflecting that the user has not yet completed authentication\.

```csharp
public Abblix.Oidc.Server.Features.DeviceAuthorization.DeviceAuthorizationStatus Status { get; set; }
```

#### Property Value
[DeviceAuthorizationStatus](https://www.abblix.com/en/docs/api/abblix-oidc-server/Abblix.Oidc.Server.Features.DeviceAuthorization.DeviceAuthorizationStatus 'Abblix\.Oidc\.Server\.Features\.DeviceAuthorization\.DeviceAuthorizationStatus')

## DeviceAuthorizationRequest\.UserCode Property {#Abblix.Oidc.Server.Features.DeviceAuthorization.DeviceAuthorizationRequest.UserCode}

The user\-friendly code displayed to the user for verification\.

```csharp
public string UserCode { get; init; }
```

#### Property Value
[System\.String](https://learn.microsoft.com/en-us/dotnet/api/system.string 'System\.String')
