Difference between revisions of "REST API:logout Resource"
From LongJump Support Wiki
imported>Aeric |
imported>Aeric |
||
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
Performs a [[Logout]] action via the [[REST API]] | Performs a [[Logout]] action via the [[REST API]] | ||
;Method:GET | ;Method:GET | ||
;URI:<tt> | ;URI:<tt>{{platformURL}}/rest/logout</tt> | ||
;Response: | ;Response: |
Latest revision as of 22:03, 30 March 2012
Performs a Logout action via the REST API
- Method
- GET
- URI
- https://na.longjump.com/networking/rest/logout
- Response
<platform> <message> <code>0</code> <description>Success</description> </message> </platform>
- Sample Logout Code
This code taken from the BaseClient sample shows how to make a REST logout request. (It ignores HTTP return codes, because the goal is to log out, and pretty much the only way to get an error would be if the session had already terminated.)
public void logout() { System.out.println("Logging out"); String url = baseUrl + "/networking/rest/logout"; Resource logoutResource = this.client.resource(url); logoutResource.accept("application/xml").get(); }