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

## EndSessionResponseFormatterDecorator Class

A decorator class that adds session management functionality to the End Session response formatting process\.

```csharp
public class EndSessionResponseFormatterDecorator : Abblix.Oidc.Server.Mvc.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-mvc/Abblix.Oidc.Server.Mvc.Formatters.Interfaces.IEndSessionResponseFormatter 'Abblix\.Oidc\.Server\.Mvc\.Formatters\.Interfaces\.IEndSessionResponseFormatter')
### Constructors

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

A decorator class that adds session management functionality to the End Session response formatting process\.

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

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

The inner End Session response formatter\.

###### `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.Mvc.Features.SessionManagement.EndSessionResponseFormatterDecorator.EndSessionResponseFormatterDecorator(Abblix.Oidc.Server.Mvc.Formatters.Interfaces.IEndSessionResponseFormatter,Abblix.Oidc.Server.Features.SessionManagement.ISessionManagementService).sessionManagementService}

The service responsible for session management\.
### Methods

## EndSessionResponseFormatterDecorator\.FormatResponseAsync\(EndSessionRequest, Result\<EndSessionSuccess,OidcError\>\) Method {#Abblix.Oidc.Server.Mvc.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 an End Session response and performs session management operations if enabled\.

```csharp
public System.Threading.Tasks.Task<Microsoft.AspNetCore.Mvc.ActionResult> 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.Mvc.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}

The End Session 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.Mvc.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}

The End Session response to be formatted\.

Implements [FormatResponseAsync\(EndSessionRequest, Result&lt;EndSessionSuccess,OidcError&gt;\)](https://www.abblix.com/en/docs/api/abblix-oidc-server-mvc/Abblix.Oidc.Server.Mvc.Formatters.Interfaces.IEndSessionResponseFormatter#Abblix.Oidc.Server.Mvc.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\.Mvc\.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\.Mvc\.ActionResult](https://learn.microsoft.com/en-us/dotnet/api/microsoft.aspnetcore.mvc.actionresult 'Microsoft\.AspNetCore\.Mvc\.ActionResult')[&gt;](https://learn.microsoft.com/en-us/dotnet/api/system.threading.tasks.task-1 'System\.Threading\.Tasks\.Task\`1')  
A [System\.Threading\.Tasks\.Task&lt;&gt;](https://learn.microsoft.com/en-us/dotnet/api/system.threading.tasks.task-1 'System\.Threading\.Tasks\.Task\`1') representing the asynchronous operation\. The task result contains
the formatted ActionResult, with additional session management actions if enabled\.
