Skip to content

Commit

Permalink
Merge pull request #103 from sendbird/feat/setup-secret-key
Browse files Browse the repository at this point in the history
chore: setup chat-ai-widget-key via Circle CI
  • Loading branch information
AhyoungRyu authored Mar 4, 2024
2 parents 893f48b + 42b4f05 commit 959af4b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
3 changes: 2 additions & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,8 @@ workflows:
--build-arg VITE_CHAT_WIDGET_APP_ID=AE8F7EEA-4555-4F86-AD8B-5E0BD86BFE67 \
--build-arg VITE_CHAT_WIDGET_BOT_ID=khan-academy-bot \
--build-arg VITE_WEB_DEMO_APP_ID=6E1B01A5-517F-4F68-A74A-8427F3DE904C \
--build-arg VITE_WIDGET_DEMO_APP_ID=58F00FA8-C48E-461D-975E-18D33C8778AB
--build-arg VITE_WIDGET_DEMO_APP_ID=58F00FA8-C48E-461D-975E-18D33C8778AB \
--build-arg VITE_CHAT_AI_WIDGET_KEY=$CHAT_AI_WIDGET_KEY
context:
- circleci-dashboard-bot
- push_arch_integrated_manifest:
Expand Down
4 changes: 3 additions & 1 deletion packages/self-service/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import '@sendbird/chat-ai-widget/dist/style.css';
import { ChatAiWidget } from '@sendbird/chat-ai-widget';

import { uuid } from './utils';
const CHAT_AI_WIDGET_KEY = import.meta.env.VITE_CHAT_AI_WIDGET_KEY;

type ChatbotConfig = Window &
typeof globalThis & {
Expand All @@ -23,7 +24,8 @@ function App() {
enableEmojiFeedback={false}
enableMention={false}
customUserAgentParam={{
'chat-ai-widget-deployed': 'True'
'chat-ai-widget-deployed': 'True',
'chat-ai-widget-key': CHAT_AI_WIDGET_KEY,
}}
/>
);
Expand Down

0 comments on commit 959af4b

Please sign in to comment.