@hubspot/cli 7.7.16-experimental.0 → 7.7.16-experimental.2

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 (66) hide show
  1. package/bin/cli.js +4 -0
  2. package/bin/hs +1 -1
  3. package/commands/getStarted.d.ts +9 -0
  4. package/commands/getStarted.js +227 -0
  5. package/commands/init.js +6 -1
  6. package/commands/mcp/setup.d.ts +2 -2
  7. package/commands/mcp/setup.js +2 -0
  8. package/commands/mcp/start.d.ts +2 -2
  9. package/commands/mcp/start.js +3 -1
  10. package/commands/project/deploy.d.ts +1 -0
  11. package/commands/project/deploy.js +29 -3
  12. package/commands/project/upload.d.ts +2 -2
  13. package/commands/project/upload.js +18 -23
  14. package/commands/project/validate.d.ts +6 -0
  15. package/commands/project/validate.js +82 -0
  16. package/commands/project.js +2 -0
  17. package/commands/testAccount/create.d.ts +6 -0
  18. package/commands/testAccount/create.js +110 -0
  19. package/commands/testAccount/createConfig.d.ts +10 -0
  20. package/commands/testAccount/createConfig.js +98 -0
  21. package/commands/testAccount/delete.d.ts +6 -0
  22. package/commands/testAccount/delete.js +48 -0
  23. package/commands/testAccount.d.ts +3 -0
  24. package/commands/testAccount.js +28 -0
  25. package/lang/en.d.ts +143 -29
  26. package/lang/en.js +143 -32
  27. package/lang/en.lyaml +9 -14
  28. package/lib/app/migrate.js +15 -3
  29. package/lib/commonOpts.d.ts +2 -0
  30. package/lib/commonOpts.js +21 -9
  31. package/lib/constants.d.ts +5 -0
  32. package/lib/constants.js +6 -1
  33. package/lib/doctor/Doctor.js +1 -1
  34. package/lib/errorHandlers/index.js +7 -0
  35. package/lib/mcp/setup.d.ts +9 -0
  36. package/lib/mcp/setup.js +23 -21
  37. package/lib/projectProfiles.d.ts +1 -0
  38. package/lib/projectProfiles.js +18 -0
  39. package/lib/projects/buildAndDeploy.js +1 -1
  40. package/lib/projects/localDev/AppDevModeInterface.d.ts +3 -0
  41. package/lib/projects/localDev/AppDevModeInterface.js +45 -16
  42. package/lib/projects/localDev/LocalDevManager.js +1 -1
  43. package/lib/projects/upload.d.ts +3 -0
  44. package/lib/projects/upload.js +56 -22
  45. package/lib/projects/urls.d.ts +2 -0
  46. package/lib/projects/urls.js +10 -0
  47. package/lib/prompts/createDeveloperTestAccountConfigPrompt.d.ts +17 -0
  48. package/lib/prompts/createDeveloperTestAccountConfigPrompt.js +96 -0
  49. package/lib/prompts/installAppPrompt.d.ts +2 -1
  50. package/lib/prompts/installAppPrompt.js +12 -2
  51. package/lib/prompts/promptUtils.d.ts +1 -0
  52. package/lib/prompts/promptUtils.js +2 -0
  53. package/lib/ui/logger.d.ts +1 -0
  54. package/lib/ui/logger.js +1 -0
  55. package/lib/yargsUtils.d.ts +1 -0
  56. package/lib/yargsUtils.js +3 -0
  57. package/mcp-server/tools/index.js +2 -0
  58. package/mcp-server/tools/project/CreateProjectTool.d.ts +3 -3
  59. package/mcp-server/tools/project/CreateProjectTool.js +5 -1
  60. package/mcp-server/tools/project/DeployProject.js +1 -1
  61. package/mcp-server/tools/project/UploadProjectTools.js +1 -1
  62. package/mcp-server/tools/project/ValidateProjectTool.d.ts +17 -0
  63. package/mcp-server/tools/project/ValidateProjectTool.js +35 -0
  64. package/package.json +10 -9
  65. package/types/LocalDev.d.ts +1 -0
  66. package/types/Yargs.d.ts +4 -0
@@ -0,0 +1,110 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ const fs_extra_1 = __importDefault(require("fs-extra"));
7
+ const path_1 = __importDefault(require("path"));
8
+ const developerTestAccounts_1 = require("@hubspot/local-dev-lib/api/developerTestAccounts");
9
+ const path_2 = require("@hubspot/local-dev-lib/path");
10
+ const yargsUtils_1 = require("../../lib/yargsUtils");
11
+ const promptUtils_1 = require("../../lib/prompts/promptUtils");
12
+ const exitCodes_1 = require("../../lib/enums/exitCodes");
13
+ const logger_1 = require("../../lib/ui/logger");
14
+ const usageTracking_1 = require("../../lib/usageTracking");
15
+ const validation_1 = require("../../lib/validation");
16
+ const en_1 = require("../../lang/en");
17
+ const createDeveloperTestAccountConfigPrompt_1 = require("../../lib/prompts/createDeveloperTestAccountConfigPrompt");
18
+ const command = 'create';
19
+ const describe = en_1.commands.testAccount.create.describe;
20
+ async function handler(args) {
21
+ const { derivedAccountId, configPath, formatOutputAsJson } = args;
22
+ (0, usageTracking_1.trackCommandUsage)('test-account-create', {}, derivedAccountId);
23
+ let accountConfigPath = configPath;
24
+ let testAccountConfig;
25
+ if (!accountConfigPath) {
26
+ const createTestAccountFromConfig = await (0, promptUtils_1.listPrompt)(en_1.commands.testAccount.create.createTestAccountFromConfigPrompt, {
27
+ choices: [
28
+ {
29
+ name: en_1.commands.testAccount.create.createFromConfigOption,
30
+ value: true,
31
+ },
32
+ {
33
+ name: en_1.commands.testAccount.create.createFromScratchOption,
34
+ value: false,
35
+ },
36
+ ],
37
+ });
38
+ if (createTestAccountFromConfig) {
39
+ const configPathPromptResult = await (0, promptUtils_1.promptUser)({
40
+ name: 'configPath',
41
+ message: en_1.commands.testAccount.create.configPathPrompt,
42
+ type: 'input',
43
+ });
44
+ accountConfigPath = configPathPromptResult.configPath;
45
+ }
46
+ }
47
+ if (accountConfigPath) {
48
+ const absoluteConfigPath = path_1.default.resolve((0, path_2.getCwd)(), accountConfigPath);
49
+ if (!(0, validation_1.fileExists)(absoluteConfigPath)) {
50
+ logger_1.uiLogger.error(en_1.commands.testAccount.create.errors.configFileNotFound(absoluteConfigPath));
51
+ process.exit(exitCodes_1.EXIT_CODES.ERROR);
52
+ }
53
+ try {
54
+ testAccountConfig = JSON.parse(fs_extra_1.default.readFileSync(absoluteConfigPath, 'utf8'));
55
+ }
56
+ catch (err) {
57
+ logger_1.uiLogger.error(en_1.commands.testAccount.create.errors.configFileParseFailed(absoluteConfigPath));
58
+ process.exit(exitCodes_1.EXIT_CODES.ERROR);
59
+ }
60
+ }
61
+ else {
62
+ testAccountConfig = await (0, createDeveloperTestAccountConfigPrompt_1.createDeveloperTestAccountConfigPrompt)();
63
+ }
64
+ const jsonOutput = {};
65
+ try {
66
+ const { data } = await (0, developerTestAccounts_1.createDeveloperTestAccount)(derivedAccountId, testAccountConfig);
67
+ if (formatOutputAsJson) {
68
+ jsonOutput.accountName = data.accountName;
69
+ jsonOutput.accountId = data.id;
70
+ jsonOutput.personalAccessKey = data.personalAccessKey;
71
+ }
72
+ logger_1.uiLogger.success(en_1.commands.testAccount.create.success.configFileUpdated(data.accountName, data.id));
73
+ }
74
+ catch (err) {
75
+ logger_1.uiLogger.error(en_1.commands.testAccount.create.errors.failedToCreate);
76
+ process.exit(exitCodes_1.EXIT_CODES.ERROR);
77
+ }
78
+ if (formatOutputAsJson) {
79
+ logger_1.uiLogger.json(jsonOutput);
80
+ }
81
+ process.exit(exitCodes_1.EXIT_CODES.SUCCESS);
82
+ }
83
+ function createTestAccountBuilder(yargs) {
84
+ yargs.option('config-path', {
85
+ type: 'string',
86
+ description: en_1.commands.testAccount.create.options.configPath,
87
+ });
88
+ yargs.example([
89
+ [
90
+ '$0 create --config-path ./test-account-config.json',
91
+ en_1.commands.testAccount.create.example('./test-account-config.json'),
92
+ ],
93
+ ]);
94
+ return yargs;
95
+ }
96
+ const builder = (0, yargsUtils_1.makeYargsBuilder)(createTestAccountBuilder, command, describe, {
97
+ useGlobalOptions: true,
98
+ useEnvironmentOptions: true,
99
+ useAccountOptions: true,
100
+ useConfigOptions: true,
101
+ useTestingOptions: true,
102
+ useJSONOutputOptions: true,
103
+ });
104
+ const createTestAccountCommand = {
105
+ command,
106
+ describe,
107
+ handler,
108
+ builder,
109
+ };
110
+ exports.default = createTestAccountCommand;
@@ -0,0 +1,10 @@
1
+ import { CommonArgs, YargsCommandModule } from '../../types/Yargs';
2
+ import { HubConfig } from '../../lib/prompts/createDeveloperTestAccountConfigPrompt';
3
+ type CreateTestAccountConfigArgs = CommonArgs & {
4
+ name?: string;
5
+ description?: string;
6
+ tiers?: HubConfig[];
7
+ path?: string;
8
+ };
9
+ declare const createTestAccountConfigCommand: YargsCommandModule<unknown, CreateTestAccountConfigArgs>;
10
+ export default createTestAccountConfigCommand;
@@ -0,0 +1,98 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ const fs_extra_1 = __importDefault(require("fs-extra"));
7
+ const path_1 = __importDefault(require("path"));
8
+ const path_2 = require("@hubspot/local-dev-lib/path");
9
+ const yargsUtils_1 = require("../../lib/yargsUtils");
10
+ const promptUtils_1 = require("../../lib/prompts/promptUtils");
11
+ const exitCodes_1 = require("../../lib/enums/exitCodes");
12
+ const logger_1 = require("../../lib/ui/logger");
13
+ const usageTracking_1 = require("../../lib/usageTracking");
14
+ const en_1 = require("../../lang/en");
15
+ const createDeveloperTestAccountConfigPrompt_1 = require("../../lib/prompts/createDeveloperTestAccountConfigPrompt");
16
+ const validation_1 = require("../../lib/validation");
17
+ const command = 'create-config';
18
+ const describe = en_1.commands.testAccount.createConfig.describe;
19
+ async function handler(args) {
20
+ const { derivedAccountId, name, tiers, description, path: configPath } = args;
21
+ (0, usageTracking_1.trackCommandUsage)('test-account-create-config', {}, derivedAccountId);
22
+ let accountConfigPath = configPath;
23
+ const testAccountConfig = await (0, createDeveloperTestAccountConfigPrompt_1.createDeveloperTestAccountConfigPrompt)({
24
+ name,
25
+ description,
26
+ tiers,
27
+ });
28
+ if (!accountConfigPath) {
29
+ const pathPromptResult = await (0, promptUtils_1.promptUser)({
30
+ name: 'path',
31
+ message: en_1.commands.testAccount.createConfig.pathPrompt,
32
+ type: 'input',
33
+ default: 'test-account-config.json',
34
+ validate: path => {
35
+ if (!path) {
36
+ return en_1.commands.testAccount.createConfig.errors.pathError;
37
+ }
38
+ else if (!path.endsWith('.json')) {
39
+ return en_1.commands.testAccount.createConfig.errors.pathFormatError;
40
+ }
41
+ return true;
42
+ },
43
+ });
44
+ accountConfigPath = pathPromptResult.path;
45
+ }
46
+ if (!accountConfigPath) {
47
+ logger_1.uiLogger.error(en_1.commands.testAccount.createConfig.errors.pathError);
48
+ process.exit(exitCodes_1.EXIT_CODES.ERROR);
49
+ }
50
+ if ((0, validation_1.fileExists)(accountConfigPath)) {
51
+ logger_1.uiLogger.error(en_1.commands.testAccount.createConfig.errors.pathExistsError);
52
+ process.exit(exitCodes_1.EXIT_CODES.ERROR);
53
+ }
54
+ try {
55
+ fs_extra_1.default.writeFileSync(path_1.default.resolve((0, path_2.getCwd)(), accountConfigPath), JSON.stringify(testAccountConfig, null, 2), 'utf8');
56
+ }
57
+ catch (err) {
58
+ logger_1.uiLogger.error(en_1.commands.testAccount.createConfig.errors.failedToCreate);
59
+ process.exit(exitCodes_1.EXIT_CODES.ERROR);
60
+ }
61
+ logger_1.uiLogger.success(en_1.commands.testAccount.createConfig.success.configFileCreated(accountConfigPath));
62
+ process.exit(exitCodes_1.EXIT_CODES.SUCCESS);
63
+ }
64
+ function createTestAccountConfigBuilder(yargs) {
65
+ yargs.option('name', {
66
+ type: 'string',
67
+ description: en_1.commands.testAccount.createConfig.options.name,
68
+ });
69
+ yargs.option('description', {
70
+ type: 'string',
71
+ description: en_1.commands.testAccount.createConfig.options.description,
72
+ });
73
+ yargs.option('tiers', {
74
+ type: 'array',
75
+ description: en_1.commands.testAccount.createConfig.options.tiers,
76
+ });
77
+ yargs.option('path', {
78
+ type: 'string',
79
+ description: en_1.commands.testAccount.createConfig.options.path,
80
+ });
81
+ yargs.example([
82
+ [
83
+ '$0 create-config --name my-account',
84
+ en_1.commands.testAccount.createConfig.example('my-account'),
85
+ ],
86
+ ]);
87
+ return yargs;
88
+ }
89
+ const builder = (0, yargsUtils_1.makeYargsBuilder)(createTestAccountConfigBuilder, command, describe, {
90
+ useGlobalOptions: true,
91
+ });
92
+ const createTestAccountConfigCommand = {
93
+ command,
94
+ describe,
95
+ handler,
96
+ builder,
97
+ };
98
+ exports.default = createTestAccountConfigCommand;
@@ -0,0 +1,6 @@
1
+ import { CommonArgs, ConfigArgs, AccountArgs, EnvironmentArgs, TestingArgs, YargsCommandModule } from '../../types/Yargs';
2
+ type DeleteTestAccountArgs = CommonArgs & AccountArgs & ConfigArgs & TestingArgs & EnvironmentArgs & {
3
+ testAccountId: number;
4
+ };
5
+ declare const deleteTestAccountCommand: YargsCommandModule<unknown, DeleteTestAccountArgs>;
6
+ export default deleteTestAccountCommand;
@@ -0,0 +1,48 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const developerTestAccounts_1 = require("@hubspot/local-dev-lib/api/developerTestAccounts");
4
+ const yargsUtils_1 = require("../../lib/yargsUtils");
5
+ const exitCodes_1 = require("../../lib/enums/exitCodes");
6
+ const logger_1 = require("../../lib/ui/logger");
7
+ const usageTracking_1 = require("../../lib/usageTracking");
8
+ const en_1 = require("../../lang/en");
9
+ const command = 'delete <test-account-id>';
10
+ const describe = en_1.commands.testAccount.delete.describe;
11
+ async function handler(args) {
12
+ const { derivedAccountId, testAccountId } = args;
13
+ (0, usageTracking_1.trackCommandUsage)('test-account-delete', {}, derivedAccountId);
14
+ try {
15
+ await (0, developerTestAccounts_1.deleteDeveloperTestAccount)(derivedAccountId, testAccountId, true);
16
+ logger_1.uiLogger.success(en_1.commands.testAccount.delete.success.testAccountDeleted(testAccountId));
17
+ }
18
+ catch (err) {
19
+ logger_1.uiLogger.error(en_1.commands.testAccount.delete.errors.failedToDelete);
20
+ process.exit(exitCodes_1.EXIT_CODES.ERROR);
21
+ }
22
+ process.exit(exitCodes_1.EXIT_CODES.SUCCESS);
23
+ }
24
+ function deleteTestAccountBuilder(yargs) {
25
+ yargs.positional('test-account-id', {
26
+ type: 'number',
27
+ description: en_1.commands.testAccount.delete.positionals.testAccountId,
28
+ required: true,
29
+ });
30
+ yargs.example([
31
+ ['$0 delete 1234567890', en_1.commands.testAccount.delete.example(1234567890)],
32
+ ]);
33
+ return yargs;
34
+ }
35
+ const builder = (0, yargsUtils_1.makeYargsBuilder)(deleteTestAccountBuilder, command, describe, {
36
+ useGlobalOptions: true,
37
+ useEnvironmentOptions: true,
38
+ useAccountOptions: true,
39
+ useConfigOptions: true,
40
+ useTestingOptions: true,
41
+ });
42
+ const deleteTestAccountCommand = {
43
+ command,
44
+ describe,
45
+ handler,
46
+ builder,
47
+ };
48
+ exports.default = deleteTestAccountCommand;
@@ -0,0 +1,3 @@
1
+ import { YargsCommandModuleBucket } from '../types/Yargs';
2
+ declare const testAccountCommand: YargsCommandModuleBucket;
3
+ export default testAccountCommand;
@@ -0,0 +1,28 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ const create_1 = __importDefault(require("./testAccount/create"));
7
+ const createConfig_1 = __importDefault(require("./testAccount/createConfig"));
8
+ const delete_1 = __importDefault(require("./testAccount/delete"));
9
+ const yargsUtils_1 = require("../lib/yargsUtils");
10
+ const en_1 = require("../lang/en");
11
+ const command = ['test-account', 'test-accounts'];
12
+ const describe = undefined; //commands.testAccount.describe;
13
+ function testAccountBuilder(yargs) {
14
+ yargs
15
+ .command(create_1.default)
16
+ .command(createConfig_1.default)
17
+ .command(delete_1.default)
18
+ .demandCommand(1, '');
19
+ return yargs;
20
+ }
21
+ const builder = (0, yargsUtils_1.makeYargsBuilder)(testAccountBuilder, command, en_1.commands.testAccount.describe);
22
+ const testAccountCommand = {
23
+ command,
24
+ describe,
25
+ builder,
26
+ handler: () => { },
27
+ };
28
+ exports.default = testAccountCommand;
package/lang/en.d.ts CHANGED
@@ -8,6 +8,54 @@ export declare const commands: {
8
8
  readonly configFileExists: (configPath: string) => string;
9
9
  };
10
10
  };
11
+ readonly getStarted: {
12
+ readonly options: {
13
+ readonly dest: {
14
+ readonly describe: "Directory where the project should be created";
15
+ };
16
+ readonly name: {
17
+ readonly describe: "Project name (cannot be changed)";
18
+ };
19
+ readonly templateSource: {
20
+ readonly describe: "Path to custom GitHub repository from which to create project template";
21
+ };
22
+ };
23
+ readonly startTitle: "Welcome to HubSpot Development!";
24
+ readonly verboseDescribe: "A step-by-step command to get you started with a HubSpot project.";
25
+ readonly startDescription: "You can use the HubSpot CLI to build apps, CMS themes, and more.";
26
+ readonly designManager: "To onboard with CMS, please visit the HubSpot Design Manager in your account and follow the checklist items.";
27
+ readonly openDesignManager: "Click here to go to the HubSpot Design Manager";
28
+ readonly openDesignManagerPrompt: "Open Design Manager in your browser?";
29
+ readonly openedDesignManager: "Redirected to Design Manager!";
30
+ readonly developerOverviewBrowserOpenPrep: "We'll take you to your HubSpot account and walk you through installing and previewing your new app.";
31
+ readonly openDeveloperOverviewPrompt: "Open HubSpot to go to your account?";
32
+ readonly openedDeveloperOverview: "HubSpot opened!";
33
+ readonly prompts: {
34
+ readonly selectOption: "Are you looking to build apps or CMS?";
35
+ readonly options: {
36
+ readonly app: "App";
37
+ readonly cms: "CMS";
38
+ };
39
+ readonly uploadProject: "Would you like to upload your project to HubSpot now?";
40
+ readonly appSelected: `We'll create a new project with a sample app for you.
41
+ Projects are what you can use to create apps, themes, and more at HubSpot.
42
+ Usually you'll use the ${string} command, but we'll go ahead and make one now.`;
43
+ readonly projectCreated: {
44
+ readonly title: string;
45
+ readonly description: `Upload your project to HubSpot - typically, you'll use the command ${string} for this.
46
+ We'll start the process now.`;
47
+ };
48
+ };
49
+ readonly logs: {
50
+ readonly uploadingProject: "Uploading your project to HubSpot...";
51
+ readonly uploadSuccess: "Project uploaded successfully!";
52
+ readonly developerOverviewLink: "Open this link to navigate to your HubSpot developer portal";
53
+ };
54
+ readonly errors: {
55
+ readonly uploadFailed: "Failed to upload project to HubSpot.";
56
+ readonly configFileNotFound: "Could not find project configuration for upload.";
57
+ };
58
+ };
11
59
  readonly completion: {
12
60
  readonly describe: "Enable bash completion shortcuts for commands. Concat the generated script to your .bashrc, .bash_profile, or .zshrc file.";
13
61
  readonly examples: {
@@ -790,13 +838,11 @@ Global configuration replaces hubspot.config.yml, and you will be prompted to mi
790
838
  readonly claudeCodeInstallFailed: "Claude Code CLI not working - skipping configuration";
791
839
  readonly failedToConfigureClaudeDesktop: "Failed to configure Claude Desktop";
792
840
  readonly configuringCursor: "Configuring Cursor...";
793
- readonly noCursorMcpFile: (configFile: string) => string;
794
841
  readonly failedToConfigureCursor: "Failed to configure Cursor";
795
842
  readonly configuredCursor: "Configured Cursor";
796
843
  readonly alreadyInstalled: "HubSpot CLI mcp server already installed, reinstalling";
797
- readonly configuringWindsurf: "Configuring Cursor...";
798
- readonly noWindsurfFile: (configFile: string) => string;
799
- readonly failedToConfigureWindsurf: "Failed to configure Cursor";
844
+ readonly configuringWindsurf: "Configuring Windsurf...";
845
+ readonly failedToConfigureWindsurf: "Failed to configure Windsurf";
800
846
  readonly configuredWindsurf: "Configured Windsurf";
801
847
  };
802
848
  readonly prompts: {
@@ -1321,6 +1367,20 @@ ${string}`;
1321
1367
  readonly noPackageJsonInProject: (projectName: string, link: string) => string;
1322
1368
  readonly packageManagerNotInstalled: (packageManager: string, link: string) => string;
1323
1369
  };
1370
+ readonly validate: {
1371
+ readonly describe: "Validate the project before uploading";
1372
+ readonly mustBeRanWithinAProject: "This command must be run from within a project directory.";
1373
+ readonly badVersion: "This command is only available for projects 2025.2 and later.";
1374
+ readonly examples: {
1375
+ readonly default: "Validate the project before uploading";
1376
+ };
1377
+ readonly success: (projectName: string) => string;
1378
+ readonly options: {
1379
+ readonly profile: {
1380
+ readonly describe: "The profile to target for this validation";
1381
+ };
1382
+ };
1383
+ };
1324
1384
  };
1325
1385
  readonly remove: {
1326
1386
  readonly describe: "Delete a file or folder from the HubSpot CMS.";
@@ -1725,6 +1785,62 @@ ${string}`;
1725
1785
  readonly missingSrc: "Please specify the path to your javascript fields file or directory with the --src flag.";
1726
1786
  };
1727
1787
  };
1788
+ readonly testAccount: {
1789
+ readonly describe: "Commands for working with test accounts.";
1790
+ readonly create: {
1791
+ readonly describe: "Create a test account from a config file";
1792
+ readonly configPathPrompt: "[--config-path] Enter the path to the test account config: ";
1793
+ readonly createTestAccountFromConfigPrompt: "How would you like to create your test account?";
1794
+ readonly createFromConfigOption: "Create test account from config file";
1795
+ readonly createFromScratchOption: "Create test account from scratch";
1796
+ readonly errors: {
1797
+ readonly configFileNotFound: (configPath: string) => string;
1798
+ readonly configFileParseFailed: (configPath: string) => string;
1799
+ readonly failedToCreate: "Failed to create test account";
1800
+ };
1801
+ readonly success: {
1802
+ readonly configFileUpdated: (testAccountName: string, testAccountId: number) => string;
1803
+ };
1804
+ readonly options: {
1805
+ readonly configPath: "The path to the test account config";
1806
+ };
1807
+ readonly example: (configPath: string) => string;
1808
+ };
1809
+ readonly createConfig: {
1810
+ readonly describe: "Create a test account config file.";
1811
+ readonly pathPrompt: "[--path] What is the path to the test account config?";
1812
+ readonly errors: {
1813
+ readonly pathError: "Path is required";
1814
+ readonly pathFormatError: "Path must end with .json";
1815
+ readonly failedToCreate: "Failed to create test account config";
1816
+ readonly pathExistsError: "A file already exists at this path. Please try again with a different path.";
1817
+ };
1818
+ readonly success: {
1819
+ readonly configFileCreated: (path: string) => string;
1820
+ };
1821
+ readonly options: {
1822
+ readonly name: "The name of the test account";
1823
+ readonly description: "The description of the test account";
1824
+ readonly tiers: "The tiers of the test account";
1825
+ readonly path: "The path to the test account config";
1826
+ };
1827
+ readonly example: (name: string) => string;
1828
+ };
1829
+ readonly delete: {
1830
+ readonly describe: "Delete a test account config file.";
1831
+ readonly pathPrompt: "[--path] What is the path to the test account config?";
1832
+ readonly errors: {
1833
+ readonly failedToDelete: "Failed to delete test account";
1834
+ };
1835
+ readonly success: {
1836
+ readonly testAccountDeleted: (testAccountId: number) => string;
1837
+ };
1838
+ readonly positionals: {
1839
+ readonly testAccountId: "The id of the test account";
1840
+ };
1841
+ readonly example: (testAccountId: number) => string;
1842
+ };
1843
+ };
1728
1844
  readonly secrets: {
1729
1845
  readonly add: {
1730
1846
  readonly loading: {
@@ -2319,7 +2435,6 @@ export declare const lib: {
2319
2435
  readonly noCompatibleComponents: (serverKey: string) => string;
2320
2436
  };
2321
2437
  readonly LocalDevManager: {
2322
- readonly staticAuthAccountsMustMatch: "You must test static auth apps in the account the project exists in";
2323
2438
  readonly appNotFound: (accountId: number, appUid: string | undefined) => string;
2324
2439
  readonly failedToInitialize: "Missing required arguments to initialize Local Dev";
2325
2440
  readonly noDeployedBuild: (projectName: string, accountIdentifier: string, uploadCommand: string) => string;
@@ -2364,6 +2479,9 @@ export declare const lib: {
2364
2479
  };
2365
2480
  readonly AppDevModeInterface: {
2366
2481
  readonly defaultMarketplaceAppWarning: (installCount: number) => string;
2482
+ readonly autoInstallDeclined: "You must install your app on your target test account to proceed with local development.";
2483
+ readonly autoInstallSuccess: (appName: string, targetTestAccountId: number) => string;
2484
+ readonly autoInstallError: (appName: string, targetTestAccountId: number) => string;
2367
2485
  };
2368
2486
  readonly LocalDevWebsocketServer: {
2369
2487
  readonly errors: {
@@ -2515,7 +2633,7 @@ Run ${string} to upgrade to version ${string}`;
2515
2633
  readonly pollProjectBuildAndDeploy: {
2516
2634
  readonly buildSucceededAutomaticallyDeploying: (buildId: number, accountIdentifier: string) => string;
2517
2635
  readonly cleanedUpTempFile: (path: string) => string;
2518
- readonly viewDeploys: "View all deploys for this project in HubSpot";
2636
+ readonly viewDeploys: "view all deploys for this project in HubSpot";
2519
2637
  readonly unableToFindAutodeployStatus: (buildId: number, viewDeploysLink: string) => string;
2520
2638
  };
2521
2639
  };
@@ -2652,31 +2770,18 @@ Run ${string} to upgrade to version ${string}`;
2652
2770
  };
2653
2771
  readonly commonOpts: {
2654
2772
  readonly options: {
2655
- readonly account: {
2656
- readonly describe: "HubSpot account id or name from config";
2657
- };
2658
- readonly config: {
2659
- readonly describe: "Path to a config file";
2660
- };
2661
- readonly overwrite: {
2662
- readonly describe: "Overwrite existing files";
2663
- };
2773
+ readonly account: "HubSpot account id or name from config";
2774
+ readonly config: "Path to a config file";
2775
+ readonly overwrite: "Overwrite existing files";
2664
2776
  readonly modes: {
2665
- readonly describe: {
2666
- readonly default: (modes: string) => string;
2667
- readonly read: (modes: string) => string;
2668
- readonly write: (modes: string) => string;
2669
- };
2670
- };
2671
- readonly qa: {
2672
- readonly describe: "Run command in QA mode";
2673
- };
2674
- readonly useEnv: {
2675
- readonly describe: "Use environment variable config";
2676
- };
2677
- readonly debug: {
2678
- readonly describe: "Set log level to debug";
2777
+ readonly default: (modes: string) => string;
2778
+ readonly read: (modes: string) => string;
2779
+ readonly write: (modes: string) => string;
2679
2780
  };
2781
+ readonly qa: "Run command in QA mode";
2782
+ readonly useEnv: "Use environment variable config";
2783
+ readonly jsonOutput: "Format output as JSON";
2784
+ readonly debug: "Set log level to debug";
2680
2785
  };
2681
2786
  };
2682
2787
  readonly configMigrate: {
@@ -2718,6 +2823,14 @@ Run ${string} to upgrade to version ${string}`;
2718
2823
  readonly setAsDefaultAccount: (accountName: string) => string;
2719
2824
  readonly keepingCurrentDefault: (accountName: string) => string;
2720
2825
  };
2826
+ readonly createDeveloperTestAccountConfigPrompt: {
2827
+ readonly namePrompt: "[--name] What is the name of the test account?";
2828
+ readonly descriptionPrompt: "[--description] What is the description of the test account?";
2829
+ readonly tiersPrompt: "[--tiers] Which product tiers should the test account have?";
2830
+ readonly errors: {
2831
+ readonly tiersError: "Cannot have more than one tier per hub";
2832
+ };
2833
+ };
2721
2834
  readonly accountNamePrompt: {
2722
2835
  readonly enterAccountName: "Enter a unique name to reference this account in the CLI:";
2723
2836
  readonly enterDeveloperTestAccountName: "Name your developer test account:";
@@ -2890,6 +3003,7 @@ Run ${string} to upgrade to version ${string}`;
2890
3003
  readonly explanation: "Local development requires this app to be installed in the target test account";
2891
3004
  readonly reinstallExplanation: "This app's required scopes have been updated since it was last installed on the target test account. To avoid issues with local development, we recommend reinstalling the app with the updated scopes.";
2892
3005
  readonly prompt: "Open HubSpot to install this app?";
3006
+ readonly autoPrompt: "Install this app in your target test account?";
2893
3007
  readonly reinstallPrompt: "Open HubSpot to reinstall this app?";
2894
3008
  readonly decline: `To continue local development of this app, install it in your target test account and re-run ${string}`;
2895
3009
  };