@entrydesk/cli 2.0.0-beta → 2.0.0

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 (50) hide show
  1. package/dist/{add-Cu0kBobt.js → add-CDlJBikf.js} +1 -1
  2. package/dist/agents-vivPBsWo.js +2 -0
  3. package/dist/billing-BietwbvI.js +2 -0
  4. package/dist/{budget-DhX2gt5z.js → budget-DcULs51p.js} +1 -1
  5. package/dist/build-task-request-config-Bbffa_rv.js +2 -0
  6. package/dist/commands-BCLJEd6x.js +2 -0
  7. package/dist/{commands-DbXuQqse.js → commands-CpuinJar.js} +1 -1
  8. package/dist/{config-eCQwQAt1.js → config-CI3k8CUK.js} +1 -1
  9. package/dist/connectors-CbkKDKQQ.js +3 -0
  10. package/dist/custom-connector-CxGNx65S.js +2 -0
  11. package/dist/format-BNEUX5Xv.js +2 -0
  12. package/dist/index.js +9 -9
  13. package/dist/{login-IvudGta0.js → login-y8SlHgZ4.js} +1 -1
  14. package/dist/{logout-Bjmk9YUh.js → logout-CGGEe0it.js} +1 -1
  15. package/dist/{marketplace-BPY5cD0d.js → marketplace-CaIuJP0T.js} +1 -1
  16. package/dist/{mcp-ydzvH8kz.js → mcp-Yz1qXxIb.js} +1 -1
  17. package/dist/{mcp-client-Cr_sHGPw.js → mcp-client-DdryEToX.js} +1 -1
  18. package/dist/{meeting-BDhBTbm3.js → meeting-CWv3iUU6.js} +1 -1
  19. package/dist/{models-BFnezI1c.js → models-DFEIoTPH.js} +1 -1
  20. package/dist/{notifications-4bo-vcIW.js → notifications-CBLIBZtc.js} +1 -1
  21. package/dist/{paths-BAZ2NsXN.js → paths-Cqjaa_lJ.js} +1 -1
  22. package/dist/{profile-BZo9STO2.js → profile-1uJ5EHdo.js} +1 -1
  23. package/dist/profile-storage-DYUIMuP0.js +72 -0
  24. package/dist/{push-Mb0Xb42_.js → push-BBY3QXxO.js} +1 -1
  25. package/dist/recordings-C0Ij3tfP.js +3 -0
  26. package/dist/{remove-CJiRVixg.js → remove-D-UQJ0IM.js} +1 -1
  27. package/dist/schedules-CFjtG3p4.js +21 -0
  28. package/dist/{skills-DYS1EQMn.js → skills-16msznfK.js} +1 -1
  29. package/dist/{status-BgIfKAmr.js → status-D6ebFbsw.js} +1 -1
  30. package/dist/{status-DzGv21m4.js → status-kRSNf0Ap.js} +1 -1
  31. package/dist/task-DKK82ixE.js +115 -0
  32. package/dist/{tasks-Dd-GdHfu.js → tasks-DX7CQir8.js} +2 -2
  33. package/dist/{tool-B6W8erW6.js → tool-3NEPlGNR.js} +1 -1
  34. package/dist/{update-CYieYkZl.js → update-DhNwkiwD.js} +1 -1
  35. package/dist/usage-050zvE6Q.js +3 -0
  36. package/dist/usage-audit-e6kpW0LZ.js +4 -0
  37. package/dist/version-orM51hu_.js +2 -0
  38. package/dist/{workflow-DlQtL_J-.js → workflow-DHTrGTRn.js} +1 -1
  39. package/dist/{workspaces-IAJitqaO.js → workspaces-BQiFZ5pV.js} +1 -1
  40. package/package.json +7 -7
  41. package/dist/agents--2Fw5-et.js +0 -2
  42. package/dist/billing-B96487c6.js +0 -2
  43. package/dist/commands-C1wX8XQY.js +0 -2
  44. package/dist/connectors-DGmZ4zTG.js +0 -3
  45. package/dist/profile-storage-mtd3aKrx.js +0 -72
  46. package/dist/recordings-D9jnWpxs.js +0 -3
  47. package/dist/schedules-BFoirR6r.js +0 -21
  48. package/dist/task-Db4UcJ6G.js +0 -115
  49. package/dist/usage-BLdNvuse.js +0 -3
  50. package/dist/version-Cos6L15W.js +0 -2
@@ -1,3 +0,0 @@
1
- #!/usr/bin/env node
2
- import{b as e,l as t}from"./profile-storage-mtd3aKrx.js";import{t as n}from"./confirm-BrJZbaxf.js";function r(e){if(e==null)return`—`;let t=Math.round(e),n=Math.floor(t/3600),r=Math.floor(t%3600/60),i=t%60,a=String(r).padStart(2,`0`),o=String(i).padStart(2,`0`);return n>0?`${n}:${a}:${o}`:`${r}:${o}`}async function i(n){let{accessToken:i,workspaceId:a}=await t(),{recordings:o,nextKey:s}=await new e().listRecordings(i,a,{limit:n.limit,nextKey:n.nextKey,search:n.search});if(n.json){console.log(JSON.stringify({recordings:o,nextKey:s}));return}if(o.length===0){console.log("No recordings yet. Import one with `entrydesk recordings import <url>`.");return}console.log(`Recordings (${o.length}):\n`);for(let e of o){let t=e.processingStatus??`ready`;console.log(` ${e.title}`),console.log(` ID: ${e.id}`),console.log(` ${r(e.duration)} · ${t}${e.source?` · ${e.source}`:``}`),console.log(``)}s&&console.log(`More results: --next-key ${s}`)}async function a(n,i){let{accessToken:a,workspaceId:o}=await t(),s=await new e().getRecording(a,o,n);if(i.json){console.log(JSON.stringify(s));return}if(console.log(s.title),console.log(`ID: ${s.id}`),console.log(`Status: ${s.processingStatus??`ready`}`),console.log(`Duration: ${r(s.duration)}`),s.recordedAt&&console.log(`Recorded: ${s.recordedAt}`),s.summary&&console.log(`\nSummary:\n${s.summary}`),s.actionItems&&s.actionItems.length>0){console.log(`
3
- Action items:`);for(let e of s.actionItems)console.log(` - ${e.description}`)}s.transcript&&console.log(`\nTranscript available — view with: entrydesk meeting transcript ${s.id}`)}async function o(n,r){let{accessToken:i,workspaceId:a}=await t(),o=await new e().importRecordingMedia(i,a,{url:n,title:r.title,modelId:r.model,preferredLanguage:r.language});if(r.json){console.log(JSON.stringify(o));return}console.log(`Importing ${o.source} recording.`),console.log(` Recording ID: ${o.recordingId}`),console.log(` ${o.message}`),console.log(` Check status: entrydesk recordings get ${o.recordingId}`)}async function s(n,i){let{accessToken:a,workspaceId:o}=await t(),s=await new e().previewRecordingMedia(a,o,n);if(i.json){console.log(JSON.stringify(s));return}console.log(`${s.title} [${s.type}]`),s.channelName&&console.log(`Channel: ${s.channelName}`),s.duration!=null&&console.log(`Duration: ${r(s.duration)}`),s.contentType&&console.log(`Type: ${s.contentType}`)}async function c(n,r){let{accessToken:i,workspaceId:a}=await t(),o=await new e().getRecordingAudioUrl(i,a,n);if(r.json){console.log(JSON.stringify(o));return}console.log(`Stream: ${o.url}`),console.log(`Download: ${o.downloadUrl}`)}async function l(n,r){let{accessToken:i,workspaceId:a}=await t(),o=await new e().retryRecording(i,a,n);if(r.json){console.log(JSON.stringify(o));return}console.log(o.message)}async function u(r,i){let{accessToken:a,workspaceId:o}=await t();if(!i.yes&&(process.stdin.isTTY||(console.error(`Deleting recording ${r} needs confirmation. Re-run with --yes.`),process.exit(1)),!await n(`Delete recording ${r}? This can't be undone from the CLI.`))){console.log(`Aborted.`);return}if(await new e().deleteRecording(a,o,r),i.json){console.log(JSON.stringify({id:r,deleted:!0}));return}console.log(`Deleted recording ${r}.`)}export{u as deleteRecording,o as importRecording,i as listRecordings,s as previewRecording,l as retryRecording,a as showRecording,c as showRecordingAudioUrl};
@@ -1,21 +0,0 @@
1
- #!/usr/bin/env node
2
- import{b as e,l as t,m as n}from"./profile-storage-mtd3aKrx.js";function r(e){return`${String(e.hour).padStart(2,`0`)}:${String(e.minute).padStart(2,`0`)}`}const i=[`Sun`,`Mon`,`Tue`,`Wed`,`Thu`,`Fri`,`Sat`];function a(e){return e?.length?` (windows: ${e.map(e=>`${r(e.start)}-${r(e.end)}`).join(`, `)})`:``}function o(e){return e?.length?` [days: ${e.map(e=>i[e]).join(`, `)}]`:``}function s(e){if(e.type===`no-repeat`)return`No repeat`;let{interval:t}=e;switch(t.unit){case`minutes`:return`Every ${t.every} minute${t.every>1?`s`:``}`+a(t.dailyWindows)+o(t.daysOfWeek);case`hours`:return`Every ${t.every} hour${t.every>1?`s`:``} at :${String(t.minute).padStart(2,`0`)}`+a(t.dailyWindows)+o(t.daysOfWeek);case`days`:{let e=`Every ${t.every} day${t.every>1?`s`:``} at ${r(t.time)}`;return t.times?.length&&(e+=` (times: ${t.times.map(r).join(`, `)})`),e+=o(t.daysOfWeek),e}case`weeks`:{let e=t.daysOfWeek.map(e=>i[e]).join(`, `);return`Every ${t.every} week${t.every>1?`s`:``} on ${e} at ${r(t.time)}`}case`months`:{let e=t.lastDayOfMonth?t.daysOfMonth.length>0?`${t.daysOfMonth.join(`, `)} and last day`:`last day`:t.daysOfMonth.join(`, `);return`Every ${t.every} month${t.every>1?`s`:``} on day ${e} at ${String(t.time.hour).padStart(2,`0`)}:${String(t.time.minute).padStart(2,`0`)}`}default:return`Unknown`}}function c(e,t){let n=new Date(e),r=t.match(/^([+-])(\d{2}):(\d{2})$/);if(!r)return n.toISOString();let i=r[1]===`+`?1:-1,a=Number.parseInt(r[2],10),o=Number.parseInt(r[3],10),s=i*(a*60+o)*60*1e3;return`${new Date(n.getTime()+s).toISOString().replace(`T`,` `).slice(0,19)} (${t})`}function l(e){console.log(`
3
- Schedule: ${e.name}
4
- ${`━`.repeat(50)}
5
- ID: ${e.id}
6
- Agent: ${e.agent.name}
7
- Status: ${e.isActive?`Active`:`Paused`}
8
- Timezone: ${e.utcOffset}
9
-
10
- Prompt:
11
- ${e.prompt.slice(0,200)}${e.prompt.length>200?`…`:``}
12
-
13
- Schedule:
14
- ${s(e.config)}
15
-
16
- Holiday Calendars: ${e.holidayCalendarIds?.length?e.holidayCalendarIds.join(`, `):`-`}
17
-
18
- Next run: ${e.nextRunAt?c(e.nextRunAt,e.utcOffset):`-`}
19
- Created: ${c(e.createdAt,e.utcOffset)}
20
- Updated: ${c(e.updatedAt,e.utcOffset)}
21
- `)}function u(e){console.log(`Runs (${e.length}):\n`);for(let t of e){let e=new Date(t.scheduledAt).toLocaleString(),n;n=t.status===`skipped`?t.skipReason===`holiday`?`Skipped (holiday)`:`Skipped`:t.task?.title??`(task unavailable)`;let r=t.task&&!t.task.read?` (unread)`:``;console.log(` ${e}`),console.log(` Task: ${n}${r}`),t.task&&console.log(` Task ID: ${t.task.id}`),console.log(` Run ID: ${t.id}`),console.log(``)}}function d(e){if(e.length===0){console.log(`No connected calendar accounts. Connect one in the Hub first.`);return}console.log(`Connected calendar accounts (${e.length}):\n`);for(let t of e){let e=n(t.provider),r=n(t.email);console.log(` ${e} (${r})`),console.log(` Account ID: ${t.id}`);for(let e of t.calendars){let t=e.isVisible?``:` (hidden)`,r=n(e.name);console.log(` ${e.id} ${r}${t}`)}console.log(``)}}function f(e,t,n){return e.type===`no-repeat`?t===void 0?(n?.length??0)>0?[]:void 0:[]:t??n??void 0}function p(e){let t=e.repeatType||`no-repeat`;e.times!==void 0&&t!==`days`&&(console.error(`--times is only supported with --repeat-type days.`),process.exit(1)),e.dailyWindows!==void 0&&t!==`minutes`&&t!==`hours`&&(console.error(`--daily-windows is only supported with --repeat-type minutes or hours.`),process.exit(1)),e.daysOfWeek!==void 0&&t!==`minutes`&&t!==`hours`&&t!==`days`&&t!==`weeks`&&(console.error(`--days-of-week is only supported with --repeat-type minutes, hours, days, or weeks.`),process.exit(1))}function m(e){if(e.type!==`repeat`)return;let{interval:t}=e;t.unit===`hours`&&(t.every<24||((t.dailyWindows?.length??0)>0&&(console.error(`--daily-windows is not available with --repeat-type hours and --every 24 or more (equivalent to a daily interval, and the existing schedule already has active windows set) — use --repeat-type days instead.`),process.exit(1)),(t.daysOfWeek?.length??0)>0&&(console.error(`--days-of-week is not available with --repeat-type hours and --every 24 or more (equivalent to a daily interval, and the existing schedule already has a weekday filter set) — use --repeat-type days instead.`),process.exit(1))))}function h(e,t){let n=e.repeatType||`no-repeat`;if(n===`no-repeat`)return{type:`no-repeat`};let r=t?.type===`repeat`&&t.interval.unit===n?t.interval:void 0,i=e.every??r?.every??1;function a(){return e.time?e.time:r&&`time`in r?r.time:{hour:9,minute:0}}switch(n){case`minutes`:return{type:`repeat`,interval:{unit:`minutes`,every:i,dailyWindows:e.dailyWindows??(r?.unit===`minutes`?r.dailyWindows:void 0),daysOfWeek:e.daysOfWeek??(r?.unit===`minutes`?r.daysOfWeek:void 0)}};case`hours`:return{type:`repeat`,interval:{unit:`hours`,every:i,minute:e.time?a().minute:r?.unit===`hours`?r.minute:0,dailyWindows:e.dailyWindows??(r?.unit===`hours`?r.dailyWindows:void 0),daysOfWeek:e.daysOfWeek??(r?.unit===`hours`?r.daysOfWeek:void 0)}};case`days`:return{type:`repeat`,interval:{unit:`days`,every:i,time:a(),times:e.times??(r?.unit===`days`?r.times:void 0),daysOfWeek:e.daysOfWeek??(r?.unit===`days`?r.daysOfWeek:void 0)}};case`weeks`:return{type:`repeat`,interval:{unit:`weeks`,every:i,daysOfWeek:e.daysOfWeek??(r?.unit===`weeks`?r.daysOfWeek:[1]),time:a()}};case`months`:return{type:`repeat`,interval:{unit:`months`,every:i,daysOfMonth:e.daysOfMonth??(r?.unit===`months`?r.daysOfMonth:[1]),lastDayOfMonth:e.lastDayOfMonth??(r?.unit===`months`&&r.lastDayOfMonth),time:a()}};default:return{type:`no-repeat`}}}async function g(n){let{accessToken:r,workspaceId:i}=await t(),a=new e,o=[],l;do{let e=await a.getSchedules(r,i,{nextKey:l,limit:100});o.push(...e.schedules),l=e.nextKey}while(l);if(n.json){console.log(JSON.stringify(o));return}if(o.length===0){console.log("No schedules in this workspace yet. Create one with `entrydesk schedules create --name <name> --prompt <text> --agent-id <id> --starts-at <time>`.");return}console.log(`Schedules (${o.length}):\n`);for(let e of o){let t=e.isActive?`\x1B[32mActive\x1B[0m`:`\x1B[33mPaused\x1B[0m`;console.log(` ${e.name}`),console.log(` Agent: ${e.agent.name}`),console.log(` Repeat: ${s(e.config)}`),console.log(` Status: ${t}`),console.log(` Next run: ${e.nextRunAt?c(e.nextRunAt,e.utcOffset):`-`}`),console.log(` ID: ${e.id}`),console.log(``)}}async function _(n,r){let{accessToken:i,workspaceId:a}=await t(),o=await new e().getSchedule(i,a,n);if(r.json){console.log(JSON.stringify(o));return}l(o)}async function v(n){p(n);let r=h(n);m(r);let{accessToken:i,workspaceId:a}=await t(),o={name:n.name,prompt:n.prompt,agentId:n.agentId,startsAt:n.startsAt,config:r,utcOffset:n.utcOffset||`+00:00`,holidayCalendarIds:f(r,n.holidayCalendars,void 0)},s=await new e().createSchedule(i,a,o);if(n.json){console.log(JSON.stringify(s));return}console.log(`Created schedule: ${s.name}`),console.log(` ID: ${s.id}`),console.log(` Next run: ${s.nextRunAt?c(s.nextRunAt,s.utcOffset):`-`}`)}async function y(n,r){let{accessToken:i,workspaceId:a}=await t(),o=new e,s=await o.getSchedule(i,a,n),c=r.agentId??s.agent?.id,l=r.agentId!==void 0&&r.agentId!==s.agent?.id;c||(console.error(`This schedule is not agent-based; the CLI can only edit agent schedules.`),process.exit(1)),(r.every!==void 0||r.time!==void 0||r.daysOfWeek!==void 0||r.daysOfMonth!==void 0||r.lastDayOfMonth!==void 0||r.dailyWindows!==void 0||r.times!==void 0)&&!r.repeatType&&(console.error(`To change the cadence, pass --repeat-type along with the repeat options.`),process.exit(1)),r.repeatType&&p(r);let u=r.repeatType?h(r,s.config):s.config;r.repeatType&&m(u);let d={name:r.name??s.name,prompt:r.prompt??s.prompt,agentId:c,startsAt:r.startsAt??s.startsAt,config:u,utcOffset:r.utcOffset??s.utcOffset,holidayCalendarIds:f(u,r.holidayCalendars,l?void 0:s.holidayCalendarIds)};if(await o.updateSchedule(i,a,n,d),s.isActive||await o.deactivateSchedule(i,a,n),r.json){console.log(JSON.stringify({id:n,updated:!0}));return}console.log(`Updated schedule: ${n}`)}async function b(n,r,i){let{accessToken:a,workspaceId:o}=await t(),s=new e;if(await(r?s.activateSchedule(a,o,n):s.deactivateSchedule(a,o,n)),i.json){console.log(JSON.stringify({id:n,isActive:r}));return}console.log(`${r?`Activated`:`Paused`} schedule: ${n}`)}async function x(n,r){let{accessToken:i,workspaceId:a}=await t(),{taskId:o}=await new e().runScheduleNow(i,a,n);if(r.json){console.log(JSON.stringify({taskId:o}));return}console.log(`Started run for schedule ${n}`),console.log(` Task ID: ${o}`)}async function S(n,r){let{accessToken:i,workspaceId:a}=await t(),o=new e;if(r.all){let e=[],t;for(let s=0;;s++){s>=100&&(console.error(`Reached maximum page limit (100). Use --limit and --next-key for manual pagination.`),process.exit(1));let c=await o.getScheduleRuns(i,a,n,{limit:r.limit??20,nextKey:t});if(e.push(...c.runs),t=c.nextKey,!t)break}if(r.json){console.log(JSON.stringify({runs:e}));return}if(e.length===0){console.log(`No runs for this schedule.`);return}u(e);return}let{runs:s,nextKey:c}=await o.getScheduleRuns(i,a,n,{limit:r.limit,nextKey:r.nextKey});if(r.json){console.log(JSON.stringify({runs:s,nextKey:c}));return}if(s.length===0){console.log(`No runs for this schedule.`);return}u(s),c&&console.log(`Next page: --next-key ${c}`)}async function C(n){let{accessToken:r,workspaceId:i}=await t();await new e().deleteSchedule(r,i,n),console.log(`Deleted schedule: ${n}`)}async function w(n){let{accessToken:r,workspaceId:i}=await t(),{accounts:a}=await new e().getCalendarAccounts(r,i);if(n.json){console.log(JSON.stringify({accounts:a}));return}d(a)}export{v as createSchedule,C as deleteSchedule,y as editSchedule,w as listCalendarAccounts,S as listScheduleRuns,g as listSchedules,x as runScheduleNow,b as setScheduleActive,_ as showSchedule};