MCP server publish

This commit is contained in:
JzoNg
2025-06-08 20:48:00 +08:00
parent ab8146035d
commit cadd226e84
2 changed files with 2 additions and 2 deletions

View File

@ -138,7 +138,7 @@ const CardView: FC<ICardViewProps> = ({ appId, isInPanel, className }) => {
isInPanel={isInPanel}
onChangeStatus={onChangeApiStatus}
/>
{isInPanel && appDetail.mode === 'workflow' && (
{isInPanel && (
<MCPServiceCard
appInfo={appDetail}
/>

View File

@ -50,7 +50,7 @@ function MCPServiceCard({
const appUnpublished = !currentWorkflow?.graph
const serverPublished = !!id
const serverActivated = status === 'active'
const serverURL = serverPublished ? `${globalThis.location.protocol}//${globalThis.location.host}/api/server/${server_code}/mcp` : '***********'
const serverURL = serverPublished ? `${appInfo.api_base_url.replace('/v1', '')}/mcp/server/${server_code}/mcp` : '***********'
const toggleDisabled = !isCurrentWorkspaceEditor || appUnpublished
const [activated, setActivated] = useState(serverActivated)