Error when adding .doc file document extraction node. #12497

Closed
opened 2026-02-21 19:07:41 -05:00 by yindo · 5 comments
Owner

Originally created by @suntao2015005848 on GitHub (Apr 2, 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

1.1.2

Cloud or Self Hosted

Self Hosted (Docker)

Steps to reproduce

Error when adding .doc file document extraction node: UNSTRUCTURED_API_URL and UNSTRUCTURED_API_KEY must be set.

✔️ Expected Behavior

Actual Behavior

Image
Originally created by @suntao2015005848 on GitHub (Apr 2, 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 1.1.2 ### Cloud or Self Hosted Self Hosted (Docker) ### Steps to reproduce Error when adding .doc file document extraction node: UNSTRUCTURED_API_URL and UNSTRUCTURED_API_KEY must be set. ### ✔️ Expected Behavior ### ❌ Actual Behavior <img width="1332" alt="Image" src="https://github.com/user-attachments/assets/beb9c2c9-2e84-4a93-a3d3-31a29ccf4134" />
yindo closed this issue 2026-02-21 19:07:41 -05:00
Author
Owner

@dosubot[bot] commented on GitHub (Apr 2, 2025):

To resolve the error "UNSTRUCTURED_API_URL and UNSTRUCTURED_API_KEY must be set" when adding a .doc file document extraction node in Dify version 1.1.2 on a self-hosted Docker setup, you need to configure both UNSTRUCTURED_API_URL and UNSTRUCTURED_API_KEY in your environment. This is necessary because DOC files require the Unstructured API for text extraction, as they cannot be processed natively by Dify.

You can find these settings in the docker/.env.example file, where you need to specify the API URL and key under the Unstructured API configuration section. Make sure to set the ETL_TYPE to Unstructured if you are using the Unstructured.io file extraction scheme [1].

To continue talking to Dosu, mention @dosu.


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

@dosubot[bot] commented on GitHub (Apr 2, 2025): <!-- Answer --> To resolve the error "UNSTRUCTURED_API_URL and UNSTRUCTURED_API_KEY must be set" when adding a .doc file document extraction node in Dify version 1.1.2 on a self-hosted Docker setup, you need to configure both `UNSTRUCTURED_API_URL` and `UNSTRUCTURED_API_KEY` in your environment. This is necessary because DOC files require the Unstructured API for text extraction, as they cannot be processed natively by Dify. You can find these settings in the `docker/.env.example` file, where you need to specify the API URL and key under the Unstructured API configuration section. Make sure to set the `ETL_TYPE` to `Unstructured` if you are using the Unstructured.io file extraction scheme <sup>[[1]](https://github.com/langgenius/dify/issues/15178)</sup>. <!-- 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/8d521480-0496-4877-bc28-6ae4046789fa?feedback_type=great_response) | [Irrelevant Answer](https://app.dosu.dev/response-feedback/8d521480-0496-4877-bc28-6ae4046789fa?feedback_type=irrelevant_answer) | [Incorrect Sources](https://app.dosu.dev/response-feedback/8d521480-0496-4877-bc28-6ae4046789fa?feedback_type=incorrect_sources) | [Too Verbose](https://app.dosu.dev/response-feedback/8d521480-0496-4877-bc28-6ae4046789fa?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/8d521480-0496-4877-bc28-6ae4046789fa?feedback_type=hallucination) | [Bug Report](https://app.dosu.dev/response-feedback/8d521480-0496-4877-bc28-6ae4046789fa?feedback_type=bug_report) | [Other](https://app.dosu.dev/response-feedback/8d521480-0496-4877-bc28-6ae4046789fa?feedback_type=other)</sup>
Author
Owner

@suntao2015005848 commented on GitHub (Apr 2, 2025):

@dosu 如果我将ETL_TYPE=Unstructured还需要配置UNSTRUCTURED_API_URL,UNSTRUCTURED_API_KEY么?

@suntao2015005848 commented on GitHub (Apr 2, 2025): @dosu 如果我将ETL_TYPE=Unstructured还需要配置UNSTRUCTURED_API_URL,UNSTRUCTURED_API_KEY么?
Author
Owner

@dosubot[bot] commented on GitHub (Apr 2, 2025):

是的,如果将 ETL_TYPE 设置为 Unstructured,您仍然需要配置 UNSTRUCTURED_API_URLUNSTRUCTURED_API_KEY。当 ETL_TYPE 设置为 Unstructured 时,必须配置 Unstructured API 路径 [1][2]

To continue talking to Dosu, mention @dosu.


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

@dosubot[bot] commented on GitHub (Apr 2, 2025): <!-- Answer --> 是的,如果将 `ETL_TYPE` 设置为 `Unstructured`,您仍然需要配置 `UNSTRUCTURED_API_URL` 和 `UNSTRUCTURED_API_KEY`。当 `ETL_TYPE` 设置为 Unstructured 时,必须配置 Unstructured API 路径 <sup>[[1]](https://github.com/langgenius/dify/blob/main/docker/.env.example)</sup><sup>[[2]](https://github.com/langgenius/dify-docs/blob/main/jp/getting-started/install-self-hosted/environments.md)</sup>。 <!-- 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/fbbdee1c-101f-483e-ac5f-9303ffab333d?feedback_type=great_response) | [Irrelevant Answer](https://app.dosu.dev/response-feedback/fbbdee1c-101f-483e-ac5f-9303ffab333d?feedback_type=irrelevant_answer) | [Incorrect Sources](https://app.dosu.dev/response-feedback/fbbdee1c-101f-483e-ac5f-9303ffab333d?feedback_type=incorrect_sources) | [Too Verbose](https://app.dosu.dev/response-feedback/fbbdee1c-101f-483e-ac5f-9303ffab333d?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/fbbdee1c-101f-483e-ac5f-9303ffab333d?feedback_type=hallucination) | [Bug Report](https://app.dosu.dev/response-feedback/fbbdee1c-101f-483e-ac5f-9303ffab333d?feedback_type=bug_report) | [Other](https://app.dosu.dev/response-feedback/fbbdee1c-101f-483e-ac5f-9303ffab333d?feedback_type=other)</sup>
Author
Owner

@crazywoola commented on GitHub (Apr 3, 2025):

add doc support in knowledge base for unstructured (#17352)

@crazywoola commented on GitHub (Apr 3, 2025): add doc support in knowledge base for unstructured (#17352)
Author
Owner

@Silow9 commented on GitHub (Apr 11, 2025):

@dosu 如果我将ETL_TYPE=Unstructured还需要配置UNSTRUCTURED_API_URL,UNSTRUCTURED_API_KEY么?

If you want to use unstructured in local environment, you also need to install unstructured in your local environment and adjust the setting in .env file in dify to match it if you use dify by docker. If you want to connect dify to unstructured online version, you can just adjust the setting in .env file in dify and connect it to unstructured by api.

@Silow9 commented on GitHub (Apr 11, 2025): > [@dosu](https://github.com/dosu) 如果我将ETL_TYPE=Unstructured还需要配置UNSTRUCTURED_API_URL,UNSTRUCTURED_API_KEY么? If you want to use unstructured in local environment, you also need to install unstructured in your local environment and adjust the setting in .env file in dify to match it if you use dify by docker. If you want to connect dify to unstructured online version, you can just adjust the setting in .env file in dify and connect it to unstructured by api.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langgenius/dify#12497