Skip to content
Snippets Groups Projects
Commit d0713e15 authored by timothycarambat's avatar timothycarambat
Browse files

patch response body for swagger

parent 76aa2a4f
No related branches found
No related tags found
No related merge requests found
......@@ -237,7 +237,7 @@ function apiDocumentEndpoints(app) {
example: {
"textContent": "This is the raw text that will be saved as a document in AnythingLLM.",
"metadata": {
"title": "This key is required. See in /server/endpoints/api/document/index.js:287"
"title": "This key is required. See in /server/endpoints/api/document/index.js:287",
keyOne: "valueOne",
keyTwo: "valueTwo",
etc: "etc"
......
......@@ -1012,7 +1012,27 @@
"description": "Internal Server Error"
}
},
"requestBody": {}
"requestBody": {
"description": "Text content and metadata of the file to be saved to the system. Use metadata-schema endpoint to get the possible metadata keys",
"required": true,
"type": "object",
"content": {
"application/json": {
"schema": {
"type": "object",
"example": {
"textContent": "This is the raw text that will be saved as a document in AnythingLLM.",
"metadata": {
"title": "This key is required. See in /server/endpoints/api/document/index.js:287",
"keyOne": "valueOne",
"keyTwo": "valueTwo",
"etc": "etc"
}
}
}
}
}
}
}
},
"/v1/documents": {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment