@uipath/delegate-cli 1.204.0-preview.20261007152645 → 1.204.0-preview.20261015062504
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.
- package/README.md +31 -7
- package/dist/cli.mjs +1 -1
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -189,7 +189,7 @@ Exit codes:
|
|
|
189
189
|
|
|
190
190
|
- `show <id>` prints the title, the owner's user id and organization, and the delegation id of a session claimed from a delegation link. A session another user shared in your organization is shown too. Use `sessions` for timestamps and sub-agent links.
|
|
191
191
|
- `rename <id> <title>` sets the title. Everything after the id is the title, so quotes are optional.
|
|
192
|
-
- `delete <id>` deletes the session permanently, with its messages and sub-agent sessions. It does not ask for confirmation, because the CLI never prompts outside a conversation, so check the id first.
|
|
192
|
+
- `delete <id>` deletes the session permanently, with its messages and sub-agent sessions, and the session's local [task log](#task-automation---task-automation) under the state root (pass the run's `--working-dir`). It does not ask for confirmation, because the CLI never prompts outside a conversation, so check the id first.
|
|
193
193
|
|
|
194
194
|
An id the backend does not know prints `Session <id> not found.` on stderr and exits 1. A missing id or title, an extra operand, or `--page` / `--limit` / `--include-subagents` exits 2 before any request. Rename and delete work only on your own sessions.
|
|
195
195
|
|
|
@@ -287,6 +287,29 @@ delegate-cli --attach screenshot.png # conversation: the first line y
|
|
|
287
287
|
- In a conversation only the first message carries attachments — the prompt given on the command line, or the first line typed. Later messages carry none of their own, but the first message's files stay in context for the rest of the session.
|
|
288
288
|
- Relative paths resolve against the current directory. A path that does not exist, or the flag on a subcommand, exits 2 before any auth or interop work; a file that cannot be read fails the turn before it starts (exit 1).
|
|
289
289
|
|
|
290
|
+
### Task automation (`--task-automation`)
|
|
291
|
+
|
|
292
|
+
`--task-automation` records every UI action of the run so the agent can afterwards turn the task into a UiPath coded workflow with the bundled `uipath-taskautomation` skill (SDK `enableTaskAutomation`):
|
|
293
|
+
|
|
294
|
+
```bash
|
|
295
|
+
delegate-cli --task-automation --working-dir ~/automation
|
|
296
|
+
You> Open Notepad and type "Weekly report"
|
|
297
|
+
You> Turn what you just did into a UiPath coded workflow.
|
|
298
|
+
```
|
|
299
|
+
|
|
300
|
+
- Each `AppAct` step, with the selector of the element it acted on, and each request you sent are appended to `<working-dir>/captures/<session>/task-log-*.jsonl` (`~/.aria-sdk/captures/…` without `--working-dir`). The log keeps on-screen text, field labels and the start of each request; typed values and anything that reads as a credential are masked.
|
|
301
|
+
- While the CLI runs, the backend is asked for a sturdier selector for each captured step. Work left when it exits is picked up by the next `--task-automation` run under the same login and state root.
|
|
302
|
+
- Ask for the workflow in the same session: in the same conversation, or with `--session <id>` (and the same `--working-dir`) in a later invocation.
|
|
303
|
+
- It needs computer use, so it exits 2 with `--headless`, `--no-computer-use` or `--cartographer`, and on subcommands. Where the deployment does not offer task automation yet (it follows the desktop app's rollout and is not on the production cloud), the run starts with a warning and records nothing. The skill also needs the `uip` CLI on `PATH`, signed in with `uip login`.
|
|
304
|
+
- `uipath-taskautomation` ships with the SDK package (see [Skills](#skills)); a copy of your own in `--skills-path` replaces it.
|
|
305
|
+
- `delegate-cli sessions delete <id>` removes the log with the session; give it the same `--working-dir` as the run.
|
|
306
|
+
|
|
307
|
+
### Skills
|
|
308
|
+
|
|
309
|
+
The CLI uses the skills the `@uipath/delegate-sdk` package ships, with no Delegate desktop app needed: the Integration Service API skills (`jira`, `confluence`, `github`, `google-workspace`, `uipath-integrations`, `uipath-orchestrator`), the Office and document skills (`excel-architect`, `word-architect`, `powerpoint-architect`, `pdf-architect`, `office-download`, `doc-coauthoring`, `internal-comms`, `knowledge-base`), `outlook-365`, `slack-operation`, `teams-operation`, `uipath-taskautomation`, `uipath-workflow-documenter`, `business-analysis`, `project-task-list`, `transcribe-media`, `media-tools` and `system-diagnostics`. The agent picks one when the task calls for it; `--preload-skill <name>` attaches one up front.
|
|
310
|
+
|
|
311
|
+
For anything else, put your skills in a folder (one sub-folder per skill, each with a `SKILL.md`) and pass `--skills-path <folder>`, or set `DELEGATE_BUNDLED_SKILLS_PATH`. They load on top of the packaged skills, and one with the same name as a packaged skill replaces it.
|
|
312
|
+
|
|
290
313
|
### Speech-to-text (`transcribe`)
|
|
291
314
|
|
|
292
315
|
Transcribe an audio file with the backend's Whisper route (`/v1/transcription`, the one the desktop app's voice input uses) and print the text:
|
|
@@ -355,11 +378,12 @@ Three levels of machine access, independent of conversation mode:
|
|
|
355
378
|
| `--no-connections` | off | Disable orchestrator ConnectionService (silences 404 noise on tenants without orchestrator). |
|
|
356
379
|
| `--no-security` | off | Disable tool security wrapper. Debug only. |
|
|
357
380
|
| `--no-memory` | off | Do not send the Delegate app's local long-term memories with each turn (SDK `enableMemory: false`). By default the CLI reads the same `Memories` folder the desktop app uses, and the model may save new preferences and learnings there with its file tools. |
|
|
381
|
+
| `--task-automation` | off | Record every UI action of the run to the session's task log, so the agent can turn the task into a UiPath coded workflow (SDK `enableTaskAutomation`). Needs computer use: refused with `--headless`, `--no-computer-use` and `--cartographer`. See [Task automation](#task-automation---task-automation). |
|
|
358
382
|
| `--preload-skill <name>` | — | Preload a skill into the session before the first model turn (repeatable; SDK `preloadSkills`). A name given twice is preloaded once. |
|
|
359
383
|
| `--cartographer` | off | Cartographer engagement preset — shorthand for `--no-computer-use --preload-skill business-analysis --preload-skill project-task-list --preload-skill knowledge-base`. Add `--project` / `--working-dir` to say where the engagement's files live, and further `--preload-skill` flags for anything extra; a skill the preset already covers is **not** preloaded twice, whichever side of the flag it is named on. Pass `--headless` alongside it to drop interop as well (`--headless` always wins over the preset's `--no-computer-use`). |
|
|
360
384
|
| `--project <id>` | — | Bind the session to a project: wiki, plans, `task-list.md` and `progress.yaml` live under `<state root>/projects/<id>/` (the state root is `--working-dir`, else `~/.aria-sdk`), the preloaded skills' declared project files are copied there on the first message, and the project context (`ProjectId`, `TaskListPath`, `ProgressPath`) is injected into every turn (SDK `projectId`). Client-side routing key only — the CLI never links a backend project row. |
|
|
361
385
|
| `--working-dir <path>` | `~/.aria-sdk` for state; process cwd for shells | Shell cwd for the agent and root for SDK-local state (SDK `workingDirectory`). Relative paths resolve against the current directory; **the directory is created if missing**. |
|
|
362
|
-
| `--skills-path <path>` | — |
|
|
386
|
+
| `--skills-path <path>` | — | Folder of your own skills, loaded on top of the [packaged skills](#skills) (SDK `bundledSkillsPath`); also `DELEGATE_BUNDLED_SKILLS_PATH`. On a name clash your copy wins. Relative paths resolve against the current directory. |
|
|
363
387
|
| `--effort <tier>` | model's recommended tier | Reasoning effort: `low` / `medium` / `high` / `xhigh` / `max` (SDK `effort`). Any other value exits with code 2. |
|
|
364
388
|
| `--session <id>` | server-assigned | Pin the session id (SDK `sessionId`). Must be an existing backend session: the backend assigns session ids, so an id it does not know fails the turn (exit 1) before anything is sent. Reuse it across invocations to continue one conversation — the agent then remembers earlier turns. Note that `--preload-skill` is stamped when the SDK *creates* a session, so passing it alongside `--session` does not reconfigure an existing one. For `complete`, the session whose history is sent as context. |
|
|
365
389
|
| `--json-schema <file>` | — | JSON schema file the structured answer must match: for `complete`, and for a prompt (the turn's result is extracted after it runs; implies `--print`). On another command the flag exits with code 2. |
|
|
@@ -431,10 +455,10 @@ npx delegate-cli --no-computer-use --project invoice-approval --working-dir ~/en
|
|
|
431
455
|
npx delegate-cli --cartographer --project invoice-approval --working-dir ~/engagements \
|
|
432
456
|
"Read the AS-IS notes and draft the process overview."
|
|
433
457
|
|
|
434
|
-
# Preset plus one extra skill
|
|
435
|
-
#
|
|
436
|
-
npx delegate-cli --cartographer --preload-skill task-design
|
|
437
|
-
"Start the engagement."
|
|
458
|
+
# Preset plus one extra skill the package does not ship, loaded from a folder of your
|
|
459
|
+
# own; business-analysis is already in the preset, so naming it again changes nothing
|
|
460
|
+
npx delegate-cli --cartographer --skills-path ~/my-skills --preload-skill task-design \
|
|
461
|
+
--project invoice-approval "Start the engagement."
|
|
438
462
|
|
|
439
463
|
# Separate one-turn commands with persistent interop
|
|
440
464
|
npx delegate-cli --print --keep-alive "take a screenshot"
|
|
@@ -502,7 +526,7 @@ A failed backend call exits 1 with the status on stderr and nothing on stdout, a
|
|
|
502
526
|
```bash
|
|
503
527
|
npx delegate-cli login --env production # once
|
|
504
528
|
npx delegate-cli host --runner-url wss://runner.example/worker \
|
|
505
|
-
--interop /path/to/UiPath.
|
|
529
|
+
--interop /path/to/UiPath.Delegate.Host.Api # omit --interop → discovery only
|
|
506
530
|
```
|
|
507
531
|
|
|
508
532
|
Backend URL defaults to the saved login's org/tenant (override with `--backend` or `AUTOPILOT_BACKEND_URL`). Tokens refresh automatically from `~/.aria/sdk-auth.json`; when refresh permanently fails the host prints a re-login instruction and exits non-zero.
|
package/dist/cli.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
const _0x4b2408=_0x4e66;(function(_0x1ce6a8,_0x18e952){const _0x590c7f=_0x4e66,_0x3ab640=_0x1ce6a8();while(!![]){try{const _0x23a246=-parseInt(_0x590c7f(0xe6))/0x1+-parseInt(_0x590c7f(0x24a))/0x2*(-parseInt(_0x590c7f(0x180))/0x3)+-parseInt(_0x590c7f(0x107))/0x4+-parseInt(_0x590c7f(0x112))/0x5+-parseInt(_0x590c7f(0x16e))/0x6+parseInt(_0x590c7f(0x138))/0x7+parseInt(_0x590c7f(0x15b))/0x8;if(_0x23a246===_0x18e952)break;else _0x3ab640['push'](_0x3ab640['shift']());}catch(_0x30ebfd){_0x3ab640['push'](_0x3ab640['shift']());}}}(_0x394f,0xe2ef9));const __dirname=import.meta.dirname;import _0x327d7 from'fs';import _0x53e3ce from'path';import{clearLine as _0x349479,createInterface as _0x45c416,cursorTo as _0x496026}from'node:readline';import{BUSINESS_ANALYSIS_PRELOADED_SKILLS as _0x18259a,DelegateAgent as _0x2a12bd,cancelTurn as _0x373a21,InteropProcess as _0x5887e6,complete as _0x3e5d4d,DEFAULT_MODEL as _0x2014de,createBackendClient as _0x305dd9,evaluate as _0x59308b,isCompletionRequestError as _0x71cc8,isEvaluationRequestError as _0x5a4402,isTranscriptionError as _0x4d36b1,rerank as _0x341947,transcribe as _0xd6590f,verify as _0x1ef4ae,acceptDelegation as _0x58239f,cancelDelegation as _0x1af96c,claimDelegation as _0xdaff81,completeDelegation as _0x274b0c,createDelegation as _0x2e241f,deleteDelegation as _0x350f12,dismissDelegation as _0x3a0c7d,getSessionDelegations as _0x5f11d9,isDelegationError as _0xfcf6ab,listDelegations as _0x305187,listOrgUsers as _0x5d4451,previewDelegation as _0x14013e,TurnResultCollector as _0x28c7ed,agentEventToJsonLine as _0x3900b8,describeBaseUrlRejection as _0x55a80a,getActivitySummary as _0x37f407,getAuthFilePath as _0x20e75f,getByoWarnings as _0x21a610,getCartographerAllowance as _0x30995d,getDailyBreakdown as _0x2f9202,getLicensingSummary as _0x840846,getMonthlySpending as _0x352089,isOutputFormat as _0x3b7f72,isCloudBaseUrl as _0x3cad23,isSafeProjectFolderSegment as _0x53d291,listModels as _0x11f95f,listSessions as _0x32f689,getSession as _0x279aac,renameSession as _0x845060,deleteSession as _0x49b938,forkSession as _0x5042fd,isBackendRequestError as _0x42e5b9,MAX_SESSION_PAGE_SIZE as _0x1e5d8b,listTenants as _0x4fd2bd,loadAndRefreshAuth as _0x29b8ac,loadAndRefreshSdkLogin as _0x595be9,parsePlatformBaseUrl as _0xd8ee01,resolveBackendUrl as _0xb77cfd,runHealthCheck as _0x339d97,runHostCommand as _0x2d42b7,runLoginFlow as _0x3d3632,runTurnForResult as _0x1208d4,saveAuthData as _0x4bed5a,switchTenant as _0x16d71c,toJsonLine as _0x354c62,ENV_TO_CLOUD as _0x1c09a4,OUTPUT_FORMATS as _0x2042be}from'@uipath/delegate-sdk';var pt=[_0x4b2408(0x165),_0x4b2408(0xf2),_0x4b2408(0x10d),'host',_0x4b2408(0x1cb),_0x4b2408(0x244),'check',_0x4b2408(0x21b),_0x4b2408(0x18d),'evaluate',_0x4b2408(0x215),_0x4b2408(0xec),_0x4b2408(0x1eb),_0x4b2408(0x1bd),_0x4b2408(0x1db),_0x4b2408(0x158)],W=['',_0x4b2408(0x10d),'whoami',_0x4b2408(0x21e),'sessions',_0x4b2408(0x18d),_0x4b2408(0x117),_0x4b2408(0x215),_0x4b2408(0xec),_0x4b2408(0x1eb),_0x4b2408(0x1bd),'delegations',_0x4b2408(0x158)],G=[_0x4b2408(0x223),_0x4b2408(0x192),'high','xhigh',_0x4b2408(0x190)],mt=_0x18259a;function p(_0x506f77,_0x347a57,_0x15c8c9,_0x39e8bd){const _0x23251d=_0x4b2408;let _0x515ebb=_0x506f77[_0x347a57];return(!_0x515ebb||_0x515ebb[_0x23251d(0x1fd)]>0x1&&_0x515ebb[_0x23251d(0x260)]('-'))&&(console[_0x23251d(0x236)](_0x15c8c9+_0x23251d(0x26d)+_0x39e8bd+'.'),process['exit'](0x2)),_0x515ebb;}function N(_0x3baddc,_0xc7dc09,_0x548ec2,_0x3778a5){const _0x39d9ce=_0x4b2408;let _0x11dbc9=p(_0x3baddc,_0xc7dc09,_0x548ec2,'a\x20number'),_0x18fd1a=Number(_0x11dbc9);return(!/^\d+$/[_0x39d9ce(0x1c3)](_0x11dbc9)||_0x18fd1a<0x1||!Number['isSafeInteger'](_0x18fd1a)||_0x3778a5!==void 0x0&&_0x18fd1a>_0x3778a5)&&(console[_0x39d9ce(0x236)](_0x548ec2+_0x39d9ce(0x245)+(_0x3778a5===void 0x0?_0x39d9ce(0x1ac):'from\x201\x20to\x20'+_0x3778a5)+',\x20got\x20'+_0x11dbc9+'.'),process[_0x39d9ce(0x111)](0x2)),_0x18fd1a;}function ft(_0x43dc34){const _0x5d4cf5=_0x4b2408;let _0x1f7847={'subcommand':'','prompt':'','print':!0x1,'keepAlive':!0x1,'cleanup':!0x1,'headless':!0x1,'noComputerUse':!0x1,'cartographer':!0x1,'noConnections':!0x1,'noSecurity':!0x1,'noMemory':!0x1,'quiet':!0x1,'verbose':!0x1,'outputFormat':_0x5d4cf5(0xd6),'preloadSkills':[],'attachments':[],'skipEnvCheck':!0x1,'includeSubAgents':!0x1,'operands':[],'help':!0x1,'version':!0x1};pt[_0x5d4cf5(0x13a)](_0x43dc34[0x0])&&(_0x1f7847[_0x5d4cf5(0xb5)]=_0x43dc34[0x0],_0x43dc34=_0x43dc34[_0x5d4cf5(0x1d0)](0x1));let _0x571eba=[];for(let _0x2bea48=0x0;_0x2bea48<_0x43dc34[_0x5d4cf5(0x1fd)];_0x2bea48++){let _0x498b6e=_0x43dc34[_0x2bea48];switch(_0x498b6e){case'--print':case'-p':_0x1f7847[_0x5d4cf5(0x26a)]=!0x0;break;case'--keep-alive':_0x1f7847['keepAlive']=!0x0;break;case _0x5d4cf5(0x239):_0x1f7847[_0x5d4cf5(0x1be)]=!0x0;break;case _0x5d4cf5(0x114):_0x1f7847[_0x5d4cf5(0x201)]=!0x0;break;case _0x5d4cf5(0x186):_0x1f7847[_0x5d4cf5(0x116)]=!0x0;break;case _0x5d4cf5(0x1a4):_0x1f7847[_0x5d4cf5(0x258)]=!0x0,_0x1f7847['noComputerUse']=!0x0,_0x1f7847[_0x5d4cf5(0x24e)]['push'](...mt);break;case _0x5d4cf5(0x213):_0x1f7847[_0x5d4cf5(0x22a)]=!0x0;break;case _0x5d4cf5(0xd9):_0x1f7847[_0x5d4cf5(0x1e8)]=!0x0;break;case _0x5d4cf5(0x150):_0x1f7847[_0x5d4cf5(0x1dc)]=!0x0;break;case _0x5d4cf5(0xc2):case'-q':_0x1f7847[_0x5d4cf5(0x214)]=!0x0;break;case _0x5d4cf5(0xd7):_0x1f7847['verbose']=!0x0;break;case _0x5d4cf5(0xee):_0x1f7847['backendUrl']=_0x43dc34[++_0x2bea48];break;case _0x5d4cf5(0xb2):_0x1f7847[_0x5d4cf5(0x17f)]=_0x43dc34[++_0x2bea48];break;case _0x5d4cf5(0x208):_0x1f7847['runnerUrl']=_0x43dc34[++_0x2bea48];break;case _0x5d4cf5(0x267):_0x1f7847['interopPath']=_0x43dc34[++_0x2bea48];break;case _0x5d4cf5(0x1a2):_0x1f7847['workerId']=_0x43dc34[++_0x2bea48];break;case _0x5d4cf5(0x160):_0x1f7847[_0x5d4cf5(0x24e)][_0x5d4cf5(0x15e)](p(_0x43dc34,++_0x2bea48,_0x498b6e,_0x5d4cf5(0xd2)));break;case'--project':{let _0x31072c=p(_0x43dc34,++_0x2bea48,_0x498b6e,_0x5d4cf5(0x207));_0x53d291(_0x31072c)||(console[_0x5d4cf5(0x236)](_0x5d4cf5(0xd8)+_0x31072c+_0x5d4cf5(0x15f)),process['exit'](0x2)),_0x1f7847[_0x5d4cf5(0x1cf)]=_0x31072c;break;}case _0x5d4cf5(0x1a6):{let _0x4eb10b=p(_0x43dc34,++_0x2bea48,_0x498b6e,_0x5d4cf5(0x23f)+_0x2042be[_0x5d4cf5(0x1c4)](_0x5d4cf5(0x225))+')');_0x3b7f72(_0x4eb10b)||(console[_0x5d4cf5(0x236)](_0x5d4cf5(0x1c7)+_0x4eb10b+_0x5d4cf5(0xfd)+_0x2042be['join'](_0x5d4cf5(0x225))+'.'),process['exit'](0x2)),_0x1f7847[_0x5d4cf5(0x263)]=_0x4eb10b;break;}case _0x5d4cf5(0xfb):_0x1f7847[_0x5d4cf5(0x1dd)]=p(_0x43dc34,++_0x2bea48,_0x498b6e,_0x5d4cf5(0x26e));break;case _0x5d4cf5(0x189):_0x1f7847['page']=N(_0x43dc34,++_0x2bea48,_0x498b6e);break;case'--limit':_0x1f7847[_0x5d4cf5(0x11f)]=N(_0x43dc34,++_0x2bea48,_0x498b6e,_0x1e5d8b);break;case _0x5d4cf5(0x242):_0x1f7847[_0x5d4cf5(0xe4)]=!0x0;break;case _0x5d4cf5(0x1d1):_0x1f7847[_0x5d4cf5(0x198)]=p(_0x43dc34,++_0x2bea48,_0x498b6e,_0x5d4cf5(0x1b2));break;case _0x5d4cf5(0x19d):{let _0x26a85b=_0x53e3ce[_0x5d4cf5(0x220)](process['cwd'](),p(_0x43dc34,++_0x2bea48,_0x498b6e,_0x5d4cf5(0x246)));_0x327d7[_0x5d4cf5(0x120)](_0x26a85b)||(console['error'](_0x5d4cf5(0x191)+_0x26a85b),process[_0x5d4cf5(0x111)](0x2)),_0x1f7847[_0x5d4cf5(0x19b)][_0x5d4cf5(0x15e)](_0x26a85b);break;}case _0x5d4cf5(0x14f):_0x1f7847[_0x5d4cf5(0x1e7)]=p(_0x43dc34,++_0x2bea48,_0x498b6e,_0x5d4cf5(0x19e));break;case _0x5d4cf5(0x170):_0x1f7847['delegateTo']=p(_0x43dc34,++_0x2bea48,_0x498b6e,_0x5d4cf5(0x23c));break;case'--summary':_0x1f7847[_0x5d4cf5(0x1bb)]=p(_0x43dc34,++_0x2bea48,_0x498b6e,_0x5d4cf5(0x156));break;case'--days':_0x1f7847['days']=N(_0x43dc34,++_0x2bea48,_0x498b6e,0x16d);break;case'--working-dir':_0x1f7847[_0x5d4cf5(0x1c8)]=_0x53e3ce[_0x5d4cf5(0x220)](process['cwd'](),p(_0x43dc34,++_0x2bea48,_0x498b6e,_0x5d4cf5(0x184)));break;case _0x5d4cf5(0x1e5):_0x1f7847[_0x5d4cf5(0x171)]=_0x53e3ce['resolve'](process[_0x5d4cf5(0x1b6)](),p(_0x43dc34,++_0x2bea48,_0x498b6e,_0x5d4cf5(0x184)));break;case _0x5d4cf5(0x14a):{let _0x19eda4=p(_0x43dc34,++_0x2bea48,_0x498b6e,_0x5d4cf5(0xe8));G[_0x5d4cf5(0x13a)](_0x19eda4)||(console[_0x5d4cf5(0x236)](_0x5d4cf5(0x194)+_0x19eda4+'.\x20Use\x20'+G[_0x5d4cf5(0x1c4)](_0x5d4cf5(0x225))+'.'),process[_0x5d4cf5(0x111)](0x2)),_0x1f7847['effort']=_0x19eda4;break;}case _0x5d4cf5(0xc5):{let _0x141a67=_0x43dc34[++_0x2bea48];(!_0x141a67||_0x141a67[_0x5d4cf5(0x260)]('--'))&&(console[_0x5d4cf5(0x236)](_0x5d4cf5(0x22d)),process[_0x5d4cf5(0x111)](0x2)),_0x1f7847[_0x5d4cf5(0xf2)]=_0x141a67;break;}case _0x5d4cf5(0x234):{let _0x5a81f7=_0x43dc34[++_0x2bea48];[_0x5d4cf5(0xbd),_0x5d4cf5(0x1b7),_0x5d4cf5(0xc0),_0x5d4cf5(0x154)][_0x5d4cf5(0x13a)](_0x5a81f7)||(console[_0x5d4cf5(0x236)](_0x5d4cf5(0x20d)+_0x5a81f7+'.\x20Use\x20alpha\x20|\x20staging\x20|\x20production\x20|\x20localhost.'),process[_0x5d4cf5(0x111)](0x2)),_0x1f7847[_0x5d4cf5(0xc1)]=_0x5a81f7;break;}case'--url':case'--authority':{let _0x552a3d=p(_0x43dc34,++_0x2bea48,_0x498b6e,'a\x20deployment\x20URL,\x20e.g.\x20https://automationsuite.contoso.com'),_0xdf3872=_0xd8ee01(_0x552a3d);if(_0xdf3872['ok']===!0x1){console[_0x5d4cf5(0x236)](_0x55a80a(_0x552a3d,_0xdf3872[_0x5d4cf5(0xfc)])),process[_0x5d4cf5(0x111)](0x2);break;}_0x1f7847['url']=_0xdf3872[_0x5d4cf5(0x1b0)];break;}case'--skip-env-check':_0x1f7847[_0x5d4cf5(0xc7)]=!0x0;break;case'-h':case _0x5d4cf5(0x229):_0x1f7847[_0x5d4cf5(0x134)]=!0x0;break;case'-v':case _0x5d4cf5(0x11a):_0x1f7847['version']=!0x0;break;default:_0x498b6e[_0x5d4cf5(0x260)]('--')&&(console[_0x5d4cf5(0x236)]('Unknown\x20flag:\x20'+_0x498b6e),process['exit'](0x2)),_0x571eba['push'](_0x498b6e);}}return _0x1f7847['tenant']!==void 0x0&&_0x1f7847[_0x5d4cf5(0xb5)]!=='login'&&(console['error'](_0x5d4cf5(0xc9)),process[_0x5d4cf5(0x111)](0x2)),_0x1f7847[_0x5d4cf5(0xc6)]!==void 0x0&&_0x1f7847[_0x5d4cf5(0xc1)]!==void 0x0&&(console['error'](_0x5d4cf5(0xe1)),process['exit'](0x2)),_0x1f7847[_0x5d4cf5(0xc6)]!==void 0x0&&_0x1f7847['subcommand']!==_0x5d4cf5(0x165)&&(console[_0x5d4cf5(0x236)](_0x5d4cf5(0x268)),process[_0x5d4cf5(0x111)](0x2)),_0x1f7847[_0x5d4cf5(0x200)]!==void 0x0&&_0x1f7847[_0x5d4cf5(0xb5)]!==_0x5d4cf5(0x18d)&&(console[_0x5d4cf5(0x236)](_0x5d4cf5(0xb9)),process['exit'](0x2)),_0x1f7847[_0x5d4cf5(0x198)]!==void 0x0&&(_0x1f7847[_0x5d4cf5(0xb5)]!==_0x5d4cf5(0x1eb)&&_0x1f7847[_0x5d4cf5(0xb5)]!==''||_0x1f7847['cleanup'])&&(console['error'](_0x5d4cf5(0x119)),process['exit'](0x2)),_0x1f7847[_0x5d4cf5(0x19b)][_0x5d4cf5(0x1fd)]>0x0&&(_0x1f7847[_0x5d4cf5(0xb5)]!==''||_0x1f7847[_0x5d4cf5(0x1be)])&&(console[_0x5d4cf5(0x236)](_0x5d4cf5(0x14e)),process['exit'](0x2)),_0x1f7847[_0x5d4cf5(0xc7)]&&_0x1f7847[_0x5d4cf5(0xb5)]!==_0x5d4cf5(0x165)&&(console[_0x5d4cf5(0x236)](_0x5d4cf5(0xdd)),process[_0x5d4cf5(0x111)](0x2)),_0x1f7847[_0x5d4cf5(0x263)]!==_0x5d4cf5(0xd6)&&!W[_0x5d4cf5(0x13a)](_0x1f7847['subcommand'])&&(console['error']('--output-format\x20'+_0x1f7847[_0x5d4cf5(0x263)]+_0x5d4cf5(0x15d)+W[_0x5d4cf5(0x1b1)](Boolean)[_0x5d4cf5(0x1c4)](',\x20')+'.'),process[_0x5d4cf5(0x111)](0x2)),(_0x1f7847[_0x5d4cf5(0x219)]!==void 0x0||_0x1f7847[_0x5d4cf5(0x11f)]!==void 0x0||_0x1f7847['includeSubAgents'])&&_0x1f7847[_0x5d4cf5(0xb5)]!=='sessions'&&(console[_0x5d4cf5(0x236)](_0x5d4cf5(0x24b)),process[_0x5d4cf5(0x111)](0x2)),(_0x1f7847[_0x5d4cf5(0x1c6)]!==void 0x0||_0x1f7847[_0x5d4cf5(0x1bb)]!==void 0x0)&&_0x1f7847['subcommand']!==_0x5d4cf5(0x1db)&&(console['error'](_0x5d4cf5(0x25a)),process[_0x5d4cf5(0x111)](0x2)),_0x1f7847[_0x5d4cf5(0x1e7)]!==void 0x0&&_0x1f7847[_0x5d4cf5(0xb5)]!==_0x5d4cf5(0x21b)&&(console[_0x5d4cf5(0x236)](_0x5d4cf5(0x1f8)),process[_0x5d4cf5(0x111)](0x2)),_0x1f7847[_0x5d4cf5(0x24e)]=[...new Set(_0x1f7847[_0x5d4cf5(0x24e)])],_0x1f7847[_0x5d4cf5(0xd0)]=_0x571eba,_0x1f7847[_0x5d4cf5(0x135)]=_0x571eba['join']('\x20'),_0x1f7847;}function _0x394f(){const _0x3ec9b5=['Session:\x20\x20\x20\x20\x20\x20','limit_enabled','a\x20project\x20id','--runner-url','\x20(resets\x20',')\x20—\x20saved\x20to\x20','tool_call','replace','Invalid\x20--env:\x20','.aria','--page,\x20--limit\x20and\x20--include-subagents\x20apply\x20to\x20`delegate-cli\x20sessions\x20[list]`\x20only.','alreadyAccepted','\x20\x20(sub-agent\x20of\x20','\x0a🤔\x20','--no-connections','quiet','rerank','\x20not\x20found,\x20has\x20no\x20messages','[env=','delegations\x20delete\x20<delegation-id>','page','getTurnUsageHistory','sessions','No\x20models\x20available\x20for\x20this\x20product/tenant.\x0a','total_sessions','check','\x20\x20from\x20','resolve','\x20\x22<prompt>\x22\x0a','No\x20sessions\x20on\x20page\x20','low','First\x20login\x20requires\x20--env\x20or\x20--url.\x20Usage:\x20delegate-cli\x20login\x20--env\x20<alpha|staging|production>,\x20or\x20delegate-cli\x20login\x20--url\x20https://automationsuite.contoso.com','\x20|\x20','email','monthly_limit_usd','map','--help','noConnections','readFileSync','Work\x20on\x20it\x20with:\x20delegate-cli\x20--session\x20','--tenant\x20requires\x20a\x20tenant\x20name.','\x20(in\x20','Use:\x20delegate-cli\x20delegations\x20','hide','pendingResults','stream-json','resume','--env','delegation','error','initialize','\x20must\x20be\x20a\x20JSON\x20object.','--cleanup','\x20PU\x20beyond\x20quota','asyncIterator','an\x20email\x20address\x20or\x20name','\x20(Delegate\x20desktop\x20app\x20fallback)','then','a\x20format\x20(','\x20\x22<prompt>\x22\x0aAnswer\x20with:\x20delegate-cli\x20delegations\x20complete\x20','Token:\x20\x20\x20\x20\x20\x20\x20\x20expired\x20','--include-subagents','\x20not\x20found.','whoami','\x20must\x20be\x20a\x20whole\x20number\x20','a\x20file\x20path','STATUS','extra_pool_consumed_pu','Unknown\x20sessions\x20action:\x20','167312tdbBRc','--page,\x20--limit\x20and\x20--include-subagents\x20apply\x20to\x20`delegate-cli\x20sessions`\x20only.','choice\x20','UiPath\x20Cloud','preloadSkills','catch','Forked\x20','No\x20delegations.\x0a','exitCode','Owner\x20\x20\x20\x20\x20\x20\x20\x20\x20','Delegation\x20\x20\x20\x20','rename','toolName',':\x20cannot\x20read\x20the\x20request\x20(','cartographer','prompt_tokens','--to\x20and\x20--summary\x20apply\x20to\x20`delegate-cli\x20delegations\x20create`\x20only.','%\x20of\x20','end','Deleted\x20session\x20','delete','\x20\x20\x20\x20','startsWith','No\x20answers\x20awaiting\x20acceptance.\x0a','models_breakdown','outputFormat','\x20into\x20','rmSync','Bearer\x20','--interop','--url\x20applies\x20to\x20`delegate-cli\x20login`\x20only.\x20Other\x20commands\x20follow\x20the\x20saved\x20login,\x20or\x20--backend\x20<url>.','bind','print','Licensing:\x20\x20\x20\x20no\x20licensing\x20quota\x20applies','Missing\x20prompt.\x20Pass\x20it\x20as\x20an\x20argument,\x20pipe\x20it\x20via\x20stdin,\x20or\x20run\x20`delegate-cli\x20--help`.','\x20requires\x20','a\x20session\x20id','accept','probability','\x20\x22<answer>\x22\x0a','No\x20structured\x20output:\x20the\x20turn\x20failed\x20(','padEnd','--model','interopPath','stderr','subcommand','Organization:\x20','UIPATH_BASE_URL\x20is\x20unusable.\x20','keepAlive','--days\x20applies\x20to\x20`delegate-cli\x20usage\x20activity|daily`\x20only.','🔧\x20','concat','Accepted','alpha','type','description','production','env','--quiet','getSessionId','pause','--tenant','url','skipEnvCheck','userId','--tenant\x20applies\x20to\x20`delegate-cli\x20login`\x20only.\x20Switch\x20tenants\x20with:\x20delegate-cli\x20tenant\x20<name>','\x0a⚠️\x20\x20Auth\x20expired.\x20Opening\x20browser\x20to\x20re-login…\x0a','score','Organization\x20\x20','tokenExpiresAt','task','monthly_spend_usd','operands','\x20cap','a\x20skill\x20name','\x20active\x20days','Model\x20','period_days','text','--verbose','Invalid\x20--project:\x20\x22','--no-security','\x20to\x20','delegations\x20complete\x20<delegation-id>\x20\x22<answer>\x22|-','\x20of\x20session\x20','--skip-env-check\x20applies\x20to\x20`delegate-cli\x20login`\x20only.','\x20in\x20progress\x20on\x20session\x20','\x0aUse\x20with:\x20delegate-cli\x20--model\x20<id>\x20\x22<prompt>\x22\x0a','Last\x20','Pass\x20either\x20--env\x20(a\x20named\x20cloud)\x20or\x20--url\x20(any\x20other\x20deployment),\x20not\x20both.','confidence','No\x20CLI\x20login\x20found.\x20Run\x20`delegate-cli\x20login\x20--env\x20<alpha|staging|production>`\x20first.','includeSubAgents','show','657231PFhunl','AUTH_TOKEN_FILE\x20\x27','an\x20effort\x20tier','\x20(stdin\x20was\x20empty)','rubric_version','dismissed','verify','✓\x20Done\x0a','--backend','Tenant:\x20\x20\x20\x20\x20\x20\x20','Deployment:\x20\x20\x20','assignedUser','tenant','complete\x20needs\x20a\x20prompt:\x20delegate-cli\x20complete\x20--json-schema\x20schema.json\x20\x22<prompt>\x22,\x20or\x20-\x20to\x20read\x20stdin.','[saved\x20login]\x20Backend\x20URL:\x20','isTTY','string','\x20(cancel\x20with:\x20delegate-cli\x20sessions\x20cancel\x20','log','now','tenantName','--session','rejection','.\x20Use\x20','toFixed','Cartographer:\x20',']\x20Backend\x20URL:\x20','active_days','\x22.\x0a','No\x20one\x20matches\x20\x22','No\x20usage\x20in\x20the\x20last\x20','Switch\x20with:\x20delegate-cli\x20tenant\x20<name>\x0a','UPDATED','2669836KzSZFz','Spending:\x20\x20\x20\x20\x20$','utf-8','Usage:\x20delegate-cli\x20org-users\x20<name\x20or\x20email\x20prefix>','total_tokens','\x20\x20\x20\x20Not\x20available\x20on\x20this\x20plan','models','delegations\x20create\x20--session\x20<id>\x20[--to\x20<email|name>]\x20[--summary\x20<text>]\x20\x22<task>\x22|-','floor','transcribe:\x20cannot\x20read\x20','exit','4486120sdpPve','\x20tokens\x0a','--headless','Already\x20accepted','noComputerUse','evaluate','add','--json-schema\x20applies\x20to\x20prompts\x20and\x20to\x20`delegate-cli\x20complete`\x20only.','--version','status','complete\x20needs\x20--json-schema\x20<file>:\x20delegate-cli\x20complete\x20--json-schema\x20schema.json\x20\x22<prompt>\x22.','delegations\x20show\x20<delegation-id|delegate://delegation/…>','Cancel\x20requested\x20for\x20turn\x20','limit','existsSync',';\x20the\x20saved\x20login\x20still\x20uses\x20','model_id','model_version','cancel','argv','token_units','displayName','toISOString','isDesktopFallback','environment\x20variables\x20(AUTH_TOKEN/TENANT_ID/ORG_ID)','\x0aStopping…\x20(Ctrl+C\x20again\x20to\x20force\x20exit)\x0a','Unknown\x20usage\x20view:\x20','completion_tokens','Tenants\x20of\x20','data','delegations\x20pending\x20<session-id>','organizationId','total_token_units','Title\x20\x20\x20\x20\x20\x20\x20\x20\x20','help','prompt','sendMessage','done','3735956uvkVuZ','/exit','includes','Licensing:\x20\x20\x20\x20','delegations\x20cancel\x20<delegation-id>','title','deepLink','updatedAt','name','Auth\x20comes\x20from\x20AUTH_TOKEN/TENANT_ID/ORG_ID\x20—\x20set\x20TENANT_ID\x20and\x20TENANT_SLUG\x20to\x20change\x20the\x20tenant.','once','entries',').\x0a','--env\x20localhost\x20has\x20no\x20OAuth\x20flow;\x20pick\x20alpha,\x20staging,\x20or\x20production.','delegations\x20list\x20<backend-project-id>','isArray','Session:\x20','stdout','--effort','transcribe\x20needs\x20audio:\x20delegate-cli\x20transcribe\x20<file>,\x20or\x20-\x20to\x20read\x20stdin.','expiresAt','Token:\x20\x20\x20\x20\x20\x20\x20\x20expires\x20','--attach\x20applies\x20to\x20prompts\x20only.','--turn','--no-memory','deleted','unknown\x20slug','lockReason','localhost','Interop\x20stopped\x20(if\x20it\x20was\x20running).','a\x20briefing\x20text','structuredError','org-users','thinking','spawn','25947880qjOund','total_completion_tokens','\x20applies\x20to\x20prompts\x20and\x20to\x20these\x20commands\x20only:\x20','push','\x22.\x20Use\x20a\x20single\x20folder-safe\x20segment\x20such\x20as\x20invoice-approval\x20(letters,\x20digits,\x20spaces,\x20\x22_\x22,\x20\x22-\x22,\x20\x22.\x22,\x20parentheses;\x20at\x20most\x2064\x20characters;\x20not\x20starting\x20with\x20\x22.\x22\x20or\x20ending\x20with\x20\x22.\x22\x20or\x20a\x20space).','--preload-skill','index','backendUrl','answers','total_prompt_tokens','login','Continue\x20it\x20with:\x20delegate-cli\x20--session\x20','activity','No\x20auth\x20found.\x20Set\x20AUTH_TOKEN\x20(or\x20AUTH_TOKEN_FILE)/TENANT_ID/ORG_ID\x20env\x20vars,\x20or\x20run\x20`delegate-cli\x20login\x20--env\x20<alpha|staging|production>`\x20(or\x20`--url\x20<deployment-url>`\x20for\x20Automation\x20Suite)\x20first.','Tenant:\x20','unknown','--session\x20applies\x20to\x20the\x20`delegate-cli\x20usage`\x20summary\x20only.','delegations\x20claim\x20<delegation-id|delegate://delegation/…>','orgLogicalName','4758372fkMBpL','runnerUrl','--to','bundledSkillsPath','\x27\x20cannot\x20be\x20read:\x20','lastType','\x20\x20(input\x20#','date','choice','No\x20CLI\x20login\x20found.\x20Note:\x20the\x20CLI\x20is\x20currently\x20authenticating\x20via\x20the\x20Delegate\x20desktop\x20app\x27s\x20','From\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','assignedUserEmail','the\x20JSON\x20schema','tenantId','message','version','from','model','6CpUWTw','Created\x20delegation\x20','Renamed\x20','byoWarning','a\x20directory\x20path','No\x20CLI\x20login\x20found\x20—\x20nothing\x20to\x20remove.','--no-computer-use','write','pending','--page','.\x20Share:\x20','sourceTitle','\x20days.\x0a','usage','\x20delegation\x20','score\x20','max','--attach:\x20no\x20such\x20file\x20or\x20folder:\x20','medium','sourceUserEmail','Invalid\x20--effort:\x20','close','\x20token\x20units','fork','jsonSchemaPath','No\x20CLI\x20login\x20to\x20switch:\x20the\x20CLI\x20is\x20authenticating\x20via\x20the\x20Delegate\x20desktop\x20app\x27s\x20','stdin','attachments','\x20days:\x20','--attach','a\x20turn\x20id','.\x20Use\x20`delegate-cli\x20usage`,\x20`usage\x20activity`\x20or\x20`usage\x20daily`.','period_end','\x20(no\x20cap\x20enforced)','--worker-id','onEvent','--cartographer','Session\x20','--output-format','daily','\x20\x20\x20\x20BYO\x20warning:\x20','stop','Usage:\x20delegate-cli\x20','list','1\x20or\x20more','off','parse','Delegated\x20','baseUrl','filter','a\x20JSON\x20schema\x20file','More:\x20delegate-cli\x20sessions\x20--page\x20','claim','parentSessionId','cwd','staging','code','response','finish','contextSummary','\x20prompt,\x20','transcribe','cleanup','content','\x20--turn\x20','session_consumed_pu','\x0adelegate-cli\x20—\x20Delegate\x20agent\x20CLI\x0a\x0aUsage:\x0a\x20\x20delegate-cli\x20[flags]\x20[\x22<prompt>\x22]\x20\x20\x20\x20Start\x20a\x20conversation\x20in\x20a\x20terminal\x0a\x20\x20delegate-cli\x20--print\x20\x22<prompt>\x22\x20\x20\x20\x20\x20\x20Send\x20one\x20prompt,\x20print\x20the\x20response,\x20and\x20exit\x0a\x20\x20delegate-cli\x20[flags]\x20-\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Read\x20one\x20prompt\x20from\x20stdin\x20through\x20EOF,\x20then\x20exit\x0a\x20\x20delegate-cli\x20-p\x20\x22<prompt>\x22\x20--output-format\x20json|stream-json\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20One\x20turn\x20with\x20JSON-only\x20stdout;\x20exit\x201\x20on\x20error\x0a\x20\x20delegate-cli\x20--json-schema\x20FILE\x20\x22<prompt>\x22\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20One\x20turn,\x20then\x20its\x20result\x20extracted\x20as\x20JSON\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20matching\x20the\x20schema\x20in\x20FILE\x20(printed\x20after\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20the\x20answer;\x20\x22structured\x22\x20in\x20the\x20JSON\x20result);\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20exit\x201\x20when\x20the\x20extraction\x20fails\x0a\x20\x20delegate-cli\x20--attach\x20PATH\x20[--attach\x20PATH\x20...]\x20\x22<prompt>\x22\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Send\x20files\x20or\x20folders\x20with\x20the\x20first\x20message\x0a\x20\x20delegate-cli\x20login\x20[--env\x20NAME\x20|\x20--url\x20BASE]\x20[--tenant\x20NAME]\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20OAuth\x20browser\x20login\x20→\x20~/.aria/sdk-auth.json.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--env\x20or\x20--url\x20required\x20on\x20FIRST\x20login;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20afterwards\x20defaults\x20to\x20the\x20saved\x20login\x27s\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20deployment.\x20--tenant\x20picks\x20a\x20tenant\x20by\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20name;\x20without\x20it\x20a\x20re-login\x20keeps\x20the\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20saved\x20tenant\x0a\x20\x20delegate-cli\x20tenant\x20[NAME]\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20List\x20the\x20organization\x27s\x20tenants,\x20or\x20switch\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20the\x20saved\x20login\x20to\x20NAME\x20(no\x20browser)\x0a\x20\x20delegate-cli\x20logout\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Remove\x20the\x20saved\x20CLI\x20login\x0a\x20\x20delegate-cli\x20whoami\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Show\x20the\x20current\x20login\x20(org,\x20tenant,\x20token\x20expiry)\x0a\x20\x20delegate-cli\x20models\x20[--env\x20NAME]\x20\x20\x20\x20\x20List\x20available\x20LLM\x20models\x20for\x20the\x20current\x20tenant,\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20with\x20any\x20BYO\x20configuration\x20warning\x20per\x20model\x0a\x20\x20delegate-cli\x20sessions\x20[list]\x20[--page\x20N]\x20[--limit\x20N]\x20[--include-subagents]\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20List\x20your\x20backend\x20chat\x20sessions,\x20most\x20recently\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20active\x20first\x20(resume\x20one\x20with\x20--session\x20ID)\x0a\x20\x20delegate-cli\x20sessions\x20show|delete\x20ID\x20Show\x20one\x20session\x27s\x20title\x20and\x20owner,\x20or\x20delete\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20it\x20with\x20its\x20messages\x20and\x20sub-agents\x20(no\x20prompt)\x0a\x20\x20delegate-cli\x20sessions\x20rename\x20ID\x20TITLE\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Rename\x20a\x20session\x20(1-500\x20characters)\x0a\x20\x20delegate-cli\x20sessions\x20fork\x20ID\x20[MESSAGE]\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Copy\x20session\x20ID\x20into\x20a\x20new\x20session,\x20up\x20to\x20and\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20including\x20message\x20MESSAGE\x20(default:\x20all\x20of\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20it);\x20continue\x20it\x20with\x20--session\x20NEW_ID\x0a\x20\x20delegate-cli\x20sessions\x20cancel\x20ID\x20--turn\x20TURN\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Cancel\x20turn\x20TURN\x20running\x20on\x20session\x20ID\x20in\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20another\x20process;\x20exits\x201\x20when\x20no\x20such\x20turn\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20is\x20in\x20progress\x0a\x20\x20delegate-cli\x20check\x20[--env\x20NAME]\x20[--headless]\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Verify\x20auth,\x20backend\x20readiness,\x20backend\x20and\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20interop\x20without\x20sending\x20a\x20prompt;\x20exits\x201\x20when\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20any\x20check\x20fails\x0a\x20\x20delegate-cli\x20usage\x20[--session\x20ID]\x20\x20\x20\x20Quota\x20and\x20spend:\x20licensing\x20quota,\x20monthly\x20spend\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20and\x20cap,\x20Cartographer\x20allowance\x0a\x20\x20delegate-cli\x20usage\x20activity|daily\x20[--days\x20N]\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Activity\x20totals,\x20or\x20per-day\x20usage,\x20over\x20the\x20last\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20N\x20days\x20(1-365,\x20default\x2030)\x0a\x20\x20delegate-cli\x20evaluate|rerank|verify\x20FILE|-\x20[--model\x20ID]\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Stateless\x20typed\x20judgments:\x20send\x20the\x20JSON\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20request\x20in\x20FILE\x20(or\x20stdin\x20with\x20-)\x20to\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20/v1/completions/<command>\x20and\x20print\x20the\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20answers;\x20--model\x20overrides\x20its\x20\x22model\x22.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Exits\x201\x20when\x20the\x20backend\x20rejects\x20it\x0a\x20\x20delegate-cli\x20complete\x20--json-schema\x20FILE\x20[--model\x20ID]\x20[--session\x20ID]\x20\x22<prompt>\x22|-\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20One\x20structured\x20completion,\x20no\x20agent\x20turn:\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20print\x20the\x20JSON\x20object\x20matching\x20the\x20schema\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20in\x20FILE\x20(--output-format\x20json\x20prints\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{structured,\x20usage});\x20--session\x20adds\x20that\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20session\x27s\x20history\x20as\x20context.\x20Exits\x201\x20when\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20the\x20output\x20fails\x20the\x20schema\x20(422)\x20or\x20the\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20backend\x20rejects\x20the\x20request\x0a\x20\x20delegate-cli\x20transcribe\x20FILE|-\x20\x20\x20\x20\x20\x20\x20Speech-to-text\x20(Whisper):\x20print\x20the\x20text\x20of\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20the\x20audio\x20in\x20FILE,\x20or\x20on\x20stdin\x20with\x20-.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20mp3,\x20mp4,\x20mpeg,\x20mpga,\x20m4a,\x20wav\x20or\x20webm,\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20up\x20to\x2025\x20MiB.\x20Exits\x202\x20when\x20the\x20audio\x20is\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20refused\x20locally,\x201\x20when\x20the\x20backend\x20rejects\x20it\x0a\x20\x20delegate-cli\x20org-users\x20QUERY\x20\x20\x20\x20\x20\x20\x20\x20\x20Search\x20your\x20organization\x27s\x20users\x20by\x20name\x20or\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20email\x20prefix\x20(2-100\x20characters)\x0a\x20\x20delegate-cli\x20delegations\x20create\x20--session\x20ID\x20[--to\x20WHO]\x20[--summary\x20TEXT]\x20\x22<task>\x22|-\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Hand\x20a\x20task\x20from\x20session\x20ID\x20to\x20a\x20colleague\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20(WHO:\x20an\x20email,\x20or\x20a\x20name\x20matching\x20one\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20person);\x20without\x20--to,\x20print\x20a\x20link\x20anyone\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20in\x20the\x20organization\x20can\x20claim\x0a\x20\x20delegate-cli\x20delegations\x20pending\x20SESSION\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Answers\x20to\x20delegations\x20from\x20SESSION\x20that\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20await\x20acceptance\x20(poll\x20this)\x0a\x20\x20delegate-cli\x20delegations\x20accept|dismiss|cancel|delete\x20ID\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Take\x20an\x20answer\x20into\x20its\x20session,\x20drop\x20it,\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20withdraw\x20a\x20live\x20delegation,\x20or\x20delete\x20it\x0a\x20\x20delegate-cli\x20delegations\x20list\x20PROJECT\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Every\x20delegation\x20targeting\x20a\x20backend\x20project\x0a\x20\x20delegate-cli\x20delegations\x20show|claim\x20ID|LINK\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Read\x20a\x20delegation\x20assigned\x20to\x20you\x20(or\x20a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20delegate://delegation/…\x20link),\x20or\x20claim\x20it:\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20prints\x20the\x20session\x20to\x20work\x20it\x20in\x0a\x20\x20delegate-cli\x20delegations\x20complete\x20ID\x20\x22<answer>\x22|-\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Send\x20the\x20answer\x20to\x20a\x20delegation\x20you\x20claimed\x0a\x20\x20delegate-cli\x20host\x20[flags]\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Run\x20this\x20PC\x20as\x20a\x20remote\x20worker\x20until\x20Ctrl+C\x0a\x20\x20delegate-cli\x20host\x20install\x20[flags]\x20\x20\x20\x20Auto-start\x20the\x20host\x20at\x20login\x20(macOS\x20LaunchAgent\x20/\x20Windows\x20Scheduled\x20Task)\x0a\x20\x20delegate-cli\x20host\x20uninstall\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Remove\x20auto-start\x0a\x20\x20delegate-cli\x20host\x20status\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Show\x20auto-start\x20state\x0a\x20\x20delegate-cli\x20--cleanup\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Stop\x20running\x20interop\x0a\x0aFlags:\x0a\x20\x20-p,\x20--print\x20\x20\x20\x20\x20\x20\x20Run\x20one\x20turn\x20and\x20exit,\x20including\x20any\x20tool\x20execution.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Automatic\x20when\x20stdin\x20or\x20stdout\x20is\x20not\x20a\x20terminal,\x20or\x20with\x20-\x0a\x20\x20--env\x20NAME\x20\x20\x20\x20\x20\x20\x20\x20alpha\x20|\x20staging\x20|\x20production\x20|\x20localhost\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Composes\x20backend\x20URL\x20from\x20saved\x20auth\x20(org/tenant\x20slugs).\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Omitted\x20→\x20the\x20deployment\x20you\x20logged\x20into\x20(delegate-cli\x20login).\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20localhost\x20→\x20http://localhost:5002.\x20No\x20saved\x20login\x20and\x20no\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--env/--backend/BACKEND_URL\x20is\x20an\x20error\x20—\x20never\x20a\x20guess.\x0a\x20\x20--url\x20BASE\x20\x20\x20\x20\x20\x20\x20\x20(login)\x20Base\x20URL\x20of\x20a\x20deployment\x20that\x20is\x20not\x20a\x20named\x20cloud\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20—\x20Automation\x20Suite,\x20Dedicated,\x20Public\x20Sector.\x20Accepts\x20a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20tenant\x20path\x20or\x20a\x20trailing\x20/identity_\x20and\x20reduces\x20it\x20to\x20the\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20origin.\x20Mutually\x20exclusive\x20with\x20--env;\x20also\x20settable\x20via\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20UIPATH_BASE_URL.\x20Alias:\x20--authority.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Automation\x20Suite\x20needs\x2026.10+\x20with\x20the\x20Delegate\x20service;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20if\x20the\x20deployment\x20rejects\x20the\x20built-in\x20client,\x20register\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20your\x20own\x20—\x20see\x20UIPATH_CLIENT_ID\x20in\x20the\x20README\x0a\x20\x20--skip-env-check\x20\x20(login)\x20Do\x20not\x20check\x20the\x20deployment\x20before\x20signing\x20in.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Escape\x20hatch\x20for\x20a\x20deployment\x20that\x20hides\x20its\x20OIDC\x20discovery\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20document\x20or\x20serves\x20Identity\x20from\x20another\x20origin;\x20it\x20also\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20gives\x20up\x20the\x20diagnosis\x20when\x20something\x20is\x20really\x20wrong\x0a\x20\x20--backend\x20URL\x20\x20\x20\x20\x20Full\x20backend\x20URL\x20—\x20escape\x20hatch\x20overrides\x20--env\x0a\x20\x20--tenant\x20NAME\x20\x20\x20\x20\x20(login)\x20Tenant\x20to\x20sign\x20into,\x20by\x20name\x20(case-insensitive).\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Default:\x20the\x20saved\x20login\x27s\x20tenant\x20on\x20that\x20cloud,\x20else\x20the\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20org\x27s\x20first\x20tenant.\x20Later:\x20delegate-cli\x20tenant\x20<name>\x0a\x20\x20--model\x20NAME\x20\x20\x20\x20\x20\x20LLM\x20model\x20id\x20(e.g.\x20claude_sonnet_5,\x20kimi_k3).\x20Checked\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20against\x20the\x20tenant\x27s\x20catalog\x20(delegate-cli\x20models)\x20before\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20the\x20run\x20starts;\x20an\x20unknown\x20id\x20fails\x20and\x20lists\x20the\x20valid\x20ones.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Default:\x20gpt_5_6_luna.\x20Also\x20settable\x20via\x20MODEL\x20env\x20var.\x0a\x20\x20--keep-alive\x20\x20\x20\x20\x20\x20Reuse/leave\x20interop\x20running\x20across\x20invocations\x0a\x20\x20--headless\x20\x20\x20\x20\x20\x20\x20\x20Skip\x20interop\x20(text-only\x20prompts)\x0a\x20\x20--no-computer-use\x20Keep\x20interop\x20—\x20file,\x20Office,\x20PDF\x20and\x20shell\x20tools\x20keep\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20working\x20—\x20but\x20drop\x20the\x20screen:\x20no\x20screenshots,\x20no\x20window\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20list,\x20no\x20UI-automation\x20tools.\x20Cuts\x20image\x20tokens\x20and\x20the\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20per-turn\x20screen\x20capture,\x20and\x20stops\x20desktop\x20window\x20titles\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20leaving\x20the\x20machine.\x20Use\x20for\x20document\x20and\x20file\x20work.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--headless\x20implies\x20this\x20and\x20turns\x20interop\x20off\x20as\x20well\x0a\x20\x20--no-connections\x20\x20Disable\x20orchestrator\x20ConnectionService\x20(silences\x20404\x20warnings)\x0a\x20\x20--no-security\x20\x20\x20\x20\x20Disable\x20tool\x20security\x20wrapper\x20(use\x20only\x20for\x20debugging)\x0a\x20\x20--no-memory\x20\x20\x20\x20\x20\x20\x20Do\x20not\x20send\x20the\x20Delegate\x20app\x27s\x20local\x20long-term\x20memories\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20with\x20each\x20turn,\x20and\x20do\x20not\x20ask\x20the\x20model\x20to\x20save\x20new\x20ones\x0a\x20\x20--attach\x20PATH\x20\x20\x20\x20\x20File\x20or\x20folder\x20sent\x20with\x20the\x20first\x20message\x20(repeatable),\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20as\x20the\x20Delegate\x20app\x20sends\x20attached\x20files:\x20images\x20inline,\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20PDFs\x20and\x20other\x20documents\x20as\x20a\x20path\x20the\x20agent\x20reads,\x20text\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20inline\x20up\x20to\x2016,000\x20characters.\x2030\x20MiB\x20per\x20message\x20in\x20all;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20larger\x20files\x20go\x20as\x20a\x20path.\x20In\x20a\x20conversation,\x20later\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20messages\x20carry\x20none\x20of\x20their\x20own,\x20but\x20the\x20first\x20message\x27s\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20stay\x20in\x20context\x0a\x20\x20--preload-skill\x20NAME\x20\x20Preload\x20a\x20skill\x20into\x20the\x20session\x20(repeatable).\x20The\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20skill\x27s\x20content\x20is\x20attached\x20before\x20the\x20first\x20model\x20turn\x20—\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20same\x20mechanism\x20as\x20project\x20preloaded\x20skills\x20in\x20the\x20app\x0a\x20\x20--cartographer\x20\x20\x20\x20Cartographer\x20engagement\x20preset.\x20Equivalent\x20to\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--no-computer-use\x20--preload-skill\x20business-analysis\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--preload-skill\x20project-task-list\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--preload-skill\x20knowledge-base.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Add\x20--project/--working-dir\x20for\x20where\x20the\x20files\x20live,\x20and\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20extra\x20--preload-skill\x20flags\x20for\x20more\x20skills\x20—\x20a\x20skill\x20the\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20preset\x20already\x20covers\x20is\x20not\x20preloaded\x20twice.\x20An\x20explicit\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--headless\x20still\x20wins\x20and\x20turns\x20interop\x20off\x0a\x20\x20--project\x20ID\x20\x20\x20\x20\x20\x20Route\x20the\x20session\x27s\x20local\x20wiki\x20and\x20plans\x20to\x20a\x20project\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20(<working-dir>/projects/<ID>/wiki).\x20Client-side\x20key\x20only\x0a\x20\x20--working-dir\x20PATH\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Shell\x20cwd\x20for\x20the\x20agent\x20and\x20root\x20for\x20SDK-local\x20state.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Relative\x20paths\x20resolve\x20against\x20the\x20current\x20directory;\x20the\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20directory\x20is\x20created\x20if\x20missing\x0a\x20\x20--skills-path\x20PATH\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Extra\x20bundled-skills\x20directory\x20(merged\x20with\x20the\x20installed\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20app\x27s\x20skills\x20and\x20DELEGATE_BUNDLED_SKILLS_PATH)\x0a\x20\x20--effort\x20TIER\x20\x20\x20\x20\x20Reasoning\x20effort:\x20low\x20|\x20medium\x20|\x20high\x20|\x20xhigh\x20|\x20max.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Default:\x20the\x20model\x27s\x20recommended\x20tier\x0a\x20\x20--session\x20ID\x20\x20\x20\x20\x20\x20Continue\x20an\x20existing\x20backend\x20session\x20(an\x20unknown\x20id\x20exits\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x201;\x20the\x20backend\x20assigns\x20new\x20ids).\x20For\x20complete:\x20the\x20session\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20whose\x20history\x20is\x20the\x20context\x0a\x20\x20--json-schema\x20FILE\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20JSON\x20schema\x20the\x20structured\x20answer\x20must\x20match\x20(complete,\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20and\x20prompts:\x20implies\x20--print)\x0a\x20\x20--runner-url\x20URL\x20\x20(host)\x20Runner\x20worker\x20WS\x20URL.\x20Required;\x20or\x20CONTROL_PLANE_WS_URL\x20env\x0a\x20\x20--interop\x20PATH\x20\x20\x20\x20(host)\x20Interop\x20binary\x20path;\x20or\x20INTEROP_EXECUTABLE_PATH\x20env.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Absent\x20→\x20registration/discovery\x20only,\x20tool\x20execution\x20disabled\x0a\x20\x20--worker-id\x20ID\x20\x20\x20\x20(host)\x20Stable\x20worker\x20identity;\x20or\x20WORKER_ID\x20env.\x20Default:\x20hostname\x0a\x20\x20--page\x20N\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20(sessions)\x20Page\x20to\x20show,\x20from\x201.\x20Default:\x201\x0a\x20\x20--limit\x20N\x20\x20\x20\x20\x20\x20\x20\x20\x20(sessions)\x20Rows\x20per\x20page,\x201-100.\x20Default:\x2030\x0a\x20\x20--include-subagents\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20(sessions)\x20Also\x20list\x20sub-agent\x20sessions,\x20hidden\x20by\x20default\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20as\x20in\x20the\x20desktop\x20app\x27s\x20history\x0a\x20\x20--to\x20WHO\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20(delegations\x20create)\x20Assign\x20to\x20this\x20person:\x20an\x20email,\x20or\x20a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20name\x20that\x20matches\x20exactly\x20one\x20colleague\x20(see\x20org-users)\x0a\x20\x20--summary\x20TEXT\x20\x20\x20\x20(delegations\x20create)\x20The\x20briefing\x20the\x20person\x20starts\x20from.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Default:\x20empty,\x20for\x20a\x20task\x20that\x20stands\x20on\x20its\x20own\x0a\x20\x20--output-format\x20FMT\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20text\x20(default)\x20|\x20json\x20|\x20stream-json.\x20json\x20prints\x20one\x20result\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20object\x20on\x20exit;\x20stream-json\x20prints\x20every\x20agent\x20event\x20as\x20one\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20JSON\x20line,\x20then\x20the\x20result.\x20Both\x20keep\x20stdout\x20JSON-only\x20(logs,\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20progress\x20and\x20the\x20session\x20id\x20go\x20to\x20stderr),\x20imply\x20--print,\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20and\x20exit\x201\x20when\x20the\x20turn\x20ends\x20in\x20error.\x20Also\x20honoured\x20by\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20every\x20subcommand\x20that\x20prints\x20a\x20result\x20(all\x20but\x20login,\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20logout,\x20tenant\x20and\x20host)\x0a\x20\x20-q,\x20--quiet\x20\x20\x20\x20\x20\x20\x20Suppress\x20🤔\x20thinking\x20output\x20to\x20stderr\x0a\x20\x20--verbose\x20\x20\x20\x20\x20\x20\x20\x20\x20Surface\x20the\x20SDK\x27s\x20and\x20the\x20framework\x27s\x20own\x20logs.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Diagnostics\x20only,\x20on\x20stdout;\x20independent\x20of\x20-q\x0a\x20\x20-h,\x20--help\x20\x20\x20\x20\x20\x20\x20\x20Show\x20this\x20help\x0a\x20\x20-v,\x20--version\x20\x20\x20\x20\x20Print\x20the\x20installed\x20CLI\x20version\x0a\x0aConversation:\x20Enter\x20sends\x20a\x20message;\x20/exit\x20or\x20EOF\x20exits;\x20Ctrl+C\x20stops\x20and\x20exits.\x0a\x20\x20Ctrl+C\x20during\x20a\x20turn\x20cancels\x20it\x20on\x20the\x20backend\x20too;\x20a\x20second\x20Ctrl+C\x20force-exits.\x0a\x20\x20An\x20optional\x20initial\x20prompt\x20is\x20followed\x20by\x20more\x20input.\x20The\x20session\x20ID\x20is\x20printed\x0a\x20\x20to\x20stderr;\x20resume\x20later\x20with\x20--session\x20ID.\x20Redirected\x20input\x20is\x20one\x20prompt.\x0aAuth:\x20prompts\x20auto-retry\x20on\x20401\x20by\x20opening\x20the\x20browser\x20to\x20re-login\x20(TTY\x20only),\x0a\x20\x20preserving\x20the\x20active\x20session.\x0a','test','join','Turn:\x20','delegateTo','Invalid\x20--output-format:\x20','workingDirectory','Unknown\x20delegations\x20action:\x20','tool','logout','\x20—\x20sign\x20out\x20in\x20the\x20Delegate\x20app\x20to\x20clear\x20that.','\x20is\x20not\x20valid\x20JSON\x20(','--to,\x20--summary\x20and\x20--session\x20apply\x20to\x20`delegate-cli\x20delegations\x20create`\x20only.','projectId','slice','--json-schema','turn_start','create','\x20<id>','ASSIGNEE',',\x20or\x20holds\x20no\x20message\x20','estimated_cost_usd','\x20(resume\x20with\x20--session\x20','isError','\x20<title>','delegations','noMemory','sessionId','structured','Removed\x20','\x20PU','restore','padStart','\x20of\x20a\x20$','session_start','--skills-path','cancelled','turnId','noSecurity','deployment','>.\x0a','complete','probability\x20','effort','keys','SIGINT','The\x20saved\x20CLI\x20login\x20could\x20not\x20be\x20refreshed.\x20Run\x20`delegate-cli\x20login`\x20again.','\x0aAccept\x20one\x20with:\x20delegate-cli\x20delegations\x20accept\x20<id>\x0a','Tenant\x20not\x20switched:\x20could\x20not\x20write\x20','Already\x20answered','\x20(confidence\x20','--days\x20applies\x20to\x20`delegate-cli\x20usage\x20activity|daily`;\x20the\x20summary\x20covers\x20the\x20current\x20month.','Usage:\x20delegate-cli\x20sessions\x20','Source:\x20\x20\x20\x20\x20\x20\x20','--turn\x20applies\x20to\x20`delegate-cli\x20sessions\x20cancel`\x20only.','.\x20Use:\x20','delegationId','trim','Usage:\x20delegate-cli\x20sessions\x20fork\x20<id>\x20[<message-id>]','length','round','Session\x20\x20\x20\x20\x20\x20\x20','days','headless',':\x20cannot\x20read\x20the\x20JSON\x20schema\x20(','accessToken','forEach'];_0x394f=function(){return _0x3ec9b5;};return _0x394f();}var S=_0x4ef645=>{const _0x21f2f6=_0x4b2408;process[_0x21f2f6(0x149)][_0x21f2f6(0x187)](_0x4ef645);};function gt(){const _0x18e8a3=_0x4b2408;let _0x107598=process['stdout'][_0x18e8a3(0x187)],_0xc5352c=_0x107598['bind'](process[_0x18e8a3(0x149)]),_0x518b65=S;return S=_0x34e4eb=>{_0xc5352c(_0x34e4eb);},process['stdout']['write']=(..._0x6e6a45)=>process[_0x18e8a3(0xb4)][_0x18e8a3(0x187)](..._0x6e6a45),()=>{const _0x2495da=_0x18e8a3;process[_0x2495da(0x149)][_0x2495da(0x187)]=_0x107598,S=_0x518b65;};}function l(_0x8146b1,_0x2aea96,_0x2d9e9c){const _0x40e59e=_0x4b2408;if(_0x8146b1[_0x40e59e(0x263)]===_0x40e59e(0xd6)){_0x2d9e9c(_0x2aea96);return;}S(_0x354c62(_0x2aea96));}function ht(){const _0x639cbf=_0x4b2408;let _0x32bd7e=_0x639cbf(0x1c2)[_0x639cbf(0x1fb)]();console['log'](_0x32bd7e);}function wt(){const _0x1d9833=_0x4b2408;try{return JSON[_0x1d9833(0x1ae)](_0x327d7['readFileSync'](_0x53e3ce[_0x1d9833(0x1c4)](__dirname,'..','package.json'),'utf-8'))['version']||_0x1d9833(0x16a);}catch{return _0x1d9833(0x16a);}}var yt=0x7d0;async function K(_0x572ee6,_0x4cfbaf){const _0xc9577c=_0x4b2408;let _0x59df88=_0x4cfbaf?[_0x4cfbaf]:[];for await(let _0x3452e3 of _0x572ee6)_0x59df88[_0xc9577c(0x15e)](Buffer[_0xc9577c(0x17e)](_0x3452e3));return Buffer['concat'](_0x59df88)['toString']('utf-8')[_0xc9577c(0x1fb)]();}function kt(_0x2faa46,_0x20ec0b){return new Promise(_0x263e82=>{const _0x2040d9=_0x4e66;let _0x303d06=_0x1dcaf9=>{const _0x596042=_0x4e66;clearTimeout(_0x1ca863),_0x2faa46[_0x596042(0x1ad)](_0x596042(0x12f),_0x574bc9),_0x2faa46['off']('end',_0x28014f),_0x2faa46[_0x596042(0x1ad)](_0x596042(0x236),_0x28014f),_0x2faa46[_0x596042(0xc4)](),_0x263e82(_0x1dcaf9);},_0x574bc9=_0x3f1db4=>_0x303d06(Buffer['from'](_0x3f1db4)),_0x28014f=()=>_0x303d06(null),_0x1ca863=setTimeout(()=>_0x303d06(null),_0x20ec0b);_0x2faa46['on'](_0x2040d9(0x12f),_0x574bc9),_0x2faa46['on'](_0x2040d9(0x25c),_0x28014f),_0x2faa46['on'](_0x2040d9(0x236),_0x28014f),_0x2faa46[_0x2040d9(0x233)]();});}async function I(_0x57750f,_0x52649b,_0x393a81=yt){let _0x4b04b4=_0x57750f==='-';if(!_0x4b04b4&&_0x57750f)return _0x57750f;if(!_0x4b04b4&&_0x52649b['isTTY'])return'';if(_0x4b04b4)return K(_0x52649b,null);let _0x471afc=await kt(_0x52649b,_0x393a81);return _0x471afc?K(_0x52649b,_0x471afc):'';}function L(){const _0x1e8f90=_0x4b2408;return _0x53e3ce[_0x1e8f90(0x1c4)](process.env.HOME||process.env.USERPROFILE||'',_0x1e8f90(0x20e),'auth.json');}function $(_0xd1e403){const _0x5a2b1f=_0x4b2408;try{let _0x161f00=JSON[_0x5a2b1f(0x1ae)](_0x327d7[_0x5a2b1f(0x22b)](_0xd1e403,_0x5a2b1f(0x109)));return!_0x161f00[_0x5a2b1f(0x203)]||!_0x161f00[_0x5a2b1f(0x17b)]||!_0x161f00[_0x5a2b1f(0x131)]?null:_0x161f00;}catch{return null;}}function St(){let _0x2435dc=[{'file':_0x20e75f(),'isDesktopFallback':!0x1},{'file':L(),'isDesktopFallback':!0x0}];for(let _0x7039a2 of _0x2435dc){let _0x58a657=$(_0x7039a2['file']);if(_0x58a657)return{..._0x7039a2,'auth':_0x58a657};}return null;}async function bt(){const _0x34bc48=_0x4b2408;let _0x146311=_0x20e75f();if(!_0x327d7[_0x34bc48(0x120)](_0x146311)){let _0x4ba4a1=L();console[_0x34bc48(0xf8)]($(_0x4ba4a1)?_0x34bc48(0x177)+_0x4ba4a1+_0x34bc48(0x1cc):_0x34bc48(0x185));return;}_0x327d7[_0x34bc48(0x265)](_0x146311),console['log'](_0x34bc48(0x1df)+_0x146311);}async function vt(_0x3df867){const _0x36b140=_0x4b2408;let _0x2b0efc=O(),_0xe16329,_0x811454;if(_0x2b0efc)_0xe16329=_0x2b0efc,_0x811454=_0x36b140(0x12a);else{let _0x212e93=St();if(!_0x212e93)throw new Error(le);_0xe16329=_0x212e93['auth'],_0x811454=_0x212e93[_0x36b140(0x129)]?_0x212e93['file']+_0x36b140(0x23d):_0x212e93['file'];}let _0xf05e5={'source':_0x811454,'baseUrl':_0xe16329[_0x36b140(0x1b0)]??null,'deployment':Et(_0xe16329[_0x36b140(0x1b0)]),'organization':{'id':_0xe16329[_0x36b140(0x131)],'slug':_0xe16329[_0x36b140(0x16d)]??null},'tenant':{'id':_0xe16329[_0x36b140(0x17b)],'name':_0xe16329['tenantName']??null},'tokenExpiresAt':_0xe16329['expiresAt']?new Date(_0xe16329[_0x36b140(0x14c)]*0x3e8)[_0x36b140(0x128)]():null};l(_0x3df867,_0xf05e5,()=>{const _0x44cbdf=_0x36b140;let _0x4fdd8b=[_0x44cbdf(0x1f7)+_0x811454,'Base\x20URL:\x20\x20\x20\x20\x20'+(_0xe16329[_0x44cbdf(0x1b0)]??_0x44cbdf(0x16a)),_0x44cbdf(0xf0)+_0xf05e5[_0x44cbdf(0x1e9)],_0x44cbdf(0xb6)+(_0xe16329[_0x44cbdf(0x16d)]??'unknown\x20slug')+'\x20('+_0xe16329['organizationId']+')',_0x44cbdf(0xef)+(_0xe16329[_0x44cbdf(0xfa)]??_0x44cbdf(0x152))+'\x20('+_0xe16329[_0x44cbdf(0x17b)]+')'];if(_0xe16329[_0x44cbdf(0x14c)]){let _0x305108=_0xe16329[_0x44cbdf(0x14c)]-Math[_0x44cbdf(0x10f)](Date[_0x44cbdf(0xf9)]()/0x3e8);_0x4fdd8b[_0x44cbdf(0x15e)](_0x305108>0x0?_0x44cbdf(0x14d)+_0xf05e5[_0x44cbdf(0xcd)]+_0x44cbdf(0x22e)+Math[_0x44cbdf(0x1fe)](_0x305108/0x3c)+'\x20min)':_0x44cbdf(0x241)+_0xf05e5['tokenExpiresAt']);}process[_0x44cbdf(0x149)][_0x44cbdf(0x187)](_0x4fdd8b[_0x44cbdf(0x1c4)]('\x0a')+'\x0a');});}var le=_0x4b2408(0x168);function Et(_0x32ac79){const _0x48e193=_0x4b2408;return _0x32ac79?_0x3cad23(_0x32ac79)?_0x48e193(0x24d):'self-hosted\x20(Automation\x20Suite\x20/\x20Dedicated)':_0x48e193(0x16a);}function O(){let _0x2a25d5=process.env.AUTH_TOKEN_FILE;return(process.env.AUTH_TOKEN||_0x2a25d5)&&process.env.TENANT_ID&&process.env.ORG_ID?{'accessToken':_0x2a25d5?At(_0x2a25d5):process.env.AUTH_TOKEN,..._0x2a25d5?{'accessTokenFile':_0x2a25d5}:{},'tenantId':process.env.TENANT_ID,'organizationId':process.env.ORG_ID,'orgLogicalName':process.env.ORG_SLUG,'tenantName':process.env.TENANT_SLUG,'baseUrl':ce()}:null;}function At(_0x15243d){const _0xddead4=_0x4b2408;let _0x4586ef;try{_0x4586ef=_0x327d7[_0xddead4(0x22b)](_0x15243d,'utf-8')[_0xddead4(0x1fb)]();}catch(_0x2f6292){throw new Error(_0xddead4(0xe7)+_0x15243d+_0xddead4(0x172)+_0x2f6292['message']);}let _0x3164de=_0x4586ef[_0xddead4(0x260)](_0xddead4(0x266))?_0x4586ef['slice'](0x7)[_0xddead4(0x1fb)]():_0x4586ef;if(!_0x3164de)throw new Error('AUTH_TOKEN_FILE\x20\x27'+_0x15243d+'\x27\x20is\x20empty.');return _0x3164de;}function ce(){const _0x1523c1=_0x4b2408;let _0xba048d=process.env.UIPATH_BASE_URL;if(!_0xba048d)return;let _0xfecc9c=_0xd8ee01(_0xba048d);if(_0xfecc9c['ok']===!0x1)throw new Error(_0x1523c1(0xb7)+_0x55a80a(_0xba048d,_0xfecc9c[_0x1523c1(0xfc)]));return _0xfecc9c['baseUrl'];}async function P(){let _0x419c0b=O();if(_0x419c0b)return _0x419c0b;let _0x222213=await _0x29b8ac();if(_0x222213)return _0x222213;throw new Error(le);}async function It(){const _0x17d421=_0x4b2408;await new _0x5887e6()[_0x17d421(0x1a9)]({'force':!0x0}),console[_0x17d421(0xf8)](_0x17d421(0x155));}function F(_0xdd2eeb,_0x12354a,_0x2f4772){const _0x3d78ef=_0x4b2408;_0xdd2eeb?process[_0x3d78ef(0xb4)]['write'](_0x3d78ef(0x217)+_0xdd2eeb+_0x3d78ef(0x100)+_0x2f4772+'\x0a'):!_0x12354a&&!process.env.BACKEND_URL&&process[_0x3d78ef(0xb4)]['write'](_0x3d78ef(0xf4)+_0x2f4772+'\x0a');}async function f(_0x9447a1){const _0x2cc059=_0x4b2408;let _0x397c5e=await P(),_0x2012e6=_0xb77cfd(_0x9447a1['env'],_0x397c5e,_0x9447a1[_0x2cc059(0x162)]);return F(_0x9447a1['env'],_0x9447a1[_0x2cc059(0x162)],_0x2012e6),{'auth':_0x397c5e,'backendUrl':_0x2012e6,'client':_0x305dd9({'auth':_0x397c5e,'backendUrl':_0x2012e6})};}async function $t(_0x5df82e){const _0x5d9b6a=_0x4b2408;let {client:_0x33978a}=await f(_0x5df82e),[_0x341c11,_0x1e826c]=await Promise['all']([_0x11f95f(_0x33978a),_0x21a610(_0x33978a)[_0x5d9b6a(0x24f)](_0x3fd937=>(process[_0x5d9b6a(0xb4)]['write']('Could\x20not\x20check\x20BYO\x20model\x20warnings:\x20'+(_0x3fd937 instanceof Error?_0x3fd937[_0x5d9b6a(0x17c)]:String(_0x3fd937))+'\x0a'),{}))]),_0x680857=_0x341c11[_0x5d9b6a(0x228)](_0x4b478e=>_0x1e826c[_0x4b478e['id']]?{..._0x4b478e,'byoWarning':_0x1e826c[_0x4b478e['id']]}:_0x4b478e);l(_0x5df82e,_0x680857,Tt);}function Tt(_0x1e4942){const _0x440d2f=_0x4b2408;if(_0x1e4942['length']===0x0){process[_0x440d2f(0xb4)][_0x440d2f(0x187)](_0x440d2f(0x21c));return;}process[_0x440d2f(0x149)][_0x440d2f(0x187)]('\x0aAvailable\x20models\x20('+_0x1e4942[_0x440d2f(0x1fd)]+'):\x0a\x0a');for(let _0x4505b7 of _0x1e4942){let _0x183e6b=_0x4505b7[_0x440d2f(0x140)]&&_0x4505b7['name']!==_0x4505b7['id']?'\x20('+_0x4505b7[_0x440d2f(0x140)]+')':'';process[_0x440d2f(0x149)][_0x440d2f(0x187)]('\x20\x20'+_0x4505b7['id']+_0x183e6b+'\x0a'),_0x4505b7[_0x440d2f(0xbf)]&&process[_0x440d2f(0x149)][_0x440d2f(0x187)](_0x440d2f(0x25f)+_0x4505b7[_0x440d2f(0xbf)]+'\x0a'),_0x4505b7['locked']&&process['stdout'][_0x440d2f(0x187)](_0x440d2f(0x10c)+(_0x4505b7[_0x440d2f(0x153)]?'\x20('+_0x4505b7[_0x440d2f(0x153)]+')':'')+'\x0a'),_0x4505b7[_0x440d2f(0x183)]&&process[_0x440d2f(0x149)][_0x440d2f(0x187)](_0x440d2f(0x1a8)+_0x4505b7['byoWarning']+'\x0a');}process[_0x440d2f(0x149)][_0x440d2f(0x187)](_0x440d2f(0xdf));}var z=['list',_0x4b2408(0xe5),_0x4b2408(0x255),_0x4b2408(0x25e),'cancel',_0x4b2408(0x197)];async function xt(_0x34fd1d){const _0x4a3ae6=_0x4b2408;let [_0x28c245='',_0x5edf5f='',..._0x34d761]=_0x34fd1d[_0x4a3ae6(0xd0)];if(_0x28c245&&!z[_0x4a3ae6(0x13a)](_0x28c245)&&(console['error'](_0x4a3ae6(0x249)+_0x28c245+_0x4a3ae6(0x1f9)+z[_0x4a3ae6(0x1c4)]('\x20|\x20')+'.'),process[_0x4a3ae6(0x111)](0x2)),_0x34fd1d[_0x4a3ae6(0x1e7)]!==void 0x0&&_0x28c245!==_0x4a3ae6(0x124)&&(console['error'](_0x4a3ae6(0x1f8)),process['exit'](0x2)),_0x28c245&&_0x28c245!==_0x4a3ae6(0x1ab)){await Dt(_0x34fd1d,_0x28c245,_0x5edf5f,_0x34d761['join']('\x20')['trim']());return;}_0x34fd1d[_0x4a3ae6(0xd0)][_0x4a3ae6(0x1fd)]>0x1&&(console[_0x4a3ae6(0x236)]('Usage:\x20delegate-cli\x20sessions\x20[list]\x20[--page\x20N]\x20[--limit\x20N]\x20[--include-subagents]'),process[_0x4a3ae6(0x111)](0x2));let {client:_0x7fa7f7}=await f(_0x34fd1d),_0x5787d7=await _0x32f689(_0x7fa7f7,{'page':_0x34fd1d[_0x4a3ae6(0x219)],'pageSize':_0x34fd1d['limit'],'includeSubAgents':_0x34fd1d[_0x4a3ae6(0xe4)]});l(_0x34fd1d,_0x5787d7,Ct);}async function Dt(_0x355e18,_0x410ace,_0x47cca3,_0x1c93cc){const _0x459401=_0x4b2408;if((_0x355e18[_0x459401(0x219)]!==void 0x0||_0x355e18[_0x459401(0x11f)]!==void 0x0||_0x355e18[_0x459401(0xe4)])&&(console['error'](_0x459401(0x20f)),process['exit'](0x2)),_0x410ace===_0x459401(0x124)){await Ut(_0x355e18,_0x47cca3,_0x1c93cc);return;}if(_0x410ace===_0x459401(0x197)){await Nt(_0x355e18,_0x47cca3,_0x1c93cc);return;}(!_0x47cca3||_0x410ace===_0x459401(0x255)!=!!_0x1c93cc)&&(console['error'](_0x459401(0x1f6)+_0x410ace+_0x459401(0x1d4)+(_0x410ace==='rename'?_0x459401(0x1da):'')),process['exit'](0x2));let {client:_0x37fb5c}=await f(_0x355e18);try{if(_0x410ace===_0x459401(0xe5)){let _0x3d375a=await _0x279aac(_0x37fb5c,_0x47cca3);_0x3d375a||V(_0x47cca3),l(_0x355e18,_0x3d375a,_t);}else{if(_0x410ace===_0x459401(0x255)){let _0xbdce76=await _0x845060(_0x37fb5c,_0x47cca3,_0x1c93cc);l(_0x355e18,_0xbdce76,_0x5c3aa8=>{const _0x1740a6=_0x459401;process[_0x1740a6(0x149)][_0x1740a6(0x187)](_0x1740a6(0x182)+_0x5c3aa8['id']+':\x20'+_0x5c3aa8['title']+'\x0a');});}else await _0x49b938(_0x37fb5c,_0x47cca3),l(_0x355e18,{'id':_0x47cca3,'deleted':!0x0},_0x1fd756=>{const _0x26a53b=_0x459401;process[_0x26a53b(0x149)][_0x26a53b(0x187)](_0x26a53b(0x25d)+_0x1fd756['id']+'.\x0a');});}}catch(_0xe5ed90){if(!_0x42e5b9(_0xe5ed90,0x194))throw _0xe5ed90;V(_0x47cca3);}}function V(_0x42f1dc){const _0x4a1d41=_0x4b2408;console[_0x4a1d41(0x236)](_0x4a1d41(0x1a5)+_0x42f1dc+_0x4a1d41(0x243)),process[_0x4a1d41(0x111)](0x1);}function _t(_0x2c34de){const _0x3e21a6=_0x4b2408;process['stdout']['write']('ID\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+_0x2c34de['id']+'\x0a'),process[_0x3e21a6(0x149)]['write'](_0x3e21a6(0x133)+_0x2c34de[_0x3e21a6(0x13d)]+'\x0a'),process['stdout'][_0x3e21a6(0x187)](_0x3e21a6(0x253)+_0x2c34de[_0x3e21a6(0xc8)]+'\x0a'),process[_0x3e21a6(0x149)]['write'](_0x3e21a6(0xcc)+_0x2c34de['organizationId']+'\x0a'),_0x2c34de[_0x3e21a6(0x1fa)]&&process[_0x3e21a6(0x149)]['write'](_0x3e21a6(0x254)+_0x2c34de[_0x3e21a6(0x1fa)]+'\x0a');}async function Ut(_0x1aca5d,_0xec2f8e,_0x12be58){const _0x450184=_0x4b2408;(!_0xec2f8e||_0x12be58||!_0x1aca5d[_0x450184(0x1e7)])&&(console['error']('Usage:\x20delegate-cli\x20sessions\x20cancel\x20<session-id>\x20--turn\x20<turn-id>'),process['exit'](0x2));let {client:_0x2da493}=await f(_0x1aca5d),_0x54186b=await _0x373a21(_0x2da493,_0xec2f8e,_0x1aca5d[_0x450184(0x1e7)]);l(_0x1aca5d,{'sessionId':_0xec2f8e,'turnId':_0x1aca5d[_0x450184(0x1e7)],'cancelled':_0x54186b},_0x411024=>{const _0x468392=_0x450184;_0x411024[_0x468392(0x1e6)]?process[_0x468392(0x149)]['write'](_0x468392(0x11e)+_0x411024[_0x468392(0x1e7)]+_0x468392(0xdc)+_0x411024['sessionId']+'.\x0a'):process[_0x468392(0xb4)][_0x468392(0x187)]('No\x20turn\x20'+_0x411024['turnId']+_0x468392(0xde)+_0x411024[_0x468392(0x1dd)]+'.\x0a');}),_0x54186b||(process[_0x450184(0x252)]=0x1);}async function Nt(_0x2a8c0b,_0x17745c,_0x379aa1){const _0x2b4e31=_0x4b2408;(!_0x17745c||/\s/[_0x2b4e31(0x1c3)](_0x379aa1))&&(console['error'](_0x2b4e31(0x1fc)),process[_0x2b4e31(0x111)](0x2));let {client:_0x3b64e3}=await f(_0x2a8c0b),_0x48aa04;try{_0x48aa04=await _0x5042fd(_0x3b64e3,_0x17745c,{'atMessageId':_0x379aa1||void 0x0});}catch(_0x34e0af){if(!_0x42e5b9(_0x34e0af,0x194))throw _0x34e0af;console[_0x2b4e31(0x236)](_0x2b4e31(0x1a5)+_0x17745c+_0x2b4e31(0x216)+(_0x379aa1?_0x2b4e31(0x1d6)+_0x379aa1:'')+'.'),process['exit'](0x1);}l(_0x2a8c0b,_0x48aa04,_0x2af3f5=>{const _0x3b9bb1=_0x2b4e31;process[_0x3b9bb1(0x149)][_0x3b9bb1(0x187)](_0x3b9bb1(0x250)+_0x17745c+_0x3b9bb1(0x264)+_0x2af3f5['id']+'.\x0a'),process[_0x3b9bb1(0xb4)][_0x3b9bb1(0x187)](_0x3b9bb1(0x166)+_0x2af3f5['id']+_0x3b9bb1(0x221));});}function Ct({sessions:_0x1866ea,page:_0x48a1ea,isLastPage:_0x583be1}){const _0x59241b=_0x4b2408;if(_0x1866ea[_0x59241b(0x1fd)]===0x0)process[_0x59241b(0xb4)][_0x59241b(0x187)](_0x59241b(0x222)+_0x48a1ea+'.\x0a');else{process[_0x59241b(0x149)]['write']('ID'['padEnd'](0x24)+'\x20\x20'+_0x59241b(0x106)['padEnd'](0x13)+'\x20\x20TITLE\x0a');for(let _0xf41ce8 of _0x1866ea){let _0xeac691=_0xf41ce8[_0x59241b(0x13f)][_0x59241b(0x20c)]('T','\x20')[_0x59241b(0x1d0)](0x0,0x13),_0x657db2=_0xf41ce8[_0x59241b(0x1b5)]?_0x59241b(0x211)+_0xf41ce8[_0x59241b(0x1b5)]+')':'';process['stdout']['write'](_0xf41ce8['id']['padEnd'](0x24)+'\x20\x20'+_0xeac691[_0x59241b(0xb1)](0x13)+'\x20\x20'+_0xf41ce8[_0x59241b(0x13d)]+_0x657db2+'\x0a');}}_0x583be1||process['stderr'][_0x59241b(0x187)](_0x59241b(0x1b3)+(_0x48a1ea+0x1)+'\x0a');}async function Rt(_0x4a3aa8){const _0x5a569c=_0x4b2408;let _0x396679=await P(),_0x39c89d=_0xb77cfd(_0x4a3aa8['env'],_0x396679,_0x4a3aa8[_0x5a569c(0x162)]);F(_0x4a3aa8[_0x5a569c(0xc1)],_0x4a3aa8['backendUrl'],_0x39c89d);let _0x4c143a=await _0x339d97({'auth':_0x396679,'backendUrl':_0x39c89d,'interop':_0x4a3aa8[_0x5a569c(0x201)]?'skip':_0x5a569c(0x15a)});l(_0x4a3aa8,_0x4c143a,({checks:_0x59e4ca})=>{const _0x2dd0d6=_0x5a569c;for(let _0x5a5357 of _0x59e4ca)process[_0x2dd0d6(0x149)][_0x2dd0d6(0x187)](Lt(_0x5a5357)+'\x0a');}),_0x4c143a['ok']||process[_0x5a569c(0x111)](0x1);}function Lt(_0xee78f9){const _0x17451d=_0x4b2408;return{'ok':'✓','failed':'✗','skipped':'-'}[_0xee78f9[_0x17451d(0x11b)]]+'\x20'+_0xee78f9[_0x17451d(0x140)]['padEnd'](0xa)+_0xee78f9['detail'];}var Ot=['',_0x4b2408(0x167),_0x4b2408(0x1a7)];async function Pt(_0x376579){const _0x31bf4f=_0x4b2408;let _0x1b95bb=_0x376579[_0x31bf4f(0x135)];Ot[_0x31bf4f(0x13a)](_0x1b95bb)||(console[_0x31bf4f(0x236)](_0x31bf4f(0x12c)+_0x376579[_0x31bf4f(0x135)]+_0x31bf4f(0x19f)),process[_0x31bf4f(0x111)](0x2)),_0x1b95bb===''&&_0x376579[_0x31bf4f(0x200)]!==void 0x0&&(console[_0x31bf4f(0x236)](_0x31bf4f(0x1f5)),process['exit'](0x2)),_0x1b95bb!==''&&_0x376579[_0x31bf4f(0x1dd)]!==void 0x0&&(console[_0x31bf4f(0x236)](_0x31bf4f(0x16b)),process[_0x31bf4f(0x111)](0x2));let {client:_0x4869fa}=await f(_0x376579);if(_0x1b95bb==='activity'){l(_0x376579,await _0x37f407(_0x4869fa,{'days':_0x376579['days']}),jt);return;}if(_0x1b95bb==='daily'){l(_0x376579,await _0x2f9202(_0x4869fa,{'days':_0x376579[_0x31bf4f(0x200)]}),Mt);return;}let [_0x508d73,_0x3bfc62,_0x2d2022]=await Promise['all']([_0x840846(_0x4869fa,{'sessionId':_0x376579[_0x31bf4f(0x1dd)]}),_0x352089(_0x4869fa),_0x30995d(_0x4869fa)]);l(_0x376579,{'licensing':_0x508d73,'monthlySpending':_0x3bfc62,'cartographerAllowance':_0x2d2022},Ft);}function Ft(_0x15be53){const _0x5ea229=_0x4b2408;let {licensing:_0x52ca92,monthlySpending:_0x1854d4,cartographerAllowance:_0x1d5439}=_0x15be53,_0x28fa9d=[_0x52ca92[_0x5ea229(0x206)]?_0x5ea229(0x13b)+_0x52ca92['pct_used']['toFixed'](0x1)+_0x5ea229(0x25b)+(_0x52ca92['total_quota_pu']??0x0)+'\x20PU\x20used'+(_0x52ca92[_0x5ea229(0x248)]>0x0?',\x20'+_0x52ca92[_0x5ea229(0x248)]+_0x5ea229(0x23a):'')+_0x5ea229(0x209)+_0x52ca92[_0x5ea229(0x1a0)]+')':_0x5ea229(0x26b),_0x5ea229(0x108)+_0x1854d4[_0x5ea229(0xcf)]['toFixed'](0x2)+'\x20this\x20month'+(_0x1854d4[_0x5ea229(0x206)]&&_0x1854d4[_0x5ea229(0x227)]!==null?_0x5ea229(0x1e3)+_0x1854d4['monthly_limit_usd'][_0x5ea229(0xfe)](0x2)+_0x5ea229(0xd1):_0x5ea229(0x1a1)),_0x5ea229(0xff)+_0x1d5439['mode']+'\x20('+_0x1d5439[_0x5ea229(0x122)]+')'];_0x52ca92[_0x5ea229(0x1c1)]!==null&&_0x52ca92[_0x5ea229(0x1c1)]!==void 0x0&&_0x28fa9d[_0x5ea229(0x15e)](_0x5ea229(0x205)+_0x52ca92[_0x5ea229(0x1c1)]+_0x5ea229(0x1e0)),process[_0x5ea229(0x149)][_0x5ea229(0x187)](_0x28fa9d[_0x5ea229(0x1c4)]('\x0a')+'\x0a');}function jt(_0xf04954){const _0x596a02=_0x4b2408;let _0x579eb0=[_0x596a02(0xe0)+_0xf04954[_0x596a02(0xd5)]+_0x596a02(0x19c)+_0xf04954[_0x596a02(0x21d)]+'\x20sessions\x20on\x20'+_0xf04954[_0x596a02(0x101)]+_0x596a02(0xd3),'Cost:\x20\x20\x20$'+_0xf04954['total_cost_usd'][_0x596a02(0xfe)](0x2)+'\x20(estimated\x20$'+_0xf04954[_0x596a02(0x1d7)]['toFixed'](0x2)+'\x20from\x20'+_0xf04954[_0x596a02(0x132)]+'\x20token\x20units)','Tokens:\x20'+_0xf04954[_0x596a02(0x164)]+_0x596a02(0x1bc)+_0xf04954[_0x596a02(0x15c)]+'\x20completion'];for(let [_0x507420,_0x557d90]of Object[_0x596a02(0x143)](_0xf04954[_0x596a02(0x262)]))_0x579eb0['push']('\x20\x20'+_0x507420+':\x20'+_0x557d90+_0x596a02(0x196));process['stdout'][_0x596a02(0x187)](_0x579eb0[_0x596a02(0x1c4)]('\x0a')+'\x0a');}function Mt(_0x44e9c1){const _0x5c42fa=_0x4b2408;if(_0x44e9c1['daily_usage']['length']===0x0){process[_0x5c42fa(0x149)]['write'](_0x5c42fa(0x104)+_0x44e9c1[_0x5c42fa(0xd5)]+_0x5c42fa(0x18c));return;}let _0x269d09=['Date\x20\x20\x20\x20\x20\x20\x20\x20Token\x20units\x20\x20Prompt\x20tokens\x20\x20Completion\x20tokens'];for(let _0x2266af of _0x44e9c1['daily_usage'])_0x269d09[_0x5c42fa(0x15e)](_0x2266af[_0x5c42fa(0x175)]+'\x20\x20'+String(_0x2266af[_0x5c42fa(0x126)])[_0x5c42fa(0x1e2)](0xb)+'\x20\x20'+String(_0x2266af[_0x5c42fa(0x259)])[_0x5c42fa(0x1e2)](0xd)+'\x20\x20'+String(_0x2266af[_0x5c42fa(0x12d)])[_0x5c42fa(0x1e2)](0x11));process[_0x5c42fa(0x149)]['write'](_0x269d09[_0x5c42fa(0x1c4)]('\x0a')+'\x0a');}async function Bt(_0x546574,_0x2d58a6){const _0x41fb19=_0x4b2408;let _0x532cbe=await Ht(_0x546574[_0x41fb19(0x135)],_0x2d58a6);_0x546574[_0x41fb19(0x17f)]&&(_0x532cbe[_0x41fb19(0x17f)]=_0x546574[_0x41fb19(0x17f)]);let {client:_0x4aaaa1}=await f(_0x546574);try{_0x2d58a6===_0x41fb19(0x117)?l(_0x546574,await _0x59308b(_0x4aaaa1,_0x532cbe,void 0x0),Jt):_0x2d58a6===_0x41fb19(0x215)?l(_0x546574,await _0x341947(_0x4aaaa1,_0x532cbe,void 0x0),Wt):l(_0x546574,await _0x1ef4ae(_0x4aaaa1,_0x532cbe,void 0x0),Gt);}catch(_0x2f0ca3){if(!_0x5a4402(_0x2f0ca3))throw _0x2f0ca3;console['error'](_0x2f0ca3['message']),process[_0x41fb19(0x111)](0x1);}}async function Ht(_0x2da026,_0x2437ee){const _0x11e371=_0x4b2408;let _0x1ff76b;try{_0x1ff76b=_0x2da026&&_0x2da026!=='-'?_0x327d7[_0x11e371(0x22b)](_0x53e3ce[_0x11e371(0x220)](_0x2da026),_0x11e371(0x109)):await I(_0x2da026,process[_0x11e371(0x19a)]);}catch(_0xb9c40){console[_0x11e371(0x236)](_0x2437ee+_0x11e371(0x257)+_0xb9c40[_0x11e371(0x17c)]+').'),process[_0x11e371(0x111)](0x2);}return _0x1ff76b||(console[_0x11e371(0x236)](_0x2437ee+'\x20needs\x20a\x20JSON\x20request:\x20delegate-cli\x20'+_0x2437ee+'\x20<file.json>,\x20or\x20-\x20to\x20read\x20stdin.'),process['exit'](0x2)),de(_0x1ff76b,_0x2437ee,'the\x20request');}function de(_0x2c96b0,_0x2c3d8c,_0x5bcc41){const _0x48c5eb=_0x4b2408;let _0x30323a;try{_0x30323a=JSON[_0x48c5eb(0x1ae)](_0x2c96b0);}catch(_0x199df8){console[_0x48c5eb(0x236)](_0x2c3d8c+':\x20'+_0x5bcc41+_0x48c5eb(0x1cd)+_0x199df8[_0x48c5eb(0x17c)]+').'),process['exit'](0x2);}return(typeof _0x30323a!='object'||_0x30323a===null||Array[_0x48c5eb(0x147)](_0x30323a))&&(console[_0x48c5eb(0x236)](_0x2c3d8c+':\x20'+_0x5bcc41+_0x48c5eb(0x238)),process[_0x48c5eb(0x111)](0x2)),_0x30323a;}function ue(_0x19973c,_0x301784){const _0x2beeec=_0x4b2408;let _0x354e5e;try{_0x354e5e=_0x327d7[_0x2beeec(0x22b)](_0x53e3ce[_0x2beeec(0x220)](_0x19973c),_0x2beeec(0x109));}catch(_0x1cdf17){console[_0x2beeec(0x236)](_0x301784+_0x2beeec(0x202)+_0x1cdf17['message']+').'),process[_0x2beeec(0x111)](0x2);}return de(_0x354e5e,_0x301784,_0x2beeec(0x17a));}async function qt(_0xad25ed){const _0x50ef42=_0x4b2408;_0xad25ed[_0x50ef42(0x198)]===void 0x0&&(console[_0x50ef42(0x236)](_0x50ef42(0x11c)),process[_0x50ef42(0x111)](0x2));let _0x5c71a9=ue(_0xad25ed['jsonSchemaPath'],_0x50ef42(0x1eb)),_0x2dd8f7=(await I(_0xad25ed[_0x50ef42(0x135)],process[_0x50ef42(0x19a)]))[_0x50ef42(0x1fb)]();_0x2dd8f7||(console[_0x50ef42(0x236)](_0x50ef42(0xf3)),process['exit'](0x2));let {client:_0x1d6054}=await f(_0xad25ed);try{let _0x43c2e8=await _0x3e5d4d(_0x1d6054,{'prompt':_0x2dd8f7,'jsonSchema':_0x5c71a9,'model':_0xad25ed[_0x50ef42(0x17f)]||process.env.MODEL||_0x2014de,..._0xad25ed[_0x50ef42(0x1dd)]!==void 0x0&&{'sessionId':_0xad25ed[_0x50ef42(0x1dd)]}},void 0x0);l(_0xad25ed,_0x43c2e8,_0x471a0c=>{const _0x1798e4=_0x50ef42;process[_0x1798e4(0x149)][_0x1798e4(0x187)](JSON['stringify'](_0x471a0c[_0x1798e4(0x1de)],null,0x2)+'\x0a');});}catch(_0x42b7dd){if(!_0x71cc8(_0x42b7dd))throw _0x42b7dd;console[_0x50ef42(0x236)](_0x42b7dd[_0x50ef42(0x17c)]),process[_0x50ef42(0x111)](0x1);}}function j(_0x59e56a){const _0x37ccaa=_0x4b2408;process[_0x37ccaa(0x149)][_0x37ccaa(0x187)](_0x37ccaa(0xd4)+_0x59e56a['model']+'\x20('+_0x59e56a[_0x37ccaa(0x123)]+'),\x20'+_0x59e56a[_0x37ccaa(0x18d)][_0x37ccaa(0x10b)]+_0x37ccaa(0x113));}function Jt(_0x5a4d52){const _0x5cb1ce=_0x4b2408;j(_0x5a4d52);for(let _0x2a2f6c of Object[_0x5cb1ce(0x1ee)](_0x5a4d52[_0x5cb1ce(0x163)])){let _0x9734a4=_0x5a4d52[_0x5cb1ce(0x163)][_0x2a2f6c],_0x320978=_0x9734a4[_0x5cb1ce(0xbe)]==='probability'?_0x5cb1ce(0x1ec)+_0x9734a4[_0x5cb1ce(0xae)]['toFixed'](0x2):_0x9734a4[_0x5cb1ce(0xbe)]===_0x5cb1ce(0x176)?_0x5cb1ce(0x24c)+_0x9734a4[_0x5cb1ce(0x176)]+_0x5cb1ce(0x1f4)+_0x9734a4['confidence'][_0x5cb1ce(0xfe)](0x2)+')':_0x5cb1ce(0x18f)+_0x9734a4['score'][_0x5cb1ce(0xfe)](0x2)+_0x5cb1ce(0x1f4)+_0x9734a4[_0x5cb1ce(0xe2)][_0x5cb1ce(0xfe)](0x2)+')';process[_0x5cb1ce(0x149)]['write']('\x20\x20'+_0x2a2f6c+':\x20'+_0x320978+'\x0a');}}function Wt(_0x238afd){const _0x3ebc5e=_0x4b2408;j(_0x238afd),_0x238afd['results'][_0x3ebc5e(0x204)]((_0x26755a,_0xe5867a)=>{const _0x570b12=_0x3ebc5e;process[_0x570b12(0x149)][_0x570b12(0x187)]('\x20\x20'+(_0xe5867a+0x1)+'.\x20'+_0x26755a['id']+'\x20\x20'+_0x26755a[_0x570b12(0xcb)]['toFixed'](0x3)+_0x570b12(0x174)+_0x26755a[_0x570b12(0x161)]+')\x0a');});}function Gt(_0x447280){const _0x2c1fe5=_0x4b2408;j(_0x447280),process['stdout'][_0x2c1fe5(0x187)]('Rubric\x20'+_0x447280[_0x2c1fe5(0xea)]+'\x0a');for(let _0x3aa30c of _0x447280['results'])process[_0x2c1fe5(0x149)][_0x2c1fe5(0x187)]('\x20\x20'+_0x3aa30c['id']+':\x20'+_0x3aa30c['verdict']+'\x20(confidence\x20'+_0x3aa30c['confidence'][_0x2c1fe5(0xfe)](0x2)+')\x0a');}async function Kt(_0x5471e1){const _0x268932=_0x4b2408;let _0x414fb6=_0x5471e1['prompt']['trim']();_0x414fb6||(console[_0x268932(0x236)](_0x268932(0x14b)),process[_0x268932(0x111)](0x2));let {client:_0x4aff00}=await f(_0x5471e1);try{let _0x171eaa=_0x414fb6==='-'?{'data':await zt(process[_0x268932(0x19a)])}:_0x414fb6;l(_0x5471e1,await _0xd6590f(_0x4aff00,_0x171eaa,void 0x0),_0x37f7e6=>{const _0x434289=_0x268932;process[_0x434289(0x149)][_0x434289(0x187)](_0x37f7e6[_0x434289(0xd6)]+'\x0a');});}catch(_0x2b8a0c){if(_0x4d36b1(_0x2b8a0c)&&(console[_0x268932(0x236)](_0x2b8a0c['message']),process['exit'](_0x2b8a0c[_0x268932(0x11b)]===void 0x0?0x2:0x1)),typeof _0x2b8a0c?.[_0x268932(0x1b8)]!=_0x268932(0xf6))throw _0x2b8a0c;console[_0x268932(0x236)](_0x268932(0x110)+_0x414fb6+'\x20('+_0x2b8a0c['message']+').'),process[_0x268932(0x111)](0x2);}}async function zt(_0x21af99){const _0x246c0b=_0x4b2408;let _0xea10b4=[];for await(let _0x460379 of _0x21af99)_0xea10b4[_0x246c0b(0x15e)](Buffer[_0x246c0b(0x17e)](_0x460379));return Buffer[_0x246c0b(0xbb)](_0xea10b4);}var Y=[_0x4b2408(0x1ab),_0x4b2408(0x188),_0x4b2408(0xe5),_0x4b2408(0x1d3),_0x4b2408(0x1b4),'complete',_0x4b2408(0xad),'dismiss','cancel','delete'],X={'list':_0x4b2408(0x146),'pending':_0x4b2408(0x130),'show':_0x4b2408(0x11d),'create':_0x4b2408(0x10e),'claim':_0x4b2408(0x16c),'complete':_0x4b2408(0xdb),'accept':'delegations\x20accept\x20<delegation-id>','dismiss':'delegations\x20dismiss\x20<delegation-id>','cancel':_0x4b2408(0x13c),'delete':_0x4b2408(0x218)};async function Vt(_0x4b59c5){const _0x589cc9=_0x4b2408;let [_0x185b2e='',_0x2940ae='',..._0x5b8601]=_0x4b59c5[_0x589cc9(0xd0)];Y[_0x589cc9(0x13a)](_0x185b2e)||(console[_0x589cc9(0x236)]((_0x185b2e?_0x589cc9(0x1c9)+_0x185b2e+'.\x20':'')+_0x589cc9(0x22f)+Y[_0x589cc9(0x1c4)](_0x589cc9(0x225))+'.'),process['exit'](0x2));let _0x3ee282=_0x185b2e;_0x3ee282!==_0x589cc9(0x1d3)&&(_0x4b59c5[_0x589cc9(0x1c6)]!==void 0x0||_0x4b59c5[_0x589cc9(0x1bb)]!==void 0x0||_0x4b59c5[_0x589cc9(0x1dd)]!==void 0x0)&&(console[_0x589cc9(0x236)](_0x589cc9(0x1ce)),process[_0x589cc9(0x111)](0x2));let _0x2e3171=(_0x3ee282==='create'?_0x4b59c5['operands'][_0x589cc9(0x1d0)](0x1):_0x5b8601)[_0x589cc9(0x1c4)]('\x20')['trim'](),_0x598078=_0x3ee282===_0x589cc9(0x1d3)||_0x3ee282===_0x589cc9(0x1eb);(_0x3ee282!==_0x589cc9(0x1d3)&&!_0x2940ae||(_0x598078?!_0x2e3171:_0x2e3171)||_0x3ee282===_0x589cc9(0x1d3)&&!_0x4b59c5[_0x589cc9(0x1dd)])&&(console[_0x589cc9(0x236)](_0x589cc9(0x1aa)+X[_0x3ee282]),process['exit'](0x2));let _0x1d188f=_0x598078&&_0x2e3171==='-'?(await I('-',process['stdin']))[_0x589cc9(0x1fb)]():_0x2e3171;_0x598078&&!_0x1d188f&&(console[_0x589cc9(0x236)](_0x589cc9(0x1aa)+X[_0x3ee282]+_0x589cc9(0xe9)),process['exit'](0x2));let {client:_0x42ceee}=await f(_0x4b59c5);try{await Yt(_0x4b59c5,_0x42ceee,_0x3ee282,_0x2940ae,_0x1d188f);}catch(_0x228c1b){if(!_0xfcf6ab(_0x228c1b))throw _0x228c1b;console[_0x589cc9(0x236)](_0x228c1b['message']),process['exit'](0x1);}}async function Yt(_0x249d54,_0x288cdd,_0xe59c6d,_0x1e1bde,_0x2f470a){const _0x2bbb8e=_0x4b2408;switch(_0xe59c6d){case'list':l(_0x249d54,await _0x305187(_0x288cdd,_0x1e1bde),Xt);return;case _0x2bbb8e(0x188):l(_0x249d54,await _0x5f11d9(_0x288cdd,_0x1e1bde),_0x467e77=>{const _0x7e4235=_0x2bbb8e;_0x467e77[_0x7e4235(0x235)]&&process['stdout'][_0x7e4235(0x187)]('Claimed\x20from\x20delegation\x20'+_0x467e77['delegation']['id']+'\x20('+_0x467e77[_0x7e4235(0x235)][_0x7e4235(0x11b)]+_0x7e4235(0x144)),_0x467e77[_0x7e4235(0x231)][_0x7e4235(0x1fd)]===0x0&&process[_0x7e4235(0xb4)]['write'](_0x7e4235(0x261));for(let _0x1b2b5c of _0x467e77[_0x7e4235(0x231)])process[_0x7e4235(0x149)][_0x7e4235(0x187)]('\x0a'+_0x1b2b5c['id']+_0x7e4235(0x21f)+(_0x1b2b5c['assignedUserEmail']??'a\x20colleague')+'\x20\x20'+(_0x1b2b5c[_0x7e4235(0xce)]??'')+'\x0a'+(_0x1b2b5c['result']?.['content']??'')+'\x0a');_0x467e77['pendingResults']['length']>0x0&&process[_0x7e4235(0xb4)][_0x7e4235(0x187)](_0x7e4235(0x1f1));});return;case'show':l(_0x249d54,await _0x14013e(_0x288cdd,_0x1e1bde),Q);return;case _0x2bbb8e(0x1d3):{let _0xb41cb=await _0x2e241f(_0x288cdd,{'sessionId':_0x249d54[_0x2bbb8e(0x1dd)],'task':_0x2f470a,..._0x249d54['contextSummary']!==void 0x0&&{'contextSummary':_0x249d54[_0x2bbb8e(0x1bb)]},..._0x249d54[_0x2bbb8e(0x1c6)]!==void 0x0&&{'recipient':_0x249d54[_0x2bbb8e(0x1c6)]}});l(_0x249d54,_0xb41cb,_0x48069f=>{const _0x1aae0d=_0x2bbb8e;_0x48069f['assignedUser']?process[_0x1aae0d(0x149)][_0x1aae0d(0x187)](_0x1aae0d(0x1af)+_0x48069f[_0x1aae0d(0x1fa)]+_0x1aae0d(0xda)+_0x48069f['assignedUser']['displayName']+'\x20<'+_0x48069f[_0x1aae0d(0xf1)][_0x1aae0d(0x226)]+_0x1aae0d(0x1ea)):process[_0x1aae0d(0x149)][_0x1aae0d(0x187)](_0x1aae0d(0x181)+_0x48069f['delegationId']+_0x1aae0d(0x18a)+_0x48069f[_0x1aae0d(0x13e)]+'\x0a');});return;}case'claim':{let _0x4e384f=await _0xdaff81(_0x288cdd,_0x1e1bde);l(_0x249d54,_0x4e384f,_0x5bd035=>{const _0x5c0362=_0x2bbb8e;Q(_0x5bd035),process[_0x5c0362(0x149)]['write']('Session\x20\x20\x20\x20\x20\x20\x20'+_0x5bd035['sessionId']+'\x0a'),process[_0x5c0362(0xb4)][_0x5c0362(0x187)](_0x5c0362(0x22c)+_0x5bd035['sessionId']+_0x5c0362(0x240)+_0x5bd035[_0x5c0362(0x1fa)]+_0x5c0362(0xaf));});return;}case _0x2bbb8e(0x1eb):{let {alreadyCompleted:_0xae0572}=await _0x274b0c(_0x288cdd,_0x1e1bde,{'content':_0x2f470a});l(_0x249d54,{'delegationId':_0x1e1bde,'alreadyCompleted':_0xae0572},_0x146e47=>{const _0x4129ec=_0x2bbb8e;process[_0x4129ec(0x149)]['write']((_0x146e47['alreadyCompleted']?_0x4129ec(0x1f3):'Answered')+_0x4129ec(0x18e)+_0x146e47[_0x4129ec(0x1fa)]+'.\x0a');});return;}case'accept':{let _0xf49f1c=await _0x58239f(_0x288cdd,_0x1e1bde);l(_0x249d54,{'delegationId':_0x1e1bde,..._0xf49f1c},_0x595fad=>{const _0xcd2083=_0x2bbb8e;process[_0xcd2083(0x149)][_0xcd2083(0x187)]((_0x595fad[_0xcd2083(0x210)]?_0xcd2083(0x115):_0xcd2083(0xbc))+'\x20delegation\x20'+_0x595fad[_0xcd2083(0x1fa)]+'.\x0a');});return;}default:{let _0x3f1610={'dismiss':_0x3a0c7d,'cancel':_0x1af96c,'delete':_0x350f12}[_0xe59c6d];await _0x3f1610(_0x288cdd,_0x1e1bde);let _0x45328a={'dismiss':_0x2bbb8e(0xeb),'cancel':_0x2bbb8e(0x1e6),'delete':_0x2bbb8e(0x151)}[_0xe59c6d];l(_0x249d54,{'delegationId':_0x1e1bde,[_0x45328a]:!0x0},()=>{const _0x3ccee6=_0x2bbb8e;process[_0x3ccee6(0x149)][_0x3ccee6(0x187)](''+_0x45328a[0x0]['toUpperCase']()+_0x45328a[_0x3ccee6(0x1d0)](0x1)+_0x3ccee6(0x18e)+_0x1e1bde+'.\x0a');});}}}function Xt(_0x3db6f3){const _0x1904d6=_0x4b2408;if(_0x3db6f3[_0x1904d6(0x1fd)]===0x0){process[_0x1904d6(0xb4)][_0x1904d6(0x187)](_0x1904d6(0x251));return;}process['stdout'][_0x1904d6(0x187)]('ID'[_0x1904d6(0xb1)](0x24)+'\x20\x20'+_0x1904d6(0x247)[_0x1904d6(0xb1)](0x9)+'\x20\x20'+_0x1904d6(0x1d5)[_0x1904d6(0xb1)](0x18)+'\x20\x20TASK\x0a');for(let _0x557040 of _0x3db6f3)process[_0x1904d6(0x149)][_0x1904d6(0x187)](_0x557040['id'][_0x1904d6(0xb1)](0x24)+'\x20\x20'+_0x557040[_0x1904d6(0x11b)][_0x1904d6(0xb1)](0x9)+'\x20\x20'+(_0x557040[_0x1904d6(0x179)]??'-')[_0x1904d6(0xb1)](0x18)+'\x20\x20'+(_0x557040['task']??'')+'\x0a');}function Q(_0x2dfecb){const _0xb4370=_0x4b2408;process[_0xb4370(0x149)]['write'](_0xb4370(0x178)+(_0x2dfecb[_0xb4370(0x193)]??'-')+'\x0a'),_0x2dfecb[_0xb4370(0x18b)]&&process[_0xb4370(0x149)][_0xb4370(0x187)](_0xb4370(0x1ff)+_0x2dfecb[_0xb4370(0x18b)]+'\x0a'),process[_0xb4370(0x149)][_0xb4370(0x187)]('Task\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+(_0x2dfecb['task']??'-')+'\x0a'),_0x2dfecb[_0xb4370(0x1bb)]&&process['stdout'][_0xb4370(0x187)]('\x0a'+_0x2dfecb[_0xb4370(0x1bb)]+'\x0a\x0a');}async function Qt(_0xd1dbe9){const _0x5ca8a4=_0x4b2408;_0xd1dbe9[_0x5ca8a4(0x135)][_0x5ca8a4(0x1fb)]()||(console['error'](_0x5ca8a4(0x10a)),process[_0x5ca8a4(0x111)](0x2));let {client:_0xe3f753}=await f(_0xd1dbe9),_0x355703;try{_0x355703=await _0x5d4451(_0xe3f753,_0xd1dbe9[_0x5ca8a4(0x135)]);}catch(_0x3cd1e8){if(!_0xfcf6ab(_0x3cd1e8))throw _0x3cd1e8;console[_0x5ca8a4(0x236)](_0x3cd1e8[_0x5ca8a4(0x17c)]),process[_0x5ca8a4(0x111)](0x1);}l(_0xd1dbe9,_0x355703,_0x4d9706=>{const _0x23fd0d=_0x5ca8a4;_0x4d9706['length']===0x0&&process[_0x23fd0d(0xb4)]['write'](_0x23fd0d(0x103)+_0xd1dbe9['prompt'][_0x23fd0d(0x1fb)]()+_0x23fd0d(0x102));for(let _0x1233ac of _0x4d9706)process[_0x23fd0d(0x149)][_0x23fd0d(0x187)](_0x1233ac['email'][_0x23fd0d(0xb1)](0x20)+'\x20\x20'+_0x1233ac[_0x23fd0d(0x127)]+'\x0a');});}async function Zt(_0x366ae7){const _0x35f926=_0x4b2408;_0x366ae7[_0x35f926(0xc1)]===_0x35f926(0x154)&&(console[_0x35f926(0x236)](_0x35f926(0x145)),process[_0x35f926(0x111)](0x2));let _0x2d14e4=$(_0x20e75f()),_0x540b35=_0x366ae7[_0x35f926(0xc7)];if(_0x366ae7[_0x35f926(0xc1)]){let _0x26aa7b=_0x366ae7[_0x35f926(0xc1)];await _0x3d3632({'env':_0x26aa7b,'tenant':_0x366ae7[_0x35f926(0xf2)]??C(_0x2d14e4,_0x1c09a4[_0x26aa7b]),'skipEnvCheck':_0x540b35});return;}let _0x59765d=_0x366ae7[_0x35f926(0xc6)]??ce();if(_0x59765d){await _0x3d3632({'baseUrl':_0x59765d,'tenant':_0x366ae7['tenant']??C(_0x2d14e4,_0x59765d),'skipEnvCheck':_0x540b35});return;}if(_0x2d14e4?.[_0x35f926(0x1b0)]){await _0x3d3632({'baseUrl':_0x2d14e4[_0x35f926(0x1b0)],'tenant':_0x366ae7[_0x35f926(0xf2)]??_0x2d14e4[_0x35f926(0xfa)],'skipEnvCheck':_0x540b35});return;}console[_0x35f926(0x236)](_0x35f926(0x224)),process[_0x35f926(0x111)](0x2);}function C(_0x4f5fe7,_0x258ff6){const _0x315ada=_0x4b2408;return _0x4f5fe7?.[_0x315ada(0x1b0)]&&en(_0x4f5fe7[_0x315ada(0x1b0)],_0x258ff6)?_0x4f5fe7[_0x315ada(0xfa)]:void 0x0;}function en(_0x3ea140,_0x54d6f9){try{return new URL(_0x3ea140)['origin']===new URL(_0x54d6f9)['origin'];}catch{return!0x1;}}async function tn(_0xcfb92a){const _0x3bbb4b=_0x4b2408;O()&&(console[_0x3bbb4b(0x236)](_0x3bbb4b(0x141)),process[_0x3bbb4b(0x111)](0x2));let _0x5c467d=await _0x595be9();if(_0x5c467d||(console['error'](nn()),process[_0x3bbb4b(0x111)](0x2)),_0xcfb92a[_0x3bbb4b(0x1fb)]()){let _0x4ed1a8=await _0x16d71c(_0x5c467d,_0xcfb92a);_0x4bed5a(_0x4ed1a8)||(console[_0x3bbb4b(0x236)](_0x3bbb4b(0x1f2)+_0x20e75f()+_0x3bbb4b(0x121)+_0x5c467d[_0x3bbb4b(0xfa)]+'.'),process[_0x3bbb4b(0x111)](0x1)),console[_0x3bbb4b(0xf8)](_0x3bbb4b(0x169)+_0x4ed1a8[_0x3bbb4b(0xfa)]+'\x20('+_0x4ed1a8[_0x3bbb4b(0x17b)]+_0x3bbb4b(0x20a)+_0x20e75f());return;}on(await _0x4fd2bd(_0x5c467d),_0x5c467d);}function nn(){const _0x4e4e37=_0x4b2408;if(_0x327d7[_0x4e4e37(0x120)](_0x20e75f()))return _0x4e4e37(0x1f0);let _0x47e002=L();return $(_0x47e002)?_0x4e4e37(0x199)+_0x47e002+',\x20whose\x20tenant\x20is\x20chosen\x20in\x20the\x20app.\x20Run\x20`delegate-cli\x20login\x20--env\x20<env>`\x20for\x20a\x20CLI\x20login\x20of\x20your\x20own.':_0x4e4e37(0xe3);}function on(_0x205573,_0x24389a){const _0x2f2b26=_0x4b2408;let _0x428745=_0x205573[_0x2f2b26(0x228)](_0x3d0f1b=>_0x3d0f1b['id']===_0x24389a[_0x2f2b26(0x17b)]?'*\x20'+_0x3d0f1b[_0x2f2b26(0x140)]+'\x20(current)':'\x20\x20'+_0x3d0f1b[_0x2f2b26(0x140)]);process[_0x2f2b26(0x149)][_0x2f2b26(0x187)](_0x2f2b26(0x12e)+(_0x24389a[_0x2f2b26(0x16d)]??_0x24389a['organizationId'])+':\x0a'+_0x428745[_0x2f2b26(0x1c4)]('\x0a')+'\x0a'),_0x205573[_0x2f2b26(0x1fd)]>0x1&&process[_0x2f2b26(0x149)][_0x2f2b26(0x187)](_0x2f2b26(0x105));}function sn(_0x470b66){const _0x3017b1=_0x4b2408;return _0x470b66?.[_0x3017b1(0x1b9)]?.[_0x3017b1(0x11b)]===0x191||/401/[_0x3017b1(0x1c3)](String(_0x470b66?.[_0x3017b1(0x17c)]??''));}var d={'lastType':null,'quiet':!0x1},rn=_0xcaeebe=>{const _0x4fb745=_0x4b2408;switch(_0xcaeebe[_0x4fb745(0xbe)]){case _0x4fb745(0x1e4):_0xcaeebe['sessionId']&&_0xcaeebe[_0x4fb745(0x1dd)]!==d[_0x4fb745(0x1dd)]&&(process['stderr'][_0x4fb745(0x187)](_0x4fb745(0x148)+_0xcaeebe['sessionId']+_0x4fb745(0x1d8)+_0xcaeebe[_0x4fb745(0x1dd)]+')\x0a'),d[_0x4fb745(0x1dd)]=_0xcaeebe[_0x4fb745(0x1dd)]);break;case'turn_start':_0xcaeebe[_0x4fb745(0x1e7)]&&_0xcaeebe['turnId']!==d['turnId']&&(d[_0x4fb745(0x173)]!==null&&process['stderr'][_0x4fb745(0x187)]('\x0a'),process[_0x4fb745(0xb4)][_0x4fb745(0x187)](_0x4fb745(0x1c5)+_0xcaeebe['turnId']+_0x4fb745(0xf7)+_0xcaeebe[_0x4fb745(0x1dd)]+_0x4fb745(0x1c0)+_0xcaeebe[_0x4fb745(0x1e7)]+')\x0a'),d[_0x4fb745(0x1e7)]=_0xcaeebe[_0x4fb745(0x1e7)],d[_0x4fb745(0x173)]=_0x4fb745(0x1d2));break;case _0x4fb745(0x159):_0xcaeebe[_0x4fb745(0x1bf)]&&!d[_0x4fb745(0x214)]&&(d['lastType']!==_0x4fb745(0x159)&&process[_0x4fb745(0xb4)]['write'](_0x4fb745(0x212)),process[_0x4fb745(0xb4)][_0x4fb745(0x187)](_0xcaeebe[_0x4fb745(0x1bf)]),d[_0x4fb745(0x173)]=_0x4fb745(0x159));break;case'tool_call':d[_0x4fb745(0x173)]!==null&&process['stderr'][_0x4fb745(0x187)]('\x0a'),process[_0x4fb745(0xb4)][_0x4fb745(0x187)](_0x4fb745(0xba)+(_0xcaeebe[_0x4fb745(0x256)]??_0x4fb745(0x1ca))+'\x0a'),d[_0x4fb745(0x173)]=_0x4fb745(0x20b);break;case _0x4fb745(0x17c):_0xcaeebe[_0x4fb745(0x1bf)]&&(d[_0x4fb745(0x173)]!=='message'&&d['lastType']!==null&&process['stdout'][_0x4fb745(0x187)]('\x0a'),process[_0x4fb745(0x149)]['write'](_0xcaeebe[_0x4fb745(0x1bf)]),d[_0x4fb745(0x173)]=_0x4fb745(0x17c));break;case _0x4fb745(0x236):d['lastType']!==null&&process[_0x4fb745(0xb4)]['write']('\x0a'),process['stderr'][_0x4fb745(0x187)]('✗\x20'+(_0xcaeebe[_0x4fb745(0x236)]??_0x4fb745(0x236))+'\x0a'),d['lastType']=_0x4fb745(0x236);break;case _0x4fb745(0x137):(d['lastType']==='message'||d['lastType']===_0x4fb745(0x159))&&process[_0x4fb745(0x149)][_0x4fb745(0x187)]('\x0a'),process['stderr'][_0x4fb745(0x187)](_0x4fb745(0xed)),d[_0x4fb745(0x173)]=_0x4fb745(0x137);break;}};function Z(_0x4c9063,_0x4e4889,_0x1645db){const _0x2c48d0=_0x4b2408;let _0x213943=_0x4c9063[_0x2c48d0(0x17f)]||process.env.MODEL;return{'backendUrl':_0x1645db,'auth':_0x4e4889,'enableComputerUse':!_0x4c9063['headless']&&!_0x4c9063[_0x2c48d0(0x116)],'autoSpawnInterop':!_0x4c9063['headless'],'enableConnections':!_0x4c9063['noConnections'],'enableSecurity':!_0x4c9063[_0x2c48d0(0x1e8)],'keepInteropAlive':_0x4c9063[_0x2c48d0(0xb8)],..._0x4c9063[_0x2c48d0(0x1dc)]?{'enableMemory':!0x1}:{},..._0x4c9063['preloadSkills']['length']>0x0?{'preloadSkills':_0x4c9063['preloadSkills']}:{},..._0x213943?{'model':_0x213943}:{},..._0x4c9063[_0x2c48d0(0x1cf)]?{'projectId':_0x4c9063[_0x2c48d0(0x1cf)]}:{},..._0x4c9063[_0x2c48d0(0x1c8)]?{'workingDirectory':_0x4c9063['workingDirectory']}:{},..._0x4c9063[_0x2c48d0(0x171)]?{'bundledSkillsPath':_0x4c9063[_0x2c48d0(0x171)]}:{},..._0x4c9063[_0x2c48d0(0x1ed)]?{'effort':_0x4c9063[_0x2c48d0(0x1ed)]}:{},..._0x4c9063[_0x2c48d0(0x1dd)]?{'sessionId':_0x4c9063[_0x2c48d0(0x1dd)]}:{},..._0x4c9063['verbose']?{'verbose':!0x0}:{}};}async function an(_0x519c29){const _0x24de48=_0x4b2408;let _0x5ef639=_0x519c29['outputFormat']!=='text',_0x17c8ea=_0x519c29[_0x24de48(0x198)]===void 0x0?null:ue(_0x519c29[_0x24de48(0x198)],'delegate-cli'),_0x249abe=!_0x5ef639&&!_0x17c8ea&&!_0x519c29['print']&&_0x519c29[_0x24de48(0x135)]!=='-'&&!!process[_0x24de48(0x19a)][_0x24de48(0xf5)]&&!!process['stdout'][_0x24de48(0xf5)],_0x507aec=_0x249abe?_0x519c29[_0x24de48(0x135)][_0x24de48(0x1fb)]():await I(_0x519c29[_0x24de48(0x135)],process[_0x24de48(0x19a)]);if(!_0x249abe&&!_0x507aec&&(console['error'](_0x24de48(0x26c)),process[_0x24de48(0x111)](0x2)),!_0x5ef639){await ee(_0x519c29,_0x507aec,_0x249abe,null,_0x17c8ea);return;}let _0x3190e9=!0x1,_0xbf76a5=_0x2b169b=>{const _0x4878f2=_0x24de48;_0x3190e9=!0x0,S(_0x354c62(_0x2b169b)),(_0x2b169b[_0x4878f2(0x1d9)]||_0x2b169b[_0x4878f2(0x157)])&&(process[_0x4878f2(0x252)]=0x1);},_0x2bdcfb=Date['now']();try{await ee(_0x519c29,_0x507aec,!0x1,_0xbf76a5,_0x17c8ea);}catch(_0x142dcc){if(_0x3190e9)throw _0x142dcc;process[_0x24de48(0xb4)][_0x24de48(0x187)]((_0x142dcc instanceof Error?_0x142dcc['stack']??_0x142dcc[_0x24de48(0x17c)]:String(_0x142dcc))+'\x0a'),_0xbf76a5(new _0x28c7ed(_0x2bdcfb)[_0x24de48(0x1ba)]({'endedAtMs':Date['now'](),'usage':[],'error':_0x142dcc}));}}async function ee(_0x1e06bc,_0x2b39dd,_0xb8a827,_0x52fd28,_0x2abb4b){const _0x3634c0=_0x4b2408;d={'lastType':null,'quiet':_0x1e06bc[_0x3634c0(0x214)]};let _0x3e73a2=new Set(),_0x1ac90f=_0x42bff6=>{const _0x4ff1a0=_0x3634c0;(!_0x52fd28||_0x42bff6[_0x4ff1a0(0xbe)]===_0x4ff1a0(0x1e4)||_0x42bff6[_0x4ff1a0(0xbe)]===_0x4ff1a0(0x1d2))&&rn(_0x42bff6);for(let _0x49055d of _0x3e73a2)_0x49055d(_0x42bff6);},_0x10156c=await P(),_0x71d399=new _0x2a12bd();_0x71d399['onEvent'](_0x1ac90f);let _0x5ccfe0=_0xb77cfd(_0x1e06bc[_0x3634c0(0xc1)],_0x10156c,_0x1e06bc[_0x3634c0(0x162)]);F(_0x1e06bc[_0x3634c0(0xc1)],_0x1e06bc['backendUrl'],_0x5ccfe0);let _0x45ff7c=Z(_0x1e06bc,_0x10156c,_0x5ccfe0),_0x3f6085=!0x1,_0x2e2f3b=!0x1,_0x205a94,_0xcd57d6=()=>_0x205a94??=_0x71d399['destroy'](),_0x759482=()=>{const _0x4acb4c=_0x3634c0;_0x2e2f3b&&process['exit'](0x82),_0x2e2f3b=!0x0,process[_0x4acb4c(0xb4)][_0x4acb4c(0x187)](_0x4acb4c(0x12b)),_0x3f6085&&_0x71d399[_0x4acb4c(0x124)]()[_0x4acb4c(0x24f)](_0x2944ce=>console['error'](_0x2944ce))[_0x4acb4c(0x23e)](_0xcd57d6)[_0x4acb4c(0x23e)](()=>process['exit'](0x82),_0x3d1727=>{const _0x37845a=_0x4acb4c;console[_0x37845a(0x236)](_0x3d1727),process[_0x37845a(0x111)](0x82);});};process['on'](_0x3634c0(0x1ef),_0x759482);let _0x28d485=_0x1e06bc[_0x3634c0(0x19b)],_0x4378e3=async _0x4d58c5=>{const _0x4c2e3c=_0x3634c0;let _0x2eafba=_0x28d485;_0x28d485=[];let _0xaffb1a=()=>_0x71d399[_0x4c2e3c(0x136)](_0x4d58c5,{'attachments':_0x2eafba});try{return await _0xaffb1a();}catch(_0x521a83){if(_0x2e2f3b||!sn(_0x521a83)||!process[_0x4c2e3c(0x19a)][_0x4c2e3c(0xf5)]||_0x1e06bc[_0x4c2e3c(0xc1)]===_0x4c2e3c(0x154)||!(_0x1e06bc[_0x4c2e3c(0xc1)]||_0x10156c['baseUrl']))throw _0x521a83;process[_0x4c2e3c(0xb4)]['write'](_0x4c2e3c(0xca));let _0x335ae3=_0x71d399[_0x4c2e3c(0xc3)]()??_0x1e06bc[_0x4c2e3c(0x1dd)],_0x19e9cf=await _0x3d3632(_0x1e06bc[_0x4c2e3c(0xc1)]?{'env':_0x1e06bc['env'],'tenant':C(_0x10156c,_0x1c09a4[_0x1e06bc[_0x4c2e3c(0xc1)]]),'skipEnvCheck':!0x0}:{'baseUrl':_0x10156c[_0x4c2e3c(0x1b0)],'tenant':_0x10156c[_0x4c2e3c(0xfa)],'skipEnvCheck':!0x0}),_0x47e95d={'text':'','failed':!0x1,'sessionId':_0x335ae3};return _0x2e2f3b||(_0x3f6085=!0x1,await _0xcd57d6(),_0x2e2f3b)?_0x47e95d:(_0x71d399=new _0x2a12bd(),_0x205a94=void 0x0,_0x71d399[_0x4c2e3c(0x1a3)](_0x1ac90f),_0x10156c=_0x19e9cf,await _0x71d399[_0x4c2e3c(0x237)]({...Z(_0x1e06bc,_0x10156c,_0x5ccfe0),..._0x335ae3?{'sessionId':_0x335ae3}:{}}),_0x3f6085=!0x0,_0x2e2f3b?_0x47e95d:_0xaffb1a());}};try{if(await _0x71d399[_0x3634c0(0x237)](_0x45ff7c),_0x3f6085=!0x0,_0x2e2f3b)return;if(_0xb8a827)await dn({'prompt':_0x2b39dd,'sendMessage':_0x4378e3,'onSigint':_0x759482});else{if(_0x52fd28||_0x2abb4b){let _0xc009e8=_0x1e06bc[_0x3634c0(0x263)]===_0x3634c0(0x232)?_0x34de49=>S(_0x3900b8(_0x34de49)):()=>{},_0x4fb351=await _0x1208d4({'onEvent':_0x5c958e=>(_0x3e73a2[_0x3634c0(0x118)](_0x5c958e),()=>{const _0x4e2cca=_0x3634c0;_0x3e73a2[_0x4e2cca(0x25e)](_0x5c958e);}),'sendMessage':_0x45639a=>_0x4378e3(_0x45639a),'getSessionId':()=>_0x71d399[_0x3634c0(0xc3)](),'getTurnUsageHistory':_0x5af2f1=>_0x71d399[_0x3634c0(0x21a)](_0x5af2f1),'complete':_0xbdfed3=>_0x71d399[_0x3634c0(0x1eb)](_0xbdfed3)},_0x2b39dd,void 0x0,_0xc009e8,_0x2abb4b?{'outputSchema':_0x2abb4b}:void 0x0);_0x52fd28?_0x52fd28(_0x4fb351):ln(_0x4fb351);}else await _0x4378e3(_0x2b39dd);}}catch(_0x370483){if(!_0x2e2f3b)throw _0x370483;}finally{try{await _0xcd57d6();}finally{process[_0x3634c0(0x1ad)]('SIGINT',_0x759482),_0x2e2f3b&&(process[_0x3634c0(0x252)]=0x82);}}}function ln(_0x1ca311){const _0x2e3048=_0x4b2408;_0x1ca311[_0x2e3048(0x157)]?(console['error']('Structured\x20output\x20failed:\x20'+_0x1ca311[_0x2e3048(0x157)]['message']),process[_0x2e3048(0x252)]=0x1):_0x1ca311[_0x2e3048(0x1d9)]?(console['error'](_0x2e3048(0xb0)+_0x1ca311[_0x2e3048(0x236)]+').'),process[_0x2e3048(0x252)]=0x1):process['stdout'][_0x2e3048(0x187)](JSON['stringify'](_0x1ca311[_0x2e3048(0x1de)],null,0x2)+'\x0a');}function cn(_0x1766dd,_0x1f413c){const _0x1e4e9f=_0x4b2408;let _0x3e177f=process['stdout']['write'][_0x1e4e9f(0x269)](process['stdout']),_0x5b8ed4=!0x1;return process[_0x1e4e9f(0x149)]['write']=(..._0x5f1735)=>{if(!_0x5b8ed4)return _0x3e177f(..._0x5f1735);_0x496026(_0x1f413c,0x0),_0x349479(_0x1f413c,0x0);let _0x14a29a=_0x3e177f(..._0x5f1735);return _0x1766dd['prompt'](!0x0),_0x14a29a;},{'show':()=>{const _0x14a14d=_0x1e4e9f;_0x5b8ed4=!0x0,_0x1766dd[_0x14a14d(0x135)]();},'hide':()=>{_0x5b8ed4=!0x1;},'restore':()=>{const _0x5854a5=_0x1e4e9f;_0x5b8ed4=!0x1,process[_0x5854a5(0x149)][_0x5854a5(0x187)]=_0x3e177f;}};}async function dn({prompt:_0x42671a,sendMessage:_0x3c32cb,onSigint:_0xa3b7e3}){const _0x21ff61=_0x4b2408;let _0x3f1819=_0x45c416({'input':process[_0x21ff61(0x19a)],'output':process[_0x21ff61(0xb4)],'terminal':!0x0,'prompt':'You>\x20'}),_0x2101c0=cn(_0x3f1819,process[_0x21ff61(0xb4)]),_0x402770=_0x3f1819[Symbol[_0x21ff61(0x23b)]](),_0x88d0a2=!0x1;_0x3f1819[_0x21ff61(0x142)](_0x21ff61(0x195),()=>{_0x88d0a2=!0x0,_0x2101c0['hide']();});let _0x10cddb=!0x1,_0x447112=()=>{_0x10cddb=!0x0,_0x3f1819['close'](),_0xa3b7e3();};_0x3f1819['on'](_0x21ff61(0x1ef),_0x447112),process[_0x21ff61(0xb4)][_0x21ff61(0x187)]('Enter\x20sends\x20a\x20message.\x20/exit\x20or\x20EOF\x20exits;\x20Ctrl+C\x20stops\x20and\x20exits.\x0a');try{if(_0x42671a&&await _0x3c32cb(_0x42671a),_0x10cddb)return;_0x88d0a2||_0x2101c0[_0x21ff61(0xe5)]();for await(let _0x1595ff of _0x402770){if(_0x2101c0[_0x21ff61(0x230)](),_0x10cddb)break;let _0x402b79=_0x1595ff[_0x21ff61(0x1fb)]();if(_0x402b79===_0x21ff61(0x139))break;_0x402b79&&await _0x3c32cb(_0x402b79),_0x88d0a2||_0x2101c0[_0x21ff61(0xe5)]();}}finally{_0x2101c0[_0x21ff61(0x1e1)](),_0x3f1819[_0x21ff61(0x1ad)](_0x21ff61(0x1ef),_0x447112),_0x3f1819[_0x21ff61(0x195)]();}}async function un(){const _0x3a7b64=_0x4b2408;let _0x36ce45=ft(process[_0x3a7b64(0x125)][_0x3a7b64(0x1d0)](0x2));if(_0x36ce45['outputFormat']===_0x3a7b64(0xd6)){await te(_0x36ce45);return;}let _0xb6e313=gt();try{await te(_0x36ce45);}finally{_0xb6e313();}}async function te(_0x5b3e10){const _0x5d7193=_0x4b2408;if(_0x5b3e10[_0x5d7193(0x134)]){ht();return;}if(_0x5b3e10[_0x5d7193(0x17d)]){console[_0x5d7193(0xf8)](wt());return;}if(_0x5b3e10[_0x5d7193(0xb5)]===_0x5d7193(0x165)){await Zt(_0x5b3e10);return;}if(_0x5b3e10[_0x5d7193(0xb5)]==='tenant'){await tn(_0x5b3e10[_0x5d7193(0x135)]);return;}if(_0x5b3e10[_0x5d7193(0xb5)]==='logout'){await bt();return;}if(_0x5b3e10[_0x5d7193(0xb5)]==='whoami'){await vt(_0x5b3e10);return;}if(_0x5b3e10[_0x5d7193(0xb5)]===_0x5d7193(0x10d)){await $t(_0x5b3e10);return;}if(_0x5b3e10['subcommand']===_0x5d7193(0x21e)){await Rt(_0x5b3e10);return;}if(_0x5b3e10[_0x5d7193(0xb5)]==='sessions'){await xt(_0x5b3e10);return;}if(_0x5b3e10[_0x5d7193(0xb5)]===_0x5d7193(0x18d)){await Pt(_0x5b3e10);return;}if(_0x5b3e10['subcommand']==='evaluate'||_0x5b3e10['subcommand']===_0x5d7193(0x215)||_0x5b3e10[_0x5d7193(0xb5)]===_0x5d7193(0xec)){await Bt(_0x5b3e10,_0x5b3e10[_0x5d7193(0xb5)]);return;}if(_0x5b3e10[_0x5d7193(0xb5)]===_0x5d7193(0x1eb)){await qt(_0x5b3e10);return;}if(_0x5b3e10['subcommand']===_0x5d7193(0x1bd)){await Kt(_0x5b3e10);return;}if(_0x5b3e10[_0x5d7193(0xb5)]==='delegations'){await Vt(_0x5b3e10);return;}if(_0x5b3e10['subcommand']===_0x5d7193(0x158)){await Qt(_0x5b3e10);return;}if(_0x5b3e10[_0x5d7193(0xb5)]==='host'){await _0x2d42b7(_0x5b3e10[_0x5d7193(0x135)],{'runnerUrl':_0x5b3e10[_0x5d7193(0x16f)],'backendUrl':_0x5b3e10['backendUrl'],'interopPath':_0x5b3e10[_0x5d7193(0xb3)],'workerId':_0x5b3e10['workerId']});return;}if(_0x5b3e10[_0x5d7193(0x1be)]){await It();return;}await an(_0x5b3e10);}function _0x4e66(_0x4cd481,_0x2f36f5){_0x4cd481=_0x4cd481-0xad;const _0x394f4d=_0x394f();let _0x4e6648=_0x394f4d[_0x4cd481];return _0x4e6648;}var pn=process.env.NODE_ENV==='test'||!!process.env.JEST_WORKER_ID;pn||un()[_0x4b2408(0x24f)](_0x5369cd=>{const _0x5f3b50=_0x4b2408;console[_0x5f3b50(0x236)](_0x5369cd['stack']||_0x5369cd['message']||_0x5369cd),process['exit'](0x1);});export{mt as CARTOGRAPHER_SKILLS,G as EFFORT_TIERS,yt as IMPLICIT_STDIN_IDLE_MS,Z as buildInitOptions,un as main,ft as parseArgs,wt as readCliVersion,I as resolvePrompt,gt as routeStdoutToStderr,l as writeCommandResult};
|
|
2
|
+
const _0x948c2c=_0x5e9d;(function(_0x2f202d,_0x2076a4){const _0xfba727=_0x5e9d,_0x6df8ec=_0x2f202d();while(!![]){try{const _0x563771=-parseInt(_0xfba727(0x20b))/0x1*(parseInt(_0xfba727(0x273))/0x2)+parseInt(_0xfba727(0x2b0))/0x3*(parseInt(_0xfba727(0x166))/0x4)+-parseInt(_0xfba727(0x120))/0x5+-parseInt(_0xfba727(0x1ba))/0x6*(parseInt(_0xfba727(0x19a))/0x7)+parseInt(_0xfba727(0x151))/0x8+parseInt(_0xfba727(0x20a))/0x9*(-parseInt(_0xfba727(0x22a))/0xa)+parseInt(_0xfba727(0x1fc))/0xb*(parseInt(_0xfba727(0x2ad))/0xc);if(_0x563771===_0x2076a4)break;else _0x6df8ec['push'](_0x6df8ec['shift']());}catch(_0x3942cc){_0x6df8ec['push'](_0x6df8ec['shift']());}}}(_0x438c,0x3eec4));const __dirname=import.meta.dirname;import _0x427e63 from'fs';import _0x136063 from'path';import{clearLine as _0x4010f6,createInterface as _0x43407f,cursorTo as _0x351761}from'node:readline';import{BUSINESS_ANALYSIS_PRELOADED_SKILLS as _0x199573,DelegateAgent as _0x446aa7,cancelTurn as _0x50e18e,InteropProcess as _0x452f17,complete as _0x583340,DEFAULT_MODEL as _0x411ef5,createBackendClient as _0x4c1d59,evaluate as _0x8028c0,isCompletionRequestError as _0x5e5d61,isEvaluationRequestError as _0x585955,isTranscriptionError as _0xa0da4c,rerank as _0x173b6d,transcribe as _0x33942f,verify as _0x11f6ba,acceptDelegation as _0xa2cd30,cancelDelegation as _0x3665d1,claimDelegation as _0x1c4b43,completeDelegation as _0x3632c4,createDelegation as _0x173f47,deleteDelegation as _0x54d810,dismissDelegation as _0x4e2bf1,getSessionDelegations as _0x15eeb2,isDelegationError as _0x182df3,listDelegations as _0x884af4,listOrgUsers as _0x2d41f6,previewDelegation as _0x421ecf,TurnResultCollector as _0x359719,agentEventToJsonLine as _0x3b2f15,describeBaseUrlRejection as _0x47b633,getActivitySummary as _0x197dd7,getAuthFilePath as _0xc9575c,getByoWarnings as _0x431307,getCartographerAllowance as _0x2ecc96,getDailyBreakdown as _0x2145a0,getLicensingSummary as _0x1a745f,getMonthlySpending as _0x110395,isOutputFormat as _0x5086b7,isCloudBaseUrl as _0x3ae5b9,isSafeProjectFolderSegment as _0x3e9f33,listModels as _0x38a78a,listSessions as _0x505b20,getSession as _0x442ab5,renameSession as _0x1a37de,deleteSession as _0x3e4eb4,deleteSessionTaskLog as _0x30384a,forkSession as _0x27dcaf,isBackendRequestError as _0x231d62,MAX_SESSION_PAGE_SIZE as _0x5e8e2d,listTenants as _0x4463c6,loadAndRefreshAuth as _0x58ece6,loadAndRefreshSdkLogin as _0x2448a0,parsePlatformBaseUrl as _0x557d0b,resolveBackendUrl as _0x580975,runHealthCheck as _0x1953b4,runHostCommand as _0x91bae4,runLoginFlow as _0x25e401,runTurnForResult as _0x52b99b,saveAuthData as _0x4ac4e5,switchTenant as _0x4fe918,toJsonLine as _0x936d44,ENV_TO_CLOUD as _0x112dd5,OUTPUT_FORMATS as _0x454fb9}from'@uipath/delegate-sdk';var mt=[_0x948c2c(0x126),'tenant',_0x948c2c(0x27b),_0x948c2c(0x13b),'logout','whoami',_0x948c2c(0x2aa),_0x948c2c(0x17e),_0x948c2c(0x17d),_0x948c2c(0x124),'rerank','verify',_0x948c2c(0x210),_0x948c2c(0x277),_0x948c2c(0x23a),'org-users'],W=['','models',_0x948c2c(0x1bd),_0x948c2c(0x2aa),_0x948c2c(0x17e),_0x948c2c(0x17d),_0x948c2c(0x124),_0x948c2c(0x2c7),_0x948c2c(0x2cf),_0x948c2c(0x210),_0x948c2c(0x277),'delegations',_0x948c2c(0x271)],G=[_0x948c2c(0x194),_0x948c2c(0x16c),_0x948c2c(0x26c),'xhigh',_0x948c2c(0x1ea)],ft=_0x199573;function _0x5e9d(_0x374233,_0x1d89af){_0x374233=_0x374233-0x10f;const _0x438c94=_0x438c();let _0x5e9d0a=_0x438c94[_0x374233];return _0x5e9d0a;}function p(_0xc20549,_0x4a04c2,_0xdbc912,_0x21911e){const _0x5485cd=_0x948c2c;let _0x13db46=_0xc20549[_0x4a04c2];return(!_0x13db46||_0x13db46[_0x5485cd(0x22b)]>0x1&&_0x13db46['startsWith']('-'))&&(console['error'](_0xdbc912+_0x5485cd(0x28b)+_0x21911e+'.'),process[_0x5485cd(0x1ad)](0x2)),_0x13db46;}function N(_0xb1a15a,_0x103f51,_0x880581,_0x2eec62){const _0x4584ef=_0x948c2c;let _0x3f3803=p(_0xb1a15a,_0x103f51,_0x880581,'a\x20number'),_0x1a3f4e=Number(_0x3f3803);return(!/^\d+$/[_0x4584ef(0x1c6)](_0x3f3803)||_0x1a3f4e<0x1||!Number[_0x4584ef(0x13f)](_0x1a3f4e)||_0x2eec62!==void 0x0&&_0x1a3f4e>_0x2eec62)&&(console[_0x4584ef(0x2b6)](_0x880581+_0x4584ef(0x142)+(_0x2eec62===void 0x0?'1\x20or\x20more':'from\x201\x20to\x20'+_0x2eec62)+',\x20got\x20'+_0x3f3803+'.'),process['exit'](0x2)),_0x1a3f4e;}function ht(_0x5d63f9){const _0x16201d=_0x948c2c;let _0x2332d1={'subcommand':'','prompt':'','print':!0x1,'keepAlive':!0x1,'cleanup':!0x1,'headless':!0x1,'noComputerUse':!0x1,'cartographer':!0x1,'noConnections':!0x1,'noSecurity':!0x1,'noMemory':!0x1,'taskAutomation':!0x1,'quiet':!0x1,'verbose':!0x1,'outputFormat':_0x16201d(0x1bc),'preloadSkills':[],'attachments':[],'skipEnvCheck':!0x1,'includeSubAgents':!0x1,'operands':[],'help':!0x1,'version':!0x1};mt[_0x16201d(0x1eb)](_0x5d63f9[0x0])&&(_0x2332d1[_0x16201d(0x1c4)]=_0x5d63f9[0x0],_0x5d63f9=_0x5d63f9[_0x16201d(0x175)](0x1));let _0x458806=[];for(let _0x27304a=0x0;_0x27304a<_0x5d63f9[_0x16201d(0x22b)];_0x27304a++){let _0x3e36a3=_0x5d63f9[_0x27304a];switch(_0x3e36a3){case _0x16201d(0x297):case'-p':_0x2332d1[_0x16201d(0x1f5)]=!0x0;break;case _0x16201d(0x138):_0x2332d1['keepAlive']=!0x0;break;case _0x16201d(0x12a):_0x2332d1[_0x16201d(0x1a3)]=!0x0;break;case _0x16201d(0x19d):_0x2332d1[_0x16201d(0x21d)]=!0x0;break;case _0x16201d(0x2d1):_0x2332d1[_0x16201d(0x265)]=!0x0;break;case _0x16201d(0x199):_0x2332d1[_0x16201d(0x1c1)]=!0x0,_0x2332d1['noComputerUse']=!0x0,_0x2332d1[_0x16201d(0x228)][_0x16201d(0x114)](...ft);break;case _0x16201d(0x12f):_0x2332d1[_0x16201d(0x1f9)]=!0x0;break;case _0x16201d(0x23f):_0x2332d1[_0x16201d(0x253)]=!0x0;break;case'--no-memory':_0x2332d1[_0x16201d(0x1d8)]=!0x0;break;case _0x16201d(0x2ba):_0x2332d1[_0x16201d(0x227)]=!0x0;break;case'--quiet':case'-q':_0x2332d1[_0x16201d(0x2c9)]=!0x0;break;case _0x16201d(0x14f):_0x2332d1['verbose']=!0x0;break;case'--backend':_0x2332d1[_0x16201d(0x1b2)]=_0x5d63f9[++_0x27304a];break;case _0x16201d(0x217):_0x2332d1[_0x16201d(0x14d)]=_0x5d63f9[++_0x27304a];break;case'--runner-url':_0x2332d1[_0x16201d(0x1a4)]=_0x5d63f9[++_0x27304a];break;case _0x16201d(0x1ab):_0x2332d1[_0x16201d(0x1b7)]=_0x5d63f9[++_0x27304a];break;case _0x16201d(0x1fa):_0x2332d1[_0x16201d(0x195)]=_0x5d63f9[++_0x27304a];break;case _0x16201d(0x2c4):_0x2332d1[_0x16201d(0x228)][_0x16201d(0x114)](p(_0x5d63f9,++_0x27304a,_0x3e36a3,_0x16201d(0x278)));break;case _0x16201d(0x29e):{let _0x5548fe=p(_0x5d63f9,++_0x27304a,_0x3e36a3,_0x16201d(0x146));_0x3e9f33(_0x5548fe)||(console['error']('Invalid\x20--project:\x20\x22'+_0x5548fe+_0x16201d(0x285)),process['exit'](0x2)),_0x2332d1[_0x16201d(0x1fd)]=_0x5548fe;break;}case _0x16201d(0x181):{let _0x1e48a6=p(_0x5d63f9,++_0x27304a,_0x3e36a3,_0x16201d(0x193)+_0x454fb9[_0x16201d(0x172)](_0x16201d(0x1e1))+')');_0x5086b7(_0x1e48a6)||(console[_0x16201d(0x2b6)](_0x16201d(0x1a9)+_0x1e48a6+'.\x20Use\x20'+_0x454fb9['join'](_0x16201d(0x1e1))+'.'),process[_0x16201d(0x1ad)](0x2)),_0x2332d1[_0x16201d(0x1c3)]=_0x1e48a6;break;}case _0x16201d(0x204):_0x2332d1[_0x16201d(0x18e)]=p(_0x5d63f9,++_0x27304a,_0x3e36a3,_0x16201d(0x2b5));break;case _0x16201d(0x13e):_0x2332d1[_0x16201d(0x1cc)]=N(_0x5d63f9,++_0x27304a,_0x3e36a3);break;case _0x16201d(0x159):_0x2332d1[_0x16201d(0x240)]=N(_0x5d63f9,++_0x27304a,_0x3e36a3,_0x5e8e2d);break;case _0x16201d(0x2d2):_0x2332d1[_0x16201d(0x243)]=!0x0;break;case _0x16201d(0x144):_0x2332d1[_0x16201d(0x29b)]=p(_0x5d63f9,++_0x27304a,_0x3e36a3,_0x16201d(0x21f));break;case _0x16201d(0x1a6):{let _0x310a34=_0x136063['resolve'](process[_0x16201d(0x139)](),p(_0x5d63f9,++_0x27304a,_0x3e36a3,_0x16201d(0x1b1)));_0x427e63[_0x16201d(0x116)](_0x310a34)||(console[_0x16201d(0x2b6)]('--attach:\x20no\x20such\x20file\x20or\x20folder:\x20'+_0x310a34),process[_0x16201d(0x1ad)](0x2)),_0x2332d1['attachments']['push'](_0x310a34);break;}case _0x16201d(0x1e2):_0x2332d1[_0x16201d(0x1c2)]=p(_0x5d63f9,++_0x27304a,_0x3e36a3,_0x16201d(0x251));break;case _0x16201d(0x280):_0x2332d1[_0x16201d(0x1e7)]=p(_0x5d63f9,++_0x27304a,_0x3e36a3,_0x16201d(0x205));break;case _0x16201d(0x291):_0x2332d1['contextSummary']=p(_0x5d63f9,++_0x27304a,_0x3e36a3,_0x16201d(0x15f));break;case _0x16201d(0x207):_0x2332d1[_0x16201d(0x17b)]=N(_0x5d63f9,++_0x27304a,_0x3e36a3,0x16d);break;case _0x16201d(0x12d):_0x2332d1[_0x16201d(0x24c)]=_0x136063[_0x16201d(0x1d1)](process['cwd'](),p(_0x5d63f9,++_0x27304a,_0x3e36a3,_0x16201d(0x2cd)));break;case _0x16201d(0x1cf):_0x2332d1[_0x16201d(0x173)]=_0x136063[_0x16201d(0x1d1)](process[_0x16201d(0x139)](),p(_0x5d63f9,++_0x27304a,_0x3e36a3,_0x16201d(0x2cd)));break;case'--effort':{let _0x25e2c6=p(_0x5d63f9,++_0x27304a,_0x3e36a3,_0x16201d(0x149));G[_0x16201d(0x1eb)](_0x25e2c6)||(console[_0x16201d(0x2b6)](_0x16201d(0x14b)+_0x25e2c6+_0x16201d(0x2a9)+G['join'](_0x16201d(0x1e1))+'.'),process['exit'](0x2)),_0x2332d1['effort']=_0x25e2c6;break;}case _0x16201d(0x218):{let _0x1ac905=_0x5d63f9[++_0x27304a];(!_0x1ac905||_0x1ac905[_0x16201d(0x1e4)]('--'))&&(console[_0x16201d(0x2b6)]('--tenant\x20requires\x20a\x20tenant\x20name.'),process[_0x16201d(0x1ad)](0x2)),_0x2332d1['tenant']=_0x1ac905;break;}case _0x16201d(0x1a0):{let _0xb444ac=_0x5d63f9[++_0x27304a];[_0x16201d(0x119),_0x16201d(0x213),_0x16201d(0x29d),_0x16201d(0x275)]['includes'](_0xb444ac)||(console[_0x16201d(0x2b6)](_0x16201d(0x281)+_0xb444ac+'.\x20Use\x20alpha\x20|\x20staging\x20|\x20production\x20|\x20localhost.'),process['exit'](0x2)),_0x2332d1[_0x16201d(0x276)]=_0xb444ac;break;}case'--url':case _0x16201d(0x27c):{let _0x410898=p(_0x5d63f9,++_0x27304a,_0x3e36a3,_0x16201d(0x222)),_0x466a0d=_0x557d0b(_0x410898);if(_0x466a0d['ok']===!0x1){console[_0x16201d(0x2b6)](_0x47b633(_0x410898,_0x466a0d[_0x16201d(0x189)])),process['exit'](0x2);break;}_0x2332d1['url']=_0x466a0d['baseUrl'];break;}case _0x16201d(0x15a):_0x2332d1[_0x16201d(0x236)]=!0x0;break;case'-h':case _0x16201d(0x290):_0x2332d1[_0x16201d(0x254)]=!0x0;break;case'-v':case'--version':_0x2332d1[_0x16201d(0x19b)]=!0x0;break;default:_0x3e36a3[_0x16201d(0x1e4)]('--')&&(console[_0x16201d(0x2b6)](_0x16201d(0x15d)+_0x3e36a3),process['exit'](0x2)),_0x458806['push'](_0x3e36a3);}}return _0x2332d1['tenant']!==void 0x0&&_0x2332d1[_0x16201d(0x1c4)]!==_0x16201d(0x126)&&(console[_0x16201d(0x2b6)](_0x16201d(0x1cb)),process['exit'](0x2)),_0x2332d1[_0x16201d(0x2a7)]!==void 0x0&&_0x2332d1['env']!==void 0x0&&(console[_0x16201d(0x2b6)]('Pass\x20either\x20--env\x20(a\x20named\x20cloud)\x20or\x20--url\x20(any\x20other\x20deployment),\x20not\x20both.'),process['exit'](0x2)),_0x2332d1[_0x16201d(0x2a7)]!==void 0x0&&_0x2332d1[_0x16201d(0x1c4)]!=='login'&&(console[_0x16201d(0x2b6)](_0x16201d(0x206)),process[_0x16201d(0x1ad)](0x2)),_0x2332d1[_0x16201d(0x17b)]!==void 0x0&&_0x2332d1[_0x16201d(0x1c4)]!==_0x16201d(0x17d)&&(console[_0x16201d(0x2b6)](_0x16201d(0x15b)),process[_0x16201d(0x1ad)](0x2)),_0x2332d1['jsonSchemaPath']!==void 0x0&&(_0x2332d1[_0x16201d(0x1c4)]!=='complete'&&_0x2332d1[_0x16201d(0x1c4)]!==''||_0x2332d1[_0x16201d(0x1a3)])&&(console[_0x16201d(0x2b6)]('--json-schema\x20applies\x20to\x20prompts\x20and\x20to\x20`delegate-cli\x20complete`\x20only.'),process[_0x16201d(0x1ad)](0x2)),_0x2332d1[_0x16201d(0x242)][_0x16201d(0x22b)]>0x0&&(_0x2332d1[_0x16201d(0x1c4)]!==''||_0x2332d1[_0x16201d(0x1a3)])&&(console['error'](_0x16201d(0x1ff)),process[_0x16201d(0x1ad)](0x2)),_0x2332d1[_0x16201d(0x227)]&&(_0x2332d1[_0x16201d(0x1c4)]!==''||_0x2332d1[_0x16201d(0x1a3)])&&(console[_0x16201d(0x2b6)](_0x16201d(0x26b)),process[_0x16201d(0x1ad)](0x2)),_0x2332d1[_0x16201d(0x227)]&&(_0x2332d1[_0x16201d(0x21d)]||_0x2332d1[_0x16201d(0x265)])&&(console[_0x16201d(0x2b6)]('--task-automation\x20needs\x20computer\x20use:\x20the\x20task\x20log\x20is\x20written\x20by\x20the\x20UI-automation\x20tools.\x20Drop\x20--headless,\x20--no-computer-use\x20and\x20--cartographer.'),process['exit'](0x2)),_0x2332d1[_0x16201d(0x236)]&&_0x2332d1[_0x16201d(0x1c4)]!=='login'&&(console['error'](_0x16201d(0x25c)),process[_0x16201d(0x1ad)](0x2)),_0x2332d1['outputFormat']!==_0x16201d(0x1bc)&&!W[_0x16201d(0x1eb)](_0x2332d1['subcommand'])&&(console['error']('--output-format\x20'+_0x2332d1[_0x16201d(0x1c3)]+_0x16201d(0x219)+W[_0x16201d(0x127)](Boolean)[_0x16201d(0x172)](',\x20')+'.'),process[_0x16201d(0x1ad)](0x2)),(_0x2332d1[_0x16201d(0x1cc)]!==void 0x0||_0x2332d1['limit']!==void 0x0||_0x2332d1['includeSubAgents'])&&_0x2332d1[_0x16201d(0x1c4)]!==_0x16201d(0x17e)&&(console['error'](_0x16201d(0x298)),process[_0x16201d(0x1ad)](0x2)),(_0x2332d1[_0x16201d(0x1e7)]!==void 0x0||_0x2332d1[_0x16201d(0x1fe)]!==void 0x0)&&_0x2332d1[_0x16201d(0x1c4)]!==_0x16201d(0x23a)&&(console['error']('--to\x20and\x20--summary\x20apply\x20to\x20`delegate-cli\x20delegations\x20create`\x20only.'),process[_0x16201d(0x1ad)](0x2)),_0x2332d1[_0x16201d(0x1c2)]!==void 0x0&&_0x2332d1[_0x16201d(0x1c4)]!==_0x16201d(0x17e)&&(console[_0x16201d(0x2b6)](_0x16201d(0x188)),process['exit'](0x2)),_0x2332d1[_0x16201d(0x228)]=[...new Set(_0x2332d1[_0x16201d(0x228)])],_0x2332d1[_0x16201d(0x183)]=_0x458806,_0x2332d1[_0x16201d(0x153)]=_0x458806[_0x16201d(0x172)]('\x20'),_0x2332d1;}var S=_0x66e8e7=>{const _0x250735=_0x948c2c;process[_0x250735(0x1f2)][_0x250735(0x268)](_0x66e8e7);};function gt(){const _0x3acd5f=_0x948c2c;let _0x426533=process[_0x3acd5f(0x1f2)][_0x3acd5f(0x268)],_0x527a4e=_0x426533[_0x3acd5f(0x1a8)](process['stdout']),_0x4451f5=S;return S=_0x274f70=>{_0x527a4e(_0x274f70);},process[_0x3acd5f(0x1f2)][_0x3acd5f(0x268)]=(..._0x41173a)=>process[_0x3acd5f(0x2d0)][_0x3acd5f(0x268)](..._0x41173a),()=>{const _0x444bad=_0x3acd5f;process[_0x444bad(0x1f2)][_0x444bad(0x268)]=_0x426533,S=_0x4451f5;};}function l(_0x550ff7,_0x13e9e6,_0x5208df){const _0xa0ca2d=_0x948c2c;if(_0x550ff7[_0xa0ca2d(0x1c3)]==='text'){_0x5208df(_0x13e9e6);return;}S(_0x936d44(_0x13e9e6));}function wt(){const _0x3cb13d=_0x948c2c;let _0x2a107e=_0x3cb13d(0x226)[_0x3cb13d(0x2d7)]();console[_0x3cb13d(0x167)](_0x2a107e);}function yt(){const _0xb6ee31=_0x948c2c;try{return JSON[_0xb6ee31(0x1d7)](_0x427e63[_0xb6ee31(0x137)](_0x136063[_0xb6ee31(0x172)](__dirname,'..',_0xb6ee31(0x1f7)),_0xb6ee31(0x26e)))[_0xb6ee31(0x19b)]||_0xb6ee31(0x215);}catch{return _0xb6ee31(0x215);}}var kt=0x7d0;async function K(_0x4be116,_0x2ac686){const _0x19c208=_0x948c2c;let _0x4d0c9e=_0x2ac686?[_0x2ac686]:[];for await(let _0x191f50 of _0x4be116)_0x4d0c9e[_0x19c208(0x114)](Buffer[_0x19c208(0x22c)](_0x191f50));return Buffer[_0x19c208(0x203)](_0x4d0c9e)['toString'](_0x19c208(0x26e))[_0x19c208(0x2d7)]();}function St(_0x327649,_0x1bab70){return new Promise(_0x130667=>{const _0x12d505=_0x5e9d;let _0x231909=_0x36a3e4=>{const _0x4b03b3=_0x5e9d;clearTimeout(_0x300445),_0x327649[_0x4b03b3(0x143)](_0x4b03b3(0x145),_0x1630ec),_0x327649[_0x4b03b3(0x143)](_0x4b03b3(0x190),_0x240599),_0x327649[_0x4b03b3(0x143)](_0x4b03b3(0x2b6),_0x240599),_0x327649[_0x4b03b3(0x134)](),_0x130667(_0x36a3e4);},_0x1630ec=_0xc8870d=>_0x231909(Buffer[_0x12d505(0x22c)](_0xc8870d)),_0x240599=()=>_0x231909(null),_0x300445=setTimeout(()=>_0x231909(null),_0x1bab70);_0x327649['on']('data',_0x1630ec),_0x327649['on'](_0x12d505(0x190),_0x240599),_0x327649['on'](_0x12d505(0x2b6),_0x240599),_0x327649['resume']();});}async function I(_0xe6d5f8,_0x58841a,_0x4ca95f=kt){const _0x2b0628=_0x948c2c;let _0x1baed4=_0xe6d5f8==='-';if(!_0x1baed4&&_0xe6d5f8)return _0xe6d5f8;if(!_0x1baed4&&_0x58841a[_0x2b0628(0x2a0)])return'';if(_0x1baed4)return K(_0x58841a,null);let _0x447763=await St(_0x58841a,_0x4ca95f);return _0x447763?K(_0x58841a,_0x447763):'';}function L(){const _0x531563=_0x948c2c;return _0x136063['join'](process.env.HOME||process.env.USERPROFILE||'',_0x531563(0x29f),_0x531563(0x28d));}function $(_0x40b172){const _0x163faf=_0x948c2c;try{let _0x711ba7=JSON['parse'](_0x427e63[_0x163faf(0x137)](_0x40b172,_0x163faf(0x26e)));return!_0x711ba7[_0x163faf(0x133)]||!_0x711ba7['tenantId']||!_0x711ba7['organizationId']?null:_0x711ba7;}catch{return null;}}function bt(){const _0x50d2c6=_0x948c2c;let _0x23f3e1=[{'file':_0xc9575c(),'isDesktopFallback':!0x1},{'file':L(),'isDesktopFallback':!0x0}];for(let _0x1f35df of _0x23f3e1){let _0x27c9a1=$(_0x1f35df[_0x50d2c6(0x18f)]);if(_0x27c9a1)return{..._0x1f35df,'auth':_0x27c9a1};}return null;}async function vt(){const _0x11d301=_0x948c2c;let _0x5675b2=_0xc9575c();if(!_0x427e63[_0x11d301(0x116)](_0x5675b2)){let _0x3a8397=L();console[_0x11d301(0x167)]($(_0x3a8397)?_0x11d301(0x244)+_0x3a8397+'\x20—\x20sign\x20out\x20in\x20the\x20Delegate\x20app\x20to\x20clear\x20that.':_0x11d301(0x1ae));return;}_0x427e63['rmSync'](_0x5675b2),console[_0x11d301(0x167)](_0x11d301(0x163)+_0x5675b2);}async function At(_0x5d3c13){const _0x53ae1a=_0x948c2c;let _0x18a196=O(),_0x47bf4e,_0x1eba2c;if(_0x18a196)_0x47bf4e=_0x18a196,_0x1eba2c='environment\x20variables\x20(AUTH_TOKEN/TENANT_ID/ORG_ID)';else{let _0x504845=bt();if(!_0x504845)throw new Error(le);_0x47bf4e=_0x504845[_0x53ae1a(0x16b)],_0x1eba2c=_0x504845[_0x53ae1a(0x24f)]?_0x504845[_0x53ae1a(0x18f)]+_0x53ae1a(0x141):_0x504845['file'];}let _0x3d2389={'source':_0x1eba2c,'baseUrl':_0x47bf4e[_0x53ae1a(0x125)]??null,'deployment':Et(_0x47bf4e[_0x53ae1a(0x125)]),'organization':{'id':_0x47bf4e['organizationId'],'slug':_0x47bf4e[_0x53ae1a(0x11b)]??null},'tenant':{'id':_0x47bf4e['tenantId'],'name':_0x47bf4e['tenantName']??null},'tokenExpiresAt':_0x47bf4e[_0x53ae1a(0x1ee)]?new Date(_0x47bf4e[_0x53ae1a(0x1ee)]*0x3e8)[_0x53ae1a(0x1f8)]():null};l(_0x5d3c13,_0x3d2389,()=>{const _0x333648=_0x53ae1a;let _0x43c6cc=[_0x333648(0x2a2)+_0x1eba2c,_0x333648(0x2af)+(_0x47bf4e[_0x333648(0x125)]??_0x333648(0x215)),_0x333648(0x28e)+_0x3d2389['deployment'],_0x333648(0x2ae)+(_0x47bf4e['orgLogicalName']??'unknown\x20slug')+'\x20('+_0x47bf4e['organizationId']+')','Tenant:\x20\x20\x20\x20\x20\x20\x20'+(_0x47bf4e['tenantName']??_0x333648(0x21e))+'\x20('+_0x47bf4e[_0x333648(0x1bf)]+')'];if(_0x47bf4e[_0x333648(0x1ee)]){let _0x29a9fe=_0x47bf4e[_0x333648(0x1ee)]-Math[_0x333648(0x23c)](Date[_0x333648(0x260)]()/0x3e8);_0x43c6cc[_0x333648(0x114)](_0x29a9fe>0x0?_0x333648(0x152)+_0x3d2389[_0x333648(0x15c)]+_0x333648(0x2b3)+Math[_0x333648(0x24d)](_0x29a9fe/0x3c)+'\x20min)':_0x333648(0x214)+_0x3d2389[_0x333648(0x15c)]);}process[_0x333648(0x1f2)]['write'](_0x43c6cc[_0x333648(0x172)]('\x0a')+'\x0a');});}var le='No\x20auth\x20found.\x20Set\x20AUTH_TOKEN\x20(or\x20AUTH_TOKEN_FILE)/TENANT_ID/ORG_ID\x20env\x20vars,\x20or\x20run\x20`delegate-cli\x20login\x20--env\x20<alpha|staging|production>`\x20(or\x20`--url\x20<deployment-url>`\x20for\x20Automation\x20Suite)\x20first.';function Et(_0x1c8dfb){const _0x56e8a0=_0x948c2c;return _0x1c8dfb?_0x3ae5b9(_0x1c8dfb)?_0x56e8a0(0x299):_0x56e8a0(0x25d):_0x56e8a0(0x215);}function O(){let _0x29daf9=process.env.AUTH_TOKEN_FILE;return(process.env.AUTH_TOKEN||_0x29daf9)&&process.env.TENANT_ID&&process.env.ORG_ID?{'accessToken':_0x29daf9?It(_0x29daf9):process.env.AUTH_TOKEN,..._0x29daf9?{'accessTokenFile':_0x29daf9}:{},'tenantId':process.env.TENANT_ID,'organizationId':process.env.ORG_ID,'orgLogicalName':process.env.ORG_SLUG,'tenantName':process.env.TENANT_SLUG,'baseUrl':ce()}:null;}function It(_0x354c0a){const _0x4c2b56=_0x948c2c;let _0x2eada6;try{_0x2eada6=_0x427e63['readFileSync'](_0x354c0a,_0x4c2b56(0x26e))['trim']();}catch(_0x5957ff){throw new Error(_0x4c2b56(0x1e6)+_0x354c0a+_0x4c2b56(0x29a)+_0x5957ff[_0x4c2b56(0x1db)]);}let _0x14392e=_0x2eada6['startsWith'](_0x4c2b56(0x123))?_0x2eada6[_0x4c2b56(0x175)](0x7)[_0x4c2b56(0x2d7)]():_0x2eada6;if(!_0x14392e)throw new Error(_0x4c2b56(0x1e6)+_0x354c0a+_0x4c2b56(0x1c0));return _0x14392e;}function ce(){const _0x4b67be=_0x948c2c;let _0x1e99a6=process.env.UIPATH_BASE_URL;if(!_0x1e99a6)return;let _0x406053=_0x557d0b(_0x1e99a6);if(_0x406053['ok']===!0x1)throw new Error(_0x4b67be(0x197)+_0x47b633(_0x1e99a6,_0x406053[_0x4b67be(0x189)]));return _0x406053[_0x4b67be(0x125)];}async function P(){let _0x365f4d=O();if(_0x365f4d)return _0x365f4d;let _0x3a1a56=await _0x58ece6();if(_0x3a1a56)return _0x3a1a56;throw new Error(le);}async function $t(){const _0x2be932=_0x948c2c;await new _0x452f17()[_0x2be932(0x2be)]({'force':!0x0}),console[_0x2be932(0x167)](_0x2be932(0x237));}function F(_0x38f277,_0x4cc66a,_0xea39ed){const _0x4ae6c5=_0x948c2c;_0x38f277?process[_0x4ae6c5(0x2d0)][_0x4ae6c5(0x268)](_0x4ae6c5(0x2cc)+_0x38f277+_0x4ae6c5(0x1c8)+_0xea39ed+'\x0a'):!_0x4cc66a&&!process.env.BACKEND_URL&&process[_0x4ae6c5(0x2d0)][_0x4ae6c5(0x268)](_0x4ae6c5(0x224)+_0xea39ed+'\x0a');}async function f(_0x28dd21){const _0x296d52=_0x948c2c;let _0x13935d=await P(),_0xa59f=_0x580975(_0x28dd21['env'],_0x13935d,_0x28dd21[_0x296d52(0x1b2)]);return F(_0x28dd21[_0x296d52(0x276)],_0x28dd21[_0x296d52(0x1b2)],_0xa59f),{'auth':_0x13935d,'backendUrl':_0xa59f,'client':_0x4c1d59({'auth':_0x13935d,'backendUrl':_0xa59f})};}async function Tt(_0x1f0f12){const _0xc5f7a3=_0x948c2c;let {client:_0x35ed7f}=await f(_0x1f0f12),[_0x71ab72,_0x4bbcf9]=await Promise[_0xc5f7a3(0x27a)]([_0x38a78a(_0x35ed7f),_0x431307(_0x35ed7f)[_0xc5f7a3(0x25f)](_0xd852dc=>(process['stderr'][_0xc5f7a3(0x268)](_0xc5f7a3(0x154)+(_0xd852dc instanceof Error?_0xd852dc[_0xc5f7a3(0x1db)]:String(_0xd852dc))+'\x0a'),{}))]),_0x503756=_0x71ab72['map'](_0x1fe761=>_0x4bbcf9[_0x1fe761['id']]?{..._0x1fe761,'byoWarning':_0x4bbcf9[_0x1fe761['id']]}:_0x1fe761);l(_0x1f0f12,_0x503756,xt);}function xt(_0xe55cb9){const _0x38343c=_0x948c2c;if(_0xe55cb9[_0x38343c(0x22b)]===0x0){process[_0x38343c(0x2d0)][_0x38343c(0x268)]('No\x20models\x20available\x20for\x20this\x20product/tenant.\x0a');return;}process[_0x38343c(0x1f2)]['write'](_0x38343c(0x231)+_0xe55cb9['length']+_0x38343c(0x272));for(let _0x4df05e of _0xe55cb9){let _0x16779c=_0x4df05e[_0x38343c(0x17c)]&&_0x4df05e[_0x38343c(0x17c)]!==_0x4df05e['id']?'\x20('+_0x4df05e['name']+')':'';process[_0x38343c(0x1f2)][_0x38343c(0x268)]('\x20\x20'+_0x4df05e['id']+_0x16779c+'\x0a'),_0x4df05e['description']&&process[_0x38343c(0x1f2)][_0x38343c(0x268)](_0x38343c(0x2a3)+_0x4df05e[_0x38343c(0x1cd)]+'\x0a'),_0x4df05e['locked']&&process[_0x38343c(0x1f2)][_0x38343c(0x268)]('\x20\x20\x20\x20Not\x20available\x20on\x20this\x20plan'+(_0x4df05e['lockReason']?'\x20('+_0x4df05e[_0x38343c(0x129)]+')':'')+'\x0a'),_0x4df05e[_0x38343c(0x19e)]&&process[_0x38343c(0x1f2)]['write'](_0x38343c(0x223)+_0x4df05e['byoWarning']+'\x0a');}process[_0x38343c(0x1f2)][_0x38343c(0x268)]('\x0aUse\x20with:\x20delegate-cli\x20--model\x20<id>\x20\x22<prompt>\x22\x0a');}var z=['list','show',_0x948c2c(0x2c1),_0x948c2c(0x174),_0x948c2c(0x11f),_0x948c2c(0x1da)];async function Dt(_0x973262){const _0x4beda3=_0x948c2c;let [_0xff5c64='',_0x398017='',..._0x335912]=_0x973262[_0x4beda3(0x183)];if(_0xff5c64&&!z[_0x4beda3(0x1eb)](_0xff5c64)&&(console[_0x4beda3(0x2b6)](_0x4beda3(0x255)+_0xff5c64+'.\x20Use:\x20'+z[_0x4beda3(0x172)](_0x4beda3(0x1e1))+'.'),process['exit'](0x2)),_0x973262[_0x4beda3(0x1c2)]!==void 0x0&&_0xff5c64!==_0x4beda3(0x11f)&&(console[_0x4beda3(0x2b6)](_0x4beda3(0x188)),process[_0x4beda3(0x1ad)](0x2)),_0xff5c64&&_0xff5c64!==_0x4beda3(0x2ac)){await Ut(_0x973262,_0xff5c64,_0x398017,_0x335912[_0x4beda3(0x172)]('\x20')[_0x4beda3(0x2d7)]());return;}_0x973262['operands']['length']>0x1&&(console[_0x4beda3(0x2b6)](_0x4beda3(0x220)),process[_0x4beda3(0x1ad)](0x2));let {client:_0x22733b}=await f(_0x973262),_0x128829=await _0x505b20(_0x22733b,{'page':_0x973262[_0x4beda3(0x1cc)],'pageSize':_0x973262[_0x4beda3(0x240)],'includeSubAgents':_0x973262[_0x4beda3(0x243)]});l(_0x973262,_0x128829,Rt);}async function Ut(_0x12853b,_0xe45f4c,_0x302aa6,_0x27ce1d){const _0x2b8cb9=_0x948c2c;if((_0x12853b[_0x2b8cb9(0x1cc)]!==void 0x0||_0x12853b['limit']!==void 0x0||_0x12853b['includeSubAgents'])&&(console['error']('--page,\x20--limit\x20and\x20--include-subagents\x20apply\x20to\x20`delegate-cli\x20sessions\x20[list]`\x20only.'),process[_0x2b8cb9(0x1ad)](0x2)),_0xe45f4c===_0x2b8cb9(0x11f)){await Nt(_0x12853b,_0x302aa6,_0x27ce1d);return;}if(_0xe45f4c===_0x2b8cb9(0x1da)){await Ct(_0x12853b,_0x302aa6,_0x27ce1d);return;}(!_0x302aa6||_0xe45f4c===_0x2b8cb9(0x2c1)!=!!_0x27ce1d)&&(console['error'](_0x2b8cb9(0x2d5)+_0xe45f4c+_0x2b8cb9(0x29c)+(_0xe45f4c===_0x2b8cb9(0x2c1)?_0x2b8cb9(0x16f):'')),process[_0x2b8cb9(0x1ad)](0x2));let {client:_0x144804}=await f(_0x12853b);try{if(_0xe45f4c===_0x2b8cb9(0x1e5)){let _0x4709f6=await _0x442ab5(_0x144804,_0x302aa6);_0x4709f6||V(_0x302aa6),l(_0x12853b,_0x4709f6,_t);}else{if(_0xe45f4c==='rename'){let _0x326319=await _0x1a37de(_0x144804,_0x302aa6,_0x27ce1d);l(_0x12853b,_0x326319,_0x425936=>{const _0x4b0463=_0x2b8cb9;process[_0x4b0463(0x1f2)][_0x4b0463(0x268)](_0x4b0463(0x279)+_0x425936['id']+':\x20'+_0x425936['title']+'\x0a');});}else await _0x3e4eb4(_0x144804,_0x302aa6),await _0x30384a(_0x302aa6,_0x12853b[_0x2b8cb9(0x24c)]),l(_0x12853b,{'id':_0x302aa6,'deleted':!0x0},_0x5dd741=>{const _0x22c630=_0x2b8cb9;process[_0x22c630(0x1f2)][_0x22c630(0x268)](_0x22c630(0x1f4)+_0x5dd741['id']+'.\x0a');});}}catch(_0x35ecd8){if(!_0x231d62(_0x35ecd8,0x194))throw _0x35ecd8;V(_0x302aa6);}}function V(_0x415fb5){const _0x6152d3=_0x948c2c;console['error'](_0x6152d3(0x26d)+_0x415fb5+'\x20not\x20found.'),process[_0x6152d3(0x1ad)](0x1);}function _t(_0x217da9){const _0x4c4a30=_0x948c2c;process[_0x4c4a30(0x1f2)][_0x4c4a30(0x268)]('ID\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+_0x217da9['id']+'\x0a'),process[_0x4c4a30(0x1f2)][_0x4c4a30(0x268)](_0x4c4a30(0x200)+_0x217da9[_0x4c4a30(0x161)]+'\x0a'),process[_0x4c4a30(0x1f2)][_0x4c4a30(0x268)](_0x4c4a30(0x1d4)+_0x217da9[_0x4c4a30(0x289)]+'\x0a'),process[_0x4c4a30(0x1f2)]['write'](_0x4c4a30(0x296)+_0x217da9[_0x4c4a30(0x198)]+'\x0a'),_0x217da9['delegationId']&&process[_0x4c4a30(0x1f2)][_0x4c4a30(0x268)](_0x4c4a30(0x2d8)+_0x217da9[_0x4c4a30(0x238)]+'\x0a');}async function Nt(_0x5d5be0,_0x1b3f11,_0x4d4cee){const _0x10a26a=_0x948c2c;(!_0x1b3f11||_0x4d4cee||!_0x5d5be0[_0x10a26a(0x1c2)])&&(console[_0x10a26a(0x2b6)](_0x10a26a(0x24a)),process[_0x10a26a(0x1ad)](0x2));let {client:_0x43880f}=await f(_0x5d5be0),_0x133d37=await _0x50e18e(_0x43880f,_0x1b3f11,_0x5d5be0[_0x10a26a(0x1c2)]);l(_0x5d5be0,{'sessionId':_0x1b3f11,'turnId':_0x5d5be0[_0x10a26a(0x1c2)],'cancelled':_0x133d37},_0x59fc8b=>{const _0x2b6747=_0x10a26a;_0x59fc8b[_0x2b6747(0x12e)]?process[_0x2b6747(0x1f2)][_0x2b6747(0x268)](_0x2b6747(0x150)+_0x59fc8b[_0x2b6747(0x1c2)]+'\x20of\x20session\x20'+_0x59fc8b['sessionId']+'.\x0a'):process['stderr'][_0x2b6747(0x268)]('No\x20turn\x20'+_0x59fc8b[_0x2b6747(0x1c2)]+_0x2b6747(0x111)+_0x59fc8b[_0x2b6747(0x18e)]+'.\x0a');}),_0x133d37||(process[_0x10a26a(0x18d)]=0x1);}async function Ct(_0x5b7af0,_0x118c28,_0x58afec){const _0x48456b=_0x948c2c;(!_0x118c28||/\s/[_0x48456b(0x1c6)](_0x58afec))&&(console[_0x48456b(0x2b6)](_0x48456b(0x19f)),process[_0x48456b(0x1ad)](0x2));let {client:_0x5c891c}=await f(_0x5b7af0),_0x51e3f1;try{_0x51e3f1=await _0x27dcaf(_0x5c891c,_0x118c28,{'atMessageId':_0x58afec||void 0x0});}catch(_0x3c33cb){if(!_0x231d62(_0x3c33cb,0x194))throw _0x3c33cb;console[_0x48456b(0x2b6)](_0x48456b(0x26d)+_0x118c28+_0x48456b(0x1f1)+(_0x58afec?_0x48456b(0x130)+_0x58afec:'')+'.'),process['exit'](0x1);}l(_0x5b7af0,_0x51e3f1,_0x4071fb=>{const _0x4d6f71=_0x48456b;process[_0x4d6f71(0x1f2)]['write']('Forked\x20'+_0x118c28+'\x20into\x20'+_0x4071fb['id']+'.\x0a'),process[_0x4d6f71(0x2d0)]['write'](_0x4d6f71(0x165)+_0x4071fb['id']+_0x4d6f71(0x1a1));});}function Rt({sessions:_0xdaa3f1,page:_0x39f045,isLastPage:_0x4ea642}){const _0x5039ce=_0x948c2c;if(_0xdaa3f1[_0x5039ce(0x22b)]===0x0)process[_0x5039ce(0x2d0)][_0x5039ce(0x268)](_0x5039ce(0x118)+_0x39f045+'.\x0a');else{process[_0x5039ce(0x1f2)][_0x5039ce(0x268)]('ID'[_0x5039ce(0x1aa)](0x24)+'\x20\x20'+_0x5039ce(0x18a)['padEnd'](0x13)+'\x20\x20TITLE\x0a');for(let _0x2d411e of _0xdaa3f1){let _0x301fc3=_0x2d411e[_0x5039ce(0x1c5)][_0x5039ce(0x1b5)]('T','\x20')['slice'](0x0,0x13),_0x7738e2=_0x2d411e[_0x5039ce(0x20c)]?'\x20\x20(sub-agent\x20of\x20'+_0x2d411e[_0x5039ce(0x20c)]+')':'';process[_0x5039ce(0x1f2)][_0x5039ce(0x268)](_0x2d411e['id']['padEnd'](0x24)+'\x20\x20'+_0x301fc3['padEnd'](0x13)+'\x20\x20'+_0x2d411e['title']+_0x7738e2+'\x0a');}}_0x4ea642||process['stderr']['write']('More:\x20delegate-cli\x20sessions\x20--page\x20'+(_0x39f045+0x1)+'\x0a');}async function Lt(_0x53e934){const _0xdaff0=_0x948c2c;let _0x2a875c=await P(),_0x7cf8de=_0x580975(_0x53e934[_0xdaff0(0x276)],_0x2a875c,_0x53e934[_0xdaff0(0x1b2)]);F(_0x53e934[_0xdaff0(0x276)],_0x53e934[_0xdaff0(0x1b2)],_0x7cf8de);let _0x10c622=await _0x1953b4({'auth':_0x2a875c,'backendUrl':_0x7cf8de,'interop':_0x53e934[_0xdaff0(0x21d)]?'skip':_0xdaff0(0x201)});l(_0x53e934,_0x10c622,({checks:_0x519da3})=>{const _0x217680=_0xdaff0;for(let _0x53ca4e of _0x519da3)process[_0x217680(0x1f2)][_0x217680(0x268)](Ot(_0x53ca4e)+'\x0a');}),_0x10c622['ok']||process[_0xdaff0(0x1ad)](0x1);}function Ot(_0x1421cf){const _0x37d148=_0x948c2c;return{'ok':'✓','failed':'✗','skipped':'-'}[_0x1421cf['status']]+'\x20'+_0x1421cf[_0x37d148(0x17c)][_0x37d148(0x1aa)](0xa)+_0x1421cf['detail'];}var Pt=['',_0x948c2c(0x232),_0x948c2c(0x216)];async function Ft(_0x42a862){const _0x2c7e5c=_0x948c2c;let _0x273d7f=_0x42a862[_0x2c7e5c(0x153)];Pt[_0x2c7e5c(0x1eb)](_0x273d7f)||(console[_0x2c7e5c(0x2b6)](_0x2c7e5c(0x27e)+_0x42a862[_0x2c7e5c(0x153)]+_0x2c7e5c(0x1de)),process['exit'](0x2)),_0x273d7f===''&&_0x42a862[_0x2c7e5c(0x17b)]!==void 0x0&&(console[_0x2c7e5c(0x2b6)]('--days\x20applies\x20to\x20`delegate-cli\x20usage\x20activity|daily`;\x20the\x20summary\x20covers\x20the\x20current\x20month.'),process[_0x2c7e5c(0x1ad)](0x2)),_0x273d7f!==''&&_0x42a862['sessionId']!==void 0x0&&(console['error'](_0x2c7e5c(0x230)),process[_0x2c7e5c(0x1ad)](0x2));let {client:_0x1d8745}=await f(_0x42a862);if(_0x273d7f===_0x2c7e5c(0x232)){l(_0x42a862,await _0x197dd7(_0x1d8745,{'days':_0x42a862[_0x2c7e5c(0x17b)]}),Mt);return;}if(_0x273d7f===_0x2c7e5c(0x216)){l(_0x42a862,await _0x2145a0(_0x1d8745,{'days':_0x42a862[_0x2c7e5c(0x17b)]}),Bt);return;}let [_0x229bb7,_0x56c437,_0x15b6a5]=await Promise[_0x2c7e5c(0x27a)]([_0x1a745f(_0x1d8745,{'sessionId':_0x42a862[_0x2c7e5c(0x18e)]}),_0x110395(_0x1d8745),_0x2ecc96(_0x1d8745)]);l(_0x42a862,{'licensing':_0x229bb7,'monthlySpending':_0x56c437,'cartographerAllowance':_0x15b6a5},jt);}function jt(_0x46ffff){const _0x147d75=_0x948c2c;let {licensing:_0x362b6d,monthlySpending:_0x263e06,cartographerAllowance:_0x49c41a}=_0x46ffff,_0x4d1026=[_0x362b6d['limit_enabled']?_0x147d75(0x269)+_0x362b6d[_0x147d75(0x110)][_0x147d75(0x1ca)](0x1)+_0x147d75(0x294)+(_0x362b6d[_0x147d75(0x264)]??0x0)+_0x147d75(0x11c)+(_0x362b6d[_0x147d75(0x184)]>0x0?',\x20'+_0x362b6d[_0x147d75(0x184)]+_0x147d75(0x16d):'')+_0x147d75(0x16a)+_0x362b6d[_0x147d75(0x2c6)]+')':'Licensing:\x20\x20\x20\x20no\x20licensing\x20quota\x20applies',_0x147d75(0x286)+_0x263e06['monthly_spend_usd']['toFixed'](0x2)+_0x147d75(0x1c9)+(_0x263e06[_0x147d75(0x28a)]&&_0x263e06['monthly_limit_usd']!==null?_0x147d75(0x187)+_0x263e06[_0x147d75(0x186)][_0x147d75(0x1ca)](0x2)+_0x147d75(0x252):_0x147d75(0x1e9)),_0x147d75(0x1d9)+_0x49c41a[_0x147d75(0x15e)]+'\x20('+_0x49c41a[_0x147d75(0x1b6)]+')'];_0x362b6d[_0x147d75(0x1e3)]!==null&&_0x362b6d[_0x147d75(0x1e3)]!==void 0x0&&_0x4d1026['push'](_0x147d75(0x262)+_0x362b6d[_0x147d75(0x1e3)]+_0x147d75(0x132)),process['stdout'][_0x147d75(0x268)](_0x4d1026[_0x147d75(0x172)]('\x0a')+'\x0a');}function Mt(_0x349674){const _0x105ef4=_0x948c2c;let _0x18562f=[_0x105ef4(0x148)+_0x349674[_0x105ef4(0x2a6)]+_0x105ef4(0x2ab)+_0x349674[_0x105ef4(0x211)]+_0x105ef4(0x1fb)+_0x349674[_0x105ef4(0x2d6)]+_0x105ef4(0x292),_0x105ef4(0x176)+_0x349674[_0x105ef4(0x131)][_0x105ef4(0x1ca)](0x2)+_0x105ef4(0x2c5)+_0x349674[_0x105ef4(0x2c8)][_0x105ef4(0x1ca)](0x2)+_0x105ef4(0x11e)+_0x349674['total_token_units']+_0x105ef4(0x1dd),_0x105ef4(0x25b)+_0x349674['total_prompt_tokens']+_0x105ef4(0x14e)+_0x349674['total_completion_tokens']+_0x105ef4(0x22d)];for(let [_0x3fc07e,_0x229506]of Object[_0x105ef4(0x1d0)](_0x349674[_0x105ef4(0x1e8)]))_0x18562f[_0x105ef4(0x114)]('\x20\x20'+_0x3fc07e+':\x20'+_0x229506+_0x105ef4(0x2bb));process[_0x105ef4(0x1f2)][_0x105ef4(0x268)](_0x18562f[_0x105ef4(0x172)]('\x0a')+'\x0a');}function Bt(_0x3d3e64){const _0x2ff176=_0x948c2c;if(_0x3d3e64[_0x2ff176(0x1b8)]['length']===0x0){process[_0x2ff176(0x1f2)][_0x2ff176(0x268)](_0x2ff176(0x239)+_0x3d3e64[_0x2ff176(0x2a6)]+_0x2ff176(0x13c));return;}let _0x141c6f=[_0x2ff176(0x209)];for(let _0x35fecd of _0x3d3e64['daily_usage'])_0x141c6f['push'](_0x35fecd['date']+'\x20\x20'+String(_0x35fecd[_0x2ff176(0x1d2)])[_0x2ff176(0x2bf)](0xb)+'\x20\x20'+String(_0x35fecd[_0x2ff176(0x2ca)])[_0x2ff176(0x2bf)](0xd)+'\x20\x20'+String(_0x35fecd[_0x2ff176(0x1ef)])[_0x2ff176(0x2bf)](0x11));process[_0x2ff176(0x1f2)][_0x2ff176(0x268)](_0x141c6f[_0x2ff176(0x172)]('\x0a')+'\x0a');}async function Ht(_0x599810,_0x3dda11){const _0x30e4d0=_0x948c2c;let _0x4bfea1=await qt(_0x599810[_0x30e4d0(0x153)],_0x3dda11);_0x599810[_0x30e4d0(0x14d)]&&(_0x4bfea1[_0x30e4d0(0x14d)]=_0x599810['model']);let {client:_0x434300}=await f(_0x599810);try{_0x3dda11===_0x30e4d0(0x124)?l(_0x599810,await _0x8028c0(_0x434300,_0x4bfea1,void 0x0),Wt):_0x3dda11===_0x30e4d0(0x2c7)?l(_0x599810,await _0x173b6d(_0x434300,_0x4bfea1,void 0x0),Gt):l(_0x599810,await _0x11f6ba(_0x434300,_0x4bfea1,void 0x0),Kt);}catch(_0x5d3be2){if(!_0x585955(_0x5d3be2))throw _0x5d3be2;console[_0x30e4d0(0x2b6)](_0x5d3be2[_0x30e4d0(0x1db)]),process['exit'](0x1);}}async function qt(_0x48ff25,_0x49df1d){const _0x243a8b=_0x948c2c;let _0x391104;try{_0x391104=_0x48ff25&&_0x48ff25!=='-'?_0x427e63[_0x243a8b(0x137)](_0x136063[_0x243a8b(0x1d1)](_0x48ff25),_0x243a8b(0x26e)):await I(_0x48ff25,process[_0x243a8b(0x26a)]);}catch(_0x24d80a){console['error'](_0x49df1d+_0x243a8b(0x112)+_0x24d80a[_0x243a8b(0x1db)]+').'),process[_0x243a8b(0x1ad)](0x2);}return _0x391104||(console[_0x243a8b(0x2b6)](_0x49df1d+_0x243a8b(0x23b)+_0x49df1d+_0x243a8b(0x25a)),process['exit'](0x2)),de(_0x391104,_0x49df1d,_0x243a8b(0x2d4));}function de(_0x439310,_0x5d95b1,_0x603afa){const _0x3f59b0=_0x948c2c;let _0x3f9b99;try{_0x3f9b99=JSON['parse'](_0x439310);}catch(_0x46e314){console['error'](_0x5d95b1+':\x20'+_0x603afa+_0x3f59b0(0x169)+_0x46e314[_0x3f59b0(0x1db)]+').'),process['exit'](0x2);}return(typeof _0x3f9b99!='object'||_0x3f9b99===null||Array[_0x3f59b0(0x20d)](_0x3f9b99))&&(console[_0x3f59b0(0x2b6)](_0x5d95b1+':\x20'+_0x603afa+_0x3f59b0(0x1be)),process[_0x3f59b0(0x1ad)](0x2)),_0x3f9b99;}function ue(_0x34b192,_0x57dd81){const _0x53ba0e=_0x948c2c;let _0x149c1f;try{_0x149c1f=_0x427e63[_0x53ba0e(0x137)](_0x136063[_0x53ba0e(0x1d1)](_0x34b192),'utf-8');}catch(_0x8c8872){console[_0x53ba0e(0x2b6)](_0x57dd81+_0x53ba0e(0x2b2)+_0x8c8872[_0x53ba0e(0x1db)]+').'),process['exit'](0x2);}return de(_0x149c1f,_0x57dd81,'the\x20JSON\x20schema');}async function Jt(_0x25f319){const _0x5e61c1=_0x948c2c;_0x25f319[_0x5e61c1(0x29b)]===void 0x0&&(console[_0x5e61c1(0x2b6)](_0x5e61c1(0x2a5)),process[_0x5e61c1(0x1ad)](0x2));let _0x1f47fa=ue(_0x25f319[_0x5e61c1(0x29b)],_0x5e61c1(0x210)),_0x443e0d=(await I(_0x25f319[_0x5e61c1(0x153)],process[_0x5e61c1(0x26a)]))['trim']();_0x443e0d||(console[_0x5e61c1(0x2b6)]('complete\x20needs\x20a\x20prompt:\x20delegate-cli\x20complete\x20--json-schema\x20schema.json\x20\x22<prompt>\x22,\x20or\x20-\x20to\x20read\x20stdin.'),process[_0x5e61c1(0x1ad)](0x2));let {client:_0x1410aa}=await f(_0x25f319);try{let _0x2cb3e2=await _0x583340(_0x1410aa,{'prompt':_0x443e0d,'jsonSchema':_0x1f47fa,'model':_0x25f319['model']||process.env.MODEL||_0x411ef5,..._0x25f319['sessionId']!==void 0x0&&{'sessionId':_0x25f319['sessionId']}},void 0x0);l(_0x25f319,_0x2cb3e2,_0x3fa1be=>{const _0x573838=_0x5e61c1;process['stdout'][_0x573838(0x268)](JSON[_0x573838(0x21b)](_0x3fa1be['structured'],null,0x2)+'\x0a');});}catch(_0x15e221){if(!_0x5e5d61(_0x15e221))throw _0x15e221;console[_0x5e61c1(0x2b6)](_0x15e221[_0x5e61c1(0x1db)]),process['exit'](0x1);}}function j(_0x28901b){const _0x504ee5=_0x948c2c;process[_0x504ee5(0x1f2)]['write']('Model\x20'+_0x28901b[_0x504ee5(0x14d)]+'\x20('+_0x28901b['model_version']+'),\x20'+_0x28901b['usage']['total_tokens']+_0x504ee5(0x170));}function Wt(_0x32ec24){const _0x32a67c=_0x948c2c;j(_0x32ec24);for(let _0x27858f of Object['keys'](_0x32ec24[_0x32a67c(0x12b)])){let _0x4c1d82=_0x32ec24[_0x32a67c(0x12b)][_0x27858f],_0x50c695=_0x4c1d82[_0x32a67c(0x1f6)]===_0x32a67c(0x121)?_0x32a67c(0x1bb)+_0x4c1d82[_0x32a67c(0x121)][_0x32a67c(0x1ca)](0x2):_0x4c1d82[_0x32a67c(0x1f6)]===_0x32a67c(0x26f)?'choice\x20'+_0x4c1d82[_0x32a67c(0x26f)]+_0x32a67c(0x2c3)+_0x4c1d82[_0x32a67c(0x1d6)]['toFixed'](0x2)+')':_0x32a67c(0x1a2)+_0x4c1d82[_0x32a67c(0x12c)][_0x32a67c(0x1ca)](0x2)+'\x20(confidence\x20'+_0x4c1d82[_0x32a67c(0x1d6)][_0x32a67c(0x1ca)](0x2)+')';process[_0x32a67c(0x1f2)][_0x32a67c(0x268)]('\x20\x20'+_0x27858f+':\x20'+_0x50c695+'\x0a');}}function Gt(_0x9950e0){const _0x2846d5=_0x948c2c;j(_0x9950e0),_0x9950e0[_0x2846d5(0x274)]['forEach']((_0x449d14,_0x234792)=>{const _0x14c99d=_0x2846d5;process['stdout'][_0x14c99d(0x268)]('\x20\x20'+(_0x234792+0x1)+'.\x20'+_0x449d14['id']+'\x20\x20'+_0x449d14['score'][_0x14c99d(0x1ca)](0x3)+_0x14c99d(0x249)+_0x449d14[_0x14c99d(0x19c)]+')\x0a');});}function Kt(_0x41e7fd){const _0x1e6a78=_0x948c2c;j(_0x41e7fd),process[_0x1e6a78(0x1f2)][_0x1e6a78(0x268)](_0x1e6a78(0x185)+_0x41e7fd[_0x1e6a78(0x208)]+'\x0a');for(let _0x5ecc01 of _0x41e7fd['results'])process[_0x1e6a78(0x1f2)][_0x1e6a78(0x268)]('\x20\x20'+_0x5ecc01['id']+':\x20'+_0x5ecc01[_0x1e6a78(0x196)]+_0x1e6a78(0x2c3)+_0x5ecc01[_0x1e6a78(0x1d6)][_0x1e6a78(0x1ca)](0x2)+')\x0a');}async function zt(_0x566b42){const _0x43fd30=_0x948c2c;let _0x3295a2=_0x566b42[_0x43fd30(0x153)]['trim']();_0x3295a2||(console['error'](_0x43fd30(0x283)),process[_0x43fd30(0x1ad)](0x2));let {client:_0x8b08d2}=await f(_0x566b42);try{let _0x347cdd=_0x3295a2==='-'?{'data':await Vt(process[_0x43fd30(0x26a)])}:_0x3295a2;l(_0x566b42,await _0x33942f(_0x8b08d2,_0x347cdd,void 0x0),_0x1ddb7b=>{const _0x10dc58=_0x43fd30;process['stdout'][_0x10dc58(0x268)](_0x1ddb7b[_0x10dc58(0x1bc)]+'\x0a');});}catch(_0x1baf50){if(_0xa0da4c(_0x1baf50)&&(console['error'](_0x1baf50[_0x43fd30(0x1db)]),process['exit'](_0x1baf50['status']===void 0x0?0x2:0x1)),typeof _0x1baf50?.[_0x43fd30(0x27f)]!=_0x43fd30(0x20e))throw _0x1baf50;console[_0x43fd30(0x2b6)](_0x43fd30(0x179)+_0x3295a2+'\x20('+_0x1baf50['message']+').'),process[_0x43fd30(0x1ad)](0x2);}}async function Vt(_0x49679a){const _0x442cdd=_0x948c2c;let _0x35775b=[];for await(let _0x5b7a5e of _0x49679a)_0x35775b['push'](Buffer['from'](_0x5b7a5e));return Buffer[_0x442cdd(0x203)](_0x35775b);}var Y=['list','pending',_0x948c2c(0x1e5),_0x948c2c(0x267),_0x948c2c(0x256),'complete','accept',_0x948c2c(0x2b4),'cancel',_0x948c2c(0x174)],X={'list':_0x948c2c(0x1c7),'pending':_0x948c2c(0x1ed),'show':_0x948c2c(0x192),'create':_0x948c2c(0x21c),'claim':_0x948c2c(0x234),'complete':_0x948c2c(0x1f3),'accept':_0x948c2c(0x2b9),'dismiss':'delegations\x20dismiss\x20<delegation-id>','cancel':'delegations\x20cancel\x20<delegation-id>','delete':_0x948c2c(0x266)};async function Yt(_0x445197){const _0x3569ac=_0x948c2c;let [_0x5313f4='',_0x4f634e='',..._0x205c94]=_0x445197[_0x3569ac(0x183)];Y['includes'](_0x5313f4)||(console[_0x3569ac(0x2b6)]((_0x5313f4?_0x3569ac(0x2d3)+_0x5313f4+'.\x20':'')+_0x3569ac(0x1dc)+Y[_0x3569ac(0x172)](_0x3569ac(0x1e1))+'.'),process[_0x3569ac(0x1ad)](0x2));let _0x7a8797=_0x5313f4;_0x7a8797!==_0x3569ac(0x267)&&(_0x445197[_0x3569ac(0x1e7)]!==void 0x0||_0x445197[_0x3569ac(0x1fe)]!==void 0x0||_0x445197['sessionId']!==void 0x0)&&(console[_0x3569ac(0x2b6)]('--to,\x20--summary\x20and\x20--session\x20apply\x20to\x20`delegate-cli\x20delegations\x20create`\x20only.'),process[_0x3569ac(0x1ad)](0x2));let _0x27e81e=(_0x7a8797===_0x3569ac(0x267)?_0x445197['operands'][_0x3569ac(0x175)](0x1):_0x205c94)[_0x3569ac(0x172)]('\x20')[_0x3569ac(0x2d7)](),_0x34c331=_0x7a8797==='create'||_0x7a8797==='complete';(_0x7a8797!=='create'&&!_0x4f634e||(_0x34c331?!_0x27e81e:_0x27e81e)||_0x7a8797===_0x3569ac(0x267)&&!_0x445197[_0x3569ac(0x18e)])&&(console['error']('Usage:\x20delegate-cli\x20'+X[_0x7a8797]),process[_0x3569ac(0x1ad)](0x2));let _0x3d1d94=_0x34c331&&_0x27e81e==='-'?(await I('-',process[_0x3569ac(0x26a)]))[_0x3569ac(0x2d7)]():_0x27e81e;_0x34c331&&!_0x3d1d94&&(console[_0x3569ac(0x2b6)]('Usage:\x20delegate-cli\x20'+X[_0x7a8797]+_0x3569ac(0x168)),process[_0x3569ac(0x1ad)](0x2));let {client:_0x3505ce}=await f(_0x445197);try{await Xt(_0x445197,_0x3505ce,_0x7a8797,_0x4f634e,_0x3d1d94);}catch(_0x5784ed){if(!_0x182df3(_0x5784ed))throw _0x5784ed;console[_0x3569ac(0x2b6)](_0x5784ed[_0x3569ac(0x1db)]),process[_0x3569ac(0x1ad)](0x1);}}async function Xt(_0x29e20d,_0x4bbd85,_0x25ac9c,_0x4e3867,_0x2f462e){const _0x3e7e24=_0x948c2c;switch(_0x25ac9c){case _0x3e7e24(0x2ac):l(_0x29e20d,await _0x884af4(_0x4bbd85,_0x4e3867),Qt);return;case _0x3e7e24(0x1d3):l(_0x29e20d,await _0x15eeb2(_0x4bbd85,_0x4e3867),_0x33949a=>{const _0x57f5dd=_0x3e7e24;_0x33949a['delegation']&&process['stdout'][_0x57f5dd(0x268)](_0x57f5dd(0x2a1)+_0x33949a[_0x57f5dd(0x113)]['id']+'\x20('+_0x33949a['delegation'][_0x57f5dd(0x22f)]+_0x57f5dd(0x24b)),_0x33949a[_0x57f5dd(0x233)][_0x57f5dd(0x22b)]===0x0&&process[_0x57f5dd(0x2d0)][_0x57f5dd(0x268)]('No\x20answers\x20awaiting\x20acceptance.\x0a');for(let _0x212e05 of _0x33949a['pendingResults'])process[_0x57f5dd(0x1f2)][_0x57f5dd(0x268)]('\x0a'+_0x212e05['id']+'\x20\x20from\x20'+(_0x212e05[_0x57f5dd(0x1a7)]??_0x57f5dd(0x115))+'\x20\x20'+(_0x212e05[_0x57f5dd(0x128)]??'')+'\x0a'+(_0x212e05[_0x57f5dd(0x245)]?.[_0x57f5dd(0x2bd)]??'')+'\x0a');_0x33949a[_0x57f5dd(0x233)][_0x57f5dd(0x22b)]>0x0&&process[_0x57f5dd(0x2d0)]['write'](_0x57f5dd(0x164));});return;case _0x3e7e24(0x1e5):l(_0x29e20d,await _0x421ecf(_0x4bbd85,_0x4e3867),Q);return;case _0x3e7e24(0x267):{let _0x39669e=await _0x173f47(_0x4bbd85,{'sessionId':_0x29e20d[_0x3e7e24(0x18e)],'task':_0x2f462e,..._0x29e20d['contextSummary']!==void 0x0&&{'contextSummary':_0x29e20d['contextSummary']},..._0x29e20d[_0x3e7e24(0x1e7)]!==void 0x0&&{'recipient':_0x29e20d[_0x3e7e24(0x1e7)]}});l(_0x29e20d,_0x39669e,_0x286351=>{const _0x1bab1a=_0x3e7e24;_0x286351[_0x1bab1a(0x250)]?process[_0x1bab1a(0x1f2)][_0x1bab1a(0x268)](_0x1bab1a(0x1b0)+_0x286351[_0x1bab1a(0x238)]+_0x1bab1a(0x18b)+_0x286351[_0x1bab1a(0x250)]['displayName']+'\x20<'+_0x286351['assignedUser'][_0x1bab1a(0x1ec)]+_0x1bab1a(0x259)):process[_0x1bab1a(0x1f2)][_0x1bab1a(0x268)]('Created\x20delegation\x20'+_0x286351[_0x1bab1a(0x238)]+'.\x20Share:\x20'+_0x286351['deepLink']+'\x0a');});return;}case _0x3e7e24(0x256):{let _0x38b9e9=await _0x1c4b43(_0x4bbd85,_0x4e3867);l(_0x29e20d,_0x38b9e9,_0x2526b7=>{const _0x3b0720=_0x3e7e24;Q(_0x2526b7),process[_0x3b0720(0x1f2)][_0x3b0720(0x268)](_0x3b0720(0x1f0)+_0x2526b7['sessionId']+'\x0a'),process['stderr'][_0x3b0720(0x268)]('Work\x20on\x20it\x20with:\x20delegate-cli\x20--session\x20'+_0x2526b7['sessionId']+_0x3b0720(0x2a4)+_0x2526b7[_0x3b0720(0x238)]+_0x3b0720(0x21a));});return;}case _0x3e7e24(0x210):{let {alreadyCompleted:_0x305a57}=await _0x3632c4(_0x4bbd85,_0x4e3867,{'content':_0x2f462e});l(_0x29e20d,{'delegationId':_0x4e3867,'alreadyCompleted':_0x305a57},_0x6f4ac1=>{const _0x396b3f=_0x3e7e24;process['stdout']['write']((_0x6f4ac1[_0x396b3f(0x14c)]?_0x396b3f(0x1e0):'Answered')+_0x396b3f(0x1af)+_0x6f4ac1[_0x396b3f(0x238)]+'.\x0a');});return;}case _0x3e7e24(0x27d):{let _0x3f85e7=await _0xa2cd30(_0x4bbd85,_0x4e3867);l(_0x29e20d,{'delegationId':_0x4e3867,..._0x3f85e7},_0x3a6ddf=>{const _0x1b1a73=_0x3e7e24;process[_0x1b1a73(0x1f2)][_0x1b1a73(0x268)]((_0x3a6ddf[_0x1b1a73(0x140)]?'Already\x20accepted':_0x1b1a73(0x13a))+'\x20delegation\x20'+_0x3a6ddf[_0x1b1a73(0x238)]+'.\x0a');});return;}default:{let _0x4c5d1a={'dismiss':_0x4e2bf1,'cancel':_0x3665d1,'delete':_0x54d810}[_0x25ac9c];await _0x4c5d1a(_0x4bbd85,_0x4e3867);let _0x4253da={'dismiss':'dismissed','cancel':_0x3e7e24(0x12e),'delete':_0x3e7e24(0x157)}[_0x25ac9c];l(_0x29e20d,{'delegationId':_0x4e3867,[_0x4253da]:!0x0},()=>{const _0x4ab411=_0x3e7e24;process[_0x4ab411(0x1f2)][_0x4ab411(0x268)](''+_0x4253da[0x0][_0x4ab411(0x122)]()+_0x4253da[_0x4ab411(0x175)](0x1)+_0x4ab411(0x1af)+_0x4e3867+'.\x0a');});}}}function Qt(_0x284006){const _0x3725be=_0x948c2c;if(_0x284006[_0x3725be(0x22b)]===0x0){process['stderr'][_0x3725be(0x268)]('No\x20delegations.\x0a');return;}process['stdout'][_0x3725be(0x268)]('ID'[_0x3725be(0x1aa)](0x24)+'\x20\x20'+_0x3725be(0x16e)[_0x3725be(0x1aa)](0x9)+'\x20\x20'+_0x3725be(0x2c2)[_0x3725be(0x1aa)](0x18)+_0x3725be(0x10f));for(let _0x5ddb69 of _0x284006)process[_0x3725be(0x1f2)]['write'](_0x5ddb69['id'][_0x3725be(0x1aa)](0x24)+'\x20\x20'+_0x5ddb69[_0x3725be(0x22f)][_0x3725be(0x1aa)](0x9)+'\x20\x20'+(_0x5ddb69[_0x3725be(0x1a7)]??'-')[_0x3725be(0x1aa)](0x18)+'\x20\x20'+(_0x5ddb69[_0x3725be(0x128)]??'')+'\x0a');}function Q(_0x28613b){const _0x492f03=_0x948c2c;process[_0x492f03(0x1f2)]['write'](_0x492f03(0x2b8)+(_0x28613b[_0x492f03(0x1b4)]??'-')+'\x0a'),_0x28613b[_0x492f03(0x28c)]&&process[_0x492f03(0x1f2)]['write'](_0x492f03(0x1f0)+_0x28613b[_0x492f03(0x28c)]+'\x0a'),process[_0x492f03(0x1f2)][_0x492f03(0x268)]('Task\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+(_0x28613b[_0x492f03(0x128)]??'-')+'\x0a'),_0x28613b['contextSummary']&&process[_0x492f03(0x1f2)][_0x492f03(0x268)]('\x0a'+_0x28613b[_0x492f03(0x1fe)]+'\x0a\x0a');}async function Zt(_0x4b0261){const _0x321002=_0x948c2c;_0x4b0261[_0x321002(0x153)][_0x321002(0x2d7)]()||(console['error']('Usage:\x20delegate-cli\x20org-users\x20<name\x20or\x20email\x20prefix>'),process['exit'](0x2));let {client:_0x4b40c6}=await f(_0x4b0261),_0x44149c;try{_0x44149c=await _0x2d41f6(_0x4b40c6,_0x4b0261[_0x321002(0x153)]);}catch(_0x10c305){if(!_0x182df3(_0x10c305))throw _0x10c305;console['error'](_0x10c305[_0x321002(0x1db)]),process[_0x321002(0x1ad)](0x1);}l(_0x4b0261,_0x44149c,_0x5283f2=>{const _0x38e5d8=_0x321002;_0x5283f2['length']===0x0&&process[_0x38e5d8(0x2d0)][_0x38e5d8(0x268)]('No\x20one\x20matches\x20\x22'+_0x4b0261['prompt'][_0x38e5d8(0x2d7)]()+'\x22.\x0a');for(let _0x376237 of _0x5283f2)process[_0x38e5d8(0x1f2)][_0x38e5d8(0x268)](_0x376237[_0x38e5d8(0x1ec)]['padEnd'](0x20)+'\x20\x20'+_0x376237[_0x38e5d8(0x261)]+'\x0a');});}async function en(_0x2d67f7){const _0x5581c9=_0x948c2c;_0x2d67f7[_0x5581c9(0x276)]===_0x5581c9(0x275)&&(console[_0x5581c9(0x2b6)](_0x5581c9(0x2cb)),process['exit'](0x2));let _0x2e51a9=$(_0xc9575c()),_0xcf037d=_0x2d67f7[_0x5581c9(0x236)];if(_0x2d67f7[_0x5581c9(0x276)]){let _0x356758=_0x2d67f7[_0x5581c9(0x276)];await _0x25e401({'env':_0x356758,'tenant':_0x2d67f7[_0x5581c9(0x17a)]??C(_0x2e51a9,_0x112dd5[_0x356758]),'skipEnvCheck':_0xcf037d});return;}let _0x46af65=_0x2d67f7[_0x5581c9(0x2a7)]??ce();if(_0x46af65){await _0x25e401({'baseUrl':_0x46af65,'tenant':_0x2d67f7['tenant']??C(_0x2e51a9,_0x46af65),'skipEnvCheck':_0xcf037d});return;}if(_0x2e51a9?.[_0x5581c9(0x125)]){await _0x25e401({'baseUrl':_0x2e51a9[_0x5581c9(0x125)],'tenant':_0x2d67f7['tenant']??_0x2e51a9[_0x5581c9(0x284)],'skipEnvCheck':_0xcf037d});return;}console['error'](_0x5581c9(0x225)),process[_0x5581c9(0x1ad)](0x2);}function C(_0x4c1b10,_0x33e97a){const _0x938ff3=_0x948c2c;return _0x4c1b10?.['baseUrl']&&tn(_0x4c1b10[_0x938ff3(0x125)],_0x33e97a)?_0x4c1b10['tenantName']:void 0x0;}function tn(_0x10cfc7,_0xc0331d){const _0x1a0111=_0x948c2c;try{return new URL(_0x10cfc7)[_0x1a0111(0x171)]===new URL(_0xc0331d)['origin'];}catch{return!0x1;}}async function nn(_0x17ca8d){const _0x38edbb=_0x948c2c;O()&&(console['error'](_0x38edbb(0x22e)),process[_0x38edbb(0x1ad)](0x2));let _0x10eb61=await _0x2448a0();if(_0x10eb61||(console[_0x38edbb(0x2b6)](on()),process[_0x38edbb(0x1ad)](0x2)),_0x17ca8d[_0x38edbb(0x2d7)]()){let _0x23b1d8=await _0x4fe918(_0x10eb61,_0x17ca8d);_0x4ac4e5(_0x23b1d8)||(console[_0x38edbb(0x2b6)](_0x38edbb(0x147)+_0xc9575c()+_0x38edbb(0x17f)+_0x10eb61['tenantName']+'.'),process[_0x38edbb(0x1ad)](0x1)),console['log'](_0x38edbb(0x1ce)+_0x23b1d8[_0x38edbb(0x284)]+'\x20('+_0x23b1d8[_0x38edbb(0x1bf)]+_0x38edbb(0x25e)+_0xc9575c());return;}sn(await _0x4463c6(_0x10eb61),_0x10eb61);}function on(){const _0x25f928=_0x948c2c;if(_0x427e63[_0x25f928(0x116)](_0xc9575c()))return _0x25f928(0x191);let _0x22910d=L();return $(_0x22910d)?_0x25f928(0x248)+_0x22910d+_0x25f928(0x20f):'No\x20CLI\x20login\x20found.\x20Run\x20`delegate-cli\x20login\x20--env\x20<alpha|staging|production>`\x20first.';}function sn(_0x4c36ae,_0x5866b9){const _0x54655a=_0x948c2c;let _0x2548c4=_0x4c36ae[_0x54655a(0x1ac)](_0x1899ed=>_0x1899ed['id']===_0x5866b9[_0x54655a(0x1bf)]?'*\x20'+_0x1899ed[_0x54655a(0x17c)]+_0x54655a(0x241):'\x20\x20'+_0x1899ed[_0x54655a(0x17c)]);process['stdout'][_0x54655a(0x268)](_0x54655a(0x212)+(_0x5866b9['orgLogicalName']??_0x5866b9['organizationId'])+':\x0a'+_0x2548c4['join']('\x0a')+'\x0a'),_0x4c36ae[_0x54655a(0x22b)]>0x1&&process['stdout'][_0x54655a(0x268)]('Switch\x20with:\x20delegate-cli\x20tenant\x20<name>\x0a');}function rn(_0x575e94){const _0x3325da=_0x948c2c;return _0x575e94?.['response']?.['status']===0x191||/401/[_0x3325da(0x1c6)](String(_0x575e94?.['message']??''));}var d={'lastType':null,'quiet':!0x1},an=_0x1168e4=>{const _0x30847b=_0x948c2c;switch(_0x1168e4[_0x30847b(0x1f6)]){case _0x30847b(0x135):_0x1168e4[_0x30847b(0x18e)]&&_0x1168e4[_0x30847b(0x18e)]!==d[_0x30847b(0x18e)]&&(process['stderr'][_0x30847b(0x268)](_0x30847b(0x1b3)+_0x1168e4['sessionId']+_0x30847b(0x28f)+_0x1168e4[_0x30847b(0x18e)]+')\x0a'),d[_0x30847b(0x18e)]=_0x1168e4['sessionId']);break;case _0x30847b(0x180):_0x1168e4[_0x30847b(0x1c2)]&&_0x1168e4[_0x30847b(0x1c2)]!==d['turnId']&&(d[_0x30847b(0x2bc)]!==null&&process[_0x30847b(0x2d0)]['write']('\x0a'),process['stderr'][_0x30847b(0x268)](_0x30847b(0x1d5)+_0x1168e4[_0x30847b(0x1c2)]+_0x30847b(0x263)+_0x1168e4[_0x30847b(0x18e)]+_0x30847b(0x23d)+_0x1168e4[_0x30847b(0x1c2)]+')\x0a'),d[_0x30847b(0x1c2)]=_0x1168e4['turnId'],d[_0x30847b(0x2bc)]=_0x30847b(0x180));break;case _0x30847b(0x160):_0x1168e4[_0x30847b(0x2bd)]&&!d['quiet']&&(d['lastType']!==_0x30847b(0x160)&&process[_0x30847b(0x2d0)][_0x30847b(0x268)](_0x30847b(0x2ce)),process[_0x30847b(0x2d0)][_0x30847b(0x268)](_0x1168e4[_0x30847b(0x2bd)]),d[_0x30847b(0x2bc)]=_0x30847b(0x160));break;case'tool_call':d['lastType']!==null&&process[_0x30847b(0x2d0)]['write']('\x0a'),process['stderr'][_0x30847b(0x268)](_0x30847b(0x288)+(_0x1168e4[_0x30847b(0x235)]??_0x30847b(0x270))+'\x0a'),d[_0x30847b(0x2bc)]=_0x30847b(0x2b7);break;case _0x30847b(0x1db):_0x1168e4[_0x30847b(0x2bd)]&&(d['lastType']!==_0x30847b(0x1db)&&d[_0x30847b(0x2bc)]!==null&&process[_0x30847b(0x1f2)][_0x30847b(0x268)]('\x0a'),process[_0x30847b(0x1f2)][_0x30847b(0x268)](_0x1168e4['content']),d[_0x30847b(0x2bc)]=_0x30847b(0x1db));break;case _0x30847b(0x2b6):d[_0x30847b(0x2bc)]!==null&&process[_0x30847b(0x2d0)]['write']('\x0a'),process[_0x30847b(0x2d0)]['write']('✗\x20'+(_0x1168e4[_0x30847b(0x2b6)]??_0x30847b(0x2b6))+'\x0a'),d[_0x30847b(0x2bc)]=_0x30847b(0x2b6);break;case _0x30847b(0x117):(d[_0x30847b(0x2bc)]===_0x30847b(0x1db)||d[_0x30847b(0x2bc)]===_0x30847b(0x160))&&process[_0x30847b(0x1f2)][_0x30847b(0x268)]('\x0a'),process[_0x30847b(0x2d0)]['write'](_0x30847b(0x295)),d[_0x30847b(0x2bc)]=_0x30847b(0x117);break;}};function Z(_0x3f3816,_0xf37a1b,_0x5b9bd6){const _0x2217f1=_0x948c2c;let _0x236bbe=_0x3f3816[_0x2217f1(0x14d)]||process.env.MODEL;return{'backendUrl':_0x5b9bd6,'auth':_0xf37a1b,'enableComputerUse':!_0x3f3816[_0x2217f1(0x21d)]&&!_0x3f3816[_0x2217f1(0x265)],'autoSpawnInterop':!_0x3f3816[_0x2217f1(0x21d)],'enableConnections':!_0x3f3816[_0x2217f1(0x1f9)],'enableSecurity':!_0x3f3816['noSecurity'],'keepInteropAlive':_0x3f3816[_0x2217f1(0x155)],..._0x3f3816[_0x2217f1(0x1d8)]?{'enableMemory':!0x1}:{},..._0x3f3816[_0x2217f1(0x227)]?{'enableTaskAutomation':!0x0}:{},..._0x3f3816[_0x2217f1(0x228)]['length']>0x0?{'preloadSkills':_0x3f3816[_0x2217f1(0x228)]}:{},..._0x236bbe?{'model':_0x236bbe}:{},..._0x3f3816[_0x2217f1(0x1fd)]?{'projectId':_0x3f3816[_0x2217f1(0x1fd)]}:{},..._0x3f3816['workingDirectory']?{'workingDirectory':_0x3f3816[_0x2217f1(0x24c)]}:{},..._0x3f3816[_0x2217f1(0x173)]?{'bundledSkillsPath':_0x3f3816[_0x2217f1(0x173)]}:{},..._0x3f3816[_0x2217f1(0x221)]?{'effort':_0x3f3816[_0x2217f1(0x221)]}:{},..._0x3f3816[_0x2217f1(0x18e)]?{'sessionId':_0x3f3816[_0x2217f1(0x18e)]}:{},..._0x3f3816[_0x2217f1(0x2a8)]?{'verbose':!0x0}:{}};}async function ln(_0x449cc7){const _0x1cd3d6=_0x948c2c;let _0x300e0e=_0x449cc7[_0x1cd3d6(0x1c3)]!==_0x1cd3d6(0x1bc),_0x2103c0=_0x449cc7[_0x1cd3d6(0x29b)]===void 0x0?null:ue(_0x449cc7[_0x1cd3d6(0x29b)],_0x1cd3d6(0x257)),_0x5631f2=!_0x300e0e&&!_0x2103c0&&!_0x449cc7[_0x1cd3d6(0x1f5)]&&_0x449cc7[_0x1cd3d6(0x153)]!=='-'&&!!process['stdin'][_0x1cd3d6(0x2a0)]&&!!process[_0x1cd3d6(0x1f2)][_0x1cd3d6(0x2a0)],_0x39fb47=_0x5631f2?_0x449cc7[_0x1cd3d6(0x153)]['trim']():await I(_0x449cc7['prompt'],process[_0x1cd3d6(0x26a)]);if(!_0x5631f2&&!_0x39fb47&&(console[_0x1cd3d6(0x2b6)](_0x1cd3d6(0x229)),process[_0x1cd3d6(0x1ad)](0x2)),!_0x300e0e){await ee(_0x449cc7,_0x39fb47,_0x5631f2,null,_0x2103c0);return;}let _0x473538=!0x1,_0x3638ee=_0x46161d=>{const _0x9c7ae=_0x1cd3d6;_0x473538=!0x0,S(_0x936d44(_0x46161d)),(_0x46161d[_0x9c7ae(0x246)]||_0x46161d[_0x9c7ae(0x11d)])&&(process[_0x9c7ae(0x18d)]=0x1);},_0x310ad9=Date[_0x1cd3d6(0x260)]();try{await ee(_0x449cc7,_0x39fb47,!0x1,_0x3638ee,_0x2103c0);}catch(_0x477a0c){if(_0x473538)throw _0x477a0c;process[_0x1cd3d6(0x2d0)]['write']((_0x477a0c instanceof Error?_0x477a0c[_0x1cd3d6(0x158)]??_0x477a0c[_0x1cd3d6(0x1db)]:String(_0x477a0c))+'\x0a'),_0x3638ee(new _0x359719(_0x310ad9)[_0x1cd3d6(0x258)]({'endedAtMs':Date['now'](),'usage':[],'error':_0x477a0c}));}}async function ee(_0x30e5ff,_0x5f45e3,_0x2d1983,_0x216744,_0x22d1c6){const _0x1fa12c=_0x948c2c;d={'lastType':null,'quiet':_0x30e5ff[_0x1fa12c(0x2c9)]};let _0x305bbd=new Set(),_0x219f53=_0x114086=>{const _0x25773d=_0x1fa12c;(!_0x216744||_0x114086[_0x25773d(0x1f6)]===_0x25773d(0x135)||_0x114086[_0x25773d(0x1f6)]===_0x25773d(0x180))&&an(_0x114086);for(let _0x5bd862 of _0x305bbd)_0x5bd862(_0x114086);},_0x3fb158=await P(),_0x34ece0=new _0x446aa7();_0x34ece0[_0x1fa12c(0x287)](_0x219f53);let _0x39eeee=_0x580975(_0x30e5ff[_0x1fa12c(0x276)],_0x3fb158,_0x30e5ff['backendUrl']);F(_0x30e5ff[_0x1fa12c(0x276)],_0x30e5ff[_0x1fa12c(0x1b2)],_0x39eeee);let _0x5c6ec8=Z(_0x30e5ff,_0x3fb158,_0x39eeee),_0x36d339=!0x1,_0x59c9f9=!0x1,_0x10acf7,_0x47ac1d=()=>_0x10acf7??=_0x34ece0['destroy'](),_0x4b56b5=()=>{const _0x361850=_0x1fa12c;_0x59c9f9&&process['exit'](0x82),_0x59c9f9=!0x0,process['stderr'][_0x361850(0x268)](_0x361850(0x178)),_0x36d339&&_0x34ece0['cancel']()[_0x361850(0x25f)](_0x23c3b4=>console[_0x361850(0x2b6)](_0x23c3b4))[_0x361850(0x24e)](_0x47ac1d)[_0x361850(0x24e)](()=>process[_0x361850(0x1ad)](0x82),_0x2aa1e6=>{const _0x2b1d21=_0x361850;console[_0x2b1d21(0x2b6)](_0x2aa1e6),process[_0x2b1d21(0x1ad)](0x82);});};process['on']('SIGINT',_0x4b56b5);let _0x4e2640=_0x30e5ff[_0x1fa12c(0x242)],_0x5e6468=async _0x56ff67=>{const _0x278d09=_0x1fa12c;let _0x515094=_0x4e2640;_0x4e2640=[];let _0x3e35ae=()=>_0x34ece0[_0x278d09(0x177)](_0x56ff67,{'attachments':_0x515094});try{return await _0x3e35ae();}catch(_0x1a1802){if(_0x59c9f9||!rn(_0x1a1802)||!process[_0x278d09(0x26a)]['isTTY']||_0x30e5ff['env']===_0x278d09(0x275)||!(_0x30e5ff[_0x278d09(0x276)]||_0x3fb158[_0x278d09(0x125)]))throw _0x1a1802;process['stderr'][_0x278d09(0x268)](_0x278d09(0x202));let _0x35f7b8=_0x34ece0[_0x278d09(0x2c0)]()??_0x30e5ff[_0x278d09(0x18e)],_0x3e5855=await _0x25e401(_0x30e5ff[_0x278d09(0x276)]?{'env':_0x30e5ff['env'],'tenant':C(_0x3fb158,_0x112dd5[_0x30e5ff[_0x278d09(0x276)]]),'skipEnvCheck':!0x0}:{'baseUrl':_0x3fb158[_0x278d09(0x125)],'tenant':_0x3fb158['tenantName'],'skipEnvCheck':!0x0}),_0x34368d={'text':'','failed':!0x1,'sessionId':_0x35f7b8};return _0x59c9f9||(_0x36d339=!0x1,await _0x47ac1d(),_0x59c9f9)?_0x34368d:(_0x34ece0=new _0x446aa7(),_0x10acf7=void 0x0,_0x34ece0[_0x278d09(0x287)](_0x219f53),_0x3fb158=_0x3e5855,await _0x34ece0[_0x278d09(0x23e)]({...Z(_0x30e5ff,_0x3fb158,_0x39eeee),..._0x35f7b8?{'sessionId':_0x35f7b8}:{}}),_0x36d339=!0x0,_0x59c9f9?_0x34368d:_0x3e35ae());}};try{if(await _0x34ece0['initialize'](_0x5c6ec8),_0x36d339=!0x0,_0x59c9f9)return;if(_0x2d1983)await un({'prompt':_0x5f45e3,'sendMessage':_0x5e6468,'onSigint':_0x4b56b5});else{if(_0x216744||_0x22d1c6){let _0x5df755=_0x30e5ff[_0x1fa12c(0x1c3)]===_0x1fa12c(0x13d)?_0x34da87=>S(_0x3b2f15(_0x34da87)):()=>{},_0x55bf6b=await _0x52b99b({'onEvent':_0x2a212a=>(_0x305bbd[_0x1fa12c(0x136)](_0x2a212a),()=>{const _0x3c86d4=_0x1fa12c;_0x305bbd[_0x3c86d4(0x174)](_0x2a212a);}),'sendMessage':_0x3bca8d=>_0x5e6468(_0x3bca8d),'getSessionId':()=>_0x34ece0[_0x1fa12c(0x2c0)](),'getTurnUsageHistory':_0x441872=>_0x34ece0[_0x1fa12c(0x156)](_0x441872),'complete':_0x220de7=>_0x34ece0['complete'](_0x220de7)},_0x5f45e3,void 0x0,_0x5df755,_0x22d1c6?{'outputSchema':_0x22d1c6}:void 0x0);_0x216744?_0x216744(_0x55bf6b):cn(_0x55bf6b);}else await _0x5e6468(_0x5f45e3);}}catch(_0x502ac4){if(!_0x59c9f9)throw _0x502ac4;}finally{try{await _0x47ac1d();}finally{process[_0x1fa12c(0x143)](_0x1fa12c(0x1a5),_0x4b56b5),_0x59c9f9&&(process[_0x1fa12c(0x18d)]=0x82);}}}function cn(_0x496236){const _0x53ca81=_0x948c2c;_0x496236[_0x53ca81(0x11d)]?(console[_0x53ca81(0x2b6)](_0x53ca81(0x18c)+_0x496236[_0x53ca81(0x11d)][_0x53ca81(0x1db)]),process['exitCode']=0x1):_0x496236[_0x53ca81(0x246)]?(console[_0x53ca81(0x2b6)](_0x53ca81(0x1df)+_0x496236[_0x53ca81(0x2b6)]+').'),process[_0x53ca81(0x18d)]=0x1):process[_0x53ca81(0x1f2)][_0x53ca81(0x268)](JSON[_0x53ca81(0x21b)](_0x496236[_0x53ca81(0x1b9)],null,0x2)+'\x0a');}function dn(_0x56381a,_0x3996ef){const _0x234ce9=_0x948c2c;let _0x1d9570=process['stdout']['write'][_0x234ce9(0x1a8)](process[_0x234ce9(0x1f2)]),_0x38c579=!0x1;return process[_0x234ce9(0x1f2)][_0x234ce9(0x268)]=(..._0x4da1a2)=>{const _0x41865d=_0x234ce9;if(!_0x38c579)return _0x1d9570(..._0x4da1a2);_0x351761(_0x3996ef,0x0),_0x4010f6(_0x3996ef,0x0);let _0x1ac4ec=_0x1d9570(..._0x4da1a2);return _0x56381a[_0x41865d(0x153)](!0x0),_0x1ac4ec;},{'show':()=>{_0x38c579=!0x0,_0x56381a['prompt']();},'hide':()=>{_0x38c579=!0x1;},'restore':()=>{const _0x52d8ae=_0x234ce9;_0x38c579=!0x1,process[_0x52d8ae(0x1f2)][_0x52d8ae(0x268)]=_0x1d9570;}};}async function un({prompt:_0x508e0e,sendMessage:_0x337b80,onSigint:_0x28902c}){const _0x4d83f3=_0x948c2c;let _0x8adaa8=_0x43407f({'input':process['stdin'],'output':process[_0x4d83f3(0x2d0)],'terminal':!0x0,'prompt':'You>\x20'}),_0x43612f=dn(_0x8adaa8,process[_0x4d83f3(0x2d0)]),_0x1f32ab=_0x8adaa8[Symbol[_0x4d83f3(0x293)]](),_0x3c4221=!0x1;_0x8adaa8[_0x4d83f3(0x247)](_0x4d83f3(0x11a),()=>{const _0x5edbc5=_0x4d83f3;_0x3c4221=!0x0,_0x43612f[_0x5edbc5(0x2b1)]();});let _0xe8aeea=!0x1,_0x3a2f90=()=>{const _0x38a9ba=_0x4d83f3;_0xe8aeea=!0x0,_0x8adaa8[_0x38a9ba(0x11a)](),_0x28902c();};_0x8adaa8['on']('SIGINT',_0x3a2f90),process[_0x4d83f3(0x2d0)][_0x4d83f3(0x268)](_0x4d83f3(0x182));try{if(_0x508e0e&&await _0x337b80(_0x508e0e),_0xe8aeea)return;_0x3c4221||_0x43612f[_0x4d83f3(0x1e5)]();for await(let _0x389110 of _0x1f32ab){if(_0x43612f[_0x4d83f3(0x2b1)](),_0xe8aeea)break;let _0x2bf6eb=_0x389110[_0x4d83f3(0x2d7)]();if(_0x2bf6eb===_0x4d83f3(0x14a))break;_0x2bf6eb&&await _0x337b80(_0x2bf6eb),_0x3c4221||_0x43612f[_0x4d83f3(0x1e5)]();}}finally{_0x43612f[_0x4d83f3(0x162)](),_0x8adaa8[_0x4d83f3(0x143)]('SIGINT',_0x3a2f90),_0x8adaa8[_0x4d83f3(0x11a)]();}}function _0x438c(){const _0xda4cea=['\x20\x22<prompt>\x22\x0a','score\x20','cleanup','runnerUrl','SIGINT','--attach','assignedUserEmail','bind','Invalid\x20--output-format:\x20','padEnd','--interop','map','exit','No\x20CLI\x20login\x20found\x20—\x20nothing\x20to\x20remove.','\x20delegation\x20','Delegated\x20','a\x20file\x20path','backendUrl','Session:\x20','sourceUserEmail','replace','model_id','interopPath','daily_usage','structured','851628vmyfHU','probability\x20','text','whoami','\x20must\x20be\x20a\x20JSON\x20object.','tenantId','\x27\x20is\x20empty.','cartographer','turnId','outputFormat','subcommand','updatedAt','test','delegations\x20list\x20<backend-project-id>',']\x20Backend\x20URL:\x20','\x20this\x20month','toFixed','--tenant\x20applies\x20to\x20`delegate-cli\x20login`\x20only.\x20Switch\x20tenants\x20with:\x20delegate-cli\x20tenant\x20<name>','page','description','Tenant:\x20','--skills-path','entries','resolve','token_units','pending','Owner\x20\x20\x20\x20\x20\x20\x20\x20\x20','Turn:\x20','confidence','parse','noMemory','Cartographer:\x20','fork','message','Use:\x20delegate-cli\x20delegations\x20','\x20token\x20units)','.\x20Use\x20`delegate-cli\x20usage`,\x20`usage\x20activity`\x20or\x20`usage\x20daily`.','No\x20structured\x20output:\x20the\x20turn\x20failed\x20(','Already\x20answered','\x20|\x20','--turn','session_consumed_pu','startsWith','show','AUTH_TOKEN_FILE\x20\x27','delegateTo','models_breakdown','\x20(no\x20cap\x20enforced)','max','includes','email','delegations\x20pending\x20<session-id>','expiresAt','completion_tokens','Session\x20\x20\x20\x20\x20\x20\x20','\x20not\x20found,\x20has\x20no\x20messages','stdout','delegations\x20complete\x20<delegation-id>\x20\x22<answer>\x22|-','Deleted\x20session\x20','print','type','package.json','toISOString','noConnections','--worker-id','\x20sessions\x20on\x20','425359EAxBek','projectId','contextSummary','--attach\x20applies\x20to\x20prompts\x20only.','Title\x20\x20\x20\x20\x20\x20\x20\x20\x20','spawn','\x0a⚠️\x20\x20Auth\x20expired.\x20Opening\x20browser\x20to\x20re-login…\x0a','concat','--session','an\x20email\x20address\x20or\x20name','--url\x20applies\x20to\x20`delegate-cli\x20login`\x20only.\x20Other\x20commands\x20follow\x20the\x20saved\x20login,\x20or\x20--backend\x20<url>.','--days','rubric_version','Date\x20\x20\x20\x20\x20\x20\x20\x20Token\x20units\x20\x20Prompt\x20tokens\x20\x20Completion\x20tokens','3017367LTWATl','107687yMGsKX','parentSessionId','isArray','string',',\x20whose\x20tenant\x20is\x20chosen\x20in\x20the\x20app.\x20Run\x20`delegate-cli\x20login\x20--env\x20<env>`\x20for\x20a\x20CLI\x20login\x20of\x20your\x20own.','complete','total_sessions','Tenants\x20of\x20','staging','Token:\x20\x20\x20\x20\x20\x20\x20\x20expired\x20','unknown','daily','--model','--tenant','\x20applies\x20to\x20prompts\x20and\x20to\x20these\x20commands\x20only:\x20','\x20\x22<answer>\x22\x0a','stringify','delegations\x20create\x20--session\x20<id>\x20[--to\x20<email|name>]\x20[--summary\x20<text>]\x20\x22<task>\x22|-','headless','unknown\x20slug','a\x20JSON\x20schema\x20file','Usage:\x20delegate-cli\x20sessions\x20[list]\x20[--page\x20N]\x20[--limit\x20N]\x20[--include-subagents]','effort','a\x20deployment\x20URL,\x20e.g.\x20https://automationsuite.contoso.com','\x20\x20\x20\x20BYO\x20warning:\x20','[saved\x20login]\x20Backend\x20URL:\x20','First\x20login\x20requires\x20--env\x20or\x20--url.\x20Usage:\x20delegate-cli\x20login\x20--env\x20<alpha|staging|production>,\x20or\x20delegate-cli\x20login\x20--url\x20https://automationsuite.contoso.com','\x0adelegate-cli\x20—\x20Delegate\x20agent\x20CLI\x0a\x0aUsage:\x0a\x20\x20delegate-cli\x20[flags]\x20[\x22<prompt>\x22]\x20\x20\x20\x20Start\x20a\x20conversation\x20in\x20a\x20terminal\x0a\x20\x20delegate-cli\x20--print\x20\x22<prompt>\x22\x20\x20\x20\x20\x20\x20Send\x20one\x20prompt,\x20print\x20the\x20response,\x20and\x20exit\x0a\x20\x20delegate-cli\x20[flags]\x20-\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Read\x20one\x20prompt\x20from\x20stdin\x20through\x20EOF,\x20then\x20exit\x0a\x20\x20delegate-cli\x20-p\x20\x22<prompt>\x22\x20--output-format\x20json|stream-json\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20One\x20turn\x20with\x20JSON-only\x20stdout;\x20exit\x201\x20on\x20error\x0a\x20\x20delegate-cli\x20--json-schema\x20FILE\x20\x22<prompt>\x22\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20One\x20turn,\x20then\x20its\x20result\x20extracted\x20as\x20JSON\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20matching\x20the\x20schema\x20in\x20FILE\x20(printed\x20after\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20the\x20answer;\x20\x22structured\x22\x20in\x20the\x20JSON\x20result);\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20exit\x201\x20when\x20the\x20extraction\x20fails\x0a\x20\x20delegate-cli\x20--attach\x20PATH\x20[--attach\x20PATH\x20...]\x20\x22<prompt>\x22\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Send\x20files\x20or\x20folders\x20with\x20the\x20first\x20message\x0a\x20\x20delegate-cli\x20login\x20[--env\x20NAME\x20|\x20--url\x20BASE]\x20[--tenant\x20NAME]\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20OAuth\x20browser\x20login\x20→\x20~/.aria/sdk-auth.json.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--env\x20or\x20--url\x20required\x20on\x20FIRST\x20login;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20afterwards\x20defaults\x20to\x20the\x20saved\x20login\x27s\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20deployment.\x20--tenant\x20picks\x20a\x20tenant\x20by\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20name;\x20without\x20it\x20a\x20re-login\x20keeps\x20the\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20saved\x20tenant\x0a\x20\x20delegate-cli\x20tenant\x20[NAME]\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20List\x20the\x20organization\x27s\x20tenants,\x20or\x20switch\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20the\x20saved\x20login\x20to\x20NAME\x20(no\x20browser)\x0a\x20\x20delegate-cli\x20logout\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Remove\x20the\x20saved\x20CLI\x20login\x0a\x20\x20delegate-cli\x20whoami\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Show\x20the\x20current\x20login\x20(org,\x20tenant,\x20token\x20expiry)\x0a\x20\x20delegate-cli\x20models\x20[--env\x20NAME]\x20\x20\x20\x20\x20List\x20available\x20LLM\x20models\x20for\x20the\x20current\x20tenant,\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20with\x20any\x20BYO\x20configuration\x20warning\x20per\x20model\x0a\x20\x20delegate-cli\x20sessions\x20[list]\x20[--page\x20N]\x20[--limit\x20N]\x20[--include-subagents]\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20List\x20your\x20backend\x20chat\x20sessions,\x20most\x20recently\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20active\x20first\x20(resume\x20one\x20with\x20--session\x20ID)\x0a\x20\x20delegate-cli\x20sessions\x20show|delete\x20ID\x20Show\x20one\x20session\x27s\x20title\x20and\x20owner,\x20or\x20delete\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20it\x20with\x20its\x20messages\x20and\x20sub-agents\x20(no\x20prompt)\x0a\x20\x20delegate-cli\x20sessions\x20rename\x20ID\x20TITLE\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Rename\x20a\x20session\x20(1-500\x20characters)\x0a\x20\x20delegate-cli\x20sessions\x20fork\x20ID\x20[MESSAGE]\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Copy\x20session\x20ID\x20into\x20a\x20new\x20session,\x20up\x20to\x20and\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20including\x20message\x20MESSAGE\x20(default:\x20all\x20of\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20it);\x20continue\x20it\x20with\x20--session\x20NEW_ID\x0a\x20\x20delegate-cli\x20sessions\x20cancel\x20ID\x20--turn\x20TURN\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Cancel\x20turn\x20TURN\x20running\x20on\x20session\x20ID\x20in\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20another\x20process;\x20exits\x201\x20when\x20no\x20such\x20turn\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20is\x20in\x20progress\x0a\x20\x20delegate-cli\x20check\x20[--env\x20NAME]\x20[--headless]\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Verify\x20auth,\x20backend\x20readiness,\x20backend\x20and\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20interop\x20without\x20sending\x20a\x20prompt;\x20exits\x201\x20when\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20any\x20check\x20fails\x0a\x20\x20delegate-cli\x20usage\x20[--session\x20ID]\x20\x20\x20\x20Quota\x20and\x20spend:\x20licensing\x20quota,\x20monthly\x20spend\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20and\x20cap,\x20Cartographer\x20allowance\x0a\x20\x20delegate-cli\x20usage\x20activity|daily\x20[--days\x20N]\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Activity\x20totals,\x20or\x20per-day\x20usage,\x20over\x20the\x20last\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20N\x20days\x20(1-365,\x20default\x2030)\x0a\x20\x20delegate-cli\x20evaluate|rerank|verify\x20FILE|-\x20[--model\x20ID]\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Stateless\x20typed\x20judgments:\x20send\x20the\x20JSON\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20request\x20in\x20FILE\x20(or\x20stdin\x20with\x20-)\x20to\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20/v1/completions/<command>\x20and\x20print\x20the\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20answers;\x20--model\x20overrides\x20its\x20\x22model\x22.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Exits\x201\x20when\x20the\x20backend\x20rejects\x20it\x0a\x20\x20delegate-cli\x20complete\x20--json-schema\x20FILE\x20[--model\x20ID]\x20[--session\x20ID]\x20\x22<prompt>\x22|-\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20One\x20structured\x20completion,\x20no\x20agent\x20turn:\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20print\x20the\x20JSON\x20object\x20matching\x20the\x20schema\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20in\x20FILE\x20(--output-format\x20json\x20prints\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{structured,\x20usage});\x20--session\x20adds\x20that\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20session\x27s\x20history\x20as\x20context.\x20Exits\x201\x20when\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20the\x20output\x20fails\x20the\x20schema\x20(422)\x20or\x20the\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20backend\x20rejects\x20the\x20request\x0a\x20\x20delegate-cli\x20transcribe\x20FILE|-\x20\x20\x20\x20\x20\x20\x20Speech-to-text\x20(Whisper):\x20print\x20the\x20text\x20of\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20the\x20audio\x20in\x20FILE,\x20or\x20on\x20stdin\x20with\x20-.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20mp3,\x20mp4,\x20mpeg,\x20mpga,\x20m4a,\x20wav\x20or\x20webm,\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20up\x20to\x2025\x20MiB.\x20Exits\x202\x20when\x20the\x20audio\x20is\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20refused\x20locally,\x201\x20when\x20the\x20backend\x20rejects\x20it\x0a\x20\x20delegate-cli\x20org-users\x20QUERY\x20\x20\x20\x20\x20\x20\x20\x20\x20Search\x20your\x20organization\x27s\x20users\x20by\x20name\x20or\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20email\x20prefix\x20(2-100\x20characters)\x0a\x20\x20delegate-cli\x20delegations\x20create\x20--session\x20ID\x20[--to\x20WHO]\x20[--summary\x20TEXT]\x20\x22<task>\x22|-\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Hand\x20a\x20task\x20from\x20session\x20ID\x20to\x20a\x20colleague\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20(WHO:\x20an\x20email,\x20or\x20a\x20name\x20matching\x20one\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20person);\x20without\x20--to,\x20print\x20a\x20link\x20anyone\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20in\x20the\x20organization\x20can\x20claim\x0a\x20\x20delegate-cli\x20delegations\x20pending\x20SESSION\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Answers\x20to\x20delegations\x20from\x20SESSION\x20that\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20await\x20acceptance\x20(poll\x20this)\x0a\x20\x20delegate-cli\x20delegations\x20accept|dismiss|cancel|delete\x20ID\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Take\x20an\x20answer\x20into\x20its\x20session,\x20drop\x20it,\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20withdraw\x20a\x20live\x20delegation,\x20or\x20delete\x20it\x0a\x20\x20delegate-cli\x20delegations\x20list\x20PROJECT\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Every\x20delegation\x20targeting\x20a\x20backend\x20project\x0a\x20\x20delegate-cli\x20delegations\x20show|claim\x20ID|LINK\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Read\x20a\x20delegation\x20assigned\x20to\x20you\x20(or\x20a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20delegate://delegation/…\x20link),\x20or\x20claim\x20it:\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20prints\x20the\x20session\x20to\x20work\x20it\x20in\x0a\x20\x20delegate-cli\x20delegations\x20complete\x20ID\x20\x22<answer>\x22|-\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Send\x20the\x20answer\x20to\x20a\x20delegation\x20you\x20claimed\x0a\x20\x20delegate-cli\x20host\x20[flags]\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Run\x20this\x20PC\x20as\x20a\x20remote\x20worker\x20until\x20Ctrl+C\x0a\x20\x20delegate-cli\x20host\x20install\x20[flags]\x20\x20\x20\x20Auto-start\x20the\x20host\x20at\x20login\x20(macOS\x20LaunchAgent\x20/\x20Windows\x20Scheduled\x20Task)\x0a\x20\x20delegate-cli\x20host\x20uninstall\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Remove\x20auto-start\x0a\x20\x20delegate-cli\x20host\x20status\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Show\x20auto-start\x20state\x0a\x20\x20delegate-cli\x20--cleanup\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Stop\x20running\x20interop\x0a\x0aFlags:\x0a\x20\x20-p,\x20--print\x20\x20\x20\x20\x20\x20\x20Run\x20one\x20turn\x20and\x20exit,\x20including\x20any\x20tool\x20execution.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Automatic\x20when\x20stdin\x20or\x20stdout\x20is\x20not\x20a\x20terminal,\x20or\x20with\x20-\x0a\x20\x20--env\x20NAME\x20\x20\x20\x20\x20\x20\x20\x20alpha\x20|\x20staging\x20|\x20production\x20|\x20localhost\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Composes\x20backend\x20URL\x20from\x20saved\x20auth\x20(org/tenant\x20slugs).\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Omitted\x20→\x20the\x20deployment\x20you\x20logged\x20into\x20(delegate-cli\x20login).\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20localhost\x20→\x20http://localhost:5002.\x20No\x20saved\x20login\x20and\x20no\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--env/--backend/BACKEND_URL\x20is\x20an\x20error\x20—\x20never\x20a\x20guess.\x0a\x20\x20--url\x20BASE\x20\x20\x20\x20\x20\x20\x20\x20(login)\x20Base\x20URL\x20of\x20a\x20deployment\x20that\x20is\x20not\x20a\x20named\x20cloud\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20—\x20Automation\x20Suite,\x20Dedicated,\x20Public\x20Sector.\x20Accepts\x20a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20tenant\x20path\x20or\x20a\x20trailing\x20/identity_\x20and\x20reduces\x20it\x20to\x20the\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20origin.\x20Mutually\x20exclusive\x20with\x20--env;\x20also\x20settable\x20via\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20UIPATH_BASE_URL.\x20Alias:\x20--authority.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Automation\x20Suite\x20needs\x2026.10+\x20with\x20the\x20Delegate\x20service;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20if\x20the\x20deployment\x20rejects\x20the\x20built-in\x20client,\x20register\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20your\x20own\x20—\x20see\x20UIPATH_CLIENT_ID\x20in\x20the\x20README\x0a\x20\x20--skip-env-check\x20\x20(login)\x20Do\x20not\x20check\x20the\x20deployment\x20before\x20signing\x20in.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Escape\x20hatch\x20for\x20a\x20deployment\x20that\x20hides\x20its\x20OIDC\x20discovery\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20document\x20or\x20serves\x20Identity\x20from\x20another\x20origin;\x20it\x20also\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20gives\x20up\x20the\x20diagnosis\x20when\x20something\x20is\x20really\x20wrong\x0a\x20\x20--backend\x20URL\x20\x20\x20\x20\x20Full\x20backend\x20URL\x20—\x20escape\x20hatch\x20overrides\x20--env\x0a\x20\x20--tenant\x20NAME\x20\x20\x20\x20\x20(login)\x20Tenant\x20to\x20sign\x20into,\x20by\x20name\x20(case-insensitive).\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Default:\x20the\x20saved\x20login\x27s\x20tenant\x20on\x20that\x20cloud,\x20else\x20the\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20org\x27s\x20first\x20tenant.\x20Later:\x20delegate-cli\x20tenant\x20<name>\x0a\x20\x20--model\x20NAME\x20\x20\x20\x20\x20\x20LLM\x20model\x20id\x20(e.g.\x20claude_sonnet_5,\x20kimi_k3).\x20Checked\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20against\x20the\x20tenant\x27s\x20catalog\x20(delegate-cli\x20models)\x20before\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20the\x20run\x20starts;\x20an\x20unknown\x20id\x20fails\x20and\x20lists\x20the\x20valid\x20ones.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Default:\x20gpt_5_6_luna.\x20Also\x20settable\x20via\x20MODEL\x20env\x20var.\x0a\x20\x20--keep-alive\x20\x20\x20\x20\x20\x20Reuse/leave\x20interop\x20running\x20across\x20invocations\x0a\x20\x20--headless\x20\x20\x20\x20\x20\x20\x20\x20Skip\x20interop\x20(text-only\x20prompts)\x0a\x20\x20--no-computer-use\x20Keep\x20interop\x20—\x20file,\x20Office,\x20PDF\x20and\x20shell\x20tools\x20keep\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20working\x20—\x20but\x20drop\x20the\x20screen:\x20no\x20screenshots,\x20no\x20window\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20list,\x20no\x20UI-automation\x20tools.\x20Cuts\x20image\x20tokens\x20and\x20the\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20per-turn\x20screen\x20capture,\x20and\x20stops\x20desktop\x20window\x20titles\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20leaving\x20the\x20machine.\x20Use\x20for\x20document\x20and\x20file\x20work.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--headless\x20implies\x20this\x20and\x20turns\x20interop\x20off\x20as\x20well\x0a\x20\x20--no-connections\x20\x20Disable\x20orchestrator\x20ConnectionService\x20(silences\x20404\x20warnings)\x0a\x20\x20--no-security\x20\x20\x20\x20\x20Disable\x20tool\x20security\x20wrapper\x20(use\x20only\x20for\x20debugging)\x0a\x20\x20--no-memory\x20\x20\x20\x20\x20\x20\x20Do\x20not\x20send\x20the\x20Delegate\x20app\x27s\x20local\x20long-term\x20memories\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20with\x20each\x20turn,\x20and\x20do\x20not\x20ask\x20the\x20model\x20to\x20save\x20new\x20ones\x0a\x20\x20--task-automation\x20Record\x20every\x20UI\x20action\x20of\x20the\x20run,\x20with\x20the\x20selector\x20of\x20the\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20element\x20it\x20acted\x20on,\x20to\x20<working-dir>/captures/<session>/\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20(~/.aria-sdk\x20without\x20--working-dir),\x20so\x20you\x20can\x20then\x20ask\x20for\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20the\x20task\x20as\x20a\x20UiPath\x20coded\x20workflow\x20(uipath-taskautomation\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20skill).\x20The\x20log\x20holds\x20on-screen\x20text\x20and\x20your\x20requests;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20typed\x20values\x20are\x20masked.\x20Needs\x20computer\x20use.\x20Ignored\x20with\x20a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20warning\x20where\x20the\x20deployment\x20does\x20not\x20offer\x20it\x20yet\x0a\x20\x20--attach\x20PATH\x20\x20\x20\x20\x20File\x20or\x20folder\x20sent\x20with\x20the\x20first\x20message\x20(repeatable),\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20as\x20the\x20Delegate\x20app\x20sends\x20attached\x20files:\x20images\x20inline,\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20PDFs\x20and\x20other\x20documents\x20as\x20a\x20path\x20the\x20agent\x20reads,\x20text\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20inline\x20up\x20to\x2016,000\x20characters.\x2030\x20MiB\x20per\x20message\x20in\x20all;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20larger\x20files\x20go\x20as\x20a\x20path.\x20In\x20a\x20conversation,\x20later\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20messages\x20carry\x20none\x20of\x20their\x20own,\x20but\x20the\x20first\x20message\x27s\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20stay\x20in\x20context\x0a\x20\x20--preload-skill\x20NAME\x20\x20Preload\x20a\x20skill\x20into\x20the\x20session\x20(repeatable).\x20The\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20skill\x27s\x20content\x20is\x20attached\x20before\x20the\x20first\x20model\x20turn\x20—\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20same\x20mechanism\x20as\x20project\x20preloaded\x20skills\x20in\x20the\x20app\x0a\x20\x20--cartographer\x20\x20\x20\x20Cartographer\x20engagement\x20preset.\x20Equivalent\x20to\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--no-computer-use\x20--preload-skill\x20business-analysis\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--preload-skill\x20project-task-list\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--preload-skill\x20knowledge-base.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Add\x20--project/--working-dir\x20for\x20where\x20the\x20files\x20live,\x20and\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20extra\x20--preload-skill\x20flags\x20for\x20more\x20skills\x20—\x20a\x20skill\x20the\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20preset\x20already\x20covers\x20is\x20not\x20preloaded\x20twice.\x20An\x20explicit\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--headless\x20still\x20wins\x20and\x20turns\x20interop\x20off\x0a\x20\x20--project\x20ID\x20\x20\x20\x20\x20\x20Route\x20the\x20session\x27s\x20local\x20wiki\x20and\x20plans\x20to\x20a\x20project\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20(<working-dir>/projects/<ID>/wiki).\x20Client-side\x20key\x20only\x0a\x20\x20--working-dir\x20PATH\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Shell\x20cwd\x20for\x20the\x20agent\x20and\x20root\x20for\x20SDK-local\x20state.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Relative\x20paths\x20resolve\x20against\x20the\x20current\x20directory;\x20the\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20directory\x20is\x20created\x20if\x20missing\x0a\x20\x20--skills-path\x20PATH\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Folder\x20of\x20custom\x20skills,\x20loaded\x20on\x20top\x20of\x20the\x20skills\x20the\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20package\x20ships;\x20wins\x20on\x20a\x20name\x20clash\x20(also:\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20DELEGATE_BUNDLED_SKILLS_PATH)\x0a\x20\x20--effort\x20TIER\x20\x20\x20\x20\x20Reasoning\x20effort:\x20low\x20|\x20medium\x20|\x20high\x20|\x20xhigh\x20|\x20max.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Default:\x20the\x20model\x27s\x20recommended\x20tier\x0a\x20\x20--session\x20ID\x20\x20\x20\x20\x20\x20Continue\x20an\x20existing\x20backend\x20session\x20(an\x20unknown\x20id\x20exits\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x201;\x20the\x20backend\x20assigns\x20new\x20ids).\x20For\x20complete:\x20the\x20session\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20whose\x20history\x20is\x20the\x20context\x0a\x20\x20--json-schema\x20FILE\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20JSON\x20schema\x20the\x20structured\x20answer\x20must\x20match\x20(complete,\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20and\x20prompts:\x20implies\x20--print)\x0a\x20\x20--runner-url\x20URL\x20\x20(host)\x20Runner\x20worker\x20WS\x20URL.\x20Required;\x20or\x20CONTROL_PLANE_WS_URL\x20env\x0a\x20\x20--interop\x20PATH\x20\x20\x20\x20(host)\x20Interop\x20binary\x20path;\x20or\x20INTEROP_EXECUTABLE_PATH\x20env.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Absent\x20→\x20registration/discovery\x20only,\x20tool\x20execution\x20disabled\x0a\x20\x20--worker-id\x20ID\x20\x20\x20\x20(host)\x20Stable\x20worker\x20identity;\x20or\x20WORKER_ID\x20env.\x20Default:\x20hostname\x0a\x20\x20--page\x20N\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20(sessions)\x20Page\x20to\x20show,\x20from\x201.\x20Default:\x201\x0a\x20\x20--limit\x20N\x20\x20\x20\x20\x20\x20\x20\x20\x20(sessions)\x20Rows\x20per\x20page,\x201-100.\x20Default:\x2030\x0a\x20\x20--include-subagents\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20(sessions)\x20Also\x20list\x20sub-agent\x20sessions,\x20hidden\x20by\x20default\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20as\x20in\x20the\x20desktop\x20app\x27s\x20history\x0a\x20\x20--to\x20WHO\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20(delegations\x20create)\x20Assign\x20to\x20this\x20person:\x20an\x20email,\x20or\x20a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20name\x20that\x20matches\x20exactly\x20one\x20colleague\x20(see\x20org-users)\x0a\x20\x20--summary\x20TEXT\x20\x20\x20\x20(delegations\x20create)\x20The\x20briefing\x20the\x20person\x20starts\x20from.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Default:\x20empty,\x20for\x20a\x20task\x20that\x20stands\x20on\x20its\x20own\x0a\x20\x20--output-format\x20FMT\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20text\x20(default)\x20|\x20json\x20|\x20stream-json.\x20json\x20prints\x20one\x20result\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20object\x20on\x20exit;\x20stream-json\x20prints\x20every\x20agent\x20event\x20as\x20one\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20JSON\x20line,\x20then\x20the\x20result.\x20Both\x20keep\x20stdout\x20JSON-only\x20(logs,\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20progress\x20and\x20the\x20session\x20id\x20go\x20to\x20stderr),\x20imply\x20--print,\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20and\x20exit\x201\x20when\x20the\x20turn\x20ends\x20in\x20error.\x20Also\x20honoured\x20by\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20every\x20subcommand\x20that\x20prints\x20a\x20result\x20(all\x20but\x20login,\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20logout,\x20tenant\x20and\x20host)\x0a\x20\x20-q,\x20--quiet\x20\x20\x20\x20\x20\x20\x20Suppress\x20🤔\x20thinking\x20output\x20to\x20stderr\x0a\x20\x20--verbose\x20\x20\x20\x20\x20\x20\x20\x20\x20Surface\x20the\x20SDK\x27s\x20and\x20the\x20framework\x27s\x20own\x20logs.\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Diagnostics\x20only,\x20on\x20stdout;\x20independent\x20of\x20-q\x0a\x20\x20-h,\x20--help\x20\x20\x20\x20\x20\x20\x20\x20Show\x20this\x20help\x0a\x20\x20-v,\x20--version\x20\x20\x20\x20\x20Print\x20the\x20installed\x20CLI\x20version\x0a\x0aConversation:\x20Enter\x20sends\x20a\x20message;\x20/exit\x20or\x20EOF\x20exits;\x20Ctrl+C\x20stops\x20and\x20exits.\x0a\x20\x20Ctrl+C\x20during\x20a\x20turn\x20cancels\x20it\x20on\x20the\x20backend\x20too;\x20a\x20second\x20Ctrl+C\x20force-exits.\x0a\x20\x20An\x20optional\x20initial\x20prompt\x20is\x20followed\x20by\x20more\x20input.\x20The\x20session\x20ID\x20is\x20printed\x0a\x20\x20to\x20stderr;\x20resume\x20later\x20with\x20--session\x20ID.\x20Redirected\x20input\x20is\x20one\x20prompt.\x0aAuth:\x20prompts\x20auto-retry\x20on\x20401\x20by\x20opening\x20the\x20browser\x20to\x20re-login\x20(TTY\x20only),\x0a\x20\x20preserving\x20the\x20active\x20session.\x0a','taskAutomation','preloadSkills','Missing\x20prompt.\x20Pass\x20it\x20as\x20an\x20argument,\x20pipe\x20it\x20via\x20stdin,\x20or\x20run\x20`delegate-cli\x20--help`.','10WLxgHh','length','from','\x20completion','Auth\x20comes\x20from\x20AUTH_TOKEN/TENANT_ID/ORG_ID\x20—\x20set\x20TENANT_ID\x20and\x20TENANT_SLUG\x20to\x20change\x20the\x20tenant.','status','--session\x20applies\x20to\x20the\x20`delegate-cli\x20usage`\x20summary\x20only.','\x0aAvailable\x20models\x20(','activity','pendingResults','delegations\x20claim\x20<delegation-id|delegate://delegation/…>','toolName','skipEnvCheck','Interop\x20stopped\x20(if\x20it\x20was\x20running).','delegationId','No\x20usage\x20in\x20the\x20last\x20','delegations','\x20needs\x20a\x20JSON\x20request:\x20delegate-cli\x20','floor','\x20--turn\x20','initialize','--no-security','limit','\x20(current)','attachments','includeSubAgents','No\x20CLI\x20login\x20found.\x20Note:\x20the\x20CLI\x20is\x20currently\x20authenticating\x20via\x20the\x20Delegate\x20desktop\x20app\x27s\x20','result','isError','once','No\x20CLI\x20login\x20to\x20switch:\x20the\x20CLI\x20is\x20authenticating\x20via\x20the\x20Delegate\x20desktop\x20app\x27s\x20','\x20\x20(input\x20#','Usage:\x20delegate-cli\x20sessions\x20cancel\x20<session-id>\x20--turn\x20<turn-id>',').\x0a','workingDirectory','round','then','isDesktopFallback','assignedUser','a\x20turn\x20id','\x20cap','noSecurity','help','Unknown\x20sessions\x20action:\x20','claim','delegate-cli','finish','>.\x0a','\x20<file.json>,\x20or\x20-\x20to\x20read\x20stdin.','Tokens:\x20','--skip-env-check\x20applies\x20to\x20`delegate-cli\x20login`\x20only.','self-hosted\x20(Automation\x20Suite\x20/\x20Dedicated)',')\x20—\x20saved\x20to\x20','catch','now','displayName','Session:\x20\x20\x20\x20\x20\x20','\x20(cancel\x20with:\x20delegate-cli\x20sessions\x20cancel\x20','total_quota_pu','noComputerUse','delegations\x20delete\x20<delegation-id>','create','write','Licensing:\x20\x20\x20\x20','stdin','--task-automation\x20applies\x20to\x20prompts\x20only.','high','Session\x20','utf-8','choice','tool','org-users','):\x0a\x0a','4TYrkNV','results','localhost','env','transcribe','a\x20skill\x20name','Renamed\x20','all','models','--authority','accept','Unknown\x20usage\x20view:\x20','code','--to','Invalid\x20--env:\x20','logout','transcribe\x20needs\x20audio:\x20delegate-cli\x20transcribe\x20<file>,\x20or\x20-\x20to\x20read\x20stdin.','tenantName','\x22.\x20Use\x20a\x20single\x20folder-safe\x20segment\x20such\x20as\x20invoice-approval\x20(letters,\x20digits,\x20spaces,\x20\x22_\x22,\x20\x22-\x22,\x20\x22.\x22,\x20parentheses;\x20at\x20most\x2064\x20characters;\x20not\x20starting\x20with\x20\x22.\x22\x20or\x20ending\x20with\x20\x22.\x22\x20or\x20a\x20space).','Spending:\x20\x20\x20\x20\x20$','onEvent','🔧\x20','userId','limit_enabled','\x20requires\x20','sourceTitle','auth.json','Deployment:\x20\x20\x20','\x20(resume\x20with\x20--session\x20','--help','--summary','\x20active\x20days','asyncIterator','%\x20of\x20','✓\x20Done\x0a','Organization\x20\x20','--print','--page,\x20--limit\x20and\x20--include-subagents\x20apply\x20to\x20`delegate-cli\x20sessions`\x20only.','UiPath\x20Cloud','\x27\x20cannot\x20be\x20read:\x20','jsonSchemaPath','\x20<id>','production','--project','.aria','isTTY','Claimed\x20from\x20delegation\x20','Source:\x20\x20\x20\x20\x20\x20\x20','\x20\x20\x20\x20','\x20\x22<prompt>\x22\x0aAnswer\x20with:\x20delegate-cli\x20delegations\x20complete\x20','complete\x20needs\x20--json-schema\x20<file>:\x20delegate-cli\x20complete\x20--json-schema\x20schema.json\x20\x22<prompt>\x22.','period_days','url','verbose','.\x20Use\x20','check','\x20days:\x20','list','120nuOzTC','Organization:\x20','Base\x20URL:\x20\x20\x20\x20\x20','3akcuDI','hide',':\x20cannot\x20read\x20the\x20JSON\x20schema\x20(','\x20(in\x20','dismiss','a\x20session\x20id','error','tool_call','From\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','delegations\x20accept\x20<delegation-id>','--task-automation','\x20token\x20units','lastType','content','stop','padStart','getSessionId','rename','ASSIGNEE','\x20(confidence\x20','--preload-skill','\x20(estimated\x20$','period_end','rerank','estimated_cost_usd','quiet','prompt_tokens','--env\x20localhost\x20has\x20no\x20OAuth\x20flow;\x20pick\x20alpha,\x20staging,\x20or\x20production.','[env=','a\x20directory\x20path','\x0a🤔\x20','verify','stderr','--no-computer-use','--include-subagents','Unknown\x20delegations\x20action:\x20','the\x20request','Usage:\x20delegate-cli\x20sessions\x20','active_days','trim','Delegation\x20\x20\x20\x20','\x20\x20TASK\x0a','pct_used','\x20in\x20progress\x20on\x20session\x20',':\x20cannot\x20read\x20the\x20request\x20(','delegation','push','a\x20colleague','existsSync','done','No\x20sessions\x20on\x20page\x20','alpha','close','orgLogicalName','\x20PU\x20used','structuredError','\x20from\x20','cancel','908120KtwHAo','probability','toUpperCase','Bearer\x20','evaluate','baseUrl','login','filter','task','lockReason','--cleanup','answers','score','--working-dir','cancelled','--no-connections',',\x20or\x20holds\x20no\x20message\x20','total_cost_usd','\x20PU','accessToken','pause','session_start','add','readFileSync','--keep-alive','cwd','Accepted','host','\x20days.\x0a','stream-json','--page','isSafeInteger','alreadyAccepted','\x20(Delegate\x20desktop\x20app\x20fallback)','\x20must\x20be\x20a\x20whole\x20number\x20','off','--json-schema','data','a\x20project\x20id','Tenant\x20not\x20switched:\x20could\x20not\x20write\x20','Last\x20','an\x20effort\x20tier','/exit','Invalid\x20--effort:\x20','alreadyCompleted','model','\x20prompt,\x20','--verbose','Cancel\x20requested\x20for\x20turn\x20','1984560asEqjP','Token:\x20\x20\x20\x20\x20\x20\x20\x20expires\x20','prompt','Could\x20not\x20check\x20BYO\x20model\x20warnings:\x20','keepAlive','getTurnUsageHistory','deleted','stack','--limit','--skip-env-check','--days\x20applies\x20to\x20`delegate-cli\x20usage\x20activity|daily`\x20only.','tokenExpiresAt','Unknown\x20flag:\x20','mode','a\x20briefing\x20text','thinking','title','restore','Removed\x20','\x0aAccept\x20one\x20with:\x20delegate-cli\x20delegations\x20accept\x20<id>\x0a','Continue\x20it\x20with:\x20delegate-cli\x20--session\x20','1988684bDwGBx','log','\x20(stdin\x20was\x20empty)','\x20is\x20not\x20valid\x20JSON\x20(','\x20(resets\x20','auth','medium','\x20PU\x20beyond\x20quota','STATUS','\x20<title>','\x20tokens\x0a','origin','join','bundledSkillsPath','delete','slice','Cost:\x20\x20\x20$','sendMessage','\x0aStopping…\x20(Ctrl+C\x20again\x20to\x20force\x20exit)\x0a','transcribe:\x20cannot\x20read\x20','tenant','days','name','usage','sessions',';\x20the\x20saved\x20login\x20still\x20uses\x20','turn_start','--output-format','Enter\x20sends\x20a\x20message.\x20/exit\x20or\x20EOF\x20exits;\x20Ctrl+C\x20stops\x20and\x20exits.\x0a','operands','extra_pool_consumed_pu','Rubric\x20','monthly_limit_usd','\x20of\x20a\x20$','--turn\x20applies\x20to\x20`delegate-cli\x20sessions\x20cancel`\x20only.','rejection','UPDATED','\x20to\x20','Structured\x20output\x20failed:\x20','exitCode','sessionId','file','end','The\x20saved\x20CLI\x20login\x20could\x20not\x20be\x20refreshed.\x20Run\x20`delegate-cli\x20login`\x20again.','delegations\x20show\x20<delegation-id|delegate://delegation/…>','a\x20format\x20(','low','workerId','verdict','UIPATH_BASE_URL\x20is\x20unusable.\x20','organizationId','--cartographer','7fPLEno','version','index','--headless','byoWarning','Usage:\x20delegate-cli\x20sessions\x20fork\x20<id>\x20[<message-id>]','--env'];_0x438c=function(){return _0xda4cea;};return _0x438c();}async function pn(){const _0x5a6f96=_0x948c2c;let _0x40f1e8=ht(process['argv'][_0x5a6f96(0x175)](0x2));if(_0x40f1e8[_0x5a6f96(0x1c3)]===_0x5a6f96(0x1bc)){await te(_0x40f1e8);return;}let _0x25df51=gt();try{await te(_0x40f1e8);}finally{_0x25df51();}}async function te(_0xe80ca4){const _0x5b0a9c=_0x948c2c;if(_0xe80ca4[_0x5b0a9c(0x254)]){wt();return;}if(_0xe80ca4['version']){console[_0x5b0a9c(0x167)](yt());return;}if(_0xe80ca4[_0x5b0a9c(0x1c4)]===_0x5b0a9c(0x126)){await en(_0xe80ca4);return;}if(_0xe80ca4[_0x5b0a9c(0x1c4)]===_0x5b0a9c(0x17a)){await nn(_0xe80ca4[_0x5b0a9c(0x153)]);return;}if(_0xe80ca4[_0x5b0a9c(0x1c4)]===_0x5b0a9c(0x282)){await vt();return;}if(_0xe80ca4[_0x5b0a9c(0x1c4)]==='whoami'){await At(_0xe80ca4);return;}if(_0xe80ca4[_0x5b0a9c(0x1c4)]==='models'){await Tt(_0xe80ca4);return;}if(_0xe80ca4['subcommand']==='check'){await Lt(_0xe80ca4);return;}if(_0xe80ca4['subcommand']===_0x5b0a9c(0x17e)){await Dt(_0xe80ca4);return;}if(_0xe80ca4['subcommand']===_0x5b0a9c(0x17d)){await Ft(_0xe80ca4);return;}if(_0xe80ca4[_0x5b0a9c(0x1c4)]===_0x5b0a9c(0x124)||_0xe80ca4['subcommand']===_0x5b0a9c(0x2c7)||_0xe80ca4[_0x5b0a9c(0x1c4)]===_0x5b0a9c(0x2cf)){await Ht(_0xe80ca4,_0xe80ca4['subcommand']);return;}if(_0xe80ca4[_0x5b0a9c(0x1c4)]===_0x5b0a9c(0x210)){await Jt(_0xe80ca4);return;}if(_0xe80ca4[_0x5b0a9c(0x1c4)]===_0x5b0a9c(0x277)){await zt(_0xe80ca4);return;}if(_0xe80ca4[_0x5b0a9c(0x1c4)]==='delegations'){await Yt(_0xe80ca4);return;}if(_0xe80ca4[_0x5b0a9c(0x1c4)]==='org-users'){await Zt(_0xe80ca4);return;}if(_0xe80ca4[_0x5b0a9c(0x1c4)]===_0x5b0a9c(0x13b)){await _0x91bae4(_0xe80ca4[_0x5b0a9c(0x153)],{'runnerUrl':_0xe80ca4['runnerUrl'],'backendUrl':_0xe80ca4[_0x5b0a9c(0x1b2)],'interopPath':_0xe80ca4[_0x5b0a9c(0x1b7)],'workerId':_0xe80ca4[_0x5b0a9c(0x195)]});return;}if(_0xe80ca4[_0x5b0a9c(0x1a3)]){await $t();return;}await ln(_0xe80ca4);}var mn=process.env.NODE_ENV===_0x948c2c(0x1c6)||!!process.env.JEST_WORKER_ID;mn||pn()[_0x948c2c(0x25f)](_0x1c8d9b=>{const _0x295d44=_0x948c2c;console['error'](_0x1c8d9b[_0x295d44(0x158)]||_0x1c8d9b[_0x295d44(0x1db)]||_0x1c8d9b),process[_0x295d44(0x1ad)](0x1);});export{ft as CARTOGRAPHER_SKILLS,G as EFFORT_TIERS,kt as IMPLICIT_STDIN_IDLE_MS,Z as buildInitOptions,pn as main,ht as parseArgs,yt as readCliVersion,I as resolvePrompt,gt as routeStdoutToStderr,l as writeCommandResult};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@uipath/delegate-cli",
|
|
3
|
-
"version": "1.204.0-preview.
|
|
3
|
+
"version": "1.204.0-preview.20261015062504",
|
|
4
4
|
"description": "UiPath Delegate CLI - drive the Delegate agent from the terminal. Wraps @uipath/delegate-sdk; installing this package pulls the SDK in — no separate install.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"type": "commonjs",
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
"publish:npmjs": "npm publish --@uipath:registry=https://registry.npmjs.org/ --access public --ignore-scripts"
|
|
23
23
|
},
|
|
24
24
|
"dependencies": {
|
|
25
|
-
"@uipath/delegate-sdk": "1.204.0-preview.
|
|
25
|
+
"@uipath/delegate-sdk": "1.204.0-preview.20261015062504"
|
|
26
26
|
},
|
|
27
27
|
"devDependencies": {
|
|
28
28
|
"@types/node": "^22.0.0",
|