SearXNG authorize issue although format: -json is allowed #7528

Closed
opened 2026-02-21 18:21:03 -05:00 by yindo · 4 comments
Owner

Originally created by @KitteeRusty on GitHub (Jan 5, 2025).

Self Checks

  • This is only for bug report, if you would like to ask a question, please head to Discussions.
  • I have searched for existing issues search for existing issues, including closed ones.
  • I confirm that I am using English to submit this report (我已阅读并同意 Language Policy).
  • [FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:)
  • Please do not modify this template :) and fill in all the required fields.

Dify version

v0.14.2

Cloud or Self Hosted

Cloud

Steps to reproduce

Authorizing SearXNG in Dify with http://(My server address):8080/
I checked the documentation to add json and json is indeed added in the settings.yml
截屏2025-01-06 11 24 29

✔️ Expected Behavior

Expect to authorize correctly

Actual Behavior

SearNXG Error 403: <!doctype html> <html lang=en>

Forbidden

You don't have the permission to access the requested resource. It is either read- protected or not readable by the server. </р>

Originally created by @KitteeRusty on GitHub (Jan 5, 2025). ### Self Checks - [X] This is only for bug report, if you would like to ask a question, please head to [Discussions](https://github.com/langgenius/dify/discussions/categories/general). - [X] I have searched for existing issues [search for existing issues](https://github.com/langgenius/dify/issues), including closed ones. - [X] I confirm that I am using English to submit this report (我已阅读并同意 [Language Policy](https://github.com/langgenius/dify/issues/1542)). - [X] [FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:) - [X] Please do not modify this template :) and fill in all the required fields. ### Dify version v0.14.2 ### Cloud or Self Hosted Cloud ### Steps to reproduce Authorizing SearXNG in Dify with http://(My server address):8080/ I checked the documentation to add json and json is indeed added in the settings.yml <img width="1470" alt="截屏2025-01-06 11 24 29" src="https://github.com/user-attachments/assets/268f6ea2-95f6-4115-9d60-9633a13905b3" /> ### ✔️ Expected Behavior Expect to authorize correctly ### ❌ Actual Behavior SearNXG Error 403: <!doctype html> <html lang=en> <title>403 Forbidden</title> <h1>Forbidden</h1> <p>You don't have the permission to access the requested resource. It is either read- protected or not readable by the server. </р>
yindo added the 🐞 bugcloud labels 2026-02-21 18:21:03 -05:00
yindo closed this issue 2026-02-21 18:21:03 -05:00
Author
Owner

@dosubot[bot] commented on GitHub (Jan 5, 2025):

I found a similar discussion that might be relevant to your issue: Set SearXNG Base URL Error 403. The issue was resolved by ensuring the correct format for the Authorization header, which should be 'Bearer '. Additionally, it was suggested to restart the container for changes to apply [1].

Make sure that your Authorization header is correctly formatted and that you have the necessary permissions. Also, consider restarting the container to ensure that any changes in the configuration are applied.

To continue talking to Dosu, mention @dosu.


Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Other

@dosubot[bot] commented on GitHub (Jan 5, 2025): <!-- Answer --> I found a similar discussion that might be relevant to your issue: [Set SearXNG Base URL Error 403](https://github.com/langgenius/dify/discussions/4599#discussioncomment-9538690). The issue was resolved by ensuring the correct format for the Authorization header, which should be 'Bearer <api-key>'. Additionally, it was suggested to restart the container for changes to apply <sup>[[1]](https://github.com/langgenius/dify/discussions/4599)</sup>. Make sure that your Authorization header is correctly formatted and that you have the necessary permissions. Also, consider restarting the container to ensure that any changes in the configuration are applied. <!-- Dosu Comment Footer --> *To continue talking to [Dosu](https://dosu.dev), mention @dosu.* --- <sup>Help Dosu learn! Give it feedback: [Great Response](https://app.dosu.dev/response-feedback/a0d40f76-3ae9-490c-992f-f6dafd3acf22?feedback_type=great_response) | [Irrelevant Answer](https://app.dosu.dev/response-feedback/a0d40f76-3ae9-490c-992f-f6dafd3acf22?feedback_type=irrelevant_answer) | [Incorrect Sources](https://app.dosu.dev/response-feedback/a0d40f76-3ae9-490c-992f-f6dafd3acf22?feedback_type=incorrect_sources) | [Too Verbose](https://app.dosu.dev/response-feedback/a0d40f76-3ae9-490c-992f-f6dafd3acf22?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/a0d40f76-3ae9-490c-992f-f6dafd3acf22?feedback_type=hallucination) | [Other](https://app.dosu.dev/response-feedback/a0d40f76-3ae9-490c-992f-f6dafd3acf22?feedback_type=other)</sup>
Author
Owner

@KitteeRusty commented on GitHub (Jan 5, 2025):

I've restarted docker with
sudo docker compose restart
but it isn't fixed

@KitteeRusty commented on GitHub (Jan 5, 2025): I've restarted docker with `sudo docker compose restart` but it isn't fixed
Author
Owner

@KitteeRusty commented on GitHub (Jan 5, 2025):

In the setting change the

formats:
   -json
   -html

into

search:
    formats:
        -json
        -html
@KitteeRusty commented on GitHub (Jan 5, 2025): In the setting change the ``` formats: -json -html ``` into ``` search: formats: -json -html ```
Author
Owner

@drummerglen commented on GitHub (Feb 10, 2025):

DO NOT MODIFY ANY SEARXNG SETTINGS.YML CONFIGURATION
REFER https://docs.dify.ai/guides/tools/tool-configuration/searxng

@drummerglen commented on GitHub (Feb 10, 2025): **DO NOT MODIFY ANY SEARXNG SETTINGS.YML CONFIGURATION** REFER https://docs.dify.ai/guides/tools/tool-configuration/searxng
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langgenius/dify#7528