Auth

Boost Note supports authentication using a bearer token. You can generate tokens in the 'Integrations' tab of the Settings modal.

To authenticate using the token pass it in an Authorization header as a bearer token.

Example:

curl -H 'Authorization: Bearer [YOUR_TOKEN]' "https://boostnote.io/api/docs"


Tokens are associated to the team it was generated on. This means you will only be able to access the resources of the team to which the token is associated and for which you have permission with each individual token.


Pagination

All 'List' endpoints allow for pagination.


Parameters

name

type

required

description

page

number

false

The page to retrieve. Defaults to 1

perPage

number

false

The amount of resources per page. Defaults to 100

Routes

Docs

Endpoints

  • GET /api/docs

  • POST /api/docs

  • PATCH /api/docs/:id

  • DELETE /api/docs:id

Document Object

interface Doc {
 id: string
 emoji: string
 head: {
  id: number
  title: string
  content: string
  createdAt: string
 }
 workspaceId: string
 parentFolderId?: string
 archivedAt: string | null
 createdAt: string
 updatedAt: string
}

List Documents

URL

GET /api/docs

Parameters

name

type

required

description

title

string

false

The documents title

archived

string ('true' | 'false')

false

Filter on whether the document is archived or not

workspaceId

string (UUID)

false

The workspace the document is in

parentFolderId

string (UUID)

false

The folder the document is in

orderBy

string ('createdAt' | 'updatedAt')

false

Order the results by either created date or last updated date

Response

interface ListDocsResponse { 
 docs: Doc[]
}

Create Document

URL

POST /api/docs

Parameters

name

type

required

description

title

string

true

The title of the document to be created

content

string

true

The initial content of the document to be created

workspaceId

string (UUID)

false

The workspace to create the document in. If empty the document will be created in the team's default workspace

parentFolder

string (UUID)

false

The folder to create the document in. If this is passed with workspaceId the folder must be in that workspace

tags

string

string[]

false

Response

interface CreateDocResponse {
 doc: Doc
}

Get A Document

URL

GET /api/docs/:id

Response

interface GetDocResponse {
 doc: Doc
}

Update A Document

URL

PATCH /api/docs/:id

Parameters

name

type

required

description

title

string

false

New title of the document

content

string

false

New content of the document

emoji

string

false

New emoji of dht document

workspaceId

string (UUID)

false

The workspace to move the document to

parentFolder

string (UUID)

false

The folder to move the document to. If this is passed with workspaceId the folder must be in that workspace

Response

interface UpdateDocResponse {
 doc: Doc
}

Delete A Document

URL

DELETE /api/docs/:id

Response

Returns an empty 200 response for a successful deletion

Folders

Endpoints

  • GET /api/folders

  • POST /api/folders

  • GET /api/folders/:id

  • DELETE /api/folders/:id

Folder Object

interface Folder { 
 id: string
 name: string
 pathname: string
 emoji: string
 childDocsIds: string[]
 childFolderIds: string[]
 teamId: string
 workspaceId: string
 parentFolderId?: string
 createdAt: string
 updatedAt: string
}


List Folders

URL

GET /api/folders

Parameters

name

type

required

description

name

string

false

Name of the folder

workspaceId

string (UUID)

false

The workspace the folder is in

parentFolder

string (UUID)

false

The parent folder of the folder

orderBy

string ('createdAt' | 'updatedAt' )

false

Sort list by either createdAt or updatedAt field

Response

interface ListFoldersResponse {
 folders: Folder[]
}



Create A Folder

URL

POST /api/folders

Parameters

name

type

required

description

name

string

true

Name of the folder to be created

emoji

string

false

Emoji for the folder to be created

workspaceId

string (UUID)

false

Workspace in which to create folder

parentFolderId

string(UUID)

false

Folder in which to create folder. If passed with workspaceId folder must be in that workspace

Either workspaceId or parentFolderId MUST be passed.

Response

interface CreateFolderResponse {
 folder: Folder
}

Get A Folder

URL

GET /api/folders/:id


Response

interface GetFolderResponse {
folder: Doc
}

Delete A Folder

Delete a folder. If the folder has any contents it will fail with a 409 Conflict unless the force parameter is passed.

URL

DELETE /api/folder/:id

Parameters

name

type

required

description

force

string ('true' | 'false')

false

If passed and is 'true', it will delete the folder along with all it's contents. (This is not recoverable)

Response

Responds with and empty 200 if delete is successful

Did this answer your question?