[]
        
(Showing Draft Content)

Admin

Admin

[DELETE] /api/v2/admin/approvers

Remove all the approver roles and abandon their ACLs when the document draft is disabled

Responses

[204] No Content

[400] Bad Request

ServerPluginError

Type: [application/json]

[GET] /api/v2/admin/knowledge-base

Get all knowledge base files

Responses

[200] Returns the list of knowledge base files

KnowledgeViewModel

Type: [text/plain], [application/json], [text/json]

[400] If there was an error retrieving the knowledge base files

ServerPluginError

Type: [text/plain], [application/json], [text/json]

[POST] /api/v2/admin/knowledge-base

Upload a new knowledge base file

Request Body

Type: multipart/form-data

Key Type Format Encoding
file string binary form

Responses

[200] Returns the created knowledge base file information

KnowledgeViewModel

Type: [text/plain], [application/json], [text/json]

[400] If the file is empty, invalid type, too large, or there was an error uploading

ServerPluginError

Type: [text/plain], [application/json], [text/json]

[GET] /api/v2/admin/knowledge-base/{id}/download

Parameters

Name In Type Description
idRequired path string The ID of the knowledge base file

Download a knowledge base file

Responses

[200] Returns the file content

binary

Type: [text/plain], [application/json], [text/json]

[400] There was an error with downloading

ServerPluginError

Type: [text/plain], [application/json], [text/json]

[404] The knowledge base was not found

ServerPluginError

Type: [text/plain], [application/json], [text/json]

[DELETE] /api/v2/admin/knowledge-base/{id}

Parameters

Name In Type Description
idRequired path string The ID of the knowledge base file to delete

Delete a knowledge base file

Responses

[204] If the file was successfully deleted

[400] There was an error deleting

ServerPluginError

Type: [text/plain], [application/json], [text/json]

[404] The knowledge base was not found

ServerPluginError

Type: [text/plain], [application/json], [text/json]

[POST] /api/v2/admin/knowledge-base/{id}/rename

Parameters

Name In Type Description
idRequired path string The ID of the knowledge base file to rename

Rename a knowledge base file

Request Body

Description: The rename request containing the new name

Type: application/json

KnowledgeRenameMode

Responses

[200] Returns the updated knowledge base file information

KnowledgeViewModel

Type: [text/plain], [application/json], [text/json]

[400] There was an error with renaming

ServerPluginError

Type: [text/plain], [application/json], [text/json]

[404] The knowledge base was not found

[GET] /api/v2/admin/knowledge-base/search

Parameters

Name In Type Description
query query string Search query string

Search knowledge base content

Responses

[200] Returns the list of search results

KnowledgeSearchResultViewModel

Type: [text/plain], [application/json], [text/json]

[400] If an error occurs during the search process

ServerPluginError

Type: [text/plain], [application/json], [text/json]

Models

Ƭ ServerPluginError

Server plugin error

Name Type Description
codeNullable string error code
messageNullable string error message
contextNullable string error context
innerError ServerPluginError
extensionsNullable any Extended result

Ƭ KnowledgeViewModel

Knowledge View Model

Name Type Description
idNullable string Id
nameNullable string Name
typeNullable string Type
size int64 Size
createTime ISO DateTime Sting CreateTime

Ƭ KnowledgeRenameMode

Name Type
newNameNullable string

Ƭ KnowledgeSearchResultViewModel

Name Type
resultsNullable Array<KnowledgeSearchResultViewModel+SearchResultItem>

Ƭ KnowledgeSearchResultViewModel+SearchResultItem

Name Type
score any
resultNullable string