logout.http 622 B

12345678910111213141516171819202122232425262728293031323334
  1. POST {{triliumHost}}/etapi/auth/login
  2. Content-Type: application/json
  3. {
  4. "password": "1234"
  5. }
  6. > {%
  7. client.assert(response.status === 201);
  8. client.global.set("testAuthToken", response.body.authToken);
  9. %}
  10. ###
  11. GET {{triliumHost}}/etapi/notes/root
  12. Authorization: {{testAuthToken}}
  13. > {% client.assert(response.status === 200); %}
  14. ###
  15. POST {{triliumHost}}/etapi/auth/logout
  16. Authorization: {{testAuthToken}}
  17. Content-Type: application/json
  18. > {% client.assert(response.status === 204); %}
  19. ###
  20. GET {{triliumHost}}/etapi/notes/root
  21. Authorization: {{testAuthToken}}
  22. > {% client.assert(response.status === 401); %}