Build Agentic workflows, RAG pipelines, with rich AI model and tool support on one collaborative workspace. Deploy on cloud, VPC, or self-hosted, so teams move from prototype to production without rebuilding the stack.
Python agentagentic-aiagentic-frameworkagentic-workflowaiautomationclaudedeepseekgenaigptllmlow-codemcpnextjsno-codeopenaipythonskillsworkflow
import type { TFunction } from 'i18next'
import type { CardVariant } from '../use-credential-panel-state'
export function getButtonConfig(
variant: CardVariant,
hasCredentials: boolean,
t: TFunction<['common', 'modelProvider']>,
) {
if (variant === 'api-required-add') {
return {
text: t(($) => $['modelProvider.auth.addApiKey'], { ns: 'modelProvider' }),
variant: 'primary' as const,
}
}
if (variant === 'api-required-configure') {
return {
text: t(($) => $['operation.config'], { ns: 'common' }),
variant: 'primary' as const,
}
}
const text = hasCredentials
? t(($) => $['operation.config'], { ns: 'common' })
: t(($) => $['modelProvider.auth.addApiKey'], { ns: 'modelProvider' })
return { text, variant: 'secondary' as const }
}