@circleback/cli 0.1.10 → 0.1.12

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.
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.forceRefreshToken = exports.getValidAccessToken = exports.login = exports.refreshAccessToken = void 0;
6
+ exports.forceRefreshToken = exports.getValidAccessToken = exports.login = void 0;
7
7
  const node_child_process_1 = require("node:child_process");
8
8
  const node_crypto_1 = __importDefault(require("node:crypto"));
9
9
  const constants_1 = require("../constants");
@@ -89,7 +89,6 @@ const refreshAccessToken = async (refreshToken, clientId) => {
89
89
  }
90
90
  return tokenData;
91
91
  };
92
- exports.refreshAccessToken = refreshAccessToken;
93
92
  const login = async (options = {}) => {
94
93
  const { port, waitForCallback, shutdown } = await (0, server_1.startCallbackServer)();
95
94
  const redirectUri = `http://127.0.0.1:${port}`;
@@ -143,7 +142,7 @@ const requireTokens = () => {
143
142
  return tokens;
144
143
  };
145
144
  const refreshAndSave = async (tokens) => {
146
- const refreshed = await (0, exports.refreshAccessToken)(tokens.refreshToken, tokens.clientId);
145
+ const refreshed = await refreshAccessToken(tokens.refreshToken, tokens.clientId);
147
146
  const updatedTokens = (0, tokenStorage_1.buildStoredTokens)(refreshed, tokens.clientId);
148
147
  (0, tokenStorage_1.saveTokens)(updatedTokens);
149
148
  return updatedTokens.accessToken;
@@ -67,13 +67,13 @@ exports.searchMeetingsCommand = new commander_1.Command('search')
67
67
  });
68
68
  exports.readMeetingsCommand = new commander_1.Command('read')
69
69
  .description('Get detailed meeting information.')
70
- .argument('<ids...>', 'Meeting numeric IDs or linkIds (max 50)')
70
+ .argument('<ids...>', 'Meeting IDs (max 50)')
71
71
  .action(async (ids) => {
72
72
  try {
73
73
  const jsonMode = exports.readMeetingsCommand.parent?.parent?.opts().json ?? false;
74
74
  const meetingIds = (0, parse_1.validateMeetingIdentifiers)(ids);
75
75
  const result = await (0, jsonRpc_1.callTool)('ReadMeetings', {
76
- intent: `Reading meeting details for IDs or linkIds: ${meetingIds.join(', ')}.`,
76
+ intent: `Reading meeting details for IDs: ${meetingIds.join(', ')}.`,
77
77
  meetingIds,
78
78
  });
79
79
  (0, formatter_1.formatOutput)('ReadMeetings', result, jsonMode);
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getAllCommands = exports.commandGroups = exports.standaloneCommands = void 0;
3
+ exports.getAllCommands = void 0;
4
4
  const commander_1 = require("commander");
5
5
  const actionItems_1 = require("./actionItems");
6
6
  const auth_1 = require("./auth");
@@ -13,12 +13,12 @@ const support_1 = require("./support");
13
13
  const tags_1 = require("./tags");
14
14
  const transcripts_1 = require("./transcripts");
15
15
  const update_1 = require("./update");
16
- exports.standaloneCommands = [
16
+ const standaloneCommands = [
17
17
  auth_1.loginCommand,
18
18
  auth_1.logoutCommand,
19
19
  update_1.updateCommand,
20
20
  ];
21
- exports.commandGroups = [
21
+ const commandGroups = [
22
22
  {
23
23
  name: 'meetings',
24
24
  description: 'Search meetings with `cb meetings search [term]` and read them with `cb meetings read <id>`.',
@@ -67,7 +67,7 @@ exports.commandGroups = [
67
67
  ];
68
68
  const buildCommandGroup = (definition) => definition.subcommands.reduce((group, command, index) => group.addCommand(command, index === 0 ? { isDefault: true } : undefined), new commander_1.Command(definition.name).description(definition.description));
69
69
  const getAllCommands = () => [
70
- ...exports.standaloneCommands,
71
- ...exports.commandGroups.map(buildCommandGroup),
70
+ ...standaloneCommands,
71
+ ...commandGroups.map(buildCommandGroup),
72
72
  ];
73
73
  exports.getAllCommands = getAllCommands;
@@ -44,14 +44,14 @@ exports.searchTranscriptsCommand = new commander_1.Command('search')
44
44
  });
45
45
  exports.getTranscriptsCommand = new commander_1.Command('read')
46
46
  .description('Get full meeting transcripts.')
47
- .argument('<meetingId...>', 'Meeting numeric IDs or linkIds (max 50)')
47
+ .argument('<ids...>', 'Meeting IDs (max 50)')
48
48
  .showHelpAfterError(true)
49
49
  .action(async (ids) => {
50
50
  try {
51
51
  const jsonMode = exports.getTranscriptsCommand.parent?.parent?.opts().json ?? false;
52
52
  const meetingIds = (0, parse_1.validateMeetingIdentifiers)(ids);
53
53
  const result = await (0, jsonRpc_1.callTool)('GetTranscriptsForMeetings', {
54
- intent: `Getting transcripts for meetings with IDs or linkIds: ${meetingIds.join(', ')}.`,
54
+ intent: `Getting transcripts for meetings with IDs: ${meetingIds.join(', ')}.`,
55
55
  meetingIds,
56
56
  });
57
57
  (0, formatter_1.formatOutput)('GetTranscriptsForMeetings', result, jsonMode);
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.validateMeetingIdentifiers = exports.validateNumericIds = exports.parseNumericIds = exports.parseIntOption = exports.extractAndValidateObjectFromString = void 0;
6
+ exports.validateMeetingIdentifiers = exports.parseNumericIds = exports.parseIntOption = exports.extractAndValidateObjectFromString = void 0;
7
7
  const chalk_1 = __importDefault(require("chalk"));
8
8
  const zod_1 = require("zod");
9
9
  const extractAndValidateObjectFromString = (rawText, schema) => {
@@ -40,21 +40,12 @@ const parseNumericIds = (value, label) => {
40
40
  return result.data;
41
41
  };
42
42
  exports.parseNumericIds = parseNumericIds;
43
- const validateNumericIds = (values, label) => {
44
- const result = numericIdsSchema.safeParse(values);
45
- if (!result.success) {
46
- console.error(chalk_1.default.red(`Invalid ${label}. Expected numeric IDs.`));
47
- process.exit(1);
48
- }
49
- return result.data;
50
- };
51
- exports.validateNumericIds = validateNumericIds;
52
43
  const validateMeetingIdentifiers = (values) => {
53
44
  const cleanedValues = values.map((value) => value.trim()).filter(Boolean);
54
45
  const isValidIdentifier = /^[A-Za-z0-9_-]{1,64}$/;
55
46
  if (cleanedValues.length === 0 ||
56
47
  cleanedValues.some((value) => !isValidIdentifier.test(value))) {
57
- console.error(chalk_1.default.red('Invalid meeting identifiers. Expected one or more numeric IDs or linkIds.'));
48
+ console.error(chalk_1.default.red('Invalid meeting identifiers. Expected one or more meeting IDs.'));
58
49
  process.exit(1);
59
50
  }
60
51
  return cleanedValues;
@@ -3,11 +3,11 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.BANNER = exports.tableStyle = exports.secondary = exports.brand = void 0;
6
+ exports.BANNER = exports.tableStyle = exports.brand = void 0;
7
7
  const chalk_1 = __importDefault(require("chalk"));
8
8
  const constants_1 = require("../constants");
9
9
  exports.brand = chalk_1.default.hex(constants_1.BRAND_COLOR);
10
- exports.secondary = chalk_1.default.hex(constants_1.SECONDARY_COLOR);
10
+ const secondary = chalk_1.default.hex(constants_1.SECONDARY_COLOR);
11
11
  exports.tableStyle = { head: [], border: [] };
12
12
  exports.BANNER = [
13
13
  '',
@@ -15,7 +15,7 @@ exports.BANNER = [
15
15
  constants_1.ASCII_LOGO.split('\n')
16
16
  .map((line) => line
17
17
  .replace(/=+/g, (match) => (0, exports.brand)(match))
18
- .replace(/\++/g, (match) => (0, exports.secondary)(match)))
18
+ .replace(/\++/g, (match) => secondary(match)))
19
19
  .join('\n'),
20
20
  '',
21
21
  ].join('\n');
@@ -39,7 +39,7 @@ const formatSender = (sender) => {
39
39
  const formatMeetingsList = (meetings) => {
40
40
  if (meetings.length === 0)
41
41
  return chalk_1.default.yellow('No meetings found.');
42
- const idWidth = idColumnWidth(meetings.map((meeting) => meeting.id));
42
+ const idWidth = idColumnWidth(meetings.map((meeting) => meeting.linkId));
43
43
  const nameWidth = 40;
44
44
  const dateWidth = 14;
45
45
  const attendeesWidth = 30;
@@ -56,7 +56,7 @@ const formatMeetingsList = (meetings) => {
56
56
  });
57
57
  table.push(...meetings.map((meeting) => [
58
58
  (0, string_1.truncate)(meeting.name, nameWidth - 2),
59
- meeting.id,
59
+ meeting.linkId,
60
60
  (0, date_1.formatDate)(meeting.createdAt),
61
61
  meeting.attendees.map(formatAttendee).join('\n'),
62
62
  ]));
@@ -70,7 +70,7 @@ const formatMeetingDetails = (meetings) => {
70
70
  .map((meeting) => {
71
71
  const header = chalk_1.default.bold.cyan(`\n# ${meeting.name}`);
72
72
  const meta = [
73
- `${chalk_1.default.bold('ID:')} ${meeting.id}`,
73
+ `${chalk_1.default.bold('ID:')} ${meeting.linkId}`,
74
74
  `${chalk_1.default.bold('Date:')} ${(0, date_1.formatDate)(meeting.createdAt)}`,
75
75
  meeting.duration
76
76
  ? `${chalk_1.default.bold('Duration:')} ${(0, lodash_1.round)(meeting.duration / 60)} min`
@@ -79,6 +79,9 @@ const formatMeetingDetails = (meetings) => {
79
79
  (meeting.tags ?? []).length > 0
80
80
  ? `${chalk_1.default.bold('Tags:')} ${(meeting.tags ?? []).join(', ')}`
81
81
  : null,
82
+ meeting.recordingUrl
83
+ ? `${chalk_1.default.bold('Recording:')} ${meeting.recordingUrl}`
84
+ : null,
82
85
  ]
83
86
  .filter(Boolean)
84
87
  .join('\n');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@circleback/cli",
3
- "version": "0.1.10",
3
+ "version": "0.1.12",
4
4
  "description": "Circleback CLI. Search and access meetings, emails, calendar events, and more.",
5
5
  "license": "MIT",
6
6
  "author": "Circleback <support@circleback.ai> (https://circleback.ai)",