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

## EndSessionResponseFormatterDecorator Class

Decorates [IEndSessionResponseFormatter](https://www.abblix.com/en/docs/api/abblix-oidc-server-minimalapi/Abblix.Oidc.Server.MinimalApi.Formatters.Interfaces.IEndSessionResponseFormatter 'Abblix\.Oidc\.Server\.MinimalApi\.Formatters\.Interfaces\.IEndSessionResponseFormatter') to delete the session\-management cookie when session management
is enabled, so the browser's logged\-in state is cleared as part of logout\.

```csharp
public class EndSessionResponseFormatterDecorator : Abblix.Oidc.Server.MinimalApi.Formatters.Interfaces.IEndSessionResponseFormatter
```

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

Implements [IEndSessionResponseFormatter](https://www.abblix.com/en/docs/api/abblix-oidc-server-minimalapi/Abblix.Oidc.Server.MinimalApi.Formatters.Interfaces.IEndSessionResponseFormatter 'Abblix\.Oidc\.Server\.MinimalApi\.Formatters\.Interfaces\.IEndSessionResponseFormatter')
### Constructors

## EndSessionResponseFormatterDecorator\(IEndSessionResponseFormatter, ISessionManagementService\) Constructor {#Abblix.Oidc.Server.MinimalApi.Features.SessionManagement.EndSessionResponseFormatterDecorator.EndSessionResponseFormatterDecorator(Abblix.Oidc.Server.MinimalApi.Formatters.Interfaces.IEndSessionResponseFormatter,Abblix.Oidc.Server.Features.SessionManagement.ISessionManagementService)}

Decorates [IEndSessionResponseFormatter](https://www.abblix.com/en/docs/api/abblix-oidc-server-minimalapi/Abblix.Oidc.Server.MinimalApi.Formatters.Interfaces.IEndSessionResponseFormatter 'Abblix\.Oidc\.Server\.MinimalApi\.Formatters\.Interfaces\.IEndSessionResponseFormatter') to delete the session\-management cookie when session management
is enabled, so the browser's logged\-in state is cleared as part of logout\.

```csharp
public EndSessionResponseFormatterDecorator(Abblix.Oidc.Server.MinimalApi.Formatters.Interfaces.IEndSessionResponseFormatter inner, Abblix.Oidc.Server.Features.SessionManagement.ISessionManagementService sessionManagementService);
```
#### Parameters

###### `inner` [IEndSessionResponseFormatter](https://www.abblix.com/en/docs/api/abblix-oidc-server-minimalapi/Abblix.Oidc.Server.MinimalApi.Formatters.Interfaces.IEndSessionResponseFormatter 'Abblix\.Oidc\.Server\.MinimalApi\.Formatters\.Interfaces\.IEndSessionResponseFormatter') {#Abblix.Oidc.Server.MinimalApi.Features.SessionManagement.EndSessionResponseFormatterDecorator.EndSessionResponseFormatterDecorator(Abblix.Oidc.Server.MinimalApi.Formatters.Interfaces.IEndSessionResponseFormatter,Abblix.Oidc.Server.Features.SessionManagement.ISessionManagementService).inner}

###### `sessionManagementService` [ISessionManagementService](https://www.abblix.com/en/docs/api/abblix-oidc-server/Abblix.Oidc.Server.Features.SessionManagement.ISessionManagementService 'Abblix\.Oidc\.Server\.Features\.SessionManagement\.ISessionManagementService') {#Abblix.Oidc.Server.MinimalApi.Features.SessionManagement.EndSessionResponseFormatterDecorator.EndSessionResponseFormatterDecorator(Abblix.Oidc.Server.MinimalApi.Formatters.Interfaces.IEndSessionResponseFormatter,Abblix.Oidc.Server.Features.SessionManagement.ISessionManagementService).sessionManagementService}
### Methods

## EndSessionResponseFormatterDecorator\.FormatResponseAsync\(EndSessionRequest, Result\<EndSessionSuccess,OidcError\>\) Method {#Abblix.Oidc.Server.MinimalApi.Features.SessionManagement.EndSessionResponseFormatterDecorator.FormatResponseAsync(Abblix.Oidc.Server.Model.EndSessionRequest,Abblix.Utils.Result_Abblix.Oidc.Server.Endpoints.EndSession.Interfaces.EndSessionSuccess,Abblix.Oidc.Server.Common.OidcError_)}

Formats the end\-session result: a front\-channel\-logout HTML page, a post\-logout redirect, an empty 204, or an
OAuth error\.

```csharp
public System.Threading.Tasks.Task<Microsoft.AspNetCore.Http.IResult> FormatResponseAsync(Abblix.Oidc.Server.Model.EndSessionRequest request, Abblix.Utils.Result<Abblix.Oidc.Server.Endpoints.EndSession.Interfaces.EndSessionSuccess,Abblix.Oidc.Server.Common.OidcError> response);
```
#### Parameters

###### `request` [EndSessionRequest](https://www.abblix.com/en/docs/api/abblix-oidc-server/Abblix.Oidc.Server.Model.EndSessionRequest 'Abblix\.Oidc\.Server\.Model\.EndSessionRequest') {#Abblix.Oidc.Server.MinimalApi.Features.SessionManagement.EndSessionResponseFormatterDecorator.FormatResponseAsync(Abblix.Oidc.Server.Model.EndSessionRequest,Abblix.Utils.Result_Abblix.Oidc.Server.Endpoints.EndSession.Interfaces.EndSessionSuccess,Abblix.Oidc.Server.Common.OidcError_).request}

###### `response` [Abblix\.Utils\.Result&lt;](https://www.abblix.com/en/docs/api/abblix-utils/Abblix.Utils.Result_TSuccess_TFailure_ 'Abblix\.Utils\.Result\`2')[EndSessionSuccess](https://www.abblix.com/en/docs/api/abblix-oidc-server/Abblix.Oidc.Server.Endpoints.EndSession.Interfaces.EndSessionSuccess 'Abblix\.Oidc\.Server\.Endpoints\.EndSession\.Interfaces\.EndSessionSuccess')[,](https://www.abblix.com/en/docs/api/abblix-utils/Abblix.Utils.Result_TSuccess_TFailure_ 'Abblix\.Utils\.Result\`2')[OidcError](https://www.abblix.com/en/docs/api/abblix-oidc-server/Abblix.Oidc.Server.Common.OidcError 'Abblix\.Oidc\.Server\.Common\.OidcError')[&gt;](https://www.abblix.com/en/docs/api/abblix-utils/Abblix.Utils.Result_TSuccess_TFailure_ 'Abblix\.Utils\.Result\`2') {#Abblix.Oidc.Server.MinimalApi.Features.SessionManagement.EndSessionResponseFormatterDecorator.FormatResponseAsync(Abblix.Oidc.Server.Model.EndSessionRequest,Abblix.Utils.Result_Abblix.Oidc.Server.Endpoints.EndSession.Interfaces.EndSessionSuccess,Abblix.Oidc.Server.Common.OidcError_).response}

Implements [FormatResponseAsync\(EndSessionRequest, Result&lt;EndSessionSuccess,OidcError&gt;\)](https://www.abblix.com/en/docs/api/abblix-oidc-server-minimalapi/Abblix.Oidc.Server.MinimalApi.Formatters.Interfaces.IEndSessionResponseFormatter#Abblix.Oidc.Server.MinimalApi.Formatters.Interfaces.IEndSessionResponseFormatter.FormatResponseAsync(Abblix.Oidc.Server.Model.EndSessionRequest,Abblix.Utils.Result_Abblix.Oidc.Server.Endpoints.EndSession.Interfaces.EndSessionSuccess,Abblix.Oidc.Server.Common.OidcError_) 'Abblix\.Oidc\.Server\.MinimalApi\.Formatters\.Interfaces\.IEndSessionResponseFormatter\.FormatResponseAsync\(Abblix\.Oidc\.Server\.Model\.EndSessionRequest, Abblix\.Utils\.Result\<Abblix\.Oidc\.Server\.Endpoints\.EndSession\.Interfaces\.EndSessionSuccess,Abblix\.Oidc\.Server\.Common\.OidcError\>\)')

#### Returns
[System\.Threading\.Tasks\.Task&lt;](https://learn.microsoft.com/en-us/dotnet/api/system.threading.tasks.task-1 'System\.Threading\.Tasks\.Task\`1')[Microsoft\.AspNetCore\.Http\.IResult](https://learn.microsoft.com/en-us/dotnet/api/microsoft.aspnetcore.http.iresult 'Microsoft\.AspNetCore\.Http\.IResult')[&gt;](https://learn.microsoft.com/en-us/dotnet/api/system.threading.tasks.task-1 'System\.Threading\.Tasks\.Task\`1')
