@sideboard-ai/core 0.1.130 → 0.1.133

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 (51) hide show
  1. package/dist/abletime-DDTV7WO3.js +36 -0
  2. package/dist/abletime-VTP4JR63.js +37 -0
  3. package/dist/agents/cursor-runner.js +1 -1
  4. package/dist/{agents-7BUQY2WX.js → agents-NHS6P25H.js} +8 -6
  5. package/dist/{agents-X2I3RNCY.js → agents-SOU5GPWI.js} +9 -7
  6. package/dist/{app-settings-6RPALX4J.js → app-settings-U5RZKUXG.js} +11 -1
  7. package/dist/{app-settings-E7NEQY7D.js → app-settings-YQ7YX2CC.js} +11 -1
  8. package/dist/chunk-2XXAAIN3.js +463 -0
  9. package/dist/{chunk-VE22NWBD.js → chunk-3UVVWNHF.js} +2 -2
  10. package/dist/{chunk-NV73AO7Q.js → chunk-4YAVXWFR.js} +21 -9
  11. package/dist/{chunk-RSFCB23A.js → chunk-6CRKPD4C.js} +4 -3
  12. package/dist/chunk-6GN5WPYZ.js +31 -0
  13. package/dist/{chunk-ZMUOPTKZ.js → chunk-AK7SWE2U.js} +55 -12
  14. package/dist/chunk-AT346U23.js +468 -0
  15. package/dist/{chunk-YMRT2DU6.js → chunk-ED4UPEJX.js} +25 -50
  16. package/dist/chunk-ELBYOGVA.js +32 -0
  17. package/dist/{chunk-IUJOI7KK.js → chunk-FSCQXMGI.js} +35 -4
  18. package/dist/{chunk-HUYEU4GS.js → chunk-GJBHOJCZ.js} +83 -2
  19. package/dist/{chunk-ZND6XV6J.js → chunk-GKKHXZCT.js} +83 -2
  20. package/dist/{chunk-HZPO3SSZ.js → chunk-IM36S4HZ.js} +4 -3
  21. package/dist/{chunk-EKIDHL2T.js → chunk-KBWND62T.js} +32 -55
  22. package/dist/{chunk-HULESWLI.js → chunk-LTP7GHIF.js} +3 -3
  23. package/dist/chunk-M267JPEA.js +103 -0
  24. package/dist/{chunk-HRSBZIXS.js → chunk-Q6XQXCOM.js} +1 -1
  25. package/dist/chunk-S42XV45P.js +104 -0
  26. package/dist/{chunk-YALVX3UE.js → chunk-TG7YU2KG.js} +157 -40
  27. package/dist/{chunk-FMBLOOAO.js → chunk-VSON7EJ6.js} +155 -39
  28. package/dist/{chunk-UDQI3N47.js → chunk-WEU5M7BW.js} +1 -1
  29. package/dist/{chunk-SYLTXDRF.js → chunk-Y645NFYN.js} +2 -2
  30. package/dist/{chunk-MNL4FSKY.js → chunk-YEIH7P7D.js} +3 -3
  31. package/dist/{connected-teams-ZCOU6KCD.js → connected-teams-4A2AXDNN.js} +3 -1
  32. package/dist/{connected-teams-O6D4PM7A.js → connected-teams-IJUJQ7R6.js} +3 -1
  33. package/dist/{coordinator-prompt-SPJSGAQS.js → coordinator-prompt-DXHEDRRN.js} +3 -3
  34. package/dist/{coordinator-prompt-MEEUOEF2.js → coordinator-prompt-XF7LVOUN.js} +3 -3
  35. package/dist/{global-workspace-KNESLWKG.js → global-workspace-2LO5ATOH.js} +4 -4
  36. package/dist/{global-workspace-BMWP7YZC.js → global-workspace-MLQNULOU.js} +4 -4
  37. package/dist/index.cjs +1410 -425
  38. package/dist/index.d.cts +224 -16
  39. package/dist/index.d.ts +224 -16
  40. package/dist/index.js +461 -292
  41. package/dist/mcp/run-stdio.cjs +1261 -342
  42. package/dist/mcp/run-stdio.js +340 -209
  43. package/dist/oauth-A7XXI2TM.js +11 -0
  44. package/dist/oauth-YJBAURIJ.js +13 -0
  45. package/dist/{orchestrator-3ZSFTG72.js → orchestrator-KR5RA5B7.js} +10 -8
  46. package/dist/{orchestrator-G6DU3AF3.js → orchestrator-P2SYHVLS.js} +11 -9
  47. package/dist/{workspaces-O4QZOASB.js → workspaces-ARWPZG6F.js} +5 -5
  48. package/dist/{workspaces-HSYRYJYV.js → workspaces-MINB764G.js} +5 -5
  49. package/dist/{worktree-ERHC7Q4F.js → worktree-EBZMUUAL.js} +2 -2
  50. package/dist/{worktree-JVGSLSLJ.js → worktree-S7MKMYAT.js} +2 -2
  51. package/package.json +1 -1
package/dist/index.d.cts CHANGED
@@ -779,6 +779,15 @@ interface IntegrationsSettings {
779
779
  githubGitAuthMode?: GithubGitAuthMode;
780
780
  /** Fine-grained or classic PAT when mode is `token` (vaulted). */
781
781
  githubPat?: string;
782
+ /**
783
+ * AbleTime personal access token (`apt_…`) for hosted MCP
784
+ * (`POST {host}/api/public/v2/mcp`). Vaulted.
785
+ */
786
+ abletimeAccessToken?: string;
787
+ /** AbleTime host (default https://track.abletime.com). */
788
+ abletimeHost?: string;
789
+ /** Display name of the connected AbleTime user (non-secret). */
790
+ abletimeViewerName?: string;
782
791
  }
783
792
  /**
784
793
  * Conductor-inspired power-user preferences (Settings → Advanced).
@@ -878,7 +887,7 @@ interface AppSettings {
878
887
  advanced: AdvancedAppSettings;
879
888
  }
880
889
  /** Integrations fields safe to send to the renderer (no token values). */
881
- type PublicIntegrationsSettings = Omit<IntegrationsSettings, 'linearApiKey' | 'linearAccessToken' | 'linearRefreshToken' | 'linearClientSecret' | 'slackClientSecret' | 'slackAppToken' | 'githubPat'> & {
890
+ type PublicIntegrationsSettings = Omit<IntegrationsSettings, 'linearApiKey' | 'linearAccessToken' | 'linearRefreshToken' | 'linearClientSecret' | 'slackClientSecret' | 'slackAppToken' | 'githubPat' | 'abletimeAccessToken'> & {
882
891
  /** True when Linear is connected (OAuth or API key). */
883
892
  hasLinearApiKey: boolean;
884
893
  hasLinearOAuth: boolean;
@@ -886,6 +895,8 @@ type PublicIntegrationsSettings = Omit<IntegrationsSettings, 'linearApiKey' | 'l
886
895
  hasSlackAppToken: boolean;
887
896
  /** True when a GitHub PAT is stored (token mode). */
888
897
  hasGithubPat: boolean;
898
+ /** True when an AbleTime personal access token is stored. */
899
+ hasAbleTimeToken: boolean;
889
900
  };
890
901
  /** Settings payload for the desktop UI. Secret values are omitted. */
891
902
  type PublicAppSettings = Omit<AppSettings, 'integrations'> & {
@@ -927,6 +938,9 @@ declare function updateIntegrationsSettings(patch: {
927
938
  slackDeviceLabel?: string | null;
928
939
  githubGitAuthMode?: GithubGitAuthMode | null;
929
940
  githubPat?: string | null;
941
+ abletimeAccessToken?: string | null;
942
+ abletimeHost?: string | null;
943
+ abletimeViewerName?: string | null;
930
944
  }): AppSettings;
931
945
  declare function updateDefaultsSettings(patch: {
932
946
  agent?: AgentKind | null;
@@ -978,6 +992,18 @@ declare function saveLinearOAuth(input: {
978
992
  }): AppSettings;
979
993
  /** Clear Linear OAuth tokens and API key. Does not revoke remotely. */
980
994
  declare function disconnectLinearConnection(): AppSettings;
995
+ /** True when Sideboard has an AbleTime personal access token stored. */
996
+ declare function isAbleTimeConnected(settings?: AppSettings): boolean;
997
+ declare function getAbleTimeAccessToken(settings?: AppSettings): string | null;
998
+ declare function getAbleTimeHost(settings?: AppSettings): string;
999
+ /** Persist AbleTime PAT after a successful MCP orientation. */
1000
+ declare function saveAbleTimeConnection(input: {
1001
+ accessToken: string;
1002
+ host?: string | null;
1003
+ viewerName?: string | null;
1004
+ }): AppSettings;
1005
+ /** Clear AbleTime PAT and viewer. Does not revoke remotely. */
1006
+ declare function disconnectAbleTimeConnection(): AppSettings;
981
1007
  /** Preferred issue source (default GitHub). */
982
1008
  declare function getIssueSource(settings?: AppSettings): IssueSource;
983
1009
  /** Declared GitHub git-auth mode (default `auto`). */
@@ -986,12 +1012,11 @@ declare function getGithubGitAuthMode(settings?: AppSettings): GithubGitAuthMode
986
1012
  declare function getGithubPat(settings?: AppSettings): string | null;
987
1013
  /**
988
1014
  * Whether this preferred source can list issues today.
989
- * AbleTime is typed for Home/Create/Settings but has no client yet.
990
1015
  */
991
1016
  declare function isIssueSourceConnected(source: IssueSource, settings?: AppSettings): boolean;
992
1017
  /**
993
1018
  * Runtime issue source: honors preference, but falls back to GitHub when
994
- * the preferred tracker is not connected (Linear unconnected, AbleTime, …).
1019
+ * the preferred tracker is not connected.
995
1020
  */
996
1021
  declare function resolveEffectiveIssueSource(settings?: AppSettings): IssueSource;
997
1022
  declare function getLinearApiKey(settings?: AppSettings): string | null;
@@ -1874,11 +1899,125 @@ declare function startLinearOAuth(opts?: {
1874
1899
  /** Revoke OAuth tokens (best-effort) and clear Linear credentials including API key. */
1875
1900
  declare function disconnectLinear(): Promise<AppSettings>;
1876
1901
 
1902
+ interface AbleTimeTask {
1903
+ id: string;
1904
+ identifier: string;
1905
+ title: string;
1906
+ url: string;
1907
+ description?: string;
1908
+ state?: string;
1909
+ projectId?: string;
1910
+ categoryId?: string;
1911
+ assignee?: {
1912
+ id?: string;
1913
+ name: string;
1914
+ };
1915
+ labels: string[];
1916
+ }
1917
+ interface AbleTimeProject {
1918
+ id: string;
1919
+ name: string;
1920
+ categories: Array<{
1921
+ id: string;
1922
+ name: string;
1923
+ }>;
1924
+ }
1925
+ interface AbleTimeViewer {
1926
+ name?: string;
1927
+ id?: string;
1928
+ }
1929
+ interface AbleTimeOrientation {
1930
+ viewer: AbleTimeViewer;
1931
+ projects: AbleTimeProject[];
1932
+ tasks: AbleTimeTask[];
1933
+ raw: unknown;
1934
+ }
1935
+ declare function taskUrl(task: Pick<AbleTimeTask, 'id' | 'identifier'>, host?: string | null): string;
1936
+ declare function mapAbleTimeTask(raw: unknown, host?: string | null): AbleTimeTask | null;
1937
+ declare function toAbleTimeIssueInfo(task: AbleTimeTask): IssueInfo;
1938
+ declare function issueAttachmentForAbleTimeTask(task: AbleTimeTask): ThreadAttachment;
1939
+ declare function getAbleTimeOrientation(opts?: {
1940
+ token?: string | null;
1941
+ host?: string | null;
1942
+ }): Promise<AbleTimeOrientation>;
1943
+ declare function listAbleTimeProjects(opts?: {
1944
+ token?: string | null;
1945
+ host?: string | null;
1946
+ }): Promise<AbleTimeProject[]>;
1947
+ declare function listAbleTimeTasks(opts?: {
1948
+ token?: string | null;
1949
+ host?: string | null;
1950
+ projectId?: string;
1951
+ query?: string;
1952
+ includeClosed?: boolean;
1953
+ }): Promise<AbleTimeTask[]>;
1954
+ declare function searchAbleTimeTasks(query: string, opts?: {
1955
+ token?: string | null;
1956
+ host?: string | null;
1957
+ }): Promise<AbleTimeTask[]>;
1958
+ declare function getAbleTimeTask(id: string, opts?: {
1959
+ token?: string | null;
1960
+ host?: string | null;
1961
+ }): Promise<AbleTimeTask>;
1962
+ declare function createAbleTimeTask(input: {
1963
+ title: string;
1964
+ description?: string;
1965
+ projectId?: string;
1966
+ categoryId?: string;
1967
+ state?: 'backlog' | 'todo';
1968
+ }, opts?: {
1969
+ token?: string | null;
1970
+ host?: string | null;
1971
+ }): Promise<AbleTimeTask>;
1972
+ /**
1973
+ * Find an open AbleTime task for this work, or create one to track against.
1974
+ * Matches identifier or exact title before creating.
1975
+ */
1976
+ declare function ensureAbleTimeTask(input: {
1977
+ title: string;
1978
+ description?: string;
1979
+ projectId?: string;
1980
+ categoryId?: string;
1981
+ }, opts?: {
1982
+ token?: string | null;
1983
+ host?: string | null;
1984
+ }): Promise<AbleTimeTask & {
1985
+ created: boolean;
1986
+ }>;
1987
+ type AbleTimeAssignedIssuesResult = {
1988
+ viewer: AbleTimeViewer;
1989
+ issues: IssueInfo[];
1990
+ };
1991
+ declare function listAbleTimeAssignedIssues(opts?: {
1992
+ token?: string | null;
1993
+ host?: string | null;
1994
+ }): Promise<AbleTimeAssignedIssuesResult>;
1995
+ declare function verifyAbleTimeConnection(input: {
1996
+ token: string;
1997
+ host?: string | null;
1998
+ }): Promise<AbleTimeViewer>;
1999
+
2000
+ declare const DEFAULT_ABLETIME_HOST = "https://track.abletime.com";
2001
+ declare const ABLETIME_MCP_PATH = "/api/public/v2/mcp";
2002
+ type AbleTimeMcpToolName = 'orientation' | 'upsert_entry' | 'update_entry' | 'list_entries' | 'delete_entry' | 'accept_entry' | 'get_project' | 'create_task' | 'update_task' | 'get_task' | 'list_tasks' | 'set_task_state' | 'create_comment' | 'description_schema' | 'search_tasks' | 'list_projects' | 'list_users' | 'tool_schema' | 'full_catalog';
2003
+ declare function normalizeAbleTimeHost(raw?: string | null): string;
2004
+ declare function abletimeMcpUrl(host?: string | null): string;
2005
+ declare function rewriteAbleTimeError(message: string): string;
2006
+ declare function abletimeMcpRequest(method: string, params?: unknown, opts?: {
2007
+ token?: string | null;
2008
+ host?: string | null;
2009
+ }): Promise<unknown>;
2010
+ declare function callAbleTimeTool<T = unknown>(name: AbleTimeMcpToolName, args?: Record<string, unknown>, opts?: {
2011
+ token?: string | null;
2012
+ host?: string | null;
2013
+ }): Promise<T>;
2014
+
1877
2015
  interface ListIssuesResult {
1878
2016
  source: IssueSource;
1879
- /** Preference before fallback (useful for “Set up Linear” UI). */
2017
+ /** Preference before fallback (useful for “Set up Linear / AbleTime” UI). */
1880
2018
  preferredSource: IssueSource;
1881
2019
  linearConnected: boolean;
2020
+ abletimeConnected: boolean;
1882
2021
  issues: IssueInfo[];
1883
2022
  /** Linear viewer name or GitHub login — used for “assigned to me”. */
1884
2023
  viewer?: {
@@ -1895,9 +2034,8 @@ declare function listGitHubIssues(repoPath: string, opts?: {
1895
2034
  }): Promise<IssueInfo[]>;
1896
2035
  /**
1897
2036
  * Unified issue list for Create-from / Link issue / Home / MCP / CLI.
1898
- * Uses Sideboard Account connections — not agent Linear MCP.
1899
- * Linear and GitHub only; AbleTime is typed but has no client yet
1900
- * (`resolveEffectiveIssueSource` falls back to GitHub).
2037
+ * Uses Sideboard Account connections — Linear GraphQL, AbleTime hosted MCP,
2038
+ * or GitHub Issues via `gh`.
1901
2039
  */
1902
2040
  declare function listIssues(repoPath: string): Promise<ListIssuesResult>;
1903
2041
 
@@ -3159,6 +3297,11 @@ declare class Orchestrator {
3159
3297
  private readonly turnBaselines;
3160
3298
  /** Timers for orchestration session-quota auto-resume. */
3161
3299
  private readonly quotaResumeTimers;
3300
+ /**
3301
+ * Threads that already got a crash-continue turn. Cleared on a successful
3302
+ * finish or a user send so a later crash can recover again.
3303
+ */
3304
+ private readonly crashContinued;
3162
3305
  private maxConcurrent;
3163
3306
  private runningCount;
3164
3307
  constructor(opts?: {
@@ -3204,6 +3347,11 @@ declare class Orchestrator {
3204
3347
  * limit (not context size): switch agent (Auto) or wait until reset.
3205
3348
  */
3206
3349
  private maybeHandleOrchestrationQuotaFailover;
3350
+ /**
3351
+ * Cursor-style recovery: after a runner crash, feed the error back as the
3352
+ * next prompt so the same agent can continue instead of sitting on lastError.
3353
+ */
3354
+ private maybeEnqueueCrashContinue;
3207
3355
  getThreads(includeArchived?: boolean): Thread[];
3208
3356
  getThread(idOrRef: string): Thread | null;
3209
3357
  createThread(input: CreateThreadInput): Promise<Thread>;
@@ -3825,11 +3973,15 @@ type HomeBoardLoaded = HomeBoardRemoteData & {
3825
3973
  fromCache: boolean;
3826
3974
  pins: BoardPin[];
3827
3975
  };
3976
+ /** How worktree rows/cards are ordered. Default `created` stays put while agents run. */
3977
+ type WorktreeSortMode = 'created' | 'name' | 'activity';
3978
+ declare const DEFAULT_WORKTREE_SORT: WorktreeSortMode;
3828
3979
  /**
3829
- * Live Home threads grouped by checkout. Each group is newest-updated first.
3980
+ * Live Home / sidebar threads grouped by checkout.
3981
+ * Groups default to newest-created first so a running agent does not reshuffle the list.
3830
3982
  * One card per group — extra chat tabs do not get their own column slot.
3831
3983
  */
3832
- declare function groupHomeBoardWorktrees<T extends Pick<Thread, 'worktreePath' | 'updatedAt'>>(threads: T[]): T[][];
3984
+ declare function groupHomeBoardWorktrees<T extends Pick<Thread, 'worktreePath' | 'updatedAt' | 'createdAt' | 'id' | 'branchName' | 'title' | 'prTitle' | 'userSetTitle'>>(threads: T[], sort?: WorktreeSortMode, labelOf?: (group: T[]) => string): T[][];
3833
3985
  /** Column for a worktree: merged → Merged, open non-draft → Review, draft → Draft. */
3834
3986
  declare function classifyWorktreeColumn(group: Array<Pick<Thread, 'prUrl' | 'prState' | 'prIsDraft'>>): BoardColumnId;
3835
3987
  /** Activity dot for a worktree: running / queued beat idle sibling tabs. */
@@ -4016,6 +4168,8 @@ interface IpcApi {
4016
4168
  slackDeviceLabel?: string | null;
4017
4169
  githubGitAuthMode?: GithubGitAuthMode | null;
4018
4170
  githubPat?: string | null;
4171
+ abletimeAccessToken?: string | null;
4172
+ abletimeHost?: string | null;
4019
4173
  }): Promise<PublicAppSettings>;
4020
4174
  updateDefaultsSettings(patch: {
4021
4175
  agent?: AgentKind | null;
@@ -4040,6 +4194,24 @@ interface IpcApi {
4040
4194
  cancelLinearOAuth(): Promise<void>;
4041
4195
  /** Revoke Linear OAuth (best-effort) and clear stored Linear credentials. */
4042
4196
  disconnectLinear(): Promise<PublicAppSettings>;
4197
+ /** Verify an AbleTime PAT via MCP orientation and store it. */
4198
+ connectAbleTime(input: {
4199
+ token: string;
4200
+ host?: string | null;
4201
+ }): Promise<PublicAppSettings>;
4202
+ /** Clear the stored AbleTime personal access token. */
4203
+ disconnectAbleTime(): Promise<PublicAppSettings>;
4204
+ /**
4205
+ * Find or create an AbleTime task to track work against
4206
+ * (hosted MCP create_task / search_tasks).
4207
+ */
4208
+ ensureAbleTimeTask(input: {
4209
+ title: string;
4210
+ description?: string;
4211
+ projectId?: string;
4212
+ }): Promise<IssueInfo & {
4213
+ created: boolean;
4214
+ }>;
4043
4215
  /** Sideboard Slack listen (DMs + @mentions → Global orchestrator). */
4044
4216
  getSlackListenStatus(): Promise<SlackListenStatus>;
4045
4217
  setSlackListen(opts: {
@@ -4054,8 +4226,8 @@ interface IpcApi {
4054
4226
  appCaffeinated: boolean;
4055
4227
  }) => void): () => void;
4056
4228
  /**
4057
- * Unified issues for Create-from / Link issue (Linear API or GitHub Issues,
4058
- * based on Account preference with Linear→GitHub fallback).
4229
+ * Unified issues for Create-from / Link issue (Linear, AbleTime MCP, or
4230
+ * GitHub Issues, based on Account preference with GitHub fallback).
4059
4231
  */
4060
4232
  listIssues(repoPath: string): Promise<ListIssuesResult>;
4061
4233
  /**
@@ -4445,8 +4617,8 @@ type HomeBoardInputs = HomeBoardRemoteData;
4445
4617
  /** Tests / Refresh: drop memory + disk snapshot. */
4446
4618
  declare function clearHomeBoardCache(): void;
4447
4619
  /**
4448
- * Same ticket + PR fetch as desktop Home: Linear once, GitHub per workspace,
4449
- * PRs per workspace. Failures are collected so a partial board still returns.
4620
+ * Same ticket + PR fetch as desktop Home: Linear/AbleTime once, GitHub per
4621
+ * workspace, PRs per workspace. Failures are collected so a partial board still returns.
4450
4622
  */
4451
4623
  declare function loadHomeBoardInputs(workspaces: HomeBoardWorkspace[]): Promise<HomeBoardInputs>;
4452
4624
  type GetHomeBoardInputsOptions = {
@@ -4454,7 +4626,7 @@ type GetHomeBoardInputsOptions = {
4454
4626
  now?: number;
4455
4627
  };
4456
4628
  /**
4457
- * Cached Home remote snapshot. Hits Linear/GitHub only on first load, after
4629
+ * Cached Home remote snapshot. Hits Linear/AbleTime/GitHub only on first load, after
4458
4630
  * TTL (15m), when workspaces change, or when refresh is set. Memory and
4459
4631
  * app-data JSON are shared so desktop Home and the orchestration MCP agree.
4460
4632
  */
@@ -4510,7 +4682,8 @@ declare class BrightsySideboardApi {
4510
4682
  get accountId(): string;
4511
4683
  get endpoint(): string;
4512
4684
  private request;
4513
- private refreshIfNeeded;
4685
+ /** Refresh ~/.brightsy when the access token is stale or has no expiry. */
4686
+ ensureFreshAccessToken(): Promise<void>;
4514
4687
  getAccess(): Promise<{
4515
4688
  enabled: boolean;
4516
4689
  allow_always: boolean;
@@ -4574,7 +4747,20 @@ interface CloudConnectOptions {
4574
4747
  */
4575
4748
  declare function runCloudConnect(opts: CloudConnectOptions): Promise<void>;
4576
4749
 
4750
+ /** Team connection stored in Sideboard (tokens for MCP + CLI sync). */
4751
+ interface ConnectedBrightsyTeam {
4752
+ id: string;
4753
+ slug: string;
4754
+ name: string;
4755
+ access_token: string;
4756
+ refresh_token?: string;
4757
+ expires_at?: number;
4758
+ endpoint?: string;
4759
+ }
4760
+
4577
4761
  declare function listConnectedBrightsyTeams(): ConnectedBrightsyTeamInfo[];
4762
+ /** Ensure stored team tokens are fresh; returns teams ready for MCP env injection. */
4763
+ declare function ensureConnectedBrightsyTeamTokens(): Promise<ConnectedBrightsyTeam[]>;
4578
4764
  /**
4579
4765
  * Connect a team for MCP + CLI: mint/store a team token and make it the
4580
4766
  * active ~/.brightsy session (Brightsy agent / CLI).
@@ -4584,6 +4770,28 @@ declare function disconnectBrightsyTeam(accountIdOrSlug: string): Promise<Connec
4584
4770
  /** Sanitize slug for Claude MCP server / tool name segments. */
4585
4771
  declare function brightsyMcpServerName(slug: string): string;
4586
4772
 
4773
+ type BrightsyTokenGrant = {
4774
+ access_token: string;
4775
+ refresh_token?: string;
4776
+ expires_at?: number;
4777
+ };
4778
+ /** True when the access token is expired, unknown, or within 60s of expiry. */
4779
+ declare function brightsyAccessTokenNeedsRefresh(expiresAt?: number, now?: number): boolean;
4780
+ /**
4781
+ * Exchange a refresh token at `{endpoint}/oauth/token`.
4782
+ * Returns null when the server rejects the grant (caller keeps the old session).
4783
+ */
4784
+ declare function refreshBrightsyAccessToken(opts: {
4785
+ endpoint: string;
4786
+ refreshToken: string;
4787
+ clientId?: string;
4788
+ fetchImpl?: typeof fetch;
4789
+ }): Promise<BrightsyTokenGrant | null>;
4790
+ /** Refresh ~/.brightsy when a refresh token exists and the access token is stale. */
4791
+ declare function ensureBrightsyLocalConfigFresh(opts?: {
4792
+ fetchImpl?: typeof fetch;
4793
+ }): Promise<BrightsyLocalConfig | null>;
4794
+
4587
4795
  /** Claude --allowedTools entries for Sideboard MCP (full fleet). */
4588
4796
  declare const SIDEBOARD_MCP_ALLOWED_TOOLS: readonly ["mcp__sideboard", "mcp__sideboard__*"];
4589
4797
  /** Legacy single-server allow list (CLI ~/.brightsy fallback). */
@@ -5011,4 +5219,4 @@ declare function pollSlackOutboundWatches(opts?: {
5011
5219
  now?: number;
5012
5220
  }): Promise<void>;
5013
5221
 
5014
- export { AGENT_GIT_ACTIONS, AGENT_RUNNER_MAX_OLD_SPACE_MB, ATTACHMENTS_DIR, type ActiveRun, type AddBoardPinInput, type AddStackLayerInput, type AdoptInput, type AdvancedAppSettings, type AgentAdapter, type AgentEvent, type AgentGitAction, type AgentInstructionFile, type AgentKind, type AgentModelCatalog, type AgentModelInfo, type AgentSetupActionResult, type AgentSetupInfo, type AgentSetupKind, type AgentStatus, type AgentTurnInput, type AnthropicCacheControl, type AppSettings, type ApplyIntoMainResult, type AttachCommand, type Autonomy, BAKED_SLACK_RELAY_URL, BRIGHTSY_MCP_ALLOWED_TOOLS, type BoardPin, type BranchInfo, type BrightsyAccount, type BrightsyChatTarget, type BrightsyChatTargets, type BrightsyCloudConnectAgent, type BrightsyHarnessSettings, type BrightsySession, BrightsySideboardApi, type BrightsyTeamTargets, CLAUDE_MODEL_CATALOG, CLOUD_COORDINATOR_BUSY_REPLY, CLOUD_COORDINATOR_STOPPED_REPLY, CLOUD_COORDINATOR_TIMEOUT_REPLY, CLOUD_ORCHESTRATOR_GOAL, CONTEXT_COMPACT_CHARS, CONTEXT_KEEP_RECENT_CHARS, CONTEXT_KEEP_RECENT_MESSAGES, CONTEXT_MIN_MESSAGES, CONVENTION_SETUP_RELPATHS, COORDINATOR_TOOL_PLAYBOOK, type CaffeinateHoldState, type ClaudeHarnessSettings, type CleanupOrphansResult, type CliAgentKind, type CliExecutableSettings, type CloudConnectAgent, type CloudConnectOptions, type CloudConnectStatus, type CompactResult, type CompactThresholds, type ComposerFileBuffer, type ConductorSettings, type ConductorWorkspace, type ConnectedBrightsyTeamInfo, type ConventionSetupFile, type CowboyThreadFields, type CreateChatTabInput, type CreateGlobalChatOpts, type CreateScheduledTaskInput, type CreateStackInput, type CreateThreadInput, type CreateWorktreeResult, type CursorAgentUsageSnapshot, type CursorModelInfo, type CursorSdkStreamMessage, type CursorTurnRequest, type CursorUsageCost, type CursorWorktreesConfig, type DefaultsAppSettings, type DevServerHandle, type DiffCommentInput, type DiffCommentLine, type DiffCommit, type DiffFile, type DiffResult, type DiffScope, type DiffScopeStat, type ExpandResult, FAMOUS_SOCCER_TEAMS, type ForkChatTabInput, type ForkThreadWorktreeInput, type FormatGhLandErrorOptions, GITHUB_GIT_AUTH_MODES, GLOBAL_WORKSPACE_ID, type GetDiffOptions, type GhStackStatus, type GitHubStatus, type GitWorktreeStatus, type GithubGitAuthMode, HARNESS_ENV_KEYS, HOME_BOARD_CACHE_TTL_MS, type HarnessId, type HomeBoardLoaded, type HomeBoardRemoteData, ISSUE_SOURCE_LABELS, type InitStackFromThreadInput, type IntegrationsSettings, type IpcApi, type IssueCycleInfo, type IssueInfo, type IssueSource, LEGACY_ATTACHMENTS_DIR, LEGACY_PLAN_FILE_REL, LEGACY_REVIEW_REQUEST_PATH, LINEAR_OAUTH_CANCELLED, LINEAR_OAUTH_PORT, LINEAR_OAUTH_REDIRECT, LINEAR_OAUTH_SCOPES, type LandPreview, type LandResult, type LinearAssignedIssuesResult, type LinearComment, type LinearIssue, LinearOAuthCancelledError, type LinearTeam, type LinearTeamsResult, type LinearWorkflowState, type ListIssuesResult, MAX_ANTHROPIC_CACHE_CONTROL_BLOCKS, type McpServerStatus, type MessagePart, ORCHESTRATOR_AGENT_KINDS, type OpenPrStackLayersInput, type OpenStackLayerInput, type OpenStackLayerResult, type OrchestrationQuotaOnLimit, Orchestrator, type OrchestratorAgentKind, type OrchestratorEvent, type OrchestratorRuntime, type OrphanWorktree, PASTE_ATTACH_MIN_CHARS, PASTE_ATTACH_MIN_LINES, PLAN_FILE_NAME, PLAN_FILE_REL, PLAN_MODE_INSTRUCTION, type PendingPlanQuestions, type PlanQuestion, type PlanQuestionAnswer, type PlanQuestionOption, type PlanToolPartLike, type PrActor, type PrCheckRun, type PrCommentInfo, type PrCommitInfo, type PrDetails, type PrInfo, type PrMeta, type PrReviewInfo, type PrStack, type PrStackLayer, type PresentedPlan, type PublicAppSettings, type PublicIntegrationsSettings, REPO_REVIEW_NAME, REPO_REVIEW_PATH, REVIEW_REQUEST_NAME, REVIEW_REQUEST_PATH, REVIEW_REQUEST_PREFILL, REVIEW_REQUEST_TEMPLATE, REVIEW_SKILL_NAME, REVIEW_SKILL_PATH, type RepoSettings, type RepoSetupInfo, type RequestReviewResult, type ResolvedReviewGuidelines, type ReviewGuidelinesSource, type RunMode, type RunScript, SESSION_RESET_OCCUPANCY_TOKENS, SIDEBOARD_FORCE_STOP, SIDEBOARD_MCP_ALLOWED_TOOLS, SIDEBOARD_MCP_PROFILE_ENV, SLACK_LISTEN_STOPPED_REPLY, SLACK_LISTEN_TIMEOUT_REPLY, SLACK_OAUTH_CANCELLED, SLACK_OAUTH_REDIRECT, SLACK_PROGRESS_DELAY_MS, SLACK_PROGRESS_EDIT_MS, SLACK_REPLY_FORMATTING, SLACK_SEEN_REACTION, type ScheduleCreatedBy, type ScheduleWhen, type ScheduledTask, type ScriptHandle, type SetupRunResult, type SideboardMcpProfile, type SkillInfo, type SlackInboundMessage, type SlackListenOptions, type SlackListenStatus, SlackOAuthCancelledError, type SlackOutboundReply, type SlackOutboundWatch, type SlackRelayClientMessage, type SlackRelayClientOptions, SlackRelayHub, type SlackRelayServerHandle, type SlackRelayServerMessage, type SlackRelayServerOptions, type SlackWorkspaceInfo, type SourceType, type SpawnTurnHandle, type SummarizeResult, THINKING_EFFORTS, type TeamName, type ThinkingEffort, type Thread, type ThreadAttachment, type ThreadMessage, type ThreadOptionsPatch, type ThreadStatus, type TokenUsage, type ToolPartLike, type TranscriptToolDetail, type TurnCommand, type UpdateScheduledTaskPatch, type UsageScope, WORKTREE_MCP_TOOLS, type Workspace, type WorkspaceInventoryEntry, type WorkspaceScriptEnvOpts, ackSlackInboundSeen, addBoardPin, addPrStackLayer, addStackLayerFromThread, addWorkspace, adoptThread, agentGitPrompt, allAdapters, allocatePort, allocatePortRange, allocateTeamName, allocateTeamSlug, appDataDir, appSettingsPath, appendIndexedGitConfig, appendMessage, applyAgentEvent, applyAgentRunnerHeapEnv, applyAppEnvironment, applyCompaction, applyGithubGitAuthEnv, applyPromptCacheTtlEnv, applyThreadIntoMain, applyTurnUsage, armSchedules, assertOrchestratorCapableAgent, attachmentFromAbsolutePath, attachmentsFromBuffers, attachmentsFromWorktreePaths, attachmentsGitignoreBody, autoArchiveOnMergeEnabled, autoCleanupOrphansEnabled, autoRenameBranchEnabled, autoRunAfterSetupEnabled, branchDisplayLabel, brightsyAdapter, brightsyCloudConnectAgent, brightsyCloudConnectEnabled, brightsyConfigPath, brightsyInjectWorktreeMcpEnabled, brightsyMcpAllowedTools, brightsyMcpServerName, buildCachedUserContent, buildClaudeStreamJsonUserMessage, buildDiffCommentAttachment, buildForkTranscriptAttachment, buildPastedTextAttachment, buildReviewRequestAttachment, buildSessionSeed, buildWorkspaceScriptEnv, caffeinateHoldPath, caffeinateWhileCloudConnectEnabled, caffeinateWhileRunningEnabled, caffeinateWhileSchedulesEnabled, caffeinateWhileSlackListenEnabled, canonicalizeRepoPath, captureLoginEnv, captureTurnBaseline, checkoutPrStackLayer, childEnvWithAppSettings, claimDesktopHost, classifyWorktreeColumn, claudeAdapter, claudeChromeEnabled, claudeUserSettingsPath, cleanupOrphanWorktrees, clearBoardPins, clearHomeBoardCache, cloneRepoIntoSideboard, codexAdapter, codexSandboxWritableRootsArgs, codexUnattendedGitConfigArgs, coerceOrchestratorAgent, collectTakenTeamSlugs, commentLinearIssue, commitAll, computeNextRunAt, conductorBundledBinDir, conductorDbPath, confirmLand, connectBrightsyTeam, connectSlackToken, contextTokens, coordinatorSystemPrompt, coordinatorTurnReminder, copyConfiguredFiles, countCacheControlBlocks, cowboyModeEnabled, createChatTab, createEmptyThread, createExistingBranchWorktree, createGlobalChat, createLinearIssue, createLinearPkce, createOrUpdatePr, createPrStack, createSchedule, createThread, createThreadWorktree, currentBranch, cursorAdapter, cursorSdkMessageToEvents, decodeBrightsyTarget, defaultScheduleName, deleteBranchOnPurgeEnabled, deleteSchedule, deleteThreadRecord, desktopHostPidPath, detectAgents, detectGhStack, detectLocalMergeConflicts, disconnectBrightsyTeam, disconnectLinear, disconnectLinearConnection, disconnectSlackWorkspace, discoverSkills, dropCachedPrefixOnResume, encodeBrightsyTarget, enrichPathWithNpmGlobalBin, enrichWorkspacesWithGithub, ensureAgentPath, ensureCloudCoordinator, ensureGhPreferOrigin, ensureGlobalCoordinatorCwd, ensureReviewRequestFile, ensureReviewSkillFile, ensureSlackCoordinator, ensureSlackDeviceIdentity, ensureWorkspace, estimateMessageChars, estimateThreadChars, expandComposerPrompt, extractGhErrorDetail, extractPendingPlanQuestions, extractPresentedPlan, extractiveSummary, fetchPrHead, finalizeParts, findConventionSetup, findInvalidCacheControlTtlOrder, findLiveThreadForCreate, findOrphanWorktrees, findSlackCoordinator, findThreadByRef, findThreadForStackLayer, fireSchedule, flattenTurnInput, forkChatTab, forkMessageSlice, forkThreadWorktree, formatAgentInstructions, formatArtifactDirective, formatBrightsyFetchError, formatFetchError, formatGhLandError, formatGitAuthModeDirective, formatIpcInvokeError, formatMergePrError, formatMessagesAsTranscript, formatPlanQuestionAnswers, formatPlanQuestionsForChat, formatProcessGuideDirective, formatRateLimitResetHint, formatRenameBranchDirective, formatScheduleWhen, formatScheduledPrompt, formatSlackExternalReplyPrompt, formatSlackInboundPrompt, formatSlackRepliesForTurn, formatSlackReplyContinuePrompt, formatSlackSignedReply, formatSlackWorkingText, formatTranscriptMarkdown, formatUiReminder, formatWorkspaceInventory, formatWorktreeDirective, formatWorktreeReminder, fromInclusiveInputUsage, getAdapter, getAgentSetupInfo, getBrightsySession, getCaffeinateHold, getDefaultAgent, getDefaultEffort, getDefaultFast, getDefaultModel, getDefaultRunScript, getDiff, getDiffSummary, getGitHubStatus, getGithubGitAuthMode, getGithubPat, getHomeBoardInputs, getIssueSource, getLinearApiKey, getLinearAuthToken, getLinearIssue, getOrchestrator, getPr, getPrChecks, getPrDetails, getPrForHeadBranch, getPrMeta, getPrStack, getRepoSetupInfo, getRunMode, getRunScript, getSchedule, getSlackWorkspace, gh, ghHeadRef, ghRepoSelectArgs, git, githubAgentGitEnv, globalAgentCwd, groupHomeBoardWorktrees, handleSlackInbound, harnessEnvKey, hasBakedLinearOAuth, hasBakedSlackOAuth, hasConductorHook, hasConventionSetup, hasCursorWorktreeSetup, hasEnabledSchedules, hasRepoHook, hasWorkspaceHook, healOrchestrationSoccerTitles, httpFetch, importConductorWorkspace, importConductorWorkspaceAsync, initPrStack, initStackFromThread, initializeGitRepository, inspectGitWorktree, installAgent, interruptSlackCoordinatorForInbound, isAskUserToolName, isBrightsyConnected, isBrightsyNdjsonLine, isCloudCoordinatorThread, isConductorBundledCli, isCowboyThread, isCursorAutoModel, isDefaultishSourceRef, isDesktopHostAlive, isDirty, isGhRateLimitError, isGlobalRepoPath, isGlobalThread, isHomeBoardThread, isImageFilePath, isInPrStack, isInboundForThisDesktop, isIssueSourceConnected, isLinearConnected, isLinearOAuthCancelled, isOrchestratorCapableAgent, isOrchestratorThread, isPidAlive, isPlaceholderBranch, isPollWrapperToolName, isPrNotMergeableError, isPresentPlanToolName, isPrimaryCheckoutThread, isSessionQuotaLimit, isShellToolName, isSideboardScratchPath, isSlackCoordinatorThread, isSlackExternalReplyPrompt, isSlackOAuthCancelled, isSubagentToolName, isThinkingEffort, isThisProcessDesktopHost, isThreadCaffeinated, isThreadRecordFile, isWorkspaceScratchPath, issueSourceLabel, lastRequestOccupancy, latestPendingPlanQuestions, linearAuthorizationHeader, linearCycleIsActive, linearGraphql, linearOAuthAuthorizeUrl, linearOAuthCredentials, listAgentSetupInfo, listBoardPins, listBranchCommits, listBranches, listBrightsyAccounts, listBrightsyChatTargets, listCodexModels, listConductorWorkspaces, listConnectedBrightsyTeams, listCursorModels, listGitHubIssues, listGlobalThreads, listIssues, listLinearAssignedIssues, listLinearIssues, listLinearIssuesDirect, listLinearTeams, listModelsForAgent, listOpencodeModels, listPrs, listRunScripts, listSchedules, listSlackOutboundWatches, listSlackWorkspaces, listThreads, listWorkspaces, listWorktreeFiles, listWorktrees, liveActivitySummary, loadAgentInstructions, loadAppSettings, loadBrightsyConfig, loadConductorSettings, loadHomeBoardInputs, loadRepoSettings, loadWorkspaceSettings, locksDir, loginAgent, lookupSoccerTeam, maxConcurrentAgents, maybeCompactContext, mcpAllowTools, mcpAuthWarnings, mergeAgentGitAuthEnv, mergePr, mergePrStack, mergeSideboardIntoMcpServersJson, mergeUsage, messagePartParentId, nextPastedTextName, nextThinkingEffort, nonInteractiveGitProcessEnv, normalizeParseResult, normalizeThinkingEffort, normalizeThread, normalizeTurnInput, normalizeWorktreePath, openInSystemTerminal, openPrStackLayers, openStackLayer, opencodeAdapter, orchestrationQuotaFallbackAgent, orchestrationQuotaOnLimit, orchestrationTitleNeedsSoccerNickname, orchestratorSessionPoisonedByBuiltins, originGhRepoEnv, parseCursorRunnerLine, parseDurationMs, parseForceStopMessage, parseGhStackViewJson, parseGithubSlugFromRemoteUrl, parseMcpList, parsePlanQuestionsInput, parseSessionQuotaResetAt, parseSlackRelayClientMessage, parseSlackRelayServerMessage, partsToAssistantText, pastedTextStats, pendingSlackExternalReplies, permissionMode, persistVaultKeyInKeychain, planFileAbs, planQuestionsSignature, pollSlackOutboundWatches, posixShellSingleQuote, preferredCursorCostCents, prepareTerminalCommand, previewLand, promptMentionsBrightsy, pushBranch, readExistingReviewRequestFile, readKeychainVaultKey, readPlanFile, readSkillBody, readThread, readWorktreeFile, readWorktreeFileForUpload, readWorktreeInclude, recordScheduleRun, recordSlackOutboundWatch, refreshGitHubAuth, registerPackagedUserMcpClients, releaseCaffeinateHoldForThread, releaseDesktopHost, removeBoardPin, removeWorkspace, removeWorktree, repoSlug, requestOccupancy, requestReview, requireAgent, resetGhStackDetectCache, resetGithubAgentTokenMemo, resolveAgentExecutable, resolveAgentGitAuthEnv, resolveClaudeExecutable, resolveCodexGitWritableRoots, resolveCommandBinarySync, resolveConductorCursorAgentId, resolveCursorModelId, resolveDefaultBranch, resolveDiffBaseRef, resolveEffectiveIssueSource, resolveFilesToCopy, resolveGhAuthToken, resolveGitDirsForLockRecovery, resolveGithubAgentToken, resolveGithubRepoSlug, resolveLinearState, resolveLinearTeam, resolveLoginCommand, resolveNewThreadOptions, resolvePlanMarkdown, resolvePrSelector, resolvePrSelectors, resolveQuotaFallbackAgent, resolveRepoRoot, resolveReviewGuidelines, resolveScheduleThreadId, resolveSlackListenMode, resolveThreadDefaults, resolveThreadEffort, resolveVaultKey, resolveWorktreeStartPoint, rewriteLinearError, run, runArchiveScript, runCloudConnect, runConventionSetup, runCursorWorktreeSetup, runSetupScript, runSlackListen, runSlackRelayClient, runWorkspaceSetup, sameWorktreePath, sanitizeMcpServerName, saveAppSettings, saveLinearOAuth, schedulesPath, scrubGithubTokensFromChildEnv, secureFileUnlocksWith, setCaffeinateHold, setHttpFetchImpl, setStatus, setVaultMasterKey, settingsSourceLabel, shouldAttachPastedText, shouldCompactContext, shouldInjectBrightsyMcp, shouldRefreshReviewRequestTemplate, shouldRemoveWorktreeOnTeardown, shouldResetSessionForOccupancy, shouldRunWorktreeCleanup, showCostEnabled, sideboardHomeDir, sideboardMcpProfile, sideboardReposDir, sideboardWorkspacesDir, slackAppLevelToken, slackArchiveUrl, slackCoordinatorSourceRef, slackListenEnabled, slackOAuthCredentials, slackOAuthResultUrl, slackRelayUrl, slugify, spawnAgentTurn, splitForCompaction, stackAgentDefaultsFrom, stackIdFrom, stackMergeReadiness, stageAbsolutePathsAsAttachments, stageBuffersAsAttachments, startDevServer, startLinearOAuth, startMcpServer, startOrchestration, startSlackOAuth, startSlackRelayServer, stripBrightsyNdjsonNoise, stripNestedElectronEnv, submitPrStack, suggestSlug, sumUsageList, summarizeConversation, switchBrightsyAccount, syncWorkspacesFromThreads, takenTeamSlugsForChatTab, takenTeamSlugsForOrchestration, taskMessageText, thinkingEffortBars, thinkingEffortLabel, thisProcessShouldDrainAgentQueues, threadDisplayLabel, threadFilePath, threadLivePath, threadLockPath, threadRequestsBrightsyMcp, threadsDir, threadsSharingWorktree, toPublicAppSettings, toolActivityLine, toolDescription, toolDetail, toolFilePath, totalTokens, turnCostUsdFromCursorUsage, updateAdvancedSettings, updateAgentExecutable, updateAppEnvironment, updateBrightsySettings, updateClaudeSettings, updateCodexSettings, updateDefaultsSettings, updateIntegrationsSettings, updateLinearIssue, updateOpencodeSettings, updateSchedule, updateThread, userClaudeMcpConfigPath, userCursorMcpConfigPath, validateLinearApiKey, waitForPidExit, warmGithubAgentAuth, withAgentInstructions, withEventParentId, withEventsParentId, withExportedPath, withMaxOldSpaceSize, withThreadLock, workspaceSettingsSourceLabel, worktreeBoardStatus, worktreeCleanupSettings, worktreeDisplayLabel, worktreeDisplayLabelForGroup, worktreeNameFromPath, worktreesRoot, wrapReviewSkillMarkdown, writeInjectedMcpConfig, writePlanFile, writeThread, writeWorktreeFile };
5222
+ export { ABLETIME_MCP_PATH, AGENT_GIT_ACTIONS, AGENT_RUNNER_MAX_OLD_SPACE_MB, ATTACHMENTS_DIR, type AbleTimeAssignedIssuesResult, type AbleTimeMcpToolName, type AbleTimeOrientation, type AbleTimeProject, type AbleTimeTask, type AbleTimeViewer, type ActiveRun, type AddBoardPinInput, type AddStackLayerInput, type AdoptInput, type AdvancedAppSettings, type AgentAdapter, type AgentEvent, type AgentGitAction, type AgentInstructionFile, type AgentKind, type AgentModelCatalog, type AgentModelInfo, type AgentSetupActionResult, type AgentSetupInfo, type AgentSetupKind, type AgentStatus, type AgentTurnInput, type AnthropicCacheControl, type AppSettings, type ApplyIntoMainResult, type AttachCommand, type Autonomy, BAKED_SLACK_RELAY_URL, BRIGHTSY_MCP_ALLOWED_TOOLS, type BoardPin, type BranchInfo, type BrightsyAccount, type BrightsyChatTarget, type BrightsyChatTargets, type BrightsyCloudConnectAgent, type BrightsyHarnessSettings, type BrightsySession, BrightsySideboardApi, type BrightsyTeamTargets, CLAUDE_MODEL_CATALOG, CLOUD_COORDINATOR_BUSY_REPLY, CLOUD_COORDINATOR_STOPPED_REPLY, CLOUD_COORDINATOR_TIMEOUT_REPLY, CLOUD_ORCHESTRATOR_GOAL, CONTEXT_COMPACT_CHARS, CONTEXT_KEEP_RECENT_CHARS, CONTEXT_KEEP_RECENT_MESSAGES, CONTEXT_MIN_MESSAGES, CONVENTION_SETUP_RELPATHS, COORDINATOR_TOOL_PLAYBOOK, type CaffeinateHoldState, type ClaudeHarnessSettings, type CleanupOrphansResult, type CliAgentKind, type CliExecutableSettings, type CloudConnectAgent, type CloudConnectOptions, type CloudConnectStatus, type CompactResult, type CompactThresholds, type ComposerFileBuffer, type ConductorSettings, type ConductorWorkspace, type ConnectedBrightsyTeamInfo, type ConventionSetupFile, type CowboyThreadFields, type CreateChatTabInput, type CreateGlobalChatOpts, type CreateScheduledTaskInput, type CreateStackInput, type CreateThreadInput, type CreateWorktreeResult, type CursorAgentUsageSnapshot, type CursorModelInfo, type CursorSdkStreamMessage, type CursorTurnRequest, type CursorUsageCost, type CursorWorktreesConfig, DEFAULT_ABLETIME_HOST, DEFAULT_WORKTREE_SORT, type DefaultsAppSettings, type DevServerHandle, type DiffCommentInput, type DiffCommentLine, type DiffCommit, type DiffFile, type DiffResult, type DiffScope, type DiffScopeStat, type ExpandResult, FAMOUS_SOCCER_TEAMS, type ForkChatTabInput, type ForkThreadWorktreeInput, type FormatGhLandErrorOptions, GITHUB_GIT_AUTH_MODES, GLOBAL_WORKSPACE_ID, type GetDiffOptions, type GhStackStatus, type GitHubStatus, type GitWorktreeStatus, type GithubGitAuthMode, HARNESS_ENV_KEYS, HOME_BOARD_CACHE_TTL_MS, type HarnessId, type HomeBoardLoaded, type HomeBoardRemoteData, ISSUE_SOURCE_LABELS, type InitStackFromThreadInput, type IntegrationsSettings, type IpcApi, type IssueCycleInfo, type IssueInfo, type IssueSource, LEGACY_ATTACHMENTS_DIR, LEGACY_PLAN_FILE_REL, LEGACY_REVIEW_REQUEST_PATH, LINEAR_OAUTH_CANCELLED, LINEAR_OAUTH_PORT, LINEAR_OAUTH_REDIRECT, LINEAR_OAUTH_SCOPES, type LandPreview, type LandResult, type LinearAssignedIssuesResult, type LinearComment, type LinearIssue, LinearOAuthCancelledError, type LinearTeam, type LinearTeamsResult, type LinearWorkflowState, type ListIssuesResult, MAX_ANTHROPIC_CACHE_CONTROL_BLOCKS, type McpServerStatus, type MessagePart, ORCHESTRATOR_AGENT_KINDS, type OpenPrStackLayersInput, type OpenStackLayerInput, type OpenStackLayerResult, type OrchestrationQuotaOnLimit, Orchestrator, type OrchestratorAgentKind, type OrchestratorEvent, type OrchestratorRuntime, type OrphanWorktree, PASTE_ATTACH_MIN_CHARS, PASTE_ATTACH_MIN_LINES, PLAN_FILE_NAME, PLAN_FILE_REL, PLAN_MODE_INSTRUCTION, type PendingPlanQuestions, type PlanQuestion, type PlanQuestionAnswer, type PlanQuestionOption, type PlanToolPartLike, type PrActor, type PrCheckRun, type PrCommentInfo, type PrCommitInfo, type PrDetails, type PrInfo, type PrMeta, type PrReviewInfo, type PrStack, type PrStackLayer, type PresentedPlan, type PublicAppSettings, type PublicIntegrationsSettings, REPO_REVIEW_NAME, REPO_REVIEW_PATH, REVIEW_REQUEST_NAME, REVIEW_REQUEST_PATH, REVIEW_REQUEST_PREFILL, REVIEW_REQUEST_TEMPLATE, REVIEW_SKILL_NAME, REVIEW_SKILL_PATH, type RepoSettings, type RepoSetupInfo, type RequestReviewResult, type ResolvedReviewGuidelines, type ReviewGuidelinesSource, type RunMode, type RunScript, SESSION_RESET_OCCUPANCY_TOKENS, SIDEBOARD_FORCE_STOP, SIDEBOARD_MCP_ALLOWED_TOOLS, SIDEBOARD_MCP_PROFILE_ENV, SLACK_LISTEN_STOPPED_REPLY, SLACK_LISTEN_TIMEOUT_REPLY, SLACK_OAUTH_CANCELLED, SLACK_OAUTH_REDIRECT, SLACK_PROGRESS_DELAY_MS, SLACK_PROGRESS_EDIT_MS, SLACK_REPLY_FORMATTING, SLACK_SEEN_REACTION, type ScheduleCreatedBy, type ScheduleWhen, type ScheduledTask, type ScriptHandle, type SetupRunResult, type SideboardMcpProfile, type SkillInfo, type SlackInboundMessage, type SlackListenOptions, type SlackListenStatus, SlackOAuthCancelledError, type SlackOutboundReply, type SlackOutboundWatch, type SlackRelayClientMessage, type SlackRelayClientOptions, SlackRelayHub, type SlackRelayServerHandle, type SlackRelayServerMessage, type SlackRelayServerOptions, type SlackWorkspaceInfo, type SourceType, type SpawnTurnHandle, type SummarizeResult, THINKING_EFFORTS, type TeamName, type ThinkingEffort, type Thread, type ThreadAttachment, type ThreadMessage, type ThreadOptionsPatch, type ThreadStatus, type TokenUsage, type ToolPartLike, type TranscriptToolDetail, type TurnCommand, type UpdateScheduledTaskPatch, type UsageScope, WORKTREE_MCP_TOOLS, type Workspace, type WorkspaceInventoryEntry, type WorkspaceScriptEnvOpts, type WorktreeSortMode, abletimeMcpRequest, abletimeMcpUrl, ackSlackInboundSeen, addBoardPin, addPrStackLayer, addStackLayerFromThread, addWorkspace, adoptThread, agentGitPrompt, allAdapters, allocatePort, allocatePortRange, allocateTeamName, allocateTeamSlug, appDataDir, appSettingsPath, appendIndexedGitConfig, appendMessage, applyAgentEvent, applyAgentRunnerHeapEnv, applyAppEnvironment, applyCompaction, applyGithubGitAuthEnv, applyPromptCacheTtlEnv, applyThreadIntoMain, applyTurnUsage, armSchedules, assertOrchestratorCapableAgent, attachmentFromAbsolutePath, attachmentsFromBuffers, attachmentsFromWorktreePaths, attachmentsGitignoreBody, autoArchiveOnMergeEnabled, autoCleanupOrphansEnabled, autoRenameBranchEnabled, autoRunAfterSetupEnabled, branchDisplayLabel, brightsyAccessTokenNeedsRefresh, brightsyAdapter, brightsyCloudConnectAgent, brightsyCloudConnectEnabled, brightsyConfigPath, brightsyInjectWorktreeMcpEnabled, brightsyMcpAllowedTools, brightsyMcpServerName, buildCachedUserContent, buildClaudeStreamJsonUserMessage, buildDiffCommentAttachment, buildForkTranscriptAttachment, buildPastedTextAttachment, buildReviewRequestAttachment, buildSessionSeed, buildWorkspaceScriptEnv, caffeinateHoldPath, caffeinateWhileCloudConnectEnabled, caffeinateWhileRunningEnabled, caffeinateWhileSchedulesEnabled, caffeinateWhileSlackListenEnabled, callAbleTimeTool, canonicalizeRepoPath, captureLoginEnv, captureTurnBaseline, checkoutPrStackLayer, childEnvWithAppSettings, claimDesktopHost, classifyWorktreeColumn, claudeAdapter, claudeChromeEnabled, claudeUserSettingsPath, cleanupOrphanWorktrees, clearBoardPins, clearHomeBoardCache, cloneRepoIntoSideboard, codexAdapter, codexSandboxWritableRootsArgs, codexUnattendedGitConfigArgs, coerceOrchestratorAgent, collectTakenTeamSlugs, commentLinearIssue, commitAll, computeNextRunAt, conductorBundledBinDir, conductorDbPath, confirmLand, connectBrightsyTeam, connectSlackToken, contextTokens, coordinatorSystemPrompt, coordinatorTurnReminder, copyConfiguredFiles, countCacheControlBlocks, cowboyModeEnabled, createAbleTimeTask, createChatTab, createEmptyThread, createExistingBranchWorktree, createGlobalChat, createLinearIssue, createLinearPkce, createOrUpdatePr, createPrStack, createSchedule, createThread, createThreadWorktree, currentBranch, cursorAdapter, cursorSdkMessageToEvents, decodeBrightsyTarget, defaultScheduleName, deleteBranchOnPurgeEnabled, deleteSchedule, deleteThreadRecord, desktopHostPidPath, detectAgents, detectGhStack, detectLocalMergeConflicts, disconnectAbleTimeConnection, disconnectBrightsyTeam, disconnectLinear, disconnectLinearConnection, disconnectSlackWorkspace, discoverSkills, dropCachedPrefixOnResume, encodeBrightsyTarget, enrichPathWithNpmGlobalBin, enrichWorkspacesWithGithub, ensureAbleTimeTask, ensureAgentPath, ensureBrightsyLocalConfigFresh, ensureCloudCoordinator, ensureConnectedBrightsyTeamTokens, ensureGhPreferOrigin, ensureGlobalCoordinatorCwd, ensureReviewRequestFile, ensureReviewSkillFile, ensureSlackCoordinator, ensureSlackDeviceIdentity, ensureWorkspace, estimateMessageChars, estimateThreadChars, expandComposerPrompt, extractGhErrorDetail, extractPendingPlanQuestions, extractPresentedPlan, extractiveSummary, fetchPrHead, finalizeParts, findConventionSetup, findInvalidCacheControlTtlOrder, findLiveThreadForCreate, findOrphanWorktrees, findSlackCoordinator, findThreadByRef, findThreadForStackLayer, fireSchedule, flattenTurnInput, forkChatTab, forkMessageSlice, forkThreadWorktree, formatAgentInstructions, formatArtifactDirective, formatBrightsyFetchError, formatFetchError, formatGhLandError, formatGitAuthModeDirective, formatIpcInvokeError, formatMergePrError, formatMessagesAsTranscript, formatPlanQuestionAnswers, formatPlanQuestionsForChat, formatProcessGuideDirective, formatRateLimitResetHint, formatRenameBranchDirective, formatScheduleWhen, formatScheduledPrompt, formatSlackExternalReplyPrompt, formatSlackInboundPrompt, formatSlackRepliesForTurn, formatSlackReplyContinuePrompt, formatSlackSignedReply, formatSlackWorkingText, formatTranscriptMarkdown, formatUiReminder, formatWorkspaceInventory, formatWorktreeDirective, formatWorktreeReminder, fromInclusiveInputUsage, getAbleTimeAccessToken, getAbleTimeHost, getAbleTimeOrientation, getAbleTimeTask, getAdapter, getAgentSetupInfo, getBrightsySession, getCaffeinateHold, getDefaultAgent, getDefaultEffort, getDefaultFast, getDefaultModel, getDefaultRunScript, getDiff, getDiffSummary, getGitHubStatus, getGithubGitAuthMode, getGithubPat, getHomeBoardInputs, getIssueSource, getLinearApiKey, getLinearAuthToken, getLinearIssue, getOrchestrator, getPr, getPrChecks, getPrDetails, getPrForHeadBranch, getPrMeta, getPrStack, getRepoSetupInfo, getRunMode, getRunScript, getSchedule, getSlackWorkspace, gh, ghHeadRef, ghRepoSelectArgs, git, githubAgentGitEnv, globalAgentCwd, groupHomeBoardWorktrees, handleSlackInbound, harnessEnvKey, hasBakedLinearOAuth, hasBakedSlackOAuth, hasConductorHook, hasConventionSetup, hasCursorWorktreeSetup, hasEnabledSchedules, hasRepoHook, hasWorkspaceHook, healOrchestrationSoccerTitles, httpFetch, importConductorWorkspace, importConductorWorkspaceAsync, initPrStack, initStackFromThread, initializeGitRepository, inspectGitWorktree, installAgent, interruptSlackCoordinatorForInbound, isAbleTimeConnected, isAskUserToolName, isBrightsyConnected, isBrightsyNdjsonLine, isCloudCoordinatorThread, isConductorBundledCli, isCowboyThread, isCursorAutoModel, isDefaultishSourceRef, isDesktopHostAlive, isDirty, isGhRateLimitError, isGlobalRepoPath, isGlobalThread, isHomeBoardThread, isImageFilePath, isInPrStack, isInboundForThisDesktop, isIssueSourceConnected, isLinearConnected, isLinearOAuthCancelled, isOrchestratorCapableAgent, isOrchestratorThread, isPidAlive, isPlaceholderBranch, isPollWrapperToolName, isPrNotMergeableError, isPresentPlanToolName, isPrimaryCheckoutThread, isSessionQuotaLimit, isShellToolName, isSideboardScratchPath, isSlackCoordinatorThread, isSlackExternalReplyPrompt, isSlackOAuthCancelled, isSubagentToolName, isThinkingEffort, isThisProcessDesktopHost, isThreadCaffeinated, isThreadRecordFile, isWorkspaceScratchPath, issueAttachmentForAbleTimeTask, issueSourceLabel, lastRequestOccupancy, latestPendingPlanQuestions, linearAuthorizationHeader, linearCycleIsActive, linearGraphql, linearOAuthAuthorizeUrl, linearOAuthCredentials, listAbleTimeAssignedIssues, listAbleTimeProjects, listAbleTimeTasks, listAgentSetupInfo, listBoardPins, listBranchCommits, listBranches, listBrightsyAccounts, listBrightsyChatTargets, listCodexModels, listConductorWorkspaces, listConnectedBrightsyTeams, listCursorModels, listGitHubIssues, listGlobalThreads, listIssues, listLinearAssignedIssues, listLinearIssues, listLinearIssuesDirect, listLinearTeams, listModelsForAgent, listOpencodeModels, listPrs, listRunScripts, listSchedules, listSlackOutboundWatches, listSlackWorkspaces, listThreads, listWorkspaces, listWorktreeFiles, listWorktrees, liveActivitySummary, loadAgentInstructions, loadAppSettings, loadBrightsyConfig, loadConductorSettings, loadHomeBoardInputs, loadRepoSettings, loadWorkspaceSettings, locksDir, loginAgent, lookupSoccerTeam, mapAbleTimeTask, maxConcurrentAgents, maybeCompactContext, mcpAllowTools, mcpAuthWarnings, mergeAgentGitAuthEnv, mergePr, mergePrStack, mergeSideboardIntoMcpServersJson, mergeUsage, messagePartParentId, nextPastedTextName, nextThinkingEffort, nonInteractiveGitProcessEnv, normalizeAbleTimeHost, normalizeParseResult, normalizeThinkingEffort, normalizeThread, normalizeTurnInput, normalizeWorktreePath, openInSystemTerminal, openPrStackLayers, openStackLayer, opencodeAdapter, orchestrationQuotaFallbackAgent, orchestrationQuotaOnLimit, orchestrationTitleNeedsSoccerNickname, orchestratorSessionPoisonedByBuiltins, originGhRepoEnv, parseCursorRunnerLine, parseDurationMs, parseForceStopMessage, parseGhStackViewJson, parseGithubSlugFromRemoteUrl, parseMcpList, parsePlanQuestionsInput, parseSessionQuotaResetAt, parseSlackRelayClientMessage, parseSlackRelayServerMessage, partsToAssistantText, pastedTextStats, pendingSlackExternalReplies, permissionMode, persistVaultKeyInKeychain, planFileAbs, planQuestionsSignature, pollSlackOutboundWatches, posixShellSingleQuote, preferredCursorCostCents, prepareTerminalCommand, previewLand, promptMentionsBrightsy, pushBranch, readExistingReviewRequestFile, readKeychainVaultKey, readPlanFile, readSkillBody, readThread, readWorktreeFile, readWorktreeFileForUpload, readWorktreeInclude, recordScheduleRun, recordSlackOutboundWatch, refreshBrightsyAccessToken, refreshGitHubAuth, registerPackagedUserMcpClients, releaseCaffeinateHoldForThread, releaseDesktopHost, removeBoardPin, removeWorkspace, removeWorktree, repoSlug, requestOccupancy, requestReview, requireAgent, resetGhStackDetectCache, resetGithubAgentTokenMemo, resolveAgentExecutable, resolveAgentGitAuthEnv, resolveClaudeExecutable, resolveCodexGitWritableRoots, resolveCommandBinarySync, resolveConductorCursorAgentId, resolveCursorModelId, resolveDefaultBranch, resolveDiffBaseRef, resolveEffectiveIssueSource, resolveFilesToCopy, resolveGhAuthToken, resolveGitDirsForLockRecovery, resolveGithubAgentToken, resolveGithubRepoSlug, resolveLinearState, resolveLinearTeam, resolveLoginCommand, resolveNewThreadOptions, resolvePlanMarkdown, resolvePrSelector, resolvePrSelectors, resolveQuotaFallbackAgent, resolveRepoRoot, resolveReviewGuidelines, resolveScheduleThreadId, resolveSlackListenMode, resolveThreadDefaults, resolveThreadEffort, resolveVaultKey, resolveWorktreeStartPoint, rewriteAbleTimeError, rewriteLinearError, run, runArchiveScript, runCloudConnect, runConventionSetup, runCursorWorktreeSetup, runSetupScript, runSlackListen, runSlackRelayClient, runWorkspaceSetup, sameWorktreePath, sanitizeMcpServerName, saveAbleTimeConnection, saveAppSettings, saveLinearOAuth, schedulesPath, scrubGithubTokensFromChildEnv, searchAbleTimeTasks, secureFileUnlocksWith, setCaffeinateHold, setHttpFetchImpl, setStatus, setVaultMasterKey, settingsSourceLabel, shouldAttachPastedText, shouldCompactContext, shouldInjectBrightsyMcp, shouldRefreshReviewRequestTemplate, shouldRemoveWorktreeOnTeardown, shouldResetSessionForOccupancy, shouldRunWorktreeCleanup, showCostEnabled, sideboardHomeDir, sideboardMcpProfile, sideboardReposDir, sideboardWorkspacesDir, slackAppLevelToken, slackArchiveUrl, slackCoordinatorSourceRef, slackListenEnabled, slackOAuthCredentials, slackOAuthResultUrl, slackRelayUrl, slugify, spawnAgentTurn, splitForCompaction, stackAgentDefaultsFrom, stackIdFrom, stackMergeReadiness, stageAbsolutePathsAsAttachments, stageBuffersAsAttachments, startDevServer, startLinearOAuth, startMcpServer, startOrchestration, startSlackOAuth, startSlackRelayServer, stripBrightsyNdjsonNoise, stripNestedElectronEnv, submitPrStack, suggestSlug, sumUsageList, summarizeConversation, switchBrightsyAccount, syncWorkspacesFromThreads, takenTeamSlugsForChatTab, takenTeamSlugsForOrchestration, taskMessageText, taskUrl, thinkingEffortBars, thinkingEffortLabel, thisProcessShouldDrainAgentQueues, threadDisplayLabel, threadFilePath, threadLivePath, threadLockPath, threadRequestsBrightsyMcp, threadsDir, threadsSharingWorktree, toAbleTimeIssueInfo, toPublicAppSettings, toolActivityLine, toolDescription, toolDetail, toolFilePath, totalTokens, turnCostUsdFromCursorUsage, updateAdvancedSettings, updateAgentExecutable, updateAppEnvironment, updateBrightsySettings, updateClaudeSettings, updateCodexSettings, updateDefaultsSettings, updateIntegrationsSettings, updateLinearIssue, updateOpencodeSettings, updateSchedule, updateThread, userClaudeMcpConfigPath, userCursorMcpConfigPath, validateLinearApiKey, verifyAbleTimeConnection, waitForPidExit, warmGithubAgentAuth, withAgentInstructions, withEventParentId, withEventsParentId, withExportedPath, withMaxOldSpaceSize, withThreadLock, workspaceSettingsSourceLabel, worktreeBoardStatus, worktreeCleanupSettings, worktreeDisplayLabel, worktreeDisplayLabelForGroup, worktreeNameFromPath, worktreesRoot, wrapReviewSkillMarkdown, writeInjectedMcpConfig, writePlanFile, writeThread, writeWorktreeFile };