SessionsControllerDeleteCurrent - метод
Close current session determined by HTTP auth header or by token query parameter.
Returns flag whether session was present and was closed.
Пространство имён: Tessa.Web.ControllersСборка: Tessa.Web (в Tessa.Web.dll) Версия: 4.0.4
[HttpPostAttribute("close")]
[SessionMethodAttribute(UserAccessLevel.Regular)]
[ProducesAttribute("application/json", new string[] { ... })]
[ProducesResponseTypeAttribute(200)]
public Task<ActionResult<bool>> DeleteCurrent(
[FromQueryAttribute][SessionTokenAttribute] string? token = null,
[FromQueryAttribute] bool cookies = false,
CancellationToken cancellationToken = default
)
<HttpPostAttribute("close")>
<SessionMethodAttribute(UserAccessLevel.Regular)>
<ProducesAttribute("application/json", New String() { ... })>
<ProducesResponseTypeAttribute(200)>
Public Function DeleteCurrent (
<FromQueryAttribute><SessionTokenAttribute> Optional token As String = Nothing,
<FromQueryAttribute> Optional cookies As Boolean = false,
Optional cancellationToken As CancellationToken = Nothing
) As Task(Of ActionResult(Of Boolean))
public:
[HttpPostAttribute(L"close")]
[SessionMethodAttribute(UserAccessLevel::Regular)]
[ProducesAttribute(L"application/json", __gc new array<String^>^ { ... })]
[ProducesResponseTypeAttribute(200)]
Task<ActionResult<bool>^>^ DeleteCurrent(
[FromQueryAttribute][SessionTokenAttribute] String^ token = nullptr,
[FromQueryAttribute] bool cookies = false,
CancellationToken cancellationToken = CancellationToken()
)
[<HttpPostAttribute("close")>]
[<SessionMethodAttribute(UserAccessLevel.Regular)>]
[<ProducesAttribute("application/json", new string[] { ... })>]
[<ProducesResponseTypeAttribute(200)>]
member DeleteCurrent :
[<FromQueryAttribute>][<SessionTokenAttribute>] ?token : string *
[<FromQueryAttribute>] ?cookies : bool *
?cancellationToken : CancellationToken
(* Defaults:
let _token = defaultArg token null
let _cookies = defaultArg cookies false
let _cancellationToken = defaultArg cancellationToken new CancellationToken()
*)
-> Task<ActionResult<bool>>
- token String (Optional)
- Auth token to close the session. If passed then HTTP auth header is ignored.
- cookies Boolean (Optional)
-
Indication that client uses cookies for authentication, i.e. it is web client.
Parameter is ignored if current application does not support web clients.
- cancellationToken CancellationToken (Optional)
- Token to cancel async task.
TaskActionResultBooleantrue if session was present and was closed;
false otherwise.