> ## Documentation Index
> Fetch the complete documentation index at: https://klef.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# AccountStatuses

> An account's status, as a policy asks for it and a read reports it, mapped to and from the field that shows it.

```csharp
public static class AccountStatuses
```

## Fields

**Key** `string` *required*

The key a policy sets the status by.

## Methods

### Parse()

```csharp
public static PrincipalStatus? Parse(string? name)
```

Reads a status from its name, or [null](https://learn.microsoft.com/dotnet/csharp/language-reference/keywords/null) when the name is none.

#### Parameters

**name** `string` *required*

#### Returns

`Nullable<PrincipalStatus>`

### Read()

```csharp
public static Principal Read(AccountObjectManifest account, Principal principal)
```

Sets an account's status from the field that shows it, when the connector reported none.

#### Parameters

**account** `AccountObjectManifest` *required*

**principal** `Principal` *required*

#### Returns

`Principal`

### Write()

```csharp
public static DesiredPrincipal Write(AccountObjectManifest account, DesiredPrincipal desired)
```

Writes an enabled or disabled status into the field that shows it. A field holding an enum value takes only `disabled`, since the field does not say which value enables.

#### Parameters

**account** `AccountObjectManifest` *required*

**desired** `DesiredPrincipal` *required*

#### Returns

`DesiredPrincipal`


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.