2022-01-08 19:01:54 +08:00
|
|
|
POST {{triliumHost}}/etapi/create-note
|
2022-01-11 00:09:20 +08:00
|
|
|
Authorization: {{authToken}}
|
2022-01-08 19:01:54 +08:00
|
|
|
Content-Type: application/json
|
|
|
|
|
|
|
|
{
|
|
|
|
"parentNoteId": "root",
|
|
|
|
"title": "Hello",
|
|
|
|
"type": "code",
|
|
|
|
"mime": "text/plain",
|
|
|
|
"content": "Hi there!"
|
|
|
|
}
|
|
|
|
|
|
|
|
> {% client.global.set("createdNoteId", response.body.note.noteId); %}
|
|
|
|
|
|
|
|
###
|
|
|
|
|
|
|
|
PUT {{triliumHost}}/etapi/notes/{{createdNoteId}}/content
|
2022-01-11 00:09:20 +08:00
|
|
|
Authorization: {{authToken}}
|
2022-01-08 19:01:54 +08:00
|
|
|
Content-Type: text/plain
|
|
|
|
|
|
|
|
Changed content
|
|
|
|
|
2023-01-12 06:22:51 +08:00
|
|
|
> {% client.assert(response.status === 204); %}
|
2022-02-19 05:34:46 +08:00
|
|
|
|
2022-01-08 19:01:54 +08:00
|
|
|
###
|
|
|
|
|
|
|
|
GET {{triliumHost}}/etapi/notes/{{createdNoteId}}/content
|
2022-01-11 00:09:20 +08:00
|
|
|
Authorization: {{authToken}}
|
2022-01-08 19:01:54 +08:00
|
|
|
|
|
|
|
> {% client.assert(response.body === "Changed content"); %}
|