@hubspot/cli 8.0.12-experimental.0 → 8.0.12-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.
Files changed (53) hide show
  1. package/bin/cli.js +4 -3
  2. package/commands/account/clean.js +2 -0
  3. package/commands/account/createOverride.js +3 -0
  4. package/commands/account/info.js +34 -16
  5. package/commands/account/link.js +3 -2
  6. package/commands/account/list.js +29 -71
  7. package/commands/account/remove.js +2 -0
  8. package/commands/account/removeOverride.js +3 -0
  9. package/commands/account/unlink.js +3 -2
  10. package/commands/account/use.js +71 -1
  11. package/commands/project/dev/deprecatedFlow.js +20 -2
  12. package/commands/project/dev/index.js +6 -0
  13. package/commands/project/dev/unifiedFlow.js +20 -3
  14. package/commands/project/lint.js +18 -1
  15. package/commands/project/upload.js +27 -15
  16. package/lang/en.d.ts +28 -0
  17. package/lang/en.js +33 -4
  18. package/lib/constants.d.ts +2 -0
  19. package/lib/constants.js +4 -0
  20. package/lib/doctor/Doctor.js +5 -5
  21. package/lib/link/index.d.ts +4 -0
  22. package/lib/link/index.js +40 -9
  23. package/lib/link/linkUtils.d.ts +1 -0
  24. package/lib/link/linkUtils.js +26 -1
  25. package/lib/link/warnIfLinkedDirectory.d.ts +1 -0
  26. package/lib/link/warnIfLinkedDirectory.js +9 -0
  27. package/lib/projects/localDev/DevServerManager_DEPRECATED.d.ts +2 -1
  28. package/lib/projects/localDev/DevServerManager_DEPRECATED.js +2 -2
  29. package/lib/projects/localDev/LocalDevManager_DEPRECATED.d.ts +2 -0
  30. package/lib/projects/localDev/LocalDevManager_DEPRECATED.js +3 -0
  31. package/lib/projects/preview.js +11 -24
  32. package/lib/projects/uieLinting.d.ts +9 -0
  33. package/lib/projects/uieLinting.js +45 -1
  34. package/lib/ui/accountTable.d.ts +8 -0
  35. package/lib/ui/accountTable.js +67 -0
  36. package/lib/yargs/parseYargsOrExit.d.ts +4 -0
  37. package/lib/yargs/parseYargsOrExit.js +25 -0
  38. package/mcp-server/server.js +8 -4
  39. package/mcp-server/tools/index.js +2 -0
  40. package/mcp-server/tools/project/AddFeatureToProjectTool.js +1 -1
  41. package/mcp-server/tools/project/CreateTestAccountTool.js +1 -1
  42. package/mcp-server/tools/project/DeployProjectTool.js +1 -1
  43. package/mcp-server/tools/project/FindProjectsTool.d.ts +15 -0
  44. package/mcp-server/tools/project/FindProjectsTool.js +60 -0
  45. package/mcp-server/tools/project/GetBuildLogsTool.js +1 -1
  46. package/mcp-server/tools/project/GetBuildStatusTool.js +1 -1
  47. package/mcp-server/tools/project/UploadProjectTools.js +1 -1
  48. package/mcp-server/tools/project/ValidateProjectTool.js +1 -1
  49. package/package.json +1 -1
  50. package/types/Link.d.ts +8 -3
  51. package/types/Link.js +5 -1
  52. package/types/PackageJson.d.ts +1 -0
  53. package/types/Yargs.d.ts +1 -0
@@ -10,6 +10,10 @@ export declare const REQUIRED_PACKAGES_AND_MIN_VERSIONS: {
10
10
  readonly prettier: "3.0.0";
11
11
  readonly jiti: "2.6.1";
12
12
  };
13
+ export declare const LINT_SCRIPTS: {
14
+ readonly lint: "eslint .";
15
+ readonly 'lint:fix': "eslint . --fix";
16
+ };
13
17
  export declare function isEslintInstalled(directory: string): boolean;
14
18
  export declare function areAllLintPackagesInstalled(directory: string): boolean;
15
19
  export declare function getMissingLintPackages(directory: string): {
@@ -36,3 +40,8 @@ export declare function displayLintResults(results: Array<{
36
40
  success: boolean;
37
41
  output: string;
38
42
  }>): void;
43
+ export declare function getMissingLintScripts(directory: string): string[];
44
+ export declare function addLintScriptsToPackageJson(directory: string): {
45
+ added: string[];
46
+ relativePath: string;
47
+ };
@@ -7,7 +7,7 @@ import { fetchRepoFile } from '@hubspot/local-dev-lib/api/github';
7
7
  import { getProjectPackageJsonLocations, isPackageInstalled, } from '../dependencyManagement.js';
8
8
  import { commands } from '../../lang/en.js';
9
9
  import { uiLogger } from '../ui/logger.js';
10
- import { safeGetPackageJsonCached } from '../npm/packageJson.js';
10
+ import { clearPackageJsonCache, safeGetPackageJsonCached, } from '../npm/packageJson.js';
11
11
  import { debugError } from '../errorHandlers/index.js';
12
12
  import { isLegacyProject } from '@hubspot/project-parsing-lib/projects';
13
13
  import { HUBSPOT_PROJECT_COMPONENTS_GITHUB_PATH, DEFAULT_PROJECT_TEMPLATE_BRANCH, } from '../constants.js';
@@ -40,6 +40,10 @@ const DEPRECATED_ESLINT_CONFIG_FILES = [
40
40
  '.eslintrc.json',
41
41
  '.eslintrc',
42
42
  ];
43
+ export const LINT_SCRIPTS = {
44
+ lint: 'eslint .',
45
+ 'lint:fix': 'eslint . --fix',
46
+ };
43
47
  function getPackageVersionFromPackageJson(directory, packageName) {
44
48
  const packageJsonPath = path.join(directory, 'package.json');
45
49
  const packageJson = safeGetPackageJsonCached(packageJsonPath);
@@ -239,3 +243,43 @@ export function displayLintResults(results) {
239
243
  });
240
244
  }
241
245
  }
246
+ export function getMissingLintScripts(directory) {
247
+ const packageJsonPath = path.join(directory, 'package.json');
248
+ const packageJson = safeGetPackageJsonCached(packageJsonPath);
249
+ if (!packageJson) {
250
+ return [];
251
+ }
252
+ return Object.keys(LINT_SCRIPTS).filter(scriptName => !packageJson.scripts?.[scriptName]);
253
+ }
254
+ export function addLintScriptsToPackageJson(directory) {
255
+ const packageJsonPath = path.join(directory, 'package.json');
256
+ try {
257
+ const rawContent = fs.readFileSync(packageJsonPath, 'utf-8');
258
+ const packageJson = JSON.parse(rawContent);
259
+ if (!packageJson.scripts) {
260
+ packageJson.scripts = {};
261
+ }
262
+ const added = [];
263
+ for (const [scriptName, scriptValue] of Object.entries(LINT_SCRIPTS)) {
264
+ if (!packageJson.scripts[scriptName]) {
265
+ packageJson.scripts[scriptName] = scriptValue;
266
+ added.push(scriptName);
267
+ }
268
+ }
269
+ if (added.length > 0) {
270
+ fs.writeFileSync(packageJsonPath, JSON.stringify(packageJson, null, 2) + '\n', 'utf-8');
271
+ clearPackageJsonCache();
272
+ }
273
+ return {
274
+ added,
275
+ relativePath: path.relative(process.cwd(), packageJsonPath),
276
+ };
277
+ }
278
+ catch {
279
+ uiLogger.warn(commands.project.lint.failedToAddLintScripts(packageJsonPath));
280
+ return {
281
+ added: [],
282
+ relativePath: path.relative(process.cwd(), packageJsonPath),
283
+ };
284
+ }
285
+ }
@@ -0,0 +1,8 @@
1
+ import { HubSpotConfigAccount } from '@hubspot/local-dev-lib/types/Accounts';
2
+ export declare function sortAndMapAccounts(accounts: HubSpotConfigAccount[]): {
3
+ [key: string]: HubSpotConfigAccount[];
4
+ };
5
+ export declare function getAccountData(mappedAccountData: {
6
+ [key: string]: HubSpotConfigAccount[];
7
+ }): string[][];
8
+ export declare function renderAccountTable(showAllLabel?: boolean): void;
@@ -0,0 +1,67 @@
1
+ import { HUBSPOT_ACCOUNT_TYPES, HUBSPOT_ACCOUNT_TYPE_STRINGS, } from '@hubspot/local-dev-lib/constants/config';
2
+ import { isSandbox, isDeveloperTestAccount } from '../accountTypes.js';
3
+ import { getAllConfigAccounts } from '@hubspot/local-dev-lib/config';
4
+ import { commands } from '../../lang/en.js';
5
+ import { renderTable } from '../../ui/render.js';
6
+ import { uiLogger } from './logger.js';
7
+ export function sortAndMapAccounts(accounts) {
8
+ const mappedAccountData = {};
9
+ // Standard and app developer accounts
10
+ accounts
11
+ .filter(p => p.accountType &&
12
+ (p.accountType === HUBSPOT_ACCOUNT_TYPES.STANDARD ||
13
+ p.accountType === HUBSPOT_ACCOUNT_TYPES.APP_DEVELOPER))
14
+ .forEach(account => {
15
+ mappedAccountData[account.accountId] = [account];
16
+ });
17
+ // Non-standard accounts (sandbox, developer test account)
18
+ accounts
19
+ .filter(p => p.accountType && (isSandbox(p) || isDeveloperTestAccount(p)))
20
+ .forEach(p => {
21
+ if (p.parentAccountId) {
22
+ mappedAccountData[p.parentAccountId] = [
23
+ ...(mappedAccountData[p.parentAccountId] || []),
24
+ p,
25
+ ];
26
+ }
27
+ else {
28
+ mappedAccountData[p.accountId] = [p];
29
+ }
30
+ });
31
+ return mappedAccountData;
32
+ }
33
+ export function getAccountData(mappedAccountData) {
34
+ const accountData = [];
35
+ Object.entries(mappedAccountData).forEach(([key, set]) => {
36
+ const hasParentAccount = set.filter(p => p.accountId === parseInt(key, 10))[0];
37
+ set.forEach(account => {
38
+ let name = `${account.name} [${HUBSPOT_ACCOUNT_TYPE_STRINGS[account.accountType]}]`;
39
+ if (isSandbox(account)) {
40
+ if (hasParentAccount && set.length > 1) {
41
+ name = `↳ ${name}`;
42
+ }
43
+ }
44
+ else if (isDeveloperTestAccount(account)) {
45
+ if (hasParentAccount && set.length > 1) {
46
+ name = `↳ ${name}`;
47
+ }
48
+ }
49
+ accountData.push([name, String(account.accountId), account.authType]);
50
+ });
51
+ });
52
+ return accountData;
53
+ }
54
+ export function renderAccountTable(showAllLabel = false) {
55
+ const accountsList = getAllConfigAccounts();
56
+ const mappedAccountData = sortAndMapAccounts(accountsList);
57
+ const accountData = getAccountData(mappedAccountData);
58
+ const tableHeader = [
59
+ commands.account.subcommands.list.labels.name,
60
+ commands.account.subcommands.list.labels.accountId,
61
+ commands.account.subcommands.list.labels.authType,
62
+ ];
63
+ uiLogger.log(showAllLabel
64
+ ? commands.account.subcommands.list.allAccounts
65
+ : commands.account.subcommands.list.accounts);
66
+ renderTable(tableHeader, accountData, true);
67
+ }
@@ -0,0 +1,4 @@
1
+ import { ArgumentsCamelCase, Argv } from 'yargs';
2
+ type YargsFailureHandler<T> = (message: string | null, error: unknown, parser: Argv<T>) => never;
3
+ export declare function parseYargsOrExit<T>(parser: Argv<T>, handleFailure: YargsFailureHandler<T>): Promise<ArgumentsCamelCase<T>>;
4
+ export {};
@@ -0,0 +1,25 @@
1
+ function getYargsErrorMessage(error) {
2
+ return error instanceof Error && error.name === 'YError' ? error.message : '';
3
+ }
4
+ function getYargsFailureMessage(message, error) {
5
+ if (message) {
6
+ return message;
7
+ }
8
+ return getYargsErrorMessage(error) || message;
9
+ }
10
+ export async function parseYargsOrExit(parser, handleFailure) {
11
+ let failureHandled = false;
12
+ const parserWithFailureHandler = parser.fail((message, error, yargs) => {
13
+ failureHandled = true;
14
+ return handleFailure(getYargsFailureMessage(message, error), error, yargs);
15
+ });
16
+ try {
17
+ return await parserWithFailureHandler.parseAsync();
18
+ }
19
+ catch (error) {
20
+ if (failureHandled) {
21
+ throw error;
22
+ }
23
+ return handleFailure(getYargsErrorMessage(error), error, parserWithFailureHandler);
24
+ }
25
+ }
@@ -20,15 +20,19 @@ REQUIRED WORKFLOWS
20
20
  1. Documentation lookup: always call \`search-docs\` first, then
21
21
  \`fetch-doc\` on the most relevant result(s) before planning, writing
22
22
  code, or answering platform/API questions. Do not answer from memory.
23
- 2. Editing \`*-hsmeta.json\`: call \`get-feature-config-schema\` for that
23
+ 2. Locating a HubSpot project: when the current working directory is not
24
+ a HubSpot project (no \`hsproject.json\`) or you need to determine
25
+ whether a directory contains one, call \`find-projects\` before
26
+ running any tool that requires a project path.
27
+ 3. Editing \`*-hsmeta.json\`: call \`get-feature-config-schema\` for that
24
28
  feature type first to learn the allowed fields and values.
25
- 3. Debugging a failed build: start with \`get-build-status\` to surface
29
+ 4. Debugging a failed build: start with \`get-build-status\` to surface
26
30
  error messages, and only reach for \`get-build-logs\` for deeper
27
31
  troubleshooting or warnings.
28
- 4. Reading serverless function logs: call \`list-cms-serverless-functions\`
32
+ 5. Reading serverless function logs: call \`list-cms-serverless-functions\`
29
33
  first to discover the endpoint path, then
30
34
  \`get-cms-serverless-function-logs\`.
31
- 5. App analytics: call \`get-apps-info\` to discover \`appId\` values
35
+ 6. App analytics: call \`get-apps-info\` to discover \`appId\` values
32
36
  before \`get-api-usage-patterns-by-app-id\`.
33
37
 
34
38
  OUTPUT
@@ -18,6 +18,7 @@ import { HsCreateFunctionTool } from './cms/HsCreateFunctionTool.js';
18
18
  import { HsListFunctionsTool } from './cms/HsListFunctionsTool.js';
19
19
  import { HsFunctionLogsTool } from './cms/HsFunctionLogsTool.js';
20
20
  import { CreateTestAccountTool } from './project/CreateTestAccountTool.js';
21
+ import { FindProjectsTool } from './project/FindProjectsTool.js';
21
22
  export function registerProjectTools(mcpServer, logger) {
22
23
  return [
23
24
  new UploadProjectTools(mcpServer, logger).register(),
@@ -34,6 +35,7 @@ export function registerProjectTools(mcpServer, logger) {
34
35
  new GetApplicationInfoTool(mcpServer, logger).register(),
35
36
  new GetBuildLogsTool(mcpServer, logger).register(),
36
37
  new GetBuildStatusTool(mcpServer, logger).register(),
38
+ new FindProjectsTool(mcpServer, logger).register(),
37
39
  ];
38
40
  }
39
41
  export function registerCmsTools(mcpServer, logger) {
@@ -71,7 +71,7 @@ export class AddFeatureToProjectTool extends Tool {
71
71
  return this.mcpServer.registerTool(toolName, {
72
72
  title: 'Add feature to HubSpot Project',
73
73
  description: `Adds a feature to an existing HubSpot project.
74
- Only works for projects with platformVersion '2025.2' and beyond`,
74
+ Only works for projects with platformVersion '2025.2' and beyond. If you do not know the project path, use the find-projects tool first to locate HubSpot projects in the workspace.`,
75
75
  inputSchema,
76
76
  annotations: {
77
77
  readOnlyHint: false,
@@ -57,7 +57,7 @@ const inputSchema = {
57
57
  contentLevel: z
58
58
  .enum(ACCOUNT_LEVEL_CHOICES)
59
59
  .optional()
60
- .describe(`CMS Hub tier level. Options: ${ACCOUNT_LEVEL_CHOICES.join(', ')}. Defaults to ENTERPRISE if not specified.`),
60
+ .describe(`Content Hub tier level. Options: ${ACCOUNT_LEVEL_CHOICES.join(', ')}. Defaults to ENTERPRISE if not specified.`),
61
61
  commerceLevel: z
62
62
  .enum(ACCOUNT_LEVEL_CHOICES_WITHOUT_STARTER)
63
63
  .optional()
@@ -43,7 +43,7 @@ export class DeployProjectTool extends Tool {
43
43
  register() {
44
44
  return this.mcpServer.registerTool(toolName, {
45
45
  title: 'Deploy a build of HubSpot Project',
46
- description: 'Takes a build number and a project name and deploys that build of the project. DO NOT run this tool unless the user specifies they would like to deploy the project.',
46
+ description: 'Takes a build number and a project name and deploys that build of the project. DO NOT run this tool unless the user specifies they would like to deploy the project. If you do not know the project path, use the find-projects tool first to locate HubSpot projects in the workspace.',
47
47
  inputSchema,
48
48
  annotations: {
49
49
  readOnlyHint: false,
@@ -0,0 +1,15 @@
1
+ import { TextContentResponse } from '../../types.js';
2
+ import { Tool } from '../../Tool.js';
3
+ import { McpServer, RegisteredTool } from '@modelcontextprotocol/sdk/server/mcp.js';
4
+ import { McpLogger } from '../../utils/logger.js';
5
+ import { z } from 'zod';
6
+ declare const inputSchemaZodObject: z.ZodObject<{
7
+ absoluteDirectory: z.ZodString;
8
+ }, z.core.$strip>;
9
+ export type FindProjectsInputSchema = z.infer<typeof inputSchemaZodObject>;
10
+ export declare class FindProjectsTool extends Tool<FindProjectsInputSchema> {
11
+ constructor(mcpServer: McpServer, logger: McpLogger);
12
+ handler({ absoluteDirectory, }: FindProjectsInputSchema): Promise<TextContentResponse>;
13
+ register(): RegisteredTool;
14
+ }
15
+ export {};
@@ -0,0 +1,60 @@
1
+ import { Tool } from '../../Tool.js';
2
+ import { z } from 'zod';
3
+ import { formatTextContents } from '../../utils/content.js';
4
+ import { walk } from '@hubspot/local-dev-lib/fs';
5
+ import path from 'path';
6
+ import { PROJECT_CONFIG_FILE } from '../../../lib/constants.js';
7
+ const TOOL_NAME = 'find-projects';
8
+ const IGNORE_DIRS = ['node_modules', '.git', '.vite'];
9
+ const inputSchema = {
10
+ absoluteDirectory: z
11
+ .string()
12
+ .describe('The absolute path to the directory to search for HubSpot projects in.'),
13
+ };
14
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
15
+ const inputSchemaZodObject = z.object({ ...inputSchema });
16
+ export class FindProjectsTool extends Tool {
17
+ constructor(mcpServer, logger) {
18
+ super(mcpServer, logger, TOOL_NAME);
19
+ }
20
+ async handler({ absoluteDirectory, }) {
21
+ try {
22
+ const allFiles = await walk(absoluteDirectory, IGNORE_DIRS);
23
+ const projectFiles = allFiles.filter(file => path.basename(file) === PROJECT_CONFIG_FILE);
24
+ if (projectFiles.length === 0) {
25
+ return formatTextContents(`No ${PROJECT_CONFIG_FILE} files found under ${absoluteDirectory}.`);
26
+ }
27
+ const projectDirs = projectFiles.map(file => path.dirname(file));
28
+ const output = [
29
+ `Found ${projectFiles.length} project(s):`,
30
+ '',
31
+ ...projectDirs.map(dir => ` ${dir}`),
32
+ ].join('\n');
33
+ return formatTextContents(output);
34
+ }
35
+ catch (error) {
36
+ this.logger.debug(TOOL_NAME, {
37
+ message: 'Handler caught error',
38
+ error: error instanceof Error ? error.message : String(error),
39
+ });
40
+ const cause = error instanceof Error ? error.cause : undefined;
41
+ const causeMessage = cause instanceof Error ? `: ${cause.message}` : '';
42
+ const errorMessage = error instanceof Error
43
+ ? error.message || `FileSystemError${causeMessage}`
44
+ : String(error);
45
+ return formatTextContents(`Error searching for projects: ${errorMessage}`);
46
+ }
47
+ }
48
+ register() {
49
+ return this.mcpServer.registerTool(TOOL_NAME, {
50
+ title: 'Find HubSpot Projects',
51
+ description: 'Use this tool to locate HubSpot projects. Traverses child directories of the given directory to find hsproject.json files, returning the paths of all discovered HubSpot projects.',
52
+ inputSchema,
53
+ annotations: {
54
+ readOnlyHint: true,
55
+ openWorldHint: false,
56
+ idempotentHint: true,
57
+ },
58
+ }, input => this.wrappedHandler(input));
59
+ }
60
+ }
@@ -114,7 +114,7 @@ export class GetBuildLogsTool extends Tool {
114
114
  register() {
115
115
  return this.mcpServer.registerTool(TOOL_NAME, {
116
116
  title: 'Get HubSpot Project Build Logs',
117
- description: 'Retrieves build logs for a specific HubSpot project build. Use this to debug build failures by viewing the full build pipeline output. This tool is for more comprehensive troubleshootings or addressing build WARNINGs, build errors should be troubleshooted with get-build-status tool first. Logs can be filtered by level (ERROR, WARN, INFO, or ALL). Use `hs project list-builds` first to identify the build ID and error messages.',
117
+ description: 'Retrieves build logs for a specific HubSpot project build. Use this to debug build failures by viewing the full build pipeline output. This tool is for more comprehensive troubleshootings or addressing build WARNINGs, build errors should be troubleshooted with get-build-status tool first. Logs can be filtered by level (ERROR, WARN, INFO, or ALL). Use `hs project list-builds` first to identify the build ID and error messages. If you do not know the project path, use the find-projects tool first to locate HubSpot projects in the workspace.',
118
118
  inputSchema,
119
119
  annotations: {
120
120
  readOnlyHint: true,
@@ -155,7 +155,7 @@ export class GetBuildStatusTool extends Tool {
155
155
  register() {
156
156
  return this.mcpServer.registerTool(TOOL_NAME, {
157
157
  title: 'Get HubSpot Projects Build Status and Errors',
158
- description: 'Retrieves build status and error messages for HubSpot projects. When buildId is omitted, shows recent builds with their status(default 3) - use this to find the latest builds when troubleshooting. When buildId is provided, shows detailed error information for that specific build. Displays buildErrorMessage and subbuild failures to help diagnose build issues.',
158
+ description: 'Retrieves build status and error messages for HubSpot projects. When buildId is omitted, shows recent builds with their status(default 3) - use this to find the latest builds when troubleshooting. When buildId is provided, shows detailed error information for that specific build. Displays buildErrorMessage and subbuild failures to help diagnose build issues. If you do not know the project path, use the find-projects tool first to locate HubSpot projects in the workspace.',
159
159
  inputSchema,
160
160
  annotations: {
161
161
  readOnlyHint: true,
@@ -72,7 +72,7 @@ export class UploadProjectTools extends Tool {
72
72
  register() {
73
73
  return this.mcpServer.registerTool(toolName, {
74
74
  title: 'Upload HubSpot Project',
75
- description: 'DO NOT run this tool unless the user specifies they would like to upload the project, it is potentially destructive. Uploads the HubSpot project in current working directory. If the project does not exist, it will be created. MUST be ran from within the project directory. IMPORTANT: Uploading a project does NOT automatically make cards live or visible to users. Cards must be manually added to a view in HubSpot after upload to become visible.',
75
+ description: 'DO NOT run this tool unless the user specifies they would like to upload the project, it is potentially destructive. Uploads the HubSpot project in current working directory. If the project does not exist, it will be created. MUST be ran from within the project directory. IMPORTANT: Uploading a project does NOT automatically make cards live or visible to users. Cards must be manually added to a view in HubSpot after upload to become visible. If you do not know the project path, use the find-projects tool first to locate HubSpot projects in the workspace.',
76
76
  inputSchema,
77
77
  annotations: {
78
78
  readOnlyHint: false,
@@ -33,7 +33,7 @@ export class ValidateProjectTool extends Tool {
33
33
  register() {
34
34
  return this.mcpServer.registerTool(toolName, {
35
35
  title: 'Validate HubSpot Project',
36
- description: 'Validates the HubSpot project and its configuration files. This tool does not need to be ran before uploading the project',
36
+ description: 'Validates the HubSpot project and its configuration files. This tool does not need to be ran before uploading the project. If you do not know the project path, use the find-projects tool first to locate HubSpot projects in the workspace.',
37
37
  inputSchema,
38
38
  annotations: {
39
39
  readOnlyHint: true,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hubspot/cli",
3
- "version": "8.0.12-experimental.0",
3
+ "version": "8.0.12-experimental.1",
4
4
  "description": "The official CLI for developing on HubSpot",
5
5
  "license": "Apache-2.0",
6
6
  "repository": "https://github.com/HubSpot/hubspot-cli",
package/types/Link.d.ts CHANGED
@@ -9,14 +9,19 @@ export type LinkContext = {
9
9
  accountOverrideId: number | null;
10
10
  preselectedAccountId?: number;
11
11
  };
12
+ export declare const ACTION_RESULT_STATUS: {
13
+ readonly SUCCESS: "success";
14
+ readonly ERROR: "error";
15
+ readonly NOOP: "noop";
16
+ };
12
17
  export type ActionResult = {
13
- status: 'success';
18
+ status: typeof ACTION_RESULT_STATUS.SUCCESS;
14
19
  settings: HsSettingsFile;
15
20
  } | {
16
- status: 'error';
21
+ status: typeof ACTION_RESULT_STATUS.ERROR;
17
22
  reason: string;
18
23
  } | {
19
- status: 'noop';
24
+ status: typeof ACTION_RESULT_STATUS.NOOP;
20
25
  };
21
26
  export type ActionHandlerParams = {
22
27
  state: HsSettingsFile;
package/types/Link.js CHANGED
@@ -1 +1,5 @@
1
- export {};
1
+ export const ACTION_RESULT_STATUS = {
2
+ SUCCESS: 'success',
3
+ ERROR: 'error',
4
+ NOOP: 'noop',
5
+ };
@@ -5,6 +5,7 @@ export interface PackageJson {
5
5
  name: string;
6
6
  version?: string;
7
7
  workspaces?: string[];
8
+ scripts?: Record<string, string>;
8
9
  dependencies?: Record<string, string>;
9
10
  devDependencies?: Record<string, string>;
10
11
  }
package/types/Yargs.d.ts CHANGED
@@ -46,6 +46,7 @@ export type ProjectDevArgs = CommonArgs & ConfigArgs & EnvironmentArgs & {
46
46
  profile?: string;
47
47
  testingAccount?: string | number;
48
48
  projectAccount?: string | number;
49
+ port?: number;
49
50
  };
50
51
  export type TestingArgs = {
51
52
  qa?: boolean;