mirror of
https://github.com/langgenius/dify-docs-archived.git
synced 2026-07-25 05:25:44 -04:00
Example Response of External Knowledge API #26
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @zolgear on GitHub (Oct 9, 2024).
https://docs.dify.ai/guides/knowledge-base/external-knowledge-api-documentation
en\guides\knowledge-base\external-knowledge-api-documentation.md
There is an issue with the JSON response generated by Swagger.
The
recordsshould be an array, but it is represented with{ }. If implemented as is, it will result in a "500 Internal Server Error: 'str' object has no attribute 'get'" during the hit test in/app/api/controllers/console/datasets/external.py.Fix:
Can you modify
en\.gitbook\assets\Dify-test.openapi.jsonto fix it?@dosubot[bot] commented on GitHub (Oct 9, 2024):
To fix the issue with the
recordsfield in theDify-test.openapi.jsonfile, you need to modify the schema to ensurerecordsis an array. Here's how you can update it:Change the
recordsfield definition from an object to an array of objects:This change will ensure that the
recordsfield is correctly formatted as an array, preventing the "500 Internal Server Error" [1].To continue talking to Dosu, mention @dosu.
@zolgear commented on GitHub (Nov 1, 2024):
Thank you for making these changes.