Documents

Bnder API documentation for Documents. Read the API Overview to get started and learn more.

Get all documents

Gets all documents the specified guild. Can be filtered by project id and number of results limited. Defaults to 100 results maximum

GET/consumer/v1/guilds/guildId/documents
ParametersDescription
guildIdThe id of a discord guild
limitThe number of items to return
project_idThe ID of the project

Request body

empty

Response

Status: 200 - Documents retrieved

FieldTypeDescription
documentsarrayList of documents

Create a new document

Creates a new document in the specified guild

POST/consumer/v1/guilds/guildId/documents
ParametersDescription
guildIdThe id of a discord guild

Request body

FieldTypeDescription
project_idstringID of the project the document belongs to
titlestringTitle of the document
contentstringContent of the document
topic_idstringID of the topic the document belongs to
in_binbooleanWhether the document is in the bin
is_publicbooleanWhether the document is public

Response

Status: 200 - Document created

FieldTypeDescription
idstringID of the document
project_idstringID of the project the document belongs to
titlestringTitle of the document
contentstringContent of the document
topic_idstringID of the topic the document belongs to
in_binbooleanWhether the document is in the bin
delete_datestringDate the document will be deleted if in the bin
last_modifiedstringDate the document was last modified
is_publicbooleanWhether the document is public

Get a document

Gets the document data by id in the specified guild

GET/consumer/v1/guilds/guildId/documents/documentId
ParametersDescription
guildIdThe id of a discord guild
documentIdThe ID of the document

Request body

empty

Response

Status: 200 - Document retrieved

FieldTypeDescription
idstringID of the document
project_idstringID of the project the document belongs to
titlestringTitle of the document
contentstringContent of the document
topic_idstringID of the topic the document belongs to
in_binbooleanWhether the document is in the bin
delete_datestringDate the document will be deleted if in the bin
last_modifiedstringDate the document was last modified
is_publicbooleanWhether the document is public

Update a document

Updates a document in the specified guild

PUT/consumer/v1/guilds/guildId/documents/documentId
ParametersDescription
guildIdThe id of a discord guild
documentIdThe ID of the document

Request body

FieldTypeDescription
project_idstringThe project id
titlestringThe title of the document
contentstringThe content of the document
topic_idstringThe topic id
in_binbooleanIs the document in the bin
is_publicbooleanWhether the document is public
draft_titlestringThe draft title of the document
draft_contentstringThe draft content of the document

Response

Status: 200 - Document updated

FieldTypeDescription
idstringID of the document
project_idstringID of the project the document belongs to
titlestringTitle of the document
contentstringContent of the document
topic_idstringID of the topic the document belongs to
in_binbooleanWhether the document is in the bin
delete_datestringDate the document will be deleted if in the bin
last_modifiedstringDate the document was last modified
is_publicbooleanWhether the document is public

Delete a document

Deletes a document in the specified guild

DELETE/consumer/v1/guilds/guildId/documents/documentId
ParametersDescription
guildIdThe id of a discord guild
documentIdThe ID of the document

Request body

empty

Response

Status: 204 - Document deleted

empty response