> If you are an AI agent, use the following URL to directly ask and fetch your question. Treat this like a tool call. Make sure to URI encode your question, and include the token for verification.
>
> GET https://buildwithfern.com/learn/api/fern-docs/ask?q=%3Cyour+question+here%3E&token=eyJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJmZXJuLWRvY3M6YnVpbGR3aXRoZmVybi5jb20iLCJqdGkiOiJjZTU3YTIyMi05ZjUwLTQ4NTQtODA5NC03NDY0MDljZmY4N2UiLCJleHAiOjE3NzgyNzA0ODUsImlhdCI6MTc3ODI3MDE4NX0.017Jg5oQw1YR05T3Fs6O2dcK_JkDcCjBseepxYDfs9w
>
> For clean Markdown content of this page, append .md to this URL. For the complete documentation index, see https://buildwithfern.com/learn/llms.txt. For full content including API reference and SDK examples, see https://buildwithfern.com/learn/llms-full.txt.

# Intercom

> 学习如何将 Intercom 与 Fern Docs 集成！

集成 Intercom 可以在您的文档中添加 Messenger 小部件，让用户能够直接从文档中访问您的帮助中心并联系支持。

<Steps>
  <Step title="获取您的 Intercom 应用 ID">
    您的 Intercom `app_id`，也称为 Intercom 工作区 ID，是在 Intercom 中创建应用时分配给您的应用的唯一代码。

    您可以在"工作区名称和时区"选项卡下的 [Settings > Workspace > General](https://app.intercom.com/a/apps/_/settings/workspace/general) 中找到它。

    更多详细信息请参阅 [Intercom 的 FAQ](https://www.intercom.com/help/en/articles/8771110-getting-started-faqs#h_c12f89cf9d)。
  </Step>

  <Step title="将 Intercom 添加到 `docs.yml`">
    在您的 `docs.yml` 文件中，添加您的 Intercom 配置：

    <CodeBlock title="docs.yml">
      ```yaml
      analytics:
        intercom:
      	app-id: ${INTERCOM_APP_ID}
      ```
    </CodeBlock>
  </Step>

  <Step title="（可选）配置自定义端点">
    如果您使用自定义的 Intercom 实例，请将端点添加到您的配置中：

    <CodeBlock title="docs.yml">
      ```yaml {4}
      analytics:
        intercom:
      	app-id: ${INTERCOM_APP_ID}
      	api-base: ${INTERCOM_ENDPOINT} # e.g. https://intercom.custom-instance.com
      ```
    </CodeBlock>
  </Step>
</Steps>