From 5c1fe457601469c6200bcc52b4b937b05384849c Mon Sep 17 00:00:00 2001 From: Ajit Kumar Saini Date: Mon, 11 May 2026 18:59:37 +0530 Subject: [PATCH] fix: update broken AI documentation link (#20401) ## Summary Updated the broken AI documentation link in `AiChatApiKeyNotConfiguredMessage.tsx`. ## Changes * Replaced outdated self-hosting AI docs URL * Updated link to a valid self-hosting documentation page Fixes #20071 --------- Co-authored-by: Charles Bochet --- .../AiChatApiKeyNotConfiguredMessage.tsx | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/packages/twenty-front/src/modules/ai/components/AiChatApiKeyNotConfiguredMessage.tsx b/packages/twenty-front/src/modules/ai/components/AiChatApiKeyNotConfiguredMessage.tsx index 3c32900ad4..488db26e0a 100644 --- a/packages/twenty-front/src/modules/ai/components/AiChatApiKeyNotConfiguredMessage.tsx +++ b/packages/twenty-front/src/modules/ai/components/AiChatApiKeyNotConfiguredMessage.tsx @@ -1,13 +1,20 @@ import { AiChatBanner } from '@/ai/components/AiChatBanner'; +import { currentWorkspaceMemberState } from '@/auth/states/currentWorkspaceMemberState'; +import { getDocumentationUrl } from '@/support/utils/getDocumentationUrl'; +import { useAtomStateValue } from '@/ui/utilities/state/jotai/hooks/useAtomStateValue'; import { t } from '@lingui/core/macro'; +import { DOCUMENTATION_PATHS } from 'twenty-shared/constants'; import { IconExternalLink } from 'twenty-ui/display'; -const DOCS_URL = - 'https://twenty.com/developers/section/self-hosting/self-hosting-var#ai-features'; - export const AiChatApiKeyNotConfiguredMessage = () => { + const currentWorkspaceMember = useAtomStateValue(currentWorkspaceMemberState); + const handleDocsClick = () => { - window.open(DOCS_URL, '_blank', 'noopener,noreferrer'); + const docsUrl = getDocumentationUrl({ + locale: currentWorkspaceMember?.locale, + path: DOCUMENTATION_PATHS.DEVELOPERS_SELF_HOST_CAPABILITIES_SETUP, + }); + window.open(docsUrl, '_blank', 'noopener,noreferrer'); }; return (