POST /api/login/logout

Destroys any authentication cookies associated with the current session for a tenant logging out.

Since this operation ends the user's session with the Akana API Platform, there is no response content.

Note: we recommend using the GET /api/login/endsession operation, rather than this operation which will be deprecated.

Authorization Roles/Permissions: Must be logged in.

This topic includes the following sections:

HTTP Method

POST

URL

https://{hostname}/api/login/logout

Sample Request

The example below logs the user out.

Sample request URL

https://{hostname}/api/login/logout?fedmemberId=acmepaymentscorp

Sample request headers

POST /api/login/logout HTTP/1.1
Host: {hostname}
Accept: application/json, text/javascript, */*; q=0.01
Content-Type: application/x-www-form-urlencoded

Request Headers

For general information on request header values, refer to HTTP Request Headers.

Header Description
Accept

application/json, application/vnd.soa.v71+json, application/vnd.soa.v72+json, application/vnd.soa.v80+json, application/vnd.soa.v81+json

Note: Although this operation doesn't include any content in the response, the Accept header is required for forward compatibility with future versions.

Content-Type application/x-www-form-urlencoded

Request Parameters

Parameter Parm Type Data Type Required Description
FedmemberID Path String Optional

Unique ID for a specific tenant. Same as TenantID.

Required for federation scenarios, otherwise optional.

Response

If successful, this operation returns HTTP status code 200. There is no response body since this operation ends the user's session.

Sample Response

The sample response below shows that the logout completed successfully. The new set-cookie parameter expires the current cookie, effectively ending the user's Akana API Platform session.

Sample response header

HTTP/1.1 200 OK
Date: Wed, 06 Feb 2013 20:30:27 GMT
Set-Cookie: AtmoAuthToken=none;path=/;expires=Wed, 06-Feb-2013 15:30:27 GMT;HttpOnly;Version=1

Sample response body

None.

Response Headers

For general information on response header values, refer to HTTP Response Headers.

Header Description
Content-Type application/json, application/vnd.soa.v71+json, application/vnd.soa.v72+json, application/vnd.soa.v80+json, application/vnd.soa.v81+json
Set-Cookie The set-cookie response header sets, updates, or expires the platform cookie to reflect changes made by the operation. In this case, it expires the browser cookie.

Response Body

None.

Error Codes/Messages

If the call is unsuccessful an error code/message is returned. One or more examples of possible errors for this operation are shown below.

Item Value
500 An error occurred processing the call.

More information about Akana API Platform API error messages.