Git sync the notes folder
POST
/sync
const url = 'http://127.0.0.1:7677/sync';const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url http://127.0.0.1:7677/sync \ --header 'Authorization: Bearer <token>'Runs git pull --rebase --autostash, then commits and pushes any
local changes. Fails if the notes folder is not a git repository.
Authorizations
Section titled “Authorizations ”Responses
Section titled “ Responses ”Sync result
Media type application/json
object
data
object
message
required
string
Example generated
{ "data": { "message": "example" }}