newo 2.0.6 → 3.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +338 -224
- package/README.md +257 -0
- package/dist/api.d.ts +23 -1
- package/dist/api.js +114 -0
- package/dist/auth.js +4 -0
- package/dist/cli/commands/create-agent.d.ts +3 -0
- package/dist/cli/commands/create-agent.js +75 -0
- package/dist/cli/commands/create-attribute.d.ts +3 -0
- package/dist/cli/commands/create-attribute.js +63 -0
- package/dist/cli/commands/create-event.d.ts +3 -0
- package/dist/cli/commands/create-event.js +66 -0
- package/dist/cli/commands/create-flow.d.ts +3 -0
- package/dist/cli/commands/create-flow.js +100 -0
- package/dist/cli/commands/create-parameter.d.ts +3 -0
- package/dist/cli/commands/create-parameter.js +47 -0
- package/dist/cli/commands/create-persona.d.ts +3 -0
- package/dist/cli/commands/create-persona.js +43 -0
- package/dist/cli/commands/create-project.d.ts +3 -0
- package/dist/cli/commands/create-project.js +55 -0
- package/dist/cli/commands/create-skill.d.ts +3 -0
- package/dist/cli/commands/create-skill.js +115 -0
- package/dist/cli/commands/create-state.d.ts +3 -0
- package/dist/cli/commands/create-state.js +58 -0
- package/dist/cli/commands/delete-agent.d.ts +3 -0
- package/dist/cli/commands/delete-agent.js +70 -0
- package/dist/cli/commands/delete-flow.d.ts +3 -0
- package/dist/cli/commands/delete-flow.js +83 -0
- package/dist/cli/commands/delete-skill.d.ts +3 -0
- package/dist/cli/commands/delete-skill.js +87 -0
- package/dist/cli/commands/help.js +114 -22
- package/dist/cli/commands/push.js +4 -3
- package/dist/cli/commands/sandbox.d.ts +14 -0
- package/dist/cli/commands/sandbox.js +306 -0
- package/dist/cli.js +57 -0
- package/dist/sandbox/chat.d.ts +40 -0
- package/dist/sandbox/chat.js +280 -0
- package/dist/sync/push.d.ts +1 -1
- package/dist/sync/push.js +372 -4
- package/dist/sync/status.js +178 -1
- package/dist/types.d.ts +181 -1
- package/package.json +6 -3
- package/src/api.ts +172 -1
- package/src/auth.ts +7 -2
- package/src/cli/commands/create-agent.ts +96 -0
- package/src/cli/commands/create-attribute.ts +75 -0
- package/src/cli/commands/create-event.ts +79 -0
- package/src/cli/commands/create-flow.ts +124 -0
- package/src/cli/commands/create-parameter.ts +59 -0
- package/src/cli/commands/create-persona.ts +54 -0
- package/src/cli/commands/create-project.ts +66 -0
- package/src/cli/commands/create-skill.ts +144 -0
- package/src/cli/commands/create-state.ts +71 -0
- package/src/cli/commands/delete-agent.ts +90 -0
- package/src/cli/commands/delete-flow.ts +105 -0
- package/src/cli/commands/delete-skill.ts +110 -0
- package/src/cli/commands/help.ts +114 -22
- package/src/cli/commands/push.ts +5 -3
- package/src/cli/commands/sandbox.ts +365 -0
- package/src/cli.ts +71 -0
- package/src/sandbox/chat.ts +339 -0
- package/src/sync/push.ts +413 -5
- package/src/sync/status.ts +183 -1
- package/src/types.ts +220 -2
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Delete Flow Command Handler - Removes local folder structure
|
|
3
|
+
*/
|
|
4
|
+
import { requireSingleCustomer } from '../customer-selection.js';
|
|
5
|
+
import { ensureState, projectDir } from '../../fsutil.js';
|
|
6
|
+
import fs from 'fs-extra';
|
|
7
|
+
export async function handleDeleteFlowCommand(customerConfig, args, verbose = false) {
|
|
8
|
+
try {
|
|
9
|
+
const selectedCustomer = requireSingleCustomer(customerConfig, args.customer);
|
|
10
|
+
// Parse arguments
|
|
11
|
+
const flowIdn = args._[1];
|
|
12
|
+
const agentIdn = args.agent;
|
|
13
|
+
const projectIdn = args.project;
|
|
14
|
+
const confirm = args.confirm || args.y;
|
|
15
|
+
if (!flowIdn) {
|
|
16
|
+
console.error('Error: Flow IDN is required');
|
|
17
|
+
console.error('Usage: newo delete-flow <flow-idn> --agent <agent-idn> --project <project-idn> [--confirm]');
|
|
18
|
+
process.exit(1);
|
|
19
|
+
}
|
|
20
|
+
if (!agentIdn) {
|
|
21
|
+
console.error('Error: Agent IDN is required');
|
|
22
|
+
console.error('Usage: newo delete-flow <flow-idn> --agent <agent-idn> --project <project-idn> [--confirm]');
|
|
23
|
+
process.exit(1);
|
|
24
|
+
}
|
|
25
|
+
if (!projectIdn) {
|
|
26
|
+
console.error('Error: Project IDN is required');
|
|
27
|
+
console.error('Usage: newo delete-flow <flow-idn> --agent <agent-idn> --project <project-idn> [--confirm]');
|
|
28
|
+
process.exit(1);
|
|
29
|
+
}
|
|
30
|
+
// Ensure state directory exists
|
|
31
|
+
await ensureState(selectedCustomer.idn);
|
|
32
|
+
// Check if project exists locally
|
|
33
|
+
const projDir = projectDir(selectedCustomer.idn, projectIdn);
|
|
34
|
+
if (!(await fs.pathExists(projDir))) {
|
|
35
|
+
console.error(`❌ Project '${projectIdn}' not found locally. Run 'newo pull' first or check project IDN.`);
|
|
36
|
+
process.exit(1);
|
|
37
|
+
}
|
|
38
|
+
// Check if agent exists locally
|
|
39
|
+
const agentDir = `${projDir}/${agentIdn}`;
|
|
40
|
+
if (!(await fs.pathExists(agentDir))) {
|
|
41
|
+
console.error(`❌ Agent '${agentIdn}' not found in project '${projectIdn}'. Check agent IDN.`);
|
|
42
|
+
process.exit(1);
|
|
43
|
+
}
|
|
44
|
+
// Check if flow exists locally
|
|
45
|
+
const flowDir = `${agentDir}/${flowIdn}`;
|
|
46
|
+
if (!(await fs.pathExists(flowDir))) {
|
|
47
|
+
console.error(`❌ Flow '${flowIdn}' not found in agent '${agentIdn}'. Check flow IDN.`);
|
|
48
|
+
process.exit(1);
|
|
49
|
+
}
|
|
50
|
+
if (verbose) {
|
|
51
|
+
console.log(`🗑️ Deleting flow locally: ${flowIdn}`);
|
|
52
|
+
console.log(` Project: ${projectIdn}`);
|
|
53
|
+
console.log(` Agent: ${agentIdn}`);
|
|
54
|
+
}
|
|
55
|
+
// Safety confirmation
|
|
56
|
+
if (!confirm) {
|
|
57
|
+
console.log('⚠️ This will permanently delete the flow and all its skills locally.');
|
|
58
|
+
console.log('⚠️ Use --confirm flag to proceed with deletion.');
|
|
59
|
+
console.log('⚠️ Run "newo push" after deletion to remove from NEWO platform.');
|
|
60
|
+
process.exit(1);
|
|
61
|
+
}
|
|
62
|
+
// Check if flow has skills
|
|
63
|
+
const skillDirs = await fs.readdir(flowDir);
|
|
64
|
+
const skillCount = skillDirs.filter(async (item) => {
|
|
65
|
+
const itemPath = `${flowDir}/${item}`;
|
|
66
|
+
return (await fs.stat(itemPath)).isDirectory() && item !== 'metadata.yaml';
|
|
67
|
+
}).length;
|
|
68
|
+
if (skillCount > 0) {
|
|
69
|
+
console.log(`⚠️ Flow contains ${skillCount} skills that will also be deleted.`);
|
|
70
|
+
}
|
|
71
|
+
// Remove flow directory
|
|
72
|
+
await fs.remove(flowDir);
|
|
73
|
+
console.log(`✅ Flow deleted locally`);
|
|
74
|
+
console.log(` IDN: ${flowIdn}`);
|
|
75
|
+
console.log(` Path: ${flowDir}`);
|
|
76
|
+
console.log(` Run 'newo push' to delete from NEWO platform`);
|
|
77
|
+
}
|
|
78
|
+
catch (error) {
|
|
79
|
+
console.error('❌ Failed to delete flow locally:', error instanceof Error ? error.message : String(error));
|
|
80
|
+
process.exit(1);
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
//# sourceMappingURL=delete-flow.js.map
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Delete Skill Command Handler - Removes local folder structure
|
|
3
|
+
*/
|
|
4
|
+
import { requireSingleCustomer } from '../customer-selection.js';
|
|
5
|
+
import { ensureState, skillFolderPath, projectDir } from '../../fsutil.js';
|
|
6
|
+
import fs from 'fs-extra';
|
|
7
|
+
export async function handleDeleteSkillCommand(customerConfig, args, verbose = false) {
|
|
8
|
+
try {
|
|
9
|
+
const selectedCustomer = requireSingleCustomer(customerConfig, args.customer);
|
|
10
|
+
// Parse arguments
|
|
11
|
+
const skillIdn = args._[1];
|
|
12
|
+
const flowIdn = args.flow;
|
|
13
|
+
const agentIdn = args.agent;
|
|
14
|
+
const projectIdn = args.project;
|
|
15
|
+
const confirm = args.confirm || args.y;
|
|
16
|
+
if (!skillIdn) {
|
|
17
|
+
console.error('Error: Skill IDN is required');
|
|
18
|
+
console.error('Usage: newo delete-skill <skill-idn> --flow <flow-idn> --agent <agent-idn> --project <project-idn> [--confirm]');
|
|
19
|
+
process.exit(1);
|
|
20
|
+
}
|
|
21
|
+
if (!flowIdn) {
|
|
22
|
+
console.error('Error: Flow IDN is required');
|
|
23
|
+
console.error('Usage: newo delete-skill <skill-idn> --flow <flow-idn> --agent <agent-idn> --project <project-idn> [--confirm]');
|
|
24
|
+
process.exit(1);
|
|
25
|
+
}
|
|
26
|
+
if (!agentIdn) {
|
|
27
|
+
console.error('Error: Agent IDN is required');
|
|
28
|
+
console.error('Usage: newo delete-skill <skill-idn> --flow <flow-idn> --agent <agent-idn> --project <project-idn> [--confirm]');
|
|
29
|
+
process.exit(1);
|
|
30
|
+
}
|
|
31
|
+
if (!projectIdn) {
|
|
32
|
+
console.error('Error: Project IDN is required');
|
|
33
|
+
console.error('Usage: newo delete-skill <skill-idn> --flow <flow-idn> --agent <agent-idn> --project <project-idn> [--confirm]');
|
|
34
|
+
process.exit(1);
|
|
35
|
+
}
|
|
36
|
+
// Ensure state directory exists
|
|
37
|
+
await ensureState(selectedCustomer.idn);
|
|
38
|
+
// Check if project exists locally
|
|
39
|
+
const projDir = projectDir(selectedCustomer.idn, projectIdn);
|
|
40
|
+
if (!(await fs.pathExists(projDir))) {
|
|
41
|
+
console.error(`❌ Project '${projectIdn}' not found locally. Run 'newo pull' first or check project IDN.`);
|
|
42
|
+
process.exit(1);
|
|
43
|
+
}
|
|
44
|
+
// Check if agent exists locally
|
|
45
|
+
const agentDir = `${projDir}/${agentIdn}`;
|
|
46
|
+
if (!(await fs.pathExists(agentDir))) {
|
|
47
|
+
console.error(`❌ Agent '${agentIdn}' not found in project '${projectIdn}'. Check agent IDN.`);
|
|
48
|
+
process.exit(1);
|
|
49
|
+
}
|
|
50
|
+
// Check if flow exists locally
|
|
51
|
+
const flowDir = `${agentDir}/${flowIdn}`;
|
|
52
|
+
if (!(await fs.pathExists(flowDir))) {
|
|
53
|
+
console.error(`❌ Flow '${flowIdn}' not found in agent '${agentIdn}'. Check flow IDN.`);
|
|
54
|
+
process.exit(1);
|
|
55
|
+
}
|
|
56
|
+
// Check if skill exists locally
|
|
57
|
+
const skillDir = skillFolderPath(selectedCustomer.idn, projectIdn, agentIdn, flowIdn, skillIdn);
|
|
58
|
+
if (!(await fs.pathExists(skillDir))) {
|
|
59
|
+
console.error(`❌ Skill '${skillIdn}' not found in flow '${flowIdn}'. Check skill IDN.`);
|
|
60
|
+
process.exit(1);
|
|
61
|
+
}
|
|
62
|
+
if (verbose) {
|
|
63
|
+
console.log(`🗑️ Deleting skill locally: ${skillIdn}`);
|
|
64
|
+
console.log(` Project: ${projectIdn}`);
|
|
65
|
+
console.log(` Agent: ${agentIdn}`);
|
|
66
|
+
console.log(` Flow: ${flowIdn}`);
|
|
67
|
+
}
|
|
68
|
+
// Safety confirmation
|
|
69
|
+
if (!confirm) {
|
|
70
|
+
console.log('⚠️ This will permanently delete the skill locally.');
|
|
71
|
+
console.log('⚠️ Use --confirm flag to proceed with deletion.');
|
|
72
|
+
console.log('⚠️ Run "newo push" after deletion to remove from NEWO platform.');
|
|
73
|
+
process.exit(1);
|
|
74
|
+
}
|
|
75
|
+
// Remove skill directory
|
|
76
|
+
await fs.remove(skillDir);
|
|
77
|
+
console.log(`✅ Skill deleted locally`);
|
|
78
|
+
console.log(` IDN: ${skillIdn}`);
|
|
79
|
+
console.log(` Path: ${skillDir}`);
|
|
80
|
+
console.log(` Run 'newo push' to delete from NEWO platform`);
|
|
81
|
+
}
|
|
82
|
+
catch (error) {
|
|
83
|
+
console.error('❌ Failed to delete skill locally:', error instanceof Error ? error.message : String(error));
|
|
84
|
+
process.exit(1);
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
//# sourceMappingURL=delete-skill.js.map
|
|
@@ -3,48 +3,140 @@
|
|
|
3
3
|
*/
|
|
4
4
|
export function handleHelpCommand() {
|
|
5
5
|
console.log(`NEWO CLI - Multi-Customer Support
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
newo
|
|
6
|
+
A professional command-line tool for NEWO AI Agent development with modular architecture and comprehensive multi-customer support.
|
|
7
|
+
|
|
8
|
+
Core Commands:
|
|
9
|
+
newo pull [--customer <idn>] # download projects + attributes -> ./newo_customers/<idn>/
|
|
10
|
+
newo push [--customer <idn>] [--no-publish] # upload modified *.guidance/*.jinja + attributes back to NEWO, publish flows by default
|
|
11
|
+
newo status [--customer <idn>] # show modified files that would be pushed
|
|
10
12
|
newo conversations [--customer <idn>] [--all] # download user conversations -> ./newo_customers/<idn>/conversations.yaml
|
|
11
|
-
newo
|
|
12
|
-
newo
|
|
13
|
-
newo
|
|
13
|
+
newo sandbox "<message>" [--customer <idn>] # test agent in sandbox - single message mode (NEW v3.1.0)
|
|
14
|
+
newo sandbox --actor <id> "message" # continue existing sandbox conversation with chat ID
|
|
15
|
+
newo pull-attributes [--customer <idn>] # download customer attributes -> ./newo_customers/<idn>/attributes.yaml
|
|
16
|
+
newo list-customers # list available customers and their configuration
|
|
17
|
+
newo meta [--customer <idn>] # get project metadata (debug command)
|
|
18
|
+
newo import-akb <file> <persona_id> [--customer <idn>] # import AKB articles from structured text file
|
|
19
|
+
|
|
20
|
+
Project Management:
|
|
21
|
+
newo create-project <idn> [--title <title>] [--description <desc>] [--version <version>] [--auto-update] # create project on platform ✅
|
|
22
|
+
|
|
23
|
+
Entity Management (Full Lifecycle Support):
|
|
24
|
+
newo create-agent <idn> --project <project-idn> [--title <title>] [--description <desc>] # create agent → push to platform ✅
|
|
25
|
+
newo delete-agent <agent-idn> --project <project-idn> [--confirm] # delete agent locally (requires --confirm)
|
|
26
|
+
newo create-flow <idn> --agent <agent-idn> --project <project-idn> [--title <title>] [--description <desc>] [--runner <guidance|nsl>] # create flow → push to platform ✅
|
|
27
|
+
newo delete-flow <flow-idn> --agent <agent-idn> --project <project-idn> [--confirm] # delete flow locally (requires --confirm)
|
|
28
|
+
newo create-skill <idn> --flow <flow-idn> --agent <agent-idn> --project <project-idn> [--title <title>] [--script <content>] [--runner <guidance|nsl>] # create skill → push to platform ✅
|
|
29
|
+
newo delete-skill <skill-idn> --flow <flow-idn> --agent <agent-idn> --project <project-idn> [--confirm] # delete skill locally (requires --confirm)
|
|
30
|
+
|
|
31
|
+
Identity & Configuration:
|
|
32
|
+
newo create-persona <name> [--title <title>] [--description <desc>] # create agent persona ✅
|
|
33
|
+
newo create-attribute <idn> --value <value> [--title <title>] [--group <group>] [--value-type <string>] # create customer attribute ✅
|
|
34
|
+
|
|
35
|
+
Advanced Components (NSL Focus):
|
|
36
|
+
newo create-event <idn> --flow <flow-id> --skill <skill-idn> [--description <desc>] [--integration <api|system>] [--connector <webhook|system>] # create flow event ✅
|
|
37
|
+
newo create-state <idn> --flow <flow-id> [--title <title>] [--default-value <value>] [--scope <user|flow|global>] # create flow state ✅
|
|
38
|
+
newo create-parameter <name> --skill <skill-id> [--default-value <value>] # create skill parameter (API limitations)
|
|
39
|
+
|
|
40
|
+
Enterprise Features:
|
|
41
|
+
newo conversations [--customer <idn>] [--all] # download conversation history
|
|
42
|
+
newo pull-attributes [--customer <idn>] # sync customer attributes
|
|
43
|
+
newo import-akb <file> <persona_id> # import knowledge base articles
|
|
14
44
|
|
|
15
45
|
Flags:
|
|
16
46
|
--customer <idn> # specify customer (if not set, uses default or interactive selection)
|
|
17
47
|
--all # include all available data (for conversations: all personas and acts)
|
|
18
48
|
--force, -f # force overwrite without prompting (for pull command)
|
|
19
|
-
--verbose, -v # enable detailed logging
|
|
49
|
+
--verbose, -v # enable detailed logging and progress information
|
|
50
|
+
--quiet, -q # minimal output for automation (sandbox only)
|
|
51
|
+
--actor <id> # continue existing sandbox chat with actor/chat ID
|
|
52
|
+
--confirm # confirm destructive operations without prompting
|
|
53
|
+
--no-publish # skip automatic flow publishing during push operations
|
|
20
54
|
|
|
21
55
|
Environment Variables:
|
|
22
56
|
NEWO_BASE_URL # NEWO API base URL (default: https://app.newo.ai)
|
|
23
|
-
|
|
57
|
+
|
|
58
|
+
Single Customer:
|
|
59
|
+
NEWO_API_KEY # API key for single customer setup
|
|
60
|
+
NEWO_PROJECT_ID # Optional: specific project ID
|
|
61
|
+
|
|
62
|
+
Multi-Customer:
|
|
63
|
+
NEWO_API_KEYS # JSON array of API keys or key+project objects
|
|
64
|
+
NEWO_CUSTOMER_<IDN>_API_KEY # API key for specific customer <IDN>
|
|
24
65
|
NEWO_CUSTOMER_<IDN>_PROJECT_ID # Optional: specific project ID for customer
|
|
25
66
|
NEWO_DEFAULT_CUSTOMER # Optional: default customer to use
|
|
26
67
|
|
|
27
|
-
|
|
28
|
-
#
|
|
29
|
-
|
|
30
|
-
|
|
68
|
+
Configuration Examples:
|
|
69
|
+
# Single customer setup:
|
|
70
|
+
NEWO_API_KEY=your_api_key_here
|
|
71
|
+
|
|
72
|
+
# Multi-customer JSON array:
|
|
73
|
+
NEWO_API_KEYS=["key1", "key2", "key3"]
|
|
74
|
+
|
|
75
|
+
# Multi-customer with project IDs:
|
|
76
|
+
NEWO_API_KEYS=[{"key":"key1","project_id":"uuid1"}, {"key":"key2"}]
|
|
77
|
+
|
|
78
|
+
# Multi-customer individual variables:
|
|
79
|
+
NEWO_CUSTOMER_acme_API_KEY=acme_api_key_here
|
|
80
|
+
NEWO_CUSTOMER_globex_API_KEY=globex_api_key_here
|
|
31
81
|
NEWO_DEFAULT_CUSTOMER=acme
|
|
32
82
|
|
|
33
|
-
|
|
34
|
-
|
|
83
|
+
Usage Examples:
|
|
84
|
+
# Basic workflow:
|
|
85
|
+
newo pull # Download all projects and attributes
|
|
86
|
+
newo status # Check for local modifications
|
|
87
|
+
newo push # Upload changes back to NEWO
|
|
88
|
+
|
|
89
|
+
# Multi-customer operations:
|
|
35
90
|
newo pull --customer acme # Pull projects for Acme only
|
|
36
|
-
newo status # Status for all customers (if no default set)
|
|
37
|
-
newo push # Interactive selection for multiple customers
|
|
38
91
|
newo push --customer globex # Push changes for Globex only
|
|
92
|
+
newo conversations --all # Download all conversations with full history
|
|
93
|
+
|
|
94
|
+
# Complete weather system workflow (FULLY WORKING - NSL Focus):
|
|
95
|
+
newo create-project weather_system --title "Weather System" --description "Comprehensive weather service"
|
|
96
|
+
newo create-persona weather_persona --title "Weather Persona" --description "Professional weather assistant"
|
|
97
|
+
newo create-attribute weather_api_key --value "your_api_key" --group "Weather Config"
|
|
98
|
+
newo pull # Sync new project locally
|
|
99
|
+
|
|
100
|
+
newo create-agent WeatherBot --project weather_system --title "Weather Bot" --persona-id <persona-id>
|
|
101
|
+
newo create-flow MainFlow --agent WeatherBot --project weather_system --title "Main Flow" --runner nsl
|
|
102
|
+
newo push && newo pull # Creates agent + flow, syncs IDs
|
|
103
|
+
|
|
104
|
+
newo create-skill WeatherSkill --flow MainFlow --agent WeatherBot --project weather_system --title "Weather NSL Skill" --runner nsl
|
|
105
|
+
newo create-event user_message --flow <flow-id> --skill WeatherSkill --integration api --connector webhook
|
|
106
|
+
newo create-state user_location --flow <flow-id> --title "User Location" --scope user
|
|
107
|
+
newo create-state request_count --flow <flow-id> --title "Request Count" --scope flow
|
|
108
|
+
newo push # Creates complete system
|
|
109
|
+
newo status # Should show: Clean
|
|
110
|
+
|
|
111
|
+
# Import AKB articles:
|
|
112
|
+
newo import-akb articles.txt da4550db-2b95-4500-91ff-fb4b60fe7be9
|
|
113
|
+
|
|
114
|
+
# Sandbox testing (NEW v3.1.0):
|
|
115
|
+
newo sandbox "Hello, I want to order pizza" # Start new conversation
|
|
116
|
+
newo sandbox --actor abc123... "I want 2 large pizzas" # Continue conversation
|
|
117
|
+
newo sandbox "Test query" --verbose # With debug info
|
|
118
|
+
newo sandbox "Test query" --quiet # For automation/scripts
|
|
39
119
|
|
|
40
120
|
File Structure:
|
|
41
121
|
newo_customers/
|
|
42
|
-
├──
|
|
122
|
+
├── <customer-idn>/
|
|
123
|
+
│ ├── attributes.yaml # Customer attributes (pull-attributes)
|
|
124
|
+
│ ├── conversations.yaml # User conversations and personas
|
|
43
125
|
│ └── projects/
|
|
44
|
-
│ └──
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
126
|
+
│ └── <project-idn>/
|
|
127
|
+
│ ├── flows.yaml # Auto-generated project structure
|
|
128
|
+
│ ├── metadata.yaml # Project metadata
|
|
129
|
+
│ └── <agent-idn>/
|
|
130
|
+
│ ├── metadata.yaml # Agent metadata
|
|
131
|
+
│ └── <flow-idn>/
|
|
132
|
+
│ ├── metadata.yaml # Flow metadata
|
|
133
|
+
│ └── <skill-idn>/
|
|
134
|
+
│ ├── skill.guidance # AI guidance scripts
|
|
135
|
+
│ ├── skill.jinja # NSL/Jinja template scripts
|
|
136
|
+
│ └── metadata.yaml # Skill metadata
|
|
137
|
+
└── .newo/ # CLI state and mappings (auto-generated)
|
|
138
|
+
|
|
139
|
+
For more information, visit: https://github.com/sabbah13/newo-cli
|
|
48
140
|
`);
|
|
49
141
|
}
|
|
50
142
|
//# sourceMappingURL=help.js.map
|
|
@@ -7,11 +7,12 @@ import { getValidAccessToken } from '../../auth.js';
|
|
|
7
7
|
import { selectSingleCustomer, interactiveCustomerSelection } from '../customer-selection.js';
|
|
8
8
|
export async function handlePushCommand(customerConfig, args, verbose) {
|
|
9
9
|
const { selectedCustomer, allCustomers, isMultiCustomer } = selectSingleCustomer(customerConfig, args.customer);
|
|
10
|
+
const shouldPublish = !args['no-publish'];
|
|
10
11
|
if (selectedCustomer) {
|
|
11
12
|
// Single customer push
|
|
12
13
|
const accessToken = await getValidAccessToken(selectedCustomer);
|
|
13
14
|
const client = await makeClient(verbose, accessToken);
|
|
14
|
-
await pushChanged(client, selectedCustomer, verbose);
|
|
15
|
+
await pushChanged(client, selectedCustomer, verbose, shouldPublish);
|
|
15
16
|
}
|
|
16
17
|
else if (isMultiCustomer) {
|
|
17
18
|
// Multiple customers exist with no default, ask user
|
|
@@ -21,7 +22,7 @@ export async function handlePushCommand(customerConfig, args, verbose) {
|
|
|
21
22
|
const customer = customersToProcess[0];
|
|
22
23
|
const accessToken = await getValidAccessToken(customer);
|
|
23
24
|
const client = await makeClient(verbose, accessToken);
|
|
24
|
-
await pushChanged(client, customer, verbose);
|
|
25
|
+
await pushChanged(client, customer, verbose, shouldPublish);
|
|
25
26
|
}
|
|
26
27
|
else {
|
|
27
28
|
// Multi-customer push (user selected "All customers")
|
|
@@ -30,7 +31,7 @@ export async function handlePushCommand(customerConfig, args, verbose) {
|
|
|
30
31
|
console.log(`\n📤 Pushing for customer: ${customer.idn}`);
|
|
31
32
|
const accessToken = await getValidAccessToken(customer);
|
|
32
33
|
const client = await makeClient(verbose, accessToken);
|
|
33
|
-
await pushChanged(client, customer, verbose);
|
|
34
|
+
await pushChanged(client, customer, verbose, shouldPublish);
|
|
34
35
|
}
|
|
35
36
|
console.log(`\n✅ Push completed for all ${customersToProcess.length} customers`);
|
|
36
37
|
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Sandbox Chat Command Handler
|
|
3
|
+
* Supports both single-command and interactive modes
|
|
4
|
+
*/
|
|
5
|
+
import type { MultiCustomerConfig, CliArgs } from '../../types.js';
|
|
6
|
+
/**
|
|
7
|
+
* Handle sandbox command
|
|
8
|
+
* Usage:
|
|
9
|
+
* npx newo sandbox "Hello" --customer <idn> # Single message mode
|
|
10
|
+
* npx newo sandbox --actor <actor_id> "Follow up" # Continue existing chat
|
|
11
|
+
* npx newo sandbox --interactive # Interactive mode (TBD)
|
|
12
|
+
*/
|
|
13
|
+
export declare function handleSandboxCommand(customerConfig: MultiCustomerConfig, args: CliArgs, verbose: boolean): Promise<void>;
|
|
14
|
+
//# sourceMappingURL=sandbox.d.ts.map
|