@mailmodo/cli 0.0.49-beta.pr51.77 → 0.0.49-beta.pr51.78

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.
@@ -8,5 +8,6 @@ export default class Init extends BaseCommand {
8
8
  yes: import("@oclif/core/interfaces").BooleanFlag<boolean>;
9
9
  };
10
10
  run(): Promise<void>;
11
+ private persistMonthlyCap;
11
12
  private confirmOverwriteIfNeeded;
12
13
  }
@@ -155,12 +155,7 @@ export default class Init extends BaseCommand {
155
155
  },
156
156
  };
157
157
  await saveYaml(yamlConfig);
158
- const billingStatus = await this.fetchBillingStatus();
159
- const monthlyCap = billingStatus?.cap?.inBlocks;
160
- if (monthlyCap !== null && monthlyCap !== undefined) {
161
- yamlConfig.project.monthlyCap = monthlyCap;
162
- await saveYaml(yamlConfig);
163
- }
158
+ await this.persistMonthlyCap(yamlConfig);
164
159
  const templateSaves = analysisPayload.recommendedEmails.flatMap((rec, index) => {
165
160
  const generated = generatedEmails[index];
166
161
  const saves = [];
@@ -185,6 +180,14 @@ export default class Init extends BaseCommand {
185
180
  this.log(` Created ${chalk.green('mailmodo.yaml')} + ${chalk.green(String(emailConfigs.length))} email templates in ${chalk.green('/mailmodo')}\n`);
186
181
  this.log(` Run ${chalk.cyan("'mailmodo emails'")} to review.\n`);
187
182
  }
183
+ async persistMonthlyCap(yamlConfig) {
184
+ const billingStatus = await this.fetchBillingStatus();
185
+ const monthlyCap = billingStatus?.cap?.inBlocks;
186
+ if (monthlyCap !== null && monthlyCap !== undefined) {
187
+ yamlConfig.project.monthlyCap = monthlyCap;
188
+ await saveYaml(yamlConfig);
189
+ }
190
+ }
188
191
  async confirmOverwriteIfNeeded(flags) {
189
192
  const existing = await loadYaml();
190
193
  if (!existing)
@@ -365,13 +365,12 @@
365
365
  "index.js"
366
366
  ]
367
367
  },
368
- "login": {
368
+ "logout": {
369
369
  "aliases": [],
370
370
  "args": {},
371
- "description": "Authenticate with Mailmodo using your API key",
371
+ "description": "Sign out by removing saved credentials from this machine",
372
372
  "examples": [
373
- "<%= config.bin %> login",
374
- "MAILMODO_API_KEY=YOUR_API_KEY <%= config.bin %> login"
373
+ "<%= config.bin %> logout"
375
374
  ],
376
375
  "flags": {
377
376
  "json": {
@@ -390,7 +389,7 @@
390
389
  },
391
390
  "hasDynamicHelp": false,
392
391
  "hiddenAliases": [],
393
- "id": "login",
392
+ "id": "logout",
394
393
  "pluginAlias": "@mailmodo/cli",
395
394
  "pluginName": "@mailmodo/cli",
396
395
  "pluginType": "core",
@@ -400,16 +399,19 @@
400
399
  "relativePath": [
401
400
  "dist",
402
401
  "commands",
403
- "login",
402
+ "logout",
404
403
  "index.js"
405
404
  ]
406
405
  },
407
- "logout": {
406
+ "logs": {
408
407
  "aliases": [],
409
408
  "args": {},
410
- "description": "Sign out by removing saved credentials from this machine",
409
+ "description": "View email send logs and delivery events",
411
410
  "examples": [
412
- "<%= config.bin %> logout"
411
+ "<%= config.bin %> logs",
412
+ "<%= config.bin %> logs --email sarah@example.com",
413
+ "<%= config.bin %> logs --failed",
414
+ "<%= config.bin %> logs --json"
413
415
  ],
414
416
  "flags": {
415
417
  "json": {
@@ -424,11 +426,40 @@
424
426
  "name": "yes",
425
427
  "allowNo": false,
426
428
  "type": "boolean"
429
+ },
430
+ "email": {
431
+ "description": "Filter logs by contact email",
432
+ "name": "email",
433
+ "hasDynamicHelp": false,
434
+ "multiple": false,
435
+ "type": "option"
436
+ },
437
+ "failed": {
438
+ "description": "Show only failed/bounced events",
439
+ "name": "failed",
440
+ "allowNo": false,
441
+ "type": "boolean"
442
+ },
443
+ "limit": {
444
+ "description": "Entries per page (max 200)",
445
+ "name": "limit",
446
+ "default": 50,
447
+ "hasDynamicHelp": false,
448
+ "multiple": false,
449
+ "type": "option"
450
+ },
451
+ "page": {
452
+ "description": "Page number",
453
+ "name": "page",
454
+ "default": 1,
455
+ "hasDynamicHelp": false,
456
+ "multiple": false,
457
+ "type": "option"
427
458
  }
428
459
  },
429
460
  "hasDynamicHelp": false,
430
461
  "hiddenAliases": [],
431
- "id": "logout",
462
+ "id": "logs",
432
463
  "pluginAlias": "@mailmodo/cli",
433
464
  "pluginName": "@mailmodo/cli",
434
465
  "pluginType": "core",
@@ -438,7 +469,7 @@
438
469
  "relativePath": [
439
470
  "dist",
440
471
  "commands",
441
- "logout",
472
+ "logs",
442
473
  "index.js"
443
474
  ]
444
475
  },
@@ -500,15 +531,14 @@
500
531
  "index.js"
501
532
  ]
502
533
  },
503
- "logs": {
534
+ "settings": {
504
535
  "aliases": [],
505
536
  "args": {},
506
- "description": "View email send logs and delivery events",
537
+ "description": "View and update project settings",
507
538
  "examples": [
508
- "<%= config.bin %> logs",
509
- "<%= config.bin %> logs --email sarah@example.com",
510
- "<%= config.bin %> logs --failed",
511
- "<%= config.bin %> logs --json"
539
+ "<%= config.bin %> settings",
540
+ "<%= config.bin %> settings --set brand_color=#0F3460",
541
+ "<%= config.bin %> settings --json"
512
542
  ],
513
543
  "flags": {
514
544
  "json": {
@@ -524,31 +554,9 @@
524
554
  "allowNo": false,
525
555
  "type": "boolean"
526
556
  },
527
- "email": {
528
- "description": "Filter logs by contact email",
529
- "name": "email",
530
- "hasDynamicHelp": false,
531
- "multiple": false,
532
- "type": "option"
533
- },
534
- "failed": {
535
- "description": "Show only failed/bounced events",
536
- "name": "failed",
537
- "allowNo": false,
538
- "type": "boolean"
539
- },
540
- "limit": {
541
- "description": "Entries per page (max 200)",
542
- "name": "limit",
543
- "default": 50,
544
- "hasDynamicHelp": false,
545
- "multiple": false,
546
- "type": "option"
547
- },
548
- "page": {
549
- "description": "Page number",
550
- "name": "page",
551
- "default": 1,
557
+ "set": {
558
+ "description": "Set a setting (format: key=value)",
559
+ "name": "set",
552
560
  "hasDynamicHelp": false,
553
561
  "multiple": false,
554
562
  "type": "option"
@@ -556,7 +564,7 @@
556
564
  },
557
565
  "hasDynamicHelp": false,
558
566
  "hiddenAliases": [],
559
- "id": "logs",
567
+ "id": "settings",
560
568
  "pluginAlias": "@mailmodo/cli",
561
569
  "pluginName": "@mailmodo/cli",
562
570
  "pluginType": "core",
@@ -566,18 +574,17 @@
566
574
  "relativePath": [
567
575
  "dist",
568
576
  "commands",
569
- "logs",
577
+ "settings",
570
578
  "index.js"
571
579
  ]
572
580
  },
573
- "settings": {
581
+ "status": {
574
582
  "aliases": [],
575
583
  "args": {},
576
- "description": "View and update project settings",
584
+ "description": "View email performance metrics and quota usage",
577
585
  "examples": [
578
- "<%= config.bin %> settings",
579
- "<%= config.bin %> settings --set brand_color=#0F3460",
580
- "<%= config.bin %> settings --json"
586
+ "<%= config.bin %> status",
587
+ "<%= config.bin %> status --json"
581
588
  ],
582
589
  "flags": {
583
590
  "json": {
@@ -592,18 +599,11 @@
592
599
  "name": "yes",
593
600
  "allowNo": false,
594
601
  "type": "boolean"
595
- },
596
- "set": {
597
- "description": "Set a setting (format: key=value)",
598
- "name": "set",
599
- "hasDynamicHelp": false,
600
- "multiple": false,
601
- "type": "option"
602
602
  }
603
603
  },
604
604
  "hasDynamicHelp": false,
605
605
  "hiddenAliases": [],
606
- "id": "settings",
606
+ "id": "status",
607
607
  "pluginAlias": "@mailmodo/cli",
608
608
  "pluginName": "@mailmodo/cli",
609
609
  "pluginType": "core",
@@ -613,17 +613,17 @@
613
613
  "relativePath": [
614
614
  "dist",
615
615
  "commands",
616
- "settings",
616
+ "status",
617
617
  "index.js"
618
618
  ]
619
619
  },
620
- "status": {
620
+ "login": {
621
621
  "aliases": [],
622
622
  "args": {},
623
- "description": "View email performance metrics and quota usage",
623
+ "description": "Authenticate with Mailmodo using your API key",
624
624
  "examples": [
625
- "<%= config.bin %> status",
626
- "<%= config.bin %> status --json"
625
+ "<%= config.bin %> login",
626
+ "MAILMODO_API_KEY=YOUR_API_KEY <%= config.bin %> login"
627
627
  ],
628
628
  "flags": {
629
629
  "json": {
@@ -642,7 +642,7 @@
642
642
  },
643
643
  "hasDynamicHelp": false,
644
644
  "hiddenAliases": [],
645
- "id": "status",
645
+ "id": "login",
646
646
  "pluginAlias": "@mailmodo/cli",
647
647
  "pluginName": "@mailmodo/cli",
648
648
  "pluginType": "core",
@@ -652,10 +652,10 @@
652
652
  "relativePath": [
653
653
  "dist",
654
654
  "commands",
655
- "status",
655
+ "login",
656
656
  "index.js"
657
657
  ]
658
658
  }
659
659
  },
660
- "version": "0.0.49-beta.pr51.77"
660
+ "version": "0.0.49-beta.pr51.78"
661
661
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@mailmodo/cli",
3
3
  "description": "Email lifecycle automation for the AI-native builder generation.",
4
- "version": "0.0.49-beta.pr51.77",
4
+ "version": "0.0.49-beta.pr51.78",
5
5
  "author": "provishalk",
6
6
  "bin": {
7
7
  "mailmodo": "bin/run.js"