dullage / flatnotes

A self-hosted, database-less note taking web app that utilises a flat folder of markdown files for storage.
MIT License
1.5k stars 87 forks source link

API Authentication #243

Closed gufertum closed 2 months ago

gufertum commented 2 months ago

I'm sorry to ask here, but I cannot find any documentation on how to authenticate using the api. Related docs: https://demo.flatnotes.io/docs

dullage commented 2 months ago

Hey @gufertum. The auth endpoints won't be shown on the demo site, as auth is disabled on that instance. But if you have your own instance with auth enabled, you'll see an /api/token endpoint which can be used to get a token. The token then needs to be sent in the header of any authenticated requests, e.g. Authorization: Bearer <token>.

I hope this helps.

gufertum commented 2 months ago

Hi and thanks a lot. I missed that endpoint somehow. It's working fine and thanks again for the hint!