mirror of
https://github.com/zadam/trilium.git
synced 2025-01-04 06:13:36 +08:00
34 lines
625 B
Text
34 lines
625 B
Text
|
POST {{triliumHost}}/etapi/auth/login
|
||
|
Content-Type: application/json
|
||
|
|
||
|
{
|
||
|
"password": "1234"
|
||
|
}
|
||
|
|
||
|
> {%
|
||
|
client.assert(response.status === 200);
|
||
|
|
||
|
client.global.set("testAuthToken", response.body.authToken);
|
||
|
%}
|
||
|
|
||
|
###
|
||
|
|
||
|
GET {{triliumHost}}/etapi/notes/root
|
||
|
Authorization: {{testAuthToken}}
|
||
|
|
||
|
> {% client.assert(response.status === 200); %}
|
||
|
|
||
|
###
|
||
|
|
||
|
POST {{triliumHost}}/etapi/auth/logout
|
||
|
Authorization: {{testAuthToken}}
|
||
|
Content-Type: application/json
|
||
|
|
||
|
> {% client.assert(response.status === 204); %}
|
||
|
|
||
|
###
|
||
|
|
||
|
GET {{triliumHost}}/etapi/notes/root
|
||
|
Authorization: {{testAuthToken}}
|
||
|
|
||
|
> {% client.assert(response.status === 401); %}
|