@hubspot/cli 8.1.1-experimental.0 → 8.1.2-experimental.1
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/api/releases.d.ts +36 -0
- package/api/releases.js +41 -0
- package/commands/account/auth.js +2 -2
- package/commands/account/clean.js +2 -2
- package/commands/account/createOverride.js +2 -2
- package/commands/account/info.js +2 -2
- package/commands/account/link.js +2 -2
- package/commands/account/list.js +2 -2
- package/commands/account/remove.js +2 -2
- package/commands/account/removeOverride.js +2 -2
- package/commands/account/rename.js +2 -2
- package/commands/account/unlink.js +2 -2
- package/commands/account/use.js +2 -2
- package/commands/api.js +2 -2
- package/commands/app/migrate.js +2 -2
- package/commands/app/secret/add.js +2 -2
- package/commands/app/secret/delete.js +2 -2
- package/commands/app/secret/list.js +2 -2
- package/commands/app/secret/update.js +2 -2
- package/commands/auth.js +2 -2
- package/commands/cms/app/create.js +2 -2
- package/commands/cms/convertFields.js +2 -2
- package/commands/cms/delete.js +2 -2
- package/commands/cms/fetch.js +2 -2
- package/commands/cms/function/create.js +2 -2
- package/commands/cms/function/deploy.js +2 -2
- package/commands/cms/function/list.js +2 -2
- package/commands/cms/function/logs.js +2 -2
- package/commands/cms/function/server.js +2 -2
- package/commands/cms/getReactModule.js +2 -2
- package/commands/cms/lighthouseScore.js +2 -2
- package/commands/cms/lint.js +2 -2
- package/commands/cms/list.js +2 -2
- package/commands/cms/module/create.js +7 -2
- package/commands/cms/module/marketplace-validate.js +2 -2
- package/commands/cms/mv.js +2 -2
- package/commands/cms/template/create.js +2 -2
- package/commands/cms/theme/create.js +2 -2
- package/commands/cms/theme/generate-selectors.js +2 -2
- package/commands/cms/theme/marketplace-validate.js +2 -2
- package/commands/cms/theme/preview.js +2 -2
- package/commands/cms/upload.js +2 -2
- package/commands/cms/watch.js +2 -2
- package/commands/cms/webpack/create.js +2 -2
- package/commands/completion.js +2 -2
- package/commands/config/migrate.js +2 -2
- package/commands/config/set.js +2 -2
- package/commands/customObject/create.js +2 -2
- package/commands/customObject/createSchema.js +2 -2
- package/commands/customObject/deleteSchema.js +2 -2
- package/commands/customObject/fetchAllSchemas.js +2 -2
- package/commands/customObject/fetchSchema.js +2 -2
- package/commands/customObject/listSchemas.js +2 -2
- package/commands/customObject/updateSchema.js +2 -2
- package/commands/doctor.js +2 -2
- package/commands/feedback.js +2 -2
- package/commands/filemanager/fetch.js +2 -2
- package/commands/filemanager/upload.js +2 -2
- package/commands/getStarted.js +2 -2
- package/commands/hubdb/clear.js +2 -2
- package/commands/hubdb/create.js +2 -2
- package/commands/hubdb/delete.js +2 -2
- package/commands/hubdb/fetch.js +2 -2
- package/commands/hubdb/list.js +2 -2
- package/commands/init.js +2 -2
- package/commands/mcp/setup.js +2 -2
- package/commands/mcp/start.js +2 -2
- package/commands/open.js +2 -2
- package/commands/project/add.js +2 -2
- package/commands/project/appInstallStatus.js +2 -2
- package/commands/project/create.js +2 -2
- package/commands/project/delete.js +2 -2
- package/commands/project/deploy.js +2 -2
- package/commands/project/dev/index.js +2 -2
- package/commands/project/download.js +2 -2
- package/commands/project/info.js +2 -2
- package/commands/project/installDeps.js +2 -2
- package/commands/project/lint.js +4 -2
- package/commands/project/list.js +2 -2
- package/commands/project/listBuilds.js +2 -2
- package/commands/project/logs.js +2 -2
- package/commands/project/migrate.js +2 -2
- package/commands/project/open.js +2 -2
- package/commands/project/profile/add.js +2 -2
- package/commands/project/profile/delete.js +2 -2
- package/commands/project/updateDeps.js +2 -2
- package/commands/project/upload.d.ts +2 -0
- package/commands/project/upload.js +62 -9
- package/commands/project/validate.js +2 -2
- package/commands/project/watch.js +2 -2
- package/commands/sandbox/create.js +2 -2
- package/commands/sandbox/delete.js +2 -2
- package/commands/secret/addSecret.js +2 -2
- package/commands/secret/deleteSecret.js +2 -2
- package/commands/secret/listSecret.js +2 -2
- package/commands/secret/updateSecret.js +2 -2
- package/commands/testAccount/create.js +2 -2
- package/commands/testAccount/createConfig.js +2 -2
- package/commands/testAccount/delete.js +2 -2
- package/commands/testAccount/importData.js +2 -2
- package/commands/upgrade.js +2 -2
- package/lang/en.d.ts +18 -0
- package/lang/en.js +18 -0
- package/lib/constants.d.ts +1 -0
- package/lib/constants.js +1 -0
- package/lib/projects/localDev/helpers/project.js +1 -1
- package/lib/projects/pollProjectBuildAndDeploy.d.ts +5 -1
- package/lib/projects/pollProjectBuildAndDeploy.js +3 -2
- package/lib/projects/preview.d.ts +7 -0
- package/lib/projects/preview.js +48 -0
- package/lib/projects/upload.d.ts +1 -0
- package/lib/projects/upload.js +5 -4
- package/lib/projects/workspaces.d.ts +11 -1
- package/lib/projects/workspaces.js +27 -12
- package/lib/yargs/makeWrappedYargsHandler.d.ts +3 -0
- package/lib/yargs/{makeYargsHandlerWithUsageTracking.js → makeWrappedYargsHandler.js} +1 -1
- package/mcp-server/tools/cms/HsCreateFunctionTool.js +2 -2
- package/mcp-server/tools/cms/HsCreateModuleTool.js +7 -5
- package/mcp-server/tools/cms/HsCreateTemplateTool.js +2 -2
- package/mcp-server/tools/cms/HsFunctionLogsTool.js +2 -3
- package/mcp-server/tools/cms/HsListFunctionsTool.js +2 -3
- package/mcp-server/tools/cms/HsListTool.js +2 -2
- package/package.json +1 -1
- package/lib/yargs/makeYargsHandlerWithUsageTracking.d.ts +0 -3
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
import { Tool } from '../../Tool.js';
|
|
2
2
|
import { z } from 'zod';
|
|
3
3
|
import { absoluteCurrentWorkingDirectory } from '../project/constants.js';
|
|
4
|
-
import { runCommandInDir } from '../../utils/command.js';
|
|
5
|
-
import {
|
|
6
|
-
import { addFlag } from '../../utils/command.js';
|
|
4
|
+
import { addFlag, runCommandInDir } from '../../utils/command.js';
|
|
5
|
+
import { formatTextContent, formatTextContents } from '../../utils/content.js';
|
|
7
6
|
import { CONTENT_TYPES } from '../../../types/Cms.js';
|
|
8
7
|
import { setupHubSpotConfig } from '../../utils/config.js';
|
|
9
8
|
import { getErrorMessage } from '../../../lib/errorHandlers/index.js';
|
|
@@ -75,7 +74,7 @@ export class HsCreateModuleTool extends Tool {
|
|
|
75
74
|
};
|
|
76
75
|
}
|
|
77
76
|
// Build the command
|
|
78
|
-
let command = 'hs
|
|
77
|
+
let command = 'hs cms module create';
|
|
79
78
|
if (userSuppliedName) {
|
|
80
79
|
command += ` "${userSuppliedName}"`;
|
|
81
80
|
}
|
|
@@ -101,6 +100,9 @@ export class HsCreateModuleTool extends Tool {
|
|
|
101
100
|
if (availableForNewContent !== undefined) {
|
|
102
101
|
command = addFlag(command, 'available-for-new-content', availableForNewContent);
|
|
103
102
|
}
|
|
103
|
+
else {
|
|
104
|
+
command = addFlag(command, 'available-for-new-content', true);
|
|
105
|
+
}
|
|
104
106
|
try {
|
|
105
107
|
const { stdout, stderr } = await runCommandInDir(absoluteCurrentWorkingDirectory, command);
|
|
106
108
|
return formatTextContents(stdout, stderr);
|
|
@@ -116,7 +118,7 @@ export class HsCreateModuleTool extends Tool {
|
|
|
116
118
|
register() {
|
|
117
119
|
return this.mcpServer.registerTool(toolName, {
|
|
118
120
|
title: 'Create HubSpot CMS Module',
|
|
119
|
-
description: 'Creates a new HubSpot CMS module using the hs
|
|
121
|
+
description: 'Creates a new HubSpot CMS module using the hs cms module create command. Modules can be created non-interactively by specifying moduleLabel and other module options. You can create either HubL or React modules by setting the reactType parameter.',
|
|
120
122
|
inputSchema,
|
|
121
123
|
annotations: {
|
|
122
124
|
readOnlyHint: false,
|
|
@@ -47,7 +47,7 @@ export class HsCreateTemplateTool extends Tool {
|
|
|
47
47
|
};
|
|
48
48
|
}
|
|
49
49
|
// Build the command
|
|
50
|
-
let command = 'hs
|
|
50
|
+
let command = 'hs cms template create';
|
|
51
51
|
if (userSuppliedName) {
|
|
52
52
|
command += ` "${userSuppliedName}"`;
|
|
53
53
|
}
|
|
@@ -73,7 +73,7 @@ export class HsCreateTemplateTool extends Tool {
|
|
|
73
73
|
register() {
|
|
74
74
|
return this.mcpServer.registerTool(toolName, {
|
|
75
75
|
title: 'Create HubSpot CMS Template',
|
|
76
|
-
description: `Creates a new HubSpot CMS template using the hs
|
|
76
|
+
description: `Creates a new HubSpot CMS template using the hs cms template create command. Templates can be created non-interactively by specifying templateType. Supports all template types including: ${TEMPLATE_TYPES.join(', ')}.`,
|
|
77
77
|
inputSchema,
|
|
78
78
|
annotations: {
|
|
79
79
|
readOnlyHint: false,
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { Tool } from '../../Tool.js';
|
|
2
2
|
import { z } from 'zod';
|
|
3
|
-
import { addFlag } from '../../utils/command.js';
|
|
3
|
+
import { addFlag, runCommandInDir } from '../../utils/command.js';
|
|
4
4
|
import { absoluteCurrentWorkingDirectory } from '../project/constants.js';
|
|
5
|
-
import { runCommandInDir } from '../../utils/command.js';
|
|
6
5
|
import { formatTextContents } from '../../utils/content.js';
|
|
7
6
|
import { setupHubSpotConfig } from '../../utils/config.js';
|
|
8
7
|
import { getErrorMessage } from '../../../lib/errorHandlers/index.js';
|
|
@@ -38,7 +37,7 @@ export class HsFunctionLogsTool extends Tool {
|
|
|
38
37
|
const normalizedEndpoint = endpoint.startsWith('/')
|
|
39
38
|
? endpoint.slice(1)
|
|
40
39
|
: endpoint;
|
|
41
|
-
let command = `hs logs ${normalizedEndpoint}`;
|
|
40
|
+
let command = `hs cms function logs ${normalizedEndpoint}`;
|
|
42
41
|
if (latest) {
|
|
43
42
|
command = addFlag(command, 'latest', latest);
|
|
44
43
|
}
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { Tool } from '../../Tool.js';
|
|
2
2
|
import { z } from 'zod';
|
|
3
|
-
import { addFlag } from '../../utils/command.js';
|
|
3
|
+
import { addFlag, runCommandInDir } from '../../utils/command.js';
|
|
4
4
|
import { absoluteCurrentWorkingDirectory } from '../project/constants.js';
|
|
5
|
-
import { runCommandInDir } from '../../utils/command.js';
|
|
6
5
|
import { formatTextContents } from '../../utils/content.js';
|
|
7
6
|
import { setupHubSpotConfig } from '../../utils/config.js';
|
|
8
7
|
import { getErrorMessage } from '../../../lib/errorHandlers/index.js';
|
|
@@ -26,7 +25,7 @@ export class HsListFunctionsTool extends Tool {
|
|
|
26
25
|
}
|
|
27
26
|
async handler({ account, json, absoluteCurrentWorkingDirectory, }) {
|
|
28
27
|
setupHubSpotConfig(absoluteCurrentWorkingDirectory);
|
|
29
|
-
let command = 'hs function list';
|
|
28
|
+
let command = 'hs cms function list';
|
|
30
29
|
if (json) {
|
|
31
30
|
command += ' --json';
|
|
32
31
|
}
|
|
@@ -26,7 +26,7 @@ export class HsListTool extends Tool {
|
|
|
26
26
|
}
|
|
27
27
|
async handler({ path, account, absoluteCurrentWorkingDirectory, }) {
|
|
28
28
|
setupHubSpotConfig(absoluteCurrentWorkingDirectory);
|
|
29
|
-
let command = 'hs list';
|
|
29
|
+
let command = 'hs cms list';
|
|
30
30
|
if (path) {
|
|
31
31
|
command += ` ${path}`;
|
|
32
32
|
}
|
|
@@ -46,7 +46,7 @@ export class HsListTool extends Tool {
|
|
|
46
46
|
content: [
|
|
47
47
|
{
|
|
48
48
|
type: 'text',
|
|
49
|
-
text: `Error executing hs list command: ${getErrorMessage(error)}`,
|
|
49
|
+
text: `Error executing hs cms list command: ${getErrorMessage(error)}`,
|
|
50
50
|
},
|
|
51
51
|
],
|
|
52
52
|
};
|
package/package.json
CHANGED
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
import { ArgumentsCamelCase } from 'yargs';
|
|
2
|
-
import { CommonArgs } from '../../types/Yargs.js';
|
|
3
|
-
export declare function makeYargsHandlerWithUsageTracking<T extends CommonArgs>(trackingName: string, handler: (args: ArgumentsCamelCase<T>) => Promise<void>): (args: ArgumentsCamelCase<T>) => Promise<void>;
|