Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
servers/genesys-cloud-architect-mcp.js linguist-generated=true
bin/deploy-runner.js linguist-generated=true
servers/genesys-cloud-architect-mcp.js linguist-generated=true generated-code
bin/deploy-runner.js linguist-generated=true generated-code
2 changes: 2 additions & 0 deletions bin/deploy-runner.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "genesys-cloud-architect",
"version": "1.0.1",
"version": "1.0.2",
"private": true,
"packageManager": "pnpm@11.1.3+sha512.c85357fe17ca12dd23dd7071822666dfd7e3cb76fe214e3370b5ea2fb34f2a231185509b63e717f3cd0acb38dd3f8d82bcd5e8172400ae678b70ea4fbed0896d",
"scripts": {
Expand Down
12 changes: 7 additions & 5 deletions servers/genesys-cloud-architect-mcp.js

Large diffs are not rendered by default.

7 changes: 6 additions & 1 deletion skills/write-flow/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,16 +31,21 @@ The user's project must have the Architect Scripting SDK installed for type chec
npm install --save-dev purecloud-flow-scripting-api-sdk-javascript
```

## Deploy only (existing flow file)

If the user already has a flow file and just wants to deploy it, skip straight to **step 5** — call the `deploy_flow` MCP tool with the file path. Only fall back to steps 1–4 if deployment fails or the user asks for help writing/fixing the flow.

## Workflow

### 1. Understand the requirement

Ask the user:
- **Flow type**: inbound call, inbound chat, inbound email, inbound message (SMS), or workflow
- **What it should do**: routing, menus, greetings, queue transfers, data lookups, etc.
- **Queue names**: which Genesys Cloud queues to route to (must exist in the org)
- **Flow name**: what to name the flow in Architect

Only ask about queue names if the user's description involves queue transfers. Not every flow routes to a queue.

### 2. Read the relevant references

Before writing any flow code, read these reference files from this skill:
Expand Down
3 changes: 3 additions & 0 deletions src/deploy-runner/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -110,9 +110,12 @@ const origGet = https.get;
const origConsoleLog = console.log;
const tracePrefix = "TRACE:";

const SUPPRESSED_TRACES = [/Unknown feature being requested/];

function interceptTrace(text: string): boolean {
if (text.startsWith(tracePrefix)) {
const msg = text.slice(tracePrefix.length).trim();
if (SUPPRESSED_TRACES.some((p) => p.test(msg))) return true;
traces.push(msg);
emit("log", "info", msg);
return true;
Expand Down
16 changes: 13 additions & 3 deletions src/mcp-server/tools/deploy-flow.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@ export const deployFlow: ToolFactory<DeployFlowConfig> = (toolConfig) => ({
description:
"Deploys a Genesys Cloud Architect flow from a TypeScript file. " +
"The file must export an async buildFlow(scripting) function that " +
"creates and saves the flow using the Architect Scripting SDK.",
"creates and saves the flow using the Architect Scripting SDK. " +
'The project\'s package.json must have "type": "module" for the ES module import to work.',
annotations: {
title: "Deploy Flow",
readOnlyHint: false,
Expand Down Expand Up @@ -140,8 +141,17 @@ export const deployFlow: ToolFactory<DeployFlowConfig> = (toolConfig) => ({
}
}

if (stderrBuf.trim()) {
logs.push(`[stderr] ${stderrBuf.trim()}`);
const filteredStderr = stderrBuf
.split("\n")
.filter(
(l) =>
!l.includes("url.parse()") &&
!l.includes("[DEP0169]"),
)
.join("\n")
.trim();
if (filteredStderr) {
logs.push(`[stderr] ${filteredStderr}`);
}

const logOutput = logs.length
Expand Down