kenso 0.1.67 → 0.1.70
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/dist/kenso.js +321 -140
- package/dist/operations.json +1 -1
- package/docs/crm.md +4 -0
- package/docs/reference.md +55 -6
- package/package.json +2 -2
package/dist/kenso.js
CHANGED
|
@@ -2421,7 +2421,7 @@ var VERSION;
|
|
|
2421
2421
|
var init_version = __esm({
|
|
2422
2422
|
"src/core/version.ts"() {
|
|
2423
2423
|
"use strict";
|
|
2424
|
-
VERSION = true ? "0.1.
|
|
2424
|
+
VERSION = true ? "0.1.70" : "0.0.0-dev";
|
|
2425
2425
|
}
|
|
2426
2426
|
});
|
|
2427
2427
|
|
|
@@ -3714,9 +3714,9 @@ async function readRunDir(dir) {
|
|
|
3714
3714
|
return null;
|
|
3715
3715
|
}
|
|
3716
3716
|
if (!raw) return null;
|
|
3717
|
-
const { runId, command:
|
|
3717
|
+
const { runId, command: command48, createdAt, status } = raw;
|
|
3718
3718
|
if (typeof runId !== "string" || !RUN_ID_PATTERN.test(runId)) return null;
|
|
3719
|
-
if (typeof
|
|
3719
|
+
if (typeof command48 !== "string" || typeof createdAt !== "string") return null;
|
|
3720
3720
|
if (typeof status !== "string" || !STATUSES.includes(status)) return null;
|
|
3721
3721
|
let chunksDone = chunkList(raw.chunksDone) ?? [];
|
|
3722
3722
|
try {
|
|
@@ -3727,7 +3727,7 @@ async function readRunDir(dir) {
|
|
|
3727
3727
|
const record = {
|
|
3728
3728
|
...raw,
|
|
3729
3729
|
runId,
|
|
3730
|
-
command:
|
|
3730
|
+
command: command48,
|
|
3731
3731
|
args: asRecord3(raw.args) ?? {},
|
|
3732
3732
|
createdAt,
|
|
3733
3733
|
status,
|
|
@@ -3782,11 +3782,11 @@ async function loadRun(runId, env = process.env) {
|
|
|
3782
3782
|
}
|
|
3783
3783
|
return run;
|
|
3784
3784
|
}
|
|
3785
|
-
async function findIdentical(
|
|
3785
|
+
async function findIdentical(command48, args, inputSha256, env, workspaceId, anyWorkspace = false) {
|
|
3786
3786
|
const identity = argsIdentity(args);
|
|
3787
3787
|
const runs = await listRuns(env);
|
|
3788
3788
|
return runs.filter(
|
|
3789
|
-
(run) => run.command ===
|
|
3789
|
+
(run) => run.command === command48 && (run.inputSha256 || void 0) === (inputSha256 || void 0) && (anyWorkspace || (run.workspaceId || void 0) === (workspaceId || void 0)) && argsIdentity(run.args) === identity
|
|
3790
3790
|
);
|
|
3791
3791
|
}
|
|
3792
3792
|
function isOtherLiveProcess(pid) {
|
|
@@ -6818,6 +6818,9 @@ var init_execute = __esm({
|
|
|
6818
6818
|
FLAG_ALIASES = [
|
|
6819
6819
|
["campaign", "campaign-id"],
|
|
6820
6820
|
["tag", "tag-id"],
|
|
6821
|
+
["account", "account-id"],
|
|
6822
|
+
["person", "person-id"],
|
|
6823
|
+
["opportunity", "opportunity-id"],
|
|
6821
6824
|
["q", "search"]
|
|
6822
6825
|
];
|
|
6823
6826
|
LIST_PARAM_TEXT = {
|
|
@@ -6938,8 +6941,8 @@ function idValue(value, field) {
|
|
|
6938
6941
|
function shellQuote3(arg) {
|
|
6939
6942
|
return /^[A-Za-z0-9_./:=@%+,-]+$/.test(arg) ? arg : `'${arg.replace(/'/g, `'\\''`)}'`;
|
|
6940
6943
|
}
|
|
6941
|
-
function commandLine2(ctx,
|
|
6942
|
-
const parts2 = ["kenso", ...
|
|
6944
|
+
function commandLine2(ctx, command48, args, extra = []) {
|
|
6945
|
+
const parts2 = ["kenso", ...command48.split(" "), ...(args.positionals ?? []).map(shellQuote3)];
|
|
6943
6946
|
for (const [name, value] of Object.entries(args.flags)) {
|
|
6944
6947
|
if (value === void 0 || value === false) continue;
|
|
6945
6948
|
if (value === true) parts2.push(`--${name}`);
|
|
@@ -7263,7 +7266,7 @@ var init_batch = __esm({
|
|
|
7263
7266
|
var crm_default;
|
|
7264
7267
|
var init_crm = __esm({
|
|
7265
7268
|
"docs/crm.md"() {
|
|
7266
|
-
crm_default = '# CRM (beta)\n\nThe CRM commands work on Kenso\'s Accounts lane: accounts (companies), the people on them, and opportunities. They are beta: they need the `accounts` feature flag on your workspace (opportunities need `opportunities`, CRM sync needs `ingestion`). Help and `kenso describe` hide them until your workspace has the flag; `--all-commands` shows them.\n\n| Command | What it does |\n|---|---|\n| `accounts import` | Create accounts from a CSV or JSONL file. Research is charged per created account |\n| `people import` | Create or match people from a file, optionally onto accounts |\n| `accounts update --each`, `people update --each`, `opportunities update --each` | Edit many records from a file, one call per row |\n| `accounts write-research`, `people write-research` | Store research you gathered as a record\'s latest research, free. `--each` writes many |\n| `opportunities stage-history <id>` | A deal\'s stage history: each stage, when, who moved it and how long it sat there |\n| `capture status` | Your captured mailbox, its backfill progress and what teammates see of a captured email. Needs the `crm_capture` flag |\n| `crm-connections`, `crm-imports`, `crm-sync-issues` | Read and run CRM sync. Connecting a CRM stays in the app |\n\nImport accounts first, then people: `people import` never creates an account.\n\n## Import accounts\n\n```bash\nkenso accounts import --file accounts.csv\nkenso accounts import --file accounts.csv --yes\n```\n\n```csv\nname,domain,industry,employeeCount\nAcme,acme.io,Software,120\nGlobex,globex.com,Manufacturing,"1,200"\n```\n\n- **Columns** map by name, ignoring case, spaces and dashes: `name` (or `company`, `companyName`, `accountName`), `domains` (several, split on `,` or `;`) or one `domain` (or `website`, `companyDomain`), `industry`, `employeeCount`, `hqLocation`, `linkedinUrl`, `stage`, `angle`, `whyNow`, `fitScore`, `fundingRound`, `cadenceDays`, `ownerMemberId`, `kenCompanyId`, `sendsFromInboxId`, `sendsFromLinkedInAccountId` and `source`.\n- **A domain is required.** A file with no domain column is a usage error, and a row without a domain is `invalid` (`domain_required`).\n- **The dry run prices the research.** It asks for a credit estimate per 1,000 accounts and puts the sum in the plan: `kind`, `accountCount`, `totalMillicredits`, `availableMillicredits` and `sufficient`.\n- **Rows go 100 per call** to `POST /v1/accounts/bulk-create`.\n\nEach row comes back `created` (`id` is the new account; its research is queued, `researchQueued`, or waits for credits, `researchWaitingCredits`), `skipped` with reason `domain_taken` (already an account; `id` is that account) or `failed` (`reason` is the API\'s code, `error` names the field; an item Kenso failed to save is sent once more first). Rerunning the same file is safe: accounts that exist come back `domain_taken`.\n\n## Import people\n\n```bash\nkenso people import --file people.csv\nkenso people import --file people.csv --find-emails --yes\nkenso people import --file people.jsonl --dry-run\n```\n\n```csv\nfullName,email,title,accountDomain,role\nAnn Lee,ann@acme.io,VP Sales,acme.io,champion\nBob Ray,,CTO,acme.io,\n```\n\n- **Columns** map by name, ignoring case, spaces and dashes: `email`, `fullName` (or `name`), `firstName`, `lastName`, `title`, `linkedinUrl` (or `linkedin`, `profileUrl`), `accountDomain` (or `domain`, `website`, `companyDomain`), `accountId`, `role` and `priority`. Other columns are ignored with one warning.\n- **A person needs a name:** `fullName`, or `firstName`, `lastName` or both (the CLI joins them). A row with none of them is `invalid` (`name_required`).\n- **To put a person on an account,** give `accountDomain` or `accountId`. A row with both sends only `accountId`.\n- **`--find-emails`** queues an email find (charged in credits) for each person without an email.\n- **Rows go 200 per call** to `POST /v1/people/batch`.\n\nPeople already in the workspace are matched by email, then LinkedIn URL, so running the same file again creates nobody twice. A row comes back `created` (a new person), `updated` (an existing person added to the account), `skipped` with reason `already_on_account`, `matched` (no account asked) or `previously_removed`, or `failed`: `account_not_found` saves the person without an account (import the account, then rerun to place them), any other reason is the API\'s. The summary adds `matched`, `addedToAccounts` and `emailFindsQueued`.\n\n## List and search accounts\n\n`accounts list` and `accounts search` sort and page on the server, so they reach every account in the workspace, however many there are.\n\n```bash\nkenso accounts list --sort score:desc --limit 100 # one page; the output\'s next: line is the following one\nkenso accounts list --sort score:desc --limit 100 --all # every page, to the end\nkenso accounts search --search hiring --sort latestSignalAt:desc --data \'{"qFields": ["name", "latestSignal"]}\'\nkenso accounts search --limit 1 --data \'{"countBy": ["stage"]}\' # how many accounts sit in each stage\nkenso accounts search --data \'{"where": {"match": "all", "conditions": [{"field": "tier", "operator": "is", "values": ["1"]}]}, "sort": "tier,-pipelineAmount"}\' --all\n```\n\n- **`--sort`** takes up to 3 comma-separated keys, each `field` (ascending), `field:asc` or `field:desc`. The API\'s `-field` form needs the equals sign here, `--sort=-score`, because a value that starts with a dash reads as a flag. Fields: `createdAt`, `name`, `score`, `tier` (ascending is tier 1 first), `latestSignalAt`, `committee`, `pipelineAmount`, `nextTouchAt`, `lastTouchAt`. An account with no value for a key comes last in both directions. The default is `-createdAt`.\n- **`--limit`** is 1 to 1000 (default 50). `--cursor` takes the previous page\'s `nextCursor` with the same filters and sort; `--all` follows the cursors for you.\n- **`--search`** (also `--q`) matches the name or a domain.\n- **Lists and objects go in `--data`** on `search`, as the API takes them (`kenso describe accounts search`); a flag beside it sets or replaces one key:\n - `qFields` picks where the search text looks: `name`, `domain`, `latestSignal` (the latest signal\'s title).\n - `countBy` (`stage`, `stageGroup`) adds `counts` to the output: every value with the number of matching accounts that hold it, whatever the page. The output is then one object: `data`, `pagination` and `counts`.\n - `filters` and `where` narrow the accounts.\n\nAn account\'s timeline pages the same way. `kenso accounts activity 812` returns the newest 100 earlier rows and, when older ones exist, `data.nextCursor`. Pass it back as `--cursor` (with the same `--category`) for the rows before them, until a page comes without one.\n\n## Edit accounts, people and opportunities\n\nApart from `accounts bulk-update`, which sets one `accountType` on up to 500 accounts, there is no bulk edit route, so run the generated `update` command once per row with `--each`. Columns are the command\'s flags by API name or flag name, and the id column fills the route:\n\n```bash\nkenso accounts update --each accounts-edit.csv --dry-run # then the same with --yes\nkenso people update --each people-edit.csv --dry-run\nkenso opportunities update --each deals.csv --dry-run\n```\n\n```csv\naccountId,stage,ownerMemberId,overwritePinned\n501,engaged,42,true\n502,customer,42,true\n```\n\nA row that changes a field someone pinned in the app fails as a whole (`409 conflict`, `pinned_by_user`: nothing on that record changes, the other fields of the row included), unless the row sets `overwritePinned` to `true` (or you pass `--overwrite-pinned`, only with the person\'s OK). Every flag of an update command: `kenso accounts update --help`.\n\n## Search opportunities\n\n`kenso opportunities search` works as `accounts search` does: it takes `--search`, `--sort`, `--limit`, `--cursor`, `--all`, and its lists in `--data`.\n\n```bash\nkenso opportunities search --data \'{"filters": [{"field": "stageCategory", "operator": "is", "values": ["open"]}]}\' --all\nkenso opportunities search --data \'{"filters": [{"field": "ownerMemberId", "operator": "is", "values": ["none"]}, {"field": "closeDate", "operator": "is", "values": ["past_due", "next_30_days"]}]}\'\nkenso opportunities search --limit 1 --data \'{"countBy": ["stage", "ownerMemberId"]}\' # how many opportunities hold each value\n```\n\n- **`filters`** is a list of `{field, operator, values}`, all of which must hold. Fields: `stage` (a stage key), `stageCategory` (`open`, `won`, `lost`), `ownerMemberId`, `closeDate` (`past_due`, `next_30_days`, `later`, `none`) and `sourceCampaignId`. `operator` is `is` or `is_not`; the values of one condition are OR. `none` in `values` matches an opportunity with no owner, no source campaign or no close date.\n- **`countBy`** takes the same field names and adds `counts` to the output: per field, every value with the number of matching opportunities that hold it.\n- `--account-id` keeps the search to one account. `closeDate` counts days in the member\'s app time zone.\n\nOne person\'s deals, meetings and campaign contacts, as their person page lists them:\n\n```bash\nkenso opportunities list --person-id 9001 # the deals they are on, or are the primary person of\nkenso meetings list --person-id 9001 # the meetings they attend, among the ones you can see\nkenso contacts list --person-id 9001 # their contact in each campaign they are in\n```\n\n## Write research you gathered\n\n`accounts write-research` and `people write-research` store research you gathered outside Kenso as the record\'s latest research (`PUT /v1/accounts/{accountId}/research`, `PUT /v1/people/{personId}/research`). The Research tab shows it like a Ken run, with `trigger: agent` and `researchedAt` now. Nothing is charged, and no account or person field changes: set an account\'s own `fitScore`, `whyNow` or `angle` with `accounts update`. They need the `accounts_research` flag and accounts edit.\n\nThe body is the research block `accounts get --expand research` (or `people get-research`) returns, without its read-only fields: leave out `id`, `status`, `trigger`, `errorCode`, `researchedAt`, `isStale` and `appliedPrompt` (for a person also `mode`, `requestedAt`, `researchedMode`, `firecrawlCredits` and `webNote`), or the write fails with `unknown_field`. Pass it with `--data @file`:\n\n```bash\nkenso accounts write-research --account-id 501 --data @acme-dossier.json\nkenso people write-research --person-id 9001 --data @jane.json\n```\n\n```json\n{\n "tagline": { "text": "Payroll for EU contractors", "sourceUrls": ["https://acme.example"] },\n "description": { "text": "Acme runs payroll and compliance for companies hiring contractors in 30 EU countries.", "sourceUrls": ["https://acme.example"] },\n "links": { "website": "https://acme.example" },\n "whyNow": { "text": "Raised a $40M Series B in October", "sourceUrls": ["https://news.example/acme-b"], "date": "2026-10" },\n "fitScore": 82,\n "angle": "Lead with contractor onboarding time."\n}\n```\n\nMany records: one JSONL line per record, with the id next to the block\'s fields. Nested objects are sent as written. Use JSONL, not CSV: the block\'s fields are objects and lists, which a CSV cell cannot carry.\n\n```bash\nkenso accounts write-research --each dossiers.jsonl --dry-run # then the same with --yes\nkenso people write-research --each people-research.jsonl --yes --concurrency 8\n```\n\n```jsonl\n{"accountId": 501, "tagline": {"text": "Payroll for EU contractors"}, "links": {"website": "https://acme.example"}}\n{"accountId": 502, "description": {"text": "Cloud cost tooling for retailers."}, "links": {"website": "https://beta.example"}}\n```\n\nA row fails as a whole with the API\'s code: `validation_failed` (an unknown field is `unknown_field`, and `error.details` names every bad field), `research_in_progress` (`409`: Ken is researching that record now, write it again once the run ends; an account run waiting for credits counts too: it runs once the workspace has credits, and the write stays refused until that run ends) or `not_found`. Rerunning a file is safe: each write replaces the record\'s research shown.\n\n## CRM sync\n\nCRM sync has generated commands only: read connections, preview, start an import, and work through sync issues. Connect the CRM itself in the app.\n\n```bash\nkenso crm-connections list\nkenso crm-connections get --connection-id 7\nkenso crm-imports create --connection-id 7 --dry-run\nkenso crm-sync-issues list --connection-id 7 --all\n```\n\nRun `kenso crm-connections --help` (or add `--all-commands` when the actions are hidden) to see every action.\n\n## A deal\'s stage history\n\n```bash\nkenso opportunities stage-history 77\nkenso opportunities stage-history 77 --query "entries[].{to: stageLabel, at: enteredAt, by: changedBy}"\n```\n\nIt prints `GET /v1/opportunities/{id}/stage-history` as it is, the same rows as the deal page and the MCP\'s `opportunities(operation="get-stage-history")`: the stage now, `isComplete` and `entries`, oldest first, each with `fromStage`, `stage`, `stageLabel`, `enteredAt`, `leftAt`, `durationSeconds`, `actorKind`, `actorMemberId` and Ken\'s `reason` on a move its stage judge made. With the `deal_stage_rules` flag on, each entry also has `changedBy` (`member`, `agent`, `api_key`, `workflow`, `stage_judge`, `crm_sync` or `ken_automation`), `crmProvider` on a CRM sync, and on a move `fromStageLabel` and `fromStageDurationSeconds`, how long the deal sat in the stage it left. `isComplete` false means Kenso has no record of part of the history.\n';
|
|
7269
|
+
crm_default = '# CRM (beta)\n\nThe CRM commands work on Kenso\'s Accounts lane: accounts (companies), the people on them, and opportunities. They are beta: they need the `accounts` feature flag on your workspace (opportunities need `opportunities`, CRM sync needs `ingestion`). Help and `kenso describe` hide them until your workspace has the flag; `--all-commands` shows them.\n\n| Command | What it does |\n|---|---|\n| `accounts import` | Create accounts from a CSV or JSONL file. Research is charged per created account |\n| `people import` | Create or match people from a file, optionally onto accounts |\n| `accounts update --each`, `people update --each`, `opportunities update --each` | Edit many records from a file, one call per row |\n| `accounts write-research`, `people write-research` | Store research you gathered as a record\'s latest research, free. `--each` writes many |\n| `opportunities stage-history <id>` | A deal\'s stage history: each stage, when, who moved it and how long it sat there |\n| `capture status` | Your captured mailbox, its backfill progress and what teammates see of a captured email. Needs the `crm_capture` flag |\n| `capture connect` | Turn capture on for your own mailbox. `--private` starts it hidden from teammates; `--provider google` prints a sign-in link when no account is connected yet |\n| `capture private on\\|off` | Hide your captured email from teammates, or show it again. Email only: meetings stay visible |\n| `capture disconnect` | Turn capture off and delete your stored email bodies. Asks first; `--yes` skips the question |\n| `capture teammates-see summary\\|full_email` | Workspace admin: what teammates see of captured email |\n| `crm-connections`, `crm-imports`, `crm-sync-issues` | Read and run CRM sync. Connecting a CRM stays in the app |\n\nImport accounts first, then people: `people import` never creates an account.\n\n## Import accounts\n\n```bash\nkenso accounts import --file accounts.csv\nkenso accounts import --file accounts.csv --yes\n```\n\n```csv\nname,domain,industry,employeeCount\nAcme,acme.io,Software,120\nGlobex,globex.com,Manufacturing,"1,200"\n```\n\n- **Columns** map by name, ignoring case, spaces and dashes: `name` (or `company`, `companyName`, `accountName`), `domains` (several, split on `,` or `;`) or one `domain` (or `website`, `companyDomain`), `industry`, `employeeCount`, `hqLocation`, `linkedinUrl`, `stage`, `angle`, `whyNow`, `fitScore`, `fundingRound`, `cadenceDays`, `ownerMemberId`, `kenCompanyId`, `sendsFromInboxId`, `sendsFromLinkedInAccountId` and `source`.\n- **A domain is required.** A file with no domain column is a usage error, and a row without a domain is `invalid` (`domain_required`).\n- **The dry run prices the research.** It asks for a credit estimate per 1,000 accounts and puts the sum in the plan: `kind`, `accountCount`, `totalMillicredits`, `availableMillicredits` and `sufficient`.\n- **Rows go 100 per call** to `POST /v1/accounts/bulk-create`.\n\nEach row comes back `created` (`id` is the new account; its research is queued, `researchQueued`, or waits for credits, `researchWaitingCredits`), `skipped` with reason `domain_taken` (already an account; `id` is that account) or `failed` (`reason` is the API\'s code, `error` names the field; an item Kenso failed to save is sent once more first). Rerunning the same file is safe: accounts that exist come back `domain_taken`.\n\n## Import people\n\n```bash\nkenso people import --file people.csv\nkenso people import --file people.csv --find-emails --yes\nkenso people import --file people.jsonl --dry-run\n```\n\n```csv\nfullName,email,title,accountDomain,role\nAnn Lee,ann@acme.io,VP Sales,acme.io,champion\nBob Ray,,CTO,acme.io,\n```\n\n- **Columns** map by name, ignoring case, spaces and dashes: `email`, `fullName` (or `name`), `firstName`, `lastName`, `title`, `linkedinUrl` (or `linkedin`, `profileUrl`), `accountDomain` (or `domain`, `website`, `companyDomain`), `accountId`, `role` and `priority`. Other columns are ignored with one warning.\n- **A person needs a name:** `fullName`, or `firstName`, `lastName` or both (the CLI joins them). A row with none of them is `invalid` (`name_required`).\n- **To put a person on an account,** give `accountDomain` or `accountId`. A row with both sends only `accountId`.\n- **`--find-emails`** queues an email find (charged in credits) for each person without an email.\n- **Rows go 200 per call** to `POST /v1/people/batch`.\n\nPeople already in the workspace are matched by email, then LinkedIn URL, so running the same file again creates nobody twice. A row comes back `created` (a new person), `updated` (an existing person added to the account), `skipped` with reason `already_on_account`, `matched` (no account asked) or `previously_removed`, or `failed`: `account_not_found` saves the person without an account (import the account, then rerun to place them), any other reason is the API\'s. The summary adds `matched`, `addedToAccounts` and `emailFindsQueued`.\n\n## List and search accounts\n\n`accounts list` and `accounts search` sort and page on the server, so they reach every account in the workspace, however many there are.\n\n```bash\nkenso accounts list --sort score:desc --limit 100 # one page; the output\'s next: line is the following one\nkenso accounts list --sort score:desc --limit 100 --all # every page, to the end\nkenso accounts search --search hiring --sort latestSignalAt:desc --data \'{"qFields": ["name", "latestSignal"]}\'\nkenso accounts search --limit 1 --data \'{"countBy": ["stage"]}\' # how many accounts sit in each stage\nkenso accounts search --data \'{"where": {"match": "all", "conditions": [{"field": "tier", "operator": "is", "values": ["1"]}]}, "sort": "tier,-pipelineAmount"}\' --all\n```\n\n- **`--sort`** takes up to 3 comma-separated keys, each `field` (ascending), `field:asc` or `field:desc`. The API\'s `-field` form needs the equals sign here, `--sort=-score`, because a value that starts with a dash reads as a flag. Fields: `createdAt`, `name`, `score`, `tier` (ascending is tier 1 first), `latestSignalAt`, `committee`, `pipelineAmount`, `nextTouchAt`, `lastTouchAt`. An account with no value for a key comes last in both directions. The default is `-createdAt`.\n- **`--limit`** is 1 to 1000 (default 50). `--cursor` takes the previous page\'s `nextCursor` with the same filters and sort; `--all` follows the cursors for you.\n- **`--search`** (also `--q`) matches the name or a domain.\n- **Lists and objects go in `--data`** on `search`, as the API takes them (`kenso describe accounts search`); a flag beside it sets or replaces one key:\n - `qFields` picks where the search text looks: `name`, `domain`, `latestSignal` (the latest signal\'s title).\n - `countBy` (`stage`, `stageGroup`) adds `counts` to the output: every value with the number of matching accounts that hold it, whatever the page. The output is then one object: `data`, `pagination` and `counts`.\n - `filters` and `where` narrow the accounts.\n\nAn account\'s timeline pages the same way. `kenso accounts activity 812` returns the newest 100 earlier rows and, when older ones exist, `data.nextCursor`. Pass it back as `--cursor` (with the same `--category`) for the rows before them, until a page comes without one.\n\n## Edit accounts, people and opportunities\n\nApart from `accounts bulk-update`, which sets one `accountType` on up to 500 accounts, there is no bulk edit route, so run the generated `update` command once per row with `--each`. Columns are the command\'s flags by API name or flag name, and the id column fills the route:\n\n```bash\nkenso accounts update --each accounts-edit.csv --dry-run # then the same with --yes\nkenso people update --each people-edit.csv --dry-run\nkenso opportunities update --each deals.csv --dry-run\n```\n\n```csv\naccountId,stage,ownerMemberId,overwritePinned\n501,engaged,42,true\n502,customer,42,true\n```\n\nA row that changes a field someone pinned in the app fails as a whole (`409 conflict`, `pinned_by_user`: nothing on that record changes, the other fields of the row included), unless the row sets `overwritePinned` to `true` (or you pass `--overwrite-pinned`, only with the person\'s OK). Every flag of an update command: `kenso accounts update --help`.\n\n## Search opportunities\n\n`kenso opportunities search` works as `accounts search` does: it takes `--search`, `--sort`, `--limit`, `--cursor`, `--all`, and its lists in `--data`.\n\n```bash\nkenso opportunities search --data \'{"filters": [{"field": "stageCategory", "operator": "is", "values": ["open"]}]}\' --all\nkenso opportunities search --data \'{"filters": [{"field": "ownerMemberId", "operator": "is", "values": ["none"]}, {"field": "closeDate", "operator": "is", "values": ["past_due", "next_30_days"]}]}\'\nkenso opportunities search --limit 1 --data \'{"countBy": ["stage", "ownerMemberId"]}\' # how many opportunities hold each value\n```\n\n- **`filters`** is a list of `{field, operator, values}`, all of which must hold. Fields: `stage` (a stage key), `stageCategory` (`open`, `won`, `lost`), `ownerMemberId`, `closeDate` (`past_due`, `next_30_days`, `later`, `none`) and `sourceCampaignId`. `operator` is `is` or `is_not`; the values of one condition are OR. `none` in `values` matches an opportunity with no owner, no source campaign or no close date.\n- **`countBy`** takes the same field names and adds `counts` to the output: per field, every value with the number of matching opportunities that hold it.\n- `--account-id` keeps the search to one account. `closeDate` counts days in the member\'s app time zone.\n\nOne person\'s deals, meetings and campaign contacts, as their person page lists them:\n\n```bash\nkenso opportunities list --person-id 9001 # the deals they are on, or are the primary person of\nkenso meetings list --person-id 9001 # the meetings they attend, among the ones you can see\nkenso contacts list --person-id 9001 # their contact in each campaign they are in\n```\n\n## Write research you gathered\n\n`accounts write-research` and `people write-research` store research you gathered outside Kenso as the record\'s latest research (`PUT /v1/accounts/{accountId}/research`, `PUT /v1/people/{personId}/research`). The Research tab shows it like a Ken run, with `trigger: agent` and `researchedAt` now. Nothing is charged, and no account or person field changes: set an account\'s own `fitScore`, `whyNow` or `angle` with `accounts update`. They need the `accounts_research` flag and accounts edit.\n\nThe body is the research block `accounts get --expand research` (or `people get-research`) returns, without its read-only fields: leave out `id`, `status`, `trigger`, `errorCode`, `researchedAt`, `isStale` and `appliedPrompt` (for a person also `mode`, `requestedAt`, `researchedMode`, `firecrawlCredits` and `webNote`), or the write fails with `unknown_field`. Pass it with `--data @file`:\n\n```bash\nkenso accounts write-research --account-id 501 --data @acme-dossier.json\nkenso people write-research --person-id 9001 --data @jane.json\n```\n\n```json\n{\n "tagline": { "text": "Payroll for EU contractors", "sourceUrls": ["https://acme.example"] },\n "description": { "text": "Acme runs payroll and compliance for companies hiring contractors in 30 EU countries.", "sourceUrls": ["https://acme.example"] },\n "links": { "website": "https://acme.example" },\n "whyNow": { "text": "Raised a $40M Series B in October", "sourceUrls": ["https://news.example/acme-b"], "date": "2026-10" },\n "fitScore": 82,\n "angle": "Lead with contractor onboarding time."\n}\n```\n\nMany records: one JSONL line per record, with the id next to the block\'s fields. Nested objects are sent as written. Use JSONL, not CSV: the block\'s fields are objects and lists, which a CSV cell cannot carry.\n\n```bash\nkenso accounts write-research --each dossiers.jsonl --dry-run # then the same with --yes\nkenso people write-research --each people-research.jsonl --yes --concurrency 8\n```\n\n```jsonl\n{"accountId": 501, "tagline": {"text": "Payroll for EU contractors"}, "links": {"website": "https://acme.example"}}\n{"accountId": 502, "description": {"text": "Cloud cost tooling for retailers."}, "links": {"website": "https://beta.example"}}\n```\n\nA row fails as a whole with the API\'s code: `validation_failed` (an unknown field is `unknown_field`, and `error.details` names every bad field), `research_in_progress` (`409`: Ken is researching that record now, write it again once the run ends; an account run waiting for credits counts too: it runs once the workspace has credits, and the write stays refused until that run ends) or `not_found`. Rerunning a file is safe: each write replaces the record\'s research shown.\n\n## CRM sync\n\nCRM sync has generated commands only: read connections, preview, start an import, and work through sync issues. Connect the CRM itself in the app.\n\n```bash\nkenso crm-connections list\nkenso crm-connections get --connection-id 7\nkenso crm-imports create --connection-id 7 --dry-run\nkenso crm-sync-issues list --connection-id 7 --all\n```\n\nRun `kenso crm-connections --help` (or add `--all-commands` when the actions are hidden) to see every action.\n\n## A deal\'s stage history\n\n```bash\nkenso opportunities stage-history 77\nkenso opportunities stage-history 77 --query "entries[].{to: stageLabel, at: enteredAt, by: changedBy}"\n```\n\nIt prints `GET /v1/opportunities/{id}/stage-history` as it is, the same rows as the deal page and the MCP\'s `opportunities(operation="get-stage-history")`: the stage now, `isComplete` and `entries`, oldest first, each with `fromStage`, `stage`, `stageLabel`, `enteredAt`, `leftAt`, `durationSeconds`, `actorKind`, `actorMemberId` and Ken\'s `reason` on a move its stage judge made. With the `deal_stage_rules` flag on, each entry also has `changedBy` (`member`, `agent`, `api_key`, `workflow`, `stage_judge`, `crm_sync` or `ken_automation`), `crmProvider` on a CRM sync, and on a move `fromStageLabel` and `fromStageDurationSeconds`, how long the deal sat in the stage it left. `isComplete` false means Kenso has no record of part of the history.\n';
|
|
7267
7270
|
}
|
|
7268
7271
|
});
|
|
7269
7272
|
|
|
@@ -8400,8 +8403,8 @@ var init_browser_login = __esm({
|
|
|
8400
8403
|
defaultDeps = {
|
|
8401
8404
|
sleep: (ms, signal) => delay2(ms, void 0, signal ? { signal } : void 0),
|
|
8402
8405
|
now: () => Date.now(),
|
|
8403
|
-
spawn: (
|
|
8404
|
-
const child = nodeSpawn(
|
|
8406
|
+
spawn: (command48, args) => {
|
|
8407
|
+
const child = nodeSpawn(command48, args, { detached: true, stdio: "ignore" });
|
|
8405
8408
|
child.on("error", () => {
|
|
8406
8409
|
});
|
|
8407
8410
|
child.unref();
|
|
@@ -8773,13 +8776,191 @@ var init_status2 = __esm({
|
|
|
8773
8776
|
}
|
|
8774
8777
|
});
|
|
8775
8778
|
|
|
8779
|
+
// src/commands/capture/connect.ts
|
|
8780
|
+
var connect_exports = {};
|
|
8781
|
+
__export(connect_exports, {
|
|
8782
|
+
default: () => connect_default
|
|
8783
|
+
});
|
|
8784
|
+
var PROVIDERS, command9, connect_default;
|
|
8785
|
+
var init_connect = __esm({
|
|
8786
|
+
"src/commands/capture/connect.ts"() {
|
|
8787
|
+
"use strict";
|
|
8788
|
+
init_errors();
|
|
8789
|
+
init_exit_codes();
|
|
8790
|
+
init_http();
|
|
8791
|
+
PROVIDERS = ["google", "microsoft"];
|
|
8792
|
+
command9 = {
|
|
8793
|
+
resource: "capture",
|
|
8794
|
+
action: "connect",
|
|
8795
|
+
summary: "Turn capture on for your own mailbox",
|
|
8796
|
+
description: "Sends PUT /v1/capture/mailbox. Kenso then logs your email with people in Kenso on the person, the account and its open deals, starting with the newest mail and going back 90 days; kenso capture status shows the progress. Running it again changes nothing. It uses the Google or Microsoft account you connected in Kenso with email access. With none, the answer is mailbox_not_connected: run it with --provider to get a sign-in link (POST /v1/calendar-accounts/connect-sessions), open the link, sign in, then run kenso capture connect again. other_mailbox_connected means your captured mailbox needs its sign-in again and the account connected now is another one: sign in to the captured mailbox again, or run kenso capture disconnect and then connect.",
|
|
8797
|
+
flags: {
|
|
8798
|
+
private: { type: "boolean", description: "Start with the Private switch on: teammates see none of this mailbox's email" },
|
|
8799
|
+
provider: { type: "string", description: "google or microsoft: when no account is connected yet, print the sign-in link for one" }
|
|
8800
|
+
},
|
|
8801
|
+
examples: ["kenso capture connect", "kenso capture connect --private", "kenso capture connect --provider google"],
|
|
8802
|
+
beta: { featureGates: { all: ["crm_capture"] } },
|
|
8803
|
+
operationIds: ["capture-mailbox.connect", "calendar-accounts.create-connect-session"],
|
|
8804
|
+
async run(ctx, { flags }) {
|
|
8805
|
+
const provider = typeof flags.provider === "string" ? flags.provider : void 0;
|
|
8806
|
+
if (provider !== void 0 && !PROVIDERS.includes(provider)) {
|
|
8807
|
+
throw usageError("--provider is google or microsoft.", { field: "provider" });
|
|
8808
|
+
}
|
|
8809
|
+
try {
|
|
8810
|
+
const res = await ctx.client.request({
|
|
8811
|
+
method: "PUT",
|
|
8812
|
+
path: "/v1/capture/mailbox",
|
|
8813
|
+
body: flags.private === true ? { isPrivate: true } : {},
|
|
8814
|
+
signal: ctx.signal
|
|
8815
|
+
});
|
|
8816
|
+
ctx.output.object(unwrap(res.body));
|
|
8817
|
+
return ExitCode.Ok;
|
|
8818
|
+
} catch (err) {
|
|
8819
|
+
if (!(err instanceof KensoError) || err.code !== "mailbox_not_connected") throw err;
|
|
8820
|
+
if (provider === void 0) {
|
|
8821
|
+
throw new KensoError({
|
|
8822
|
+
code: err.code,
|
|
8823
|
+
message: "No Google or Microsoft account with email access is connected for you in Kenso.",
|
|
8824
|
+
exitCode: err.exitCode,
|
|
8825
|
+
httpStatus: err.httpStatus,
|
|
8826
|
+
requestId: err.requestId,
|
|
8827
|
+
hint: "Get a sign-in link with --provider google or --provider microsoft, open it, then run kenso capture connect again.",
|
|
8828
|
+
next: "kenso capture connect --provider google"
|
|
8829
|
+
});
|
|
8830
|
+
}
|
|
8831
|
+
const session = await ctx.client.request({
|
|
8832
|
+
method: "POST",
|
|
8833
|
+
path: "/v1/calendar-accounts/connect-sessions",
|
|
8834
|
+
body: { provider, access: "calendar_and_email" },
|
|
8835
|
+
signal: ctx.signal
|
|
8836
|
+
});
|
|
8837
|
+
ctx.output.object({ status: "sign_in_needed", ...unwrap(session.body), next: "kenso capture connect" });
|
|
8838
|
+
return ExitCode.Ok;
|
|
8839
|
+
}
|
|
8840
|
+
}
|
|
8841
|
+
};
|
|
8842
|
+
connect_default = command9;
|
|
8843
|
+
}
|
|
8844
|
+
});
|
|
8845
|
+
|
|
8846
|
+
// src/commands/capture/private.ts
|
|
8847
|
+
var private_exports = {};
|
|
8848
|
+
__export(private_exports, {
|
|
8849
|
+
default: () => private_default
|
|
8850
|
+
});
|
|
8851
|
+
var command10, private_default;
|
|
8852
|
+
var init_private = __esm({
|
|
8853
|
+
"src/commands/capture/private.ts"() {
|
|
8854
|
+
"use strict";
|
|
8855
|
+
init_errors();
|
|
8856
|
+
init_exit_codes();
|
|
8857
|
+
init_http();
|
|
8858
|
+
command10 = {
|
|
8859
|
+
resource: "capture",
|
|
8860
|
+
action: "private",
|
|
8861
|
+
summary: "Hide your captured email from teammates, or show it again",
|
|
8862
|
+
description: "Sends PATCH /v1/capture/mailbox with isPrivate. on hides your captured email from teammates, mail already captured included: a teammate sees no trace of a thread only your mailbox holds, and a private mailbox creates no people or accounts. A message a teammate's own mailbox also holds stays visible through theirs. off shows your email again as the workspace setting allows. Email only: meetings stay visible, and Ken still reads the mailbox for you.",
|
|
8863
|
+
flags: {},
|
|
8864
|
+
positionals: [{ name: "state", required: true, description: "on or off" }],
|
|
8865
|
+
examples: ["kenso capture private on", "kenso capture private off"],
|
|
8866
|
+
beta: { featureGates: { all: ["crm_capture"] } },
|
|
8867
|
+
operationIds: ["capture-mailbox.update"],
|
|
8868
|
+
async run(ctx, { positionals }) {
|
|
8869
|
+
const state = positionals[0];
|
|
8870
|
+
if (state !== "on" && state !== "off") throw usageError("Say on or off: kenso capture private on.", { field: "state" });
|
|
8871
|
+
const res = await ctx.client.request({
|
|
8872
|
+
method: "PATCH",
|
|
8873
|
+
path: "/v1/capture/mailbox",
|
|
8874
|
+
body: { isPrivate: state === "on" },
|
|
8875
|
+
signal: ctx.signal
|
|
8876
|
+
});
|
|
8877
|
+
ctx.output.object(unwrap(res.body));
|
|
8878
|
+
return ExitCode.Ok;
|
|
8879
|
+
}
|
|
8880
|
+
};
|
|
8881
|
+
private_default = command10;
|
|
8882
|
+
}
|
|
8883
|
+
});
|
|
8884
|
+
|
|
8885
|
+
// src/commands/capture/disconnect.ts
|
|
8886
|
+
var disconnect_exports = {};
|
|
8887
|
+
__export(disconnect_exports, {
|
|
8888
|
+
default: () => disconnect_default
|
|
8889
|
+
});
|
|
8890
|
+
var command11, disconnect_default;
|
|
8891
|
+
var init_disconnect = __esm({
|
|
8892
|
+
"src/commands/capture/disconnect.ts"() {
|
|
8893
|
+
"use strict";
|
|
8894
|
+
init_confirm();
|
|
8895
|
+
init_exit_codes();
|
|
8896
|
+
command11 = {
|
|
8897
|
+
resource: "capture",
|
|
8898
|
+
action: "disconnect",
|
|
8899
|
+
summary: "Turn capture off for your own mailbox and delete its stored email bodies",
|
|
8900
|
+
description: "Sends DELETE /v1/capture/mailbox. Sync stops and Kenso deletes the stored body of every email only your mailbox holds. Subject, people, time and Ken's summary stay on the records. Your Google or Microsoft account stays connected for calendar and scheduling. Deleted bodies do not come back, so it asks first: add --yes to run it without the question.",
|
|
8901
|
+
flags: {},
|
|
8902
|
+
examples: ["kenso capture disconnect --yes"],
|
|
8903
|
+
beta: { featureGates: { all: ["crm_capture"] } },
|
|
8904
|
+
operationIds: ["capture-mailbox.disconnect"],
|
|
8905
|
+
async run(ctx) {
|
|
8906
|
+
await confirmDestructive(ctx, "This turns capture off and deletes your stored email bodies", "kenso capture disconnect --yes");
|
|
8907
|
+
await ctx.client.request({ method: "DELETE", path: "/v1/capture/mailbox", signal: ctx.signal });
|
|
8908
|
+
ctx.output.object({ disconnected: true });
|
|
8909
|
+
return ExitCode.Ok;
|
|
8910
|
+
}
|
|
8911
|
+
};
|
|
8912
|
+
disconnect_default = command11;
|
|
8913
|
+
}
|
|
8914
|
+
});
|
|
8915
|
+
|
|
8916
|
+
// src/commands/capture/teammates-see.ts
|
|
8917
|
+
var teammates_see_exports = {};
|
|
8918
|
+
__export(teammates_see_exports, {
|
|
8919
|
+
default: () => teammates_see_default
|
|
8920
|
+
});
|
|
8921
|
+
var VALUES, command12, teammates_see_default;
|
|
8922
|
+
var init_teammates_see = __esm({
|
|
8923
|
+
"src/commands/capture/teammates-see.ts"() {
|
|
8924
|
+
"use strict";
|
|
8925
|
+
init_errors();
|
|
8926
|
+
init_exit_codes();
|
|
8927
|
+
init_http();
|
|
8928
|
+
VALUES = ["summary", "full_email"];
|
|
8929
|
+
command12 = {
|
|
8930
|
+
resource: "capture",
|
|
8931
|
+
action: "teammates-see",
|
|
8932
|
+
summary: "Pick what teammates see of captured email: the summary, or the full email (workspace admin)",
|
|
8933
|
+
description: "Sends PATCH /v1/capture with teammatesSee. summary (the default): teammates read subject, people, time and Ken's summary, and only the mailbox owner opens the body. full_email: every member can open a captured body. It applies to every read from then on, mail already captured included. A member's Private switch still hides their email either way. Only a workspace admin can change it.",
|
|
8934
|
+
flags: {},
|
|
8935
|
+
positionals: [{ name: "value", required: true, description: "summary or full_email" }],
|
|
8936
|
+
examples: ["kenso capture teammates-see summary", "kenso capture teammates-see full_email"],
|
|
8937
|
+
beta: { featureGates: { all: ["crm_capture"] } },
|
|
8938
|
+
operationIds: ["capture.update"],
|
|
8939
|
+
async run(ctx, { positionals }) {
|
|
8940
|
+
const value = positionals[0];
|
|
8941
|
+
if (value === void 0 || !VALUES.includes(value)) {
|
|
8942
|
+
throw usageError("Say summary or full_email: kenso capture teammates-see summary.", { field: "value" });
|
|
8943
|
+
}
|
|
8944
|
+
const res = await ctx.client.request({ method: "PATCH", path: "/v1/capture", body: { teammatesSee: value }, signal: ctx.signal });
|
|
8945
|
+
ctx.output.object(unwrap(res.body));
|
|
8946
|
+
return ExitCode.Ok;
|
|
8947
|
+
}
|
|
8948
|
+
};
|
|
8949
|
+
teammates_see_default = command12;
|
|
8950
|
+
}
|
|
8951
|
+
});
|
|
8952
|
+
|
|
8776
8953
|
// src/commands/capture/index.ts
|
|
8777
8954
|
var actions5;
|
|
8778
8955
|
var init_capture = __esm({
|
|
8779
8956
|
"src/commands/capture/index.ts"() {
|
|
8780
8957
|
"use strict";
|
|
8781
8958
|
actions5 = {
|
|
8782
|
-
status: () => Promise.resolve().then(() => (init_status2(), status_exports2)).then((m) => m.default)
|
|
8959
|
+
status: () => Promise.resolve().then(() => (init_status2(), status_exports2)).then((m) => m.default),
|
|
8960
|
+
connect: () => Promise.resolve().then(() => (init_connect(), connect_exports)).then((m) => m.default),
|
|
8961
|
+
private: () => Promise.resolve().then(() => (init_private(), private_exports)).then((m) => m.default),
|
|
8962
|
+
disconnect: () => Promise.resolve().then(() => (init_disconnect(), disconnect_exports)).then((m) => m.default),
|
|
8963
|
+
"teammates-see": () => Promise.resolve().then(() => (init_teammates_see(), teammates_see_exports)).then((m) => m.default)
|
|
8783
8964
|
};
|
|
8784
8965
|
}
|
|
8785
8966
|
});
|
|
@@ -8790,7 +8971,7 @@ __export(completion_exports, {
|
|
|
8790
8971
|
SCRIPTS: () => SCRIPTS,
|
|
8791
8972
|
default: () => completion_default
|
|
8792
8973
|
});
|
|
8793
|
-
var ZSH, BASH, FISH, SCRIPTS,
|
|
8974
|
+
var ZSH, BASH, FISH, SCRIPTS, command13, completion_default;
|
|
8794
8975
|
var init_completion = __esm({
|
|
8795
8976
|
"src/commands/completion/completion.ts"() {
|
|
8796
8977
|
"use strict";
|
|
@@ -8854,7 +9035,7 @@ end
|
|
|
8854
9035
|
complete -c kenso -f -a '(__kenso_complete)'
|
|
8855
9036
|
`;
|
|
8856
9037
|
SCRIPTS = { bash: BASH, zsh: ZSH, fish: FISH };
|
|
8857
|
-
|
|
9038
|
+
command13 = {
|
|
8858
9039
|
resource: "completion",
|
|
8859
9040
|
action: "",
|
|
8860
9041
|
summary: "Print the tab-completion script for bash, zsh or fish",
|
|
@@ -8882,7 +9063,7 @@ complete -c kenso -f -a '(__kenso_complete)'
|
|
|
8882
9063
|
return ExitCode.Ok;
|
|
8883
9064
|
}
|
|
8884
9065
|
};
|
|
8885
|
-
completion_default =
|
|
9066
|
+
completion_default = command13;
|
|
8886
9067
|
}
|
|
8887
9068
|
});
|
|
8888
9069
|
|
|
@@ -8907,9 +9088,9 @@ function stringFlag2(flags, name) {
|
|
|
8907
9088
|
const text3 = value.trim();
|
|
8908
9089
|
return text3 === "" ? void 0 : text3;
|
|
8909
9090
|
}
|
|
8910
|
-
function requireFlag(flags, name,
|
|
9091
|
+
function requireFlag(flags, name, command48, hint) {
|
|
8911
9092
|
const value = stringFlag2(flags, name);
|
|
8912
|
-
if (value === void 0) throw usageError(`--${name} is required for ${
|
|
9093
|
+
if (value === void 0) throw usageError(`--${name} is required for ${command48}.`, { field: name, next: `${command48} --help`, ...hint ? { hint } : {} });
|
|
8913
9094
|
return value;
|
|
8914
9095
|
}
|
|
8915
9096
|
function positiveId(value) {
|
|
@@ -8918,8 +9099,8 @@ function positiveId(value) {
|
|
|
8918
9099
|
const id = Number(text3);
|
|
8919
9100
|
return Number.isSafeInteger(id) && id > 0 ? id : void 0;
|
|
8920
9101
|
}
|
|
8921
|
-
function idFlag(flags, name,
|
|
8922
|
-
const raw = requireFlag(flags, name,
|
|
9102
|
+
function idFlag(flags, name, command48) {
|
|
9103
|
+
const raw = requireFlag(flags, name, command48);
|
|
8923
9104
|
const id = positiveId(raw);
|
|
8924
9105
|
if (id === void 0) throw usageError(`--${name} must be a positive whole number (got "${raw}").`, { field: name });
|
|
8925
9106
|
return id;
|
|
@@ -8939,8 +9120,8 @@ function isDryRun(ctx) {
|
|
|
8939
9120
|
function shellQuote4(value) {
|
|
8940
9121
|
return /^[A-Za-z0-9_\-.,:/@=+%]+$/.test(value) ? value : `'${value.replace(/'/g, `'\\''`)}'`;
|
|
8941
9122
|
}
|
|
8942
|
-
function sameCommand2(
|
|
8943
|
-
const parts2 = [
|
|
9123
|
+
function sameCommand2(command48, flags, ctx, extra = []) {
|
|
9124
|
+
const parts2 = [command48];
|
|
8944
9125
|
for (const [name, value] of Object.entries(flags)) {
|
|
8945
9126
|
if (value === void 0 || value === false) continue;
|
|
8946
9127
|
if (value === true) parts2.push(`--${name}`);
|
|
@@ -9540,7 +9721,7 @@ function parseDuration(text3) {
|
|
|
9540
9721
|
const ms = Number(match[1]) * (UNIT_MS[(match[2] || "s").toLowerCase()] ?? 1e3);
|
|
9541
9722
|
return Number.isFinite(ms) ? Math.round(ms) : void 0;
|
|
9542
9723
|
}
|
|
9543
|
-
var UNIT_MS,
|
|
9724
|
+
var UNIT_MS, command14, wait_default;
|
|
9544
9725
|
var init_wait = __esm({
|
|
9545
9726
|
"src/commands/jobs/wait.ts"() {
|
|
9546
9727
|
"use strict";
|
|
@@ -9548,7 +9729,7 @@ var init_wait = __esm({
|
|
|
9548
9729
|
init_errors();
|
|
9549
9730
|
init_exit_codes();
|
|
9550
9731
|
UNIT_MS = { s: 1e3, m: 6e4, h: 36e5 };
|
|
9551
|
-
|
|
9732
|
+
command14 = {
|
|
9552
9733
|
resource: "jobs",
|
|
9553
9734
|
action: "wait",
|
|
9554
9735
|
summary: "Wait for a background job and print it",
|
|
@@ -9587,7 +9768,7 @@ var init_wait = __esm({
|
|
|
9587
9768
|
});
|
|
9588
9769
|
}
|
|
9589
9770
|
};
|
|
9590
|
-
wait_default =
|
|
9771
|
+
wait_default = command14;
|
|
9591
9772
|
}
|
|
9592
9773
|
});
|
|
9593
9774
|
|
|
@@ -9769,7 +9950,7 @@ function summarize2(campaignId) {
|
|
|
9769
9950
|
notSendable: results.filter((r) => (r.status === "created" || r.status === "updated") && r.sendable === false).length
|
|
9770
9951
|
});
|
|
9771
9952
|
}
|
|
9772
|
-
var COMMAND2, CHUNK_SIZE2, LINKEDIN_ONLY_CHANNELS, TEMPLATE_HEADER,
|
|
9953
|
+
var COMMAND2, CHUNK_SIZE2, LINKEDIN_ONLY_CHANNELS, TEMPLATE_HEADER, command15, import_default2;
|
|
9773
9954
|
var init_import2 = __esm({
|
|
9774
9955
|
"src/commands/contacts/import.ts"() {
|
|
9775
9956
|
"use strict";
|
|
@@ -9788,7 +9969,7 @@ var init_import2 = __esm({
|
|
|
9788
9969
|
CHUNK_SIZE2 = 1e3;
|
|
9789
9970
|
LINKEDIN_ONLY_CHANNELS = /* @__PURE__ */ new Set(["linkedin", "linkedin_only"]);
|
|
9790
9971
|
TEMPLATE_HEADER = `${CONTACT_FIELDS.join(",")},<your custom columns>`;
|
|
9791
|
-
|
|
9972
|
+
command15 = {
|
|
9792
9973
|
resource: "contacts",
|
|
9793
9974
|
action: "import",
|
|
9794
9975
|
summary: "Add leads from a CSV or JSONL file to a campaign",
|
|
@@ -9877,7 +10058,7 @@ var init_import2 = __esm({
|
|
|
9877
10058
|
return outcome.exitCode;
|
|
9878
10059
|
}
|
|
9879
10060
|
};
|
|
9880
|
-
import_default2 =
|
|
10061
|
+
import_default2 = command15;
|
|
9881
10062
|
}
|
|
9882
10063
|
});
|
|
9883
10064
|
|
|
@@ -9981,7 +10162,7 @@ async function sendUpdateChunk(chunk, ctx) {
|
|
|
9981
10162
|
});
|
|
9982
10163
|
return { results: mapUpdateAnswer(chunk, res.body), rateLimitRemaining: rateLimitRemaining3(res.headers) };
|
|
9983
10164
|
}
|
|
9984
|
-
var COMMAND3, CHUNK_SIZE3, PAGE_SIZE,
|
|
10165
|
+
var COMMAND3, CHUNK_SIZE3, PAGE_SIZE, command16, update_default;
|
|
9985
10166
|
var init_update = __esm({
|
|
9986
10167
|
"src/commands/contacts/update.ts"() {
|
|
9987
10168
|
"use strict";
|
|
@@ -9995,7 +10176,7 @@ var init_update = __esm({
|
|
|
9995
10176
|
COMMAND3 = "kenso contacts update";
|
|
9996
10177
|
CHUNK_SIZE3 = 1e3;
|
|
9997
10178
|
PAGE_SIZE = 200;
|
|
9998
|
-
|
|
10179
|
+
command16 = {
|
|
9999
10180
|
resource: "contacts",
|
|
10000
10181
|
action: "update",
|
|
10001
10182
|
summary: "Edit leads from a CSV or JSONL file, by id or email (also one lead)",
|
|
@@ -10066,7 +10247,7 @@ var init_update = __esm({
|
|
|
10066
10247
|
return outcome.exitCode;
|
|
10067
10248
|
}
|
|
10068
10249
|
};
|
|
10069
|
-
update_default =
|
|
10250
|
+
update_default = command16;
|
|
10070
10251
|
}
|
|
10071
10252
|
});
|
|
10072
10253
|
|
|
@@ -10077,12 +10258,12 @@ import { join as join11 } from "node:path";
|
|
|
10077
10258
|
function whereDir(env) {
|
|
10078
10259
|
return join11(runsRoot(env), WHERE_DIR);
|
|
10079
10260
|
}
|
|
10080
|
-
async function unfinishedWhereIds(ctx,
|
|
10261
|
+
async function unfinishedWhereIds(ctx, command48, args) {
|
|
10081
10262
|
const dir = whereDir(ctx.env);
|
|
10082
10263
|
const identity = argsIdentity(args);
|
|
10083
10264
|
const workspaceId = ctx.client.workspaceId ?? ctx.auth.workspaceId;
|
|
10084
10265
|
for (const run of await listRuns(ctx.env)) {
|
|
10085
|
-
if (run.command !==
|
|
10266
|
+
if (run.command !== command48 || run.status === "done" || run.status === "planned") continue;
|
|
10086
10267
|
if ((run.workspaceId || void 0) !== (workspaceId || void 0) || argsIdentity(run.args) !== identity) continue;
|
|
10087
10268
|
if (run.inputPath?.startsWith(`${dir}/`) && existsSync5(run.inputPath)) return run.inputPath;
|
|
10088
10269
|
}
|
|
@@ -10228,14 +10409,14 @@ async function idsFromRun(ctx, runId) {
|
|
|
10228
10409
|
return { ...idItems(ids2), source: "run" };
|
|
10229
10410
|
}
|
|
10230
10411
|
async function collectIds(ctx, flags, kind, dryRun2) {
|
|
10231
|
-
const
|
|
10412
|
+
const command48 = `kenso contacts ${kind}`;
|
|
10232
10413
|
const ids2 = stringFlag2(flags, "ids");
|
|
10233
10414
|
const where = kind === "restore" ? void 0 : stringFlag2(flags, "where");
|
|
10234
10415
|
const run = kind === "restore" ? stringFlag2(flags, "run") : void 0;
|
|
10235
10416
|
const given = [ids2, where, run].filter((v) => v !== void 0).length;
|
|
10236
10417
|
if (given !== 1) {
|
|
10237
10418
|
const choices = kind === "restore" ? "--ids <file|-> or --run <runId>" : "--ids <file|-> or --where '<json>'";
|
|
10238
|
-
throw usageError(`${
|
|
10419
|
+
throw usageError(`${command48} needs exactly one of ${choices}.`, { field: "ids", next: `${command48} --help` });
|
|
10239
10420
|
}
|
|
10240
10421
|
if (ids2 !== void 0) return idsFromFile(ctx, ids2);
|
|
10241
10422
|
if (where !== void 0) return idsFromWhere(ctx, kind, flags, where, dryRun2);
|
|
@@ -10537,7 +10718,7 @@ async function download(ctx, job, exportId, out) {
|
|
|
10537
10718
|
}
|
|
10538
10719
|
return { rows: countRows(body), path };
|
|
10539
10720
|
}
|
|
10540
|
-
var COMMAND4, JOB_TYPE, DEFAULT_TIMEOUT2, CONTENT_PATH,
|
|
10721
|
+
var COMMAND4, JOB_TYPE, DEFAULT_TIMEOUT2, CONTENT_PATH, command17, export_default;
|
|
10541
10722
|
var init_export = __esm({
|
|
10542
10723
|
"src/commands/contacts/export.ts"() {
|
|
10543
10724
|
"use strict";
|
|
@@ -10552,7 +10733,7 @@ var init_export = __esm({
|
|
|
10552
10733
|
JOB_TYPE = "contact_export";
|
|
10553
10734
|
DEFAULT_TIMEOUT2 = "30m";
|
|
10554
10735
|
CONTENT_PATH = /\/v1\/contact-exports\/([0-9]+)\/content/;
|
|
10555
|
-
|
|
10736
|
+
command17 = {
|
|
10556
10737
|
resource: "contacts",
|
|
10557
10738
|
action: "export",
|
|
10558
10739
|
summary: "Export a campaign's contacts to CSV (a segment: contact-exports create)",
|
|
@@ -10610,7 +10791,7 @@ var init_export = __esm({
|
|
|
10610
10791
|
return ExitCode.Ok;
|
|
10611
10792
|
}
|
|
10612
10793
|
};
|
|
10613
|
-
export_default =
|
|
10794
|
+
export_default = command17;
|
|
10614
10795
|
}
|
|
10615
10796
|
});
|
|
10616
10797
|
|
|
@@ -10734,7 +10915,7 @@ function unknown(words) {
|
|
|
10734
10915
|
next: "kenso describe"
|
|
10735
10916
|
});
|
|
10736
10917
|
}
|
|
10737
|
-
var
|
|
10918
|
+
var command18, describe_default;
|
|
10738
10919
|
var init_describe = __esm({
|
|
10739
10920
|
"src/commands/describe/describe.ts"() {
|
|
10740
10921
|
"use strict";
|
|
@@ -10747,7 +10928,7 @@ var init_describe = __esm({
|
|
|
10747
10928
|
init_manifest();
|
|
10748
10929
|
init_help();
|
|
10749
10930
|
init_registry();
|
|
10750
|
-
|
|
10931
|
+
command18 = {
|
|
10751
10932
|
resource: "describe",
|
|
10752
10933
|
action: "",
|
|
10753
10934
|
summary: "The command map as JSON: commands, flags, body schemas",
|
|
@@ -10788,7 +10969,7 @@ var init_describe = __esm({
|
|
|
10788
10969
|
return ExitCode.Ok;
|
|
10789
10970
|
}
|
|
10790
10971
|
};
|
|
10791
|
-
describe_default =
|
|
10972
|
+
describe_default = command18;
|
|
10792
10973
|
}
|
|
10793
10974
|
});
|
|
10794
10975
|
|
|
@@ -10812,7 +10993,7 @@ function findTopic(input) {
|
|
|
10812
10993
|
const name = input.trim().toLowerCase().replace(/\.md$/, "");
|
|
10813
10994
|
return TOPICS.find((t) => t.topic === name);
|
|
10814
10995
|
}
|
|
10815
|
-
var NAMES,
|
|
10996
|
+
var NAMES, command19, docs_default;
|
|
10816
10997
|
var init_docs = __esm({
|
|
10817
10998
|
"src/commands/docs/docs.ts"() {
|
|
10818
10999
|
"use strict";
|
|
@@ -10820,7 +11001,7 @@ var init_docs = __esm({
|
|
|
10820
11001
|
init_exit_codes();
|
|
10821
11002
|
init_content();
|
|
10822
11003
|
NAMES = TOPICS.map((t) => t.topic).join(", ");
|
|
10823
|
-
|
|
11004
|
+
command19 = {
|
|
10824
11005
|
resource: "docs",
|
|
10825
11006
|
action: "",
|
|
10826
11007
|
summary: "Offline docs: the topic list, or one topic",
|
|
@@ -10861,7 +11042,7 @@ var init_docs = __esm({
|
|
|
10861
11042
|
return ExitCode.Ok;
|
|
10862
11043
|
}
|
|
10863
11044
|
};
|
|
10864
|
-
docs_default =
|
|
11045
|
+
docs_default = command19;
|
|
10865
11046
|
}
|
|
10866
11047
|
});
|
|
10867
11048
|
|
|
@@ -10899,7 +11080,7 @@ function configCheck(env) {
|
|
|
10899
11080
|
const octal = mode.toString(8).padStart(4, "0");
|
|
10900
11081
|
return mode === 384 ? { name: "config_permissions", ok: true, detail: `${file} is ${octal}` } : { name: "config_permissions", ok: false, detail: `${file} is ${octal}: run chmod 600 ${file}` };
|
|
10901
11082
|
}
|
|
10902
|
-
var MIN_NODE_MAJOR,
|
|
11083
|
+
var MIN_NODE_MAJOR, command20, actions10;
|
|
10903
11084
|
var init_doctor = __esm({
|
|
10904
11085
|
"src/commands/doctor/index.ts"() {
|
|
10905
11086
|
"use strict";
|
|
@@ -10908,7 +11089,7 @@ var init_doctor = __esm({
|
|
|
10908
11089
|
init_exit_codes();
|
|
10909
11090
|
init_http();
|
|
10910
11091
|
MIN_NODE_MAJOR = 22;
|
|
10911
|
-
|
|
11092
|
+
command20 = {
|
|
10912
11093
|
resource: "doctor",
|
|
10913
11094
|
action: "",
|
|
10914
11095
|
summary: "Check Node, the config, the API and the key",
|
|
@@ -10973,7 +11154,7 @@ var init_doctor = __esm({
|
|
|
10973
11154
|
}
|
|
10974
11155
|
};
|
|
10975
11156
|
actions10 = {
|
|
10976
|
-
"": async () =>
|
|
11157
|
+
"": async () => command20
|
|
10977
11158
|
};
|
|
10978
11159
|
}
|
|
10979
11160
|
});
|
|
@@ -11016,7 +11197,7 @@ function readable(row) {
|
|
|
11016
11197
|
const parts2 = [time, `[${row.status}]`, row.method, row.pathTemplate, row.errorCode, `${row.durationMs}ms`, row.apiKeyId, row.requestId];
|
|
11017
11198
|
return parts2.filter((p) => p !== void 0 && p !== "").join(" ");
|
|
11018
11199
|
}
|
|
11019
|
-
var MIN_INTERVAL_MS, MAX_INTERVAL_MS, MAX_SINCE_MS, OVERLAP_MS, MAX_PAGES, RATE_LIMITED_WAIT_MS, isOwnPoll, pad,
|
|
11200
|
+
var MIN_INTERVAL_MS, MAX_INTERVAL_MS, MAX_SINCE_MS, OVERLAP_MS, MAX_PAGES, RATE_LIMITED_WAIT_MS, isOwnPoll, pad, command21, tail_default;
|
|
11020
11201
|
var init_tail = __esm({
|
|
11021
11202
|
"src/commands/logs/tail.ts"() {
|
|
11022
11203
|
"use strict";
|
|
@@ -11032,7 +11213,7 @@ var init_tail = __esm({
|
|
|
11032
11213
|
RATE_LIMITED_WAIT_MS = 3e4;
|
|
11033
11214
|
isOwnPoll = (row) => row.method === "GET" && row.pathTemplate === "/v1/api-requests" && row.userAgent?.startsWith("kenso-cli/") === true;
|
|
11034
11215
|
pad = (n) => String(n).padStart(2, "0");
|
|
11035
|
-
|
|
11216
|
+
command21 = {
|
|
11036
11217
|
resource: "logs",
|
|
11037
11218
|
action: "tail",
|
|
11038
11219
|
summary: "Stream your workspace's new API request log rows",
|
|
@@ -11138,7 +11319,7 @@ var init_tail = __esm({
|
|
|
11138
11319
|
return ExitCode.Ok;
|
|
11139
11320
|
}
|
|
11140
11321
|
};
|
|
11141
|
-
tail_default =
|
|
11322
|
+
tail_default = command21;
|
|
11142
11323
|
}
|
|
11143
11324
|
});
|
|
11144
11325
|
|
|
@@ -11183,7 +11364,7 @@ function writeRaw(ctx, text3) {
|
|
|
11183
11364
|
ctx.output.writeRaw(text3.endsWith("\n") ? text3 : `${text3}
|
|
11184
11365
|
`);
|
|
11185
11366
|
}
|
|
11186
|
-
var
|
|
11367
|
+
var init_connect2 = __esm({
|
|
11187
11368
|
"src/commands/mcp/connect.ts"() {
|
|
11188
11369
|
"use strict";
|
|
11189
11370
|
init_errors();
|
|
@@ -11203,15 +11384,15 @@ function isRecord6(value) {
|
|
|
11203
11384
|
function textOf(result) {
|
|
11204
11385
|
return (result.content ?? []).filter((part) => part.type === "text" && typeof part.text === "string").map((part) => part.text).join("\n");
|
|
11205
11386
|
}
|
|
11206
|
-
var
|
|
11387
|
+
var command22, call_default;
|
|
11207
11388
|
var init_call = __esm({
|
|
11208
11389
|
"src/commands/mcp/call.ts"() {
|
|
11209
11390
|
"use strict";
|
|
11210
11391
|
init_errors();
|
|
11211
11392
|
init_exit_codes();
|
|
11212
11393
|
init_input();
|
|
11213
|
-
|
|
11214
|
-
|
|
11394
|
+
init_connect2();
|
|
11395
|
+
command22 = {
|
|
11215
11396
|
resource: "mcp",
|
|
11216
11397
|
action: "call",
|
|
11217
11398
|
summary: "Call a hosted Kenso MCP tool, such as list_skills",
|
|
@@ -11264,7 +11445,7 @@ var init_call = __esm({
|
|
|
11264
11445
|
return ExitCode.Ok;
|
|
11265
11446
|
}
|
|
11266
11447
|
};
|
|
11267
|
-
call_default =
|
|
11448
|
+
call_default = command22;
|
|
11268
11449
|
}
|
|
11269
11450
|
});
|
|
11270
11451
|
|
|
@@ -11273,13 +11454,13 @@ var tools_exports = {};
|
|
|
11273
11454
|
__export(tools_exports, {
|
|
11274
11455
|
default: () => tools_default
|
|
11275
11456
|
});
|
|
11276
|
-
var
|
|
11457
|
+
var command23, tools_default;
|
|
11277
11458
|
var init_tools = __esm({
|
|
11278
11459
|
"src/commands/mcp/tools.ts"() {
|
|
11279
11460
|
"use strict";
|
|
11280
11461
|
init_exit_codes();
|
|
11281
|
-
|
|
11282
|
-
|
|
11462
|
+
init_connect2();
|
|
11463
|
+
command23 = {
|
|
11283
11464
|
resource: "mcp",
|
|
11284
11465
|
action: "tools",
|
|
11285
11466
|
summary: "List the hosted Kenso MCP's tools",
|
|
@@ -11294,7 +11475,7 @@ var init_tools = __esm({
|
|
|
11294
11475
|
return ExitCode.Ok;
|
|
11295
11476
|
}
|
|
11296
11477
|
};
|
|
11297
|
-
tools_default =
|
|
11478
|
+
tools_default = command23;
|
|
11298
11479
|
}
|
|
11299
11480
|
});
|
|
11300
11481
|
|
|
@@ -11315,14 +11496,14 @@ var stage_history_exports = {};
|
|
|
11315
11496
|
__export(stage_history_exports, {
|
|
11316
11497
|
default: () => stage_history_default
|
|
11317
11498
|
});
|
|
11318
|
-
var
|
|
11499
|
+
var command24, stage_history_default;
|
|
11319
11500
|
var init_stage_history = __esm({
|
|
11320
11501
|
"src/commands/opportunities/stage-history.ts"() {
|
|
11321
11502
|
"use strict";
|
|
11322
11503
|
init_errors();
|
|
11323
11504
|
init_exit_codes();
|
|
11324
11505
|
init_http();
|
|
11325
|
-
|
|
11506
|
+
command24 = {
|
|
11326
11507
|
resource: "opportunities",
|
|
11327
11508
|
action: "stage-history",
|
|
11328
11509
|
summary: "Show a deal's stage history: each stage, when, who moved it and how long it sat there",
|
|
@@ -11346,7 +11527,7 @@ var init_stage_history = __esm({
|
|
|
11346
11527
|
return ExitCode.Ok;
|
|
11347
11528
|
}
|
|
11348
11529
|
};
|
|
11349
|
-
stage_history_default =
|
|
11530
|
+
stage_history_default = command24;
|
|
11350
11531
|
}
|
|
11351
11532
|
});
|
|
11352
11533
|
|
|
@@ -11432,7 +11613,7 @@ function summarize3(results) {
|
|
|
11432
11613
|
}
|
|
11433
11614
|
return { matched, addedToAccounts, emailFindsQueued };
|
|
11434
11615
|
}
|
|
11435
|
-
var COMMAND5, CHUNK_SIZE6, ALIASES3, PERSON_FIELDS, ACCOUNT_NOT_FOUND,
|
|
11616
|
+
var COMMAND5, CHUNK_SIZE6, ALIASES3, PERSON_FIELDS, ACCOUNT_NOT_FOUND, command25, import_default3;
|
|
11436
11617
|
var init_import3 = __esm({
|
|
11437
11618
|
"src/commands/people/import.ts"() {
|
|
11438
11619
|
"use strict";
|
|
@@ -11464,7 +11645,7 @@ var init_import3 = __esm({
|
|
|
11464
11645
|
};
|
|
11465
11646
|
PERSON_FIELDS = ["email", "fullName", "firstName", "lastName", "linkedinUrl", "title"];
|
|
11466
11647
|
ACCOUNT_NOT_FOUND = "No account in this workspace has that domain. The person was saved without an account: add the account (kenso accounts import) and run the same command again.";
|
|
11467
|
-
|
|
11648
|
+
command25 = {
|
|
11468
11649
|
resource: "people",
|
|
11469
11650
|
action: "import",
|
|
11470
11651
|
summary: "Create or match people from a CSV or JSONL file, optionally onto accounts",
|
|
@@ -11529,7 +11710,7 @@ var init_import3 = __esm({
|
|
|
11529
11710
|
return outcome.exitCode;
|
|
11530
11711
|
}
|
|
11531
11712
|
};
|
|
11532
|
-
import_default3 =
|
|
11713
|
+
import_default3 = command25;
|
|
11533
11714
|
}
|
|
11534
11715
|
});
|
|
11535
11716
|
|
|
@@ -11549,14 +11730,14 @@ var list_exports = {};
|
|
|
11549
11730
|
__export(list_exports, {
|
|
11550
11731
|
default: () => list_default
|
|
11551
11732
|
});
|
|
11552
|
-
var
|
|
11733
|
+
var command26, list_default;
|
|
11553
11734
|
var init_list = __esm({
|
|
11554
11735
|
"src/commands/runs/list.ts"() {
|
|
11555
11736
|
"use strict";
|
|
11556
11737
|
init_runs();
|
|
11557
11738
|
init_errors();
|
|
11558
11739
|
init_exit_codes();
|
|
11559
|
-
|
|
11740
|
+
command26 = {
|
|
11560
11741
|
resource: "runs",
|
|
11561
11742
|
action: "list",
|
|
11562
11743
|
summary: "List batch runs, newest first (finds an interrupted run)",
|
|
@@ -11577,7 +11758,7 @@ var init_list = __esm({
|
|
|
11577
11758
|
return ExitCode.Ok;
|
|
11578
11759
|
}
|
|
11579
11760
|
};
|
|
11580
|
-
list_default =
|
|
11761
|
+
list_default = command26;
|
|
11581
11762
|
}
|
|
11582
11763
|
});
|
|
11583
11764
|
|
|
@@ -11588,7 +11769,7 @@ __export(show_exports, {
|
|
|
11588
11769
|
});
|
|
11589
11770
|
import { existsSync as existsSync6, readFileSync as readFileSync9 } from "node:fs";
|
|
11590
11771
|
import { join as join12 } from "node:path";
|
|
11591
|
-
var FILES,
|
|
11772
|
+
var FILES, command27, show_default;
|
|
11592
11773
|
var init_show = __esm({
|
|
11593
11774
|
"src/commands/runs/show.ts"() {
|
|
11594
11775
|
"use strict";
|
|
@@ -11603,7 +11784,7 @@ var init_show = __esm({
|
|
|
11603
11784
|
["plan", "plan.json"],
|
|
11604
11785
|
["summary", "summary.json"]
|
|
11605
11786
|
];
|
|
11606
|
-
|
|
11787
|
+
command27 = {
|
|
11607
11788
|
resource: "runs",
|
|
11608
11789
|
action: "show",
|
|
11609
11790
|
summary: "Show one batch run and its files",
|
|
@@ -11630,7 +11811,7 @@ var init_show = __esm({
|
|
|
11630
11811
|
return ExitCode.Ok;
|
|
11631
11812
|
}
|
|
11632
11813
|
};
|
|
11633
|
-
show_default =
|
|
11814
|
+
show_default = command27;
|
|
11634
11815
|
}
|
|
11635
11816
|
});
|
|
11636
11817
|
|
|
@@ -11689,14 +11870,14 @@ function resumeArgv(run, globals = {}) {
|
|
|
11689
11870
|
async function sha256(path) {
|
|
11690
11871
|
return createHash5("sha256").update(await readFile9(path)).digest("hex");
|
|
11691
11872
|
}
|
|
11692
|
-
var SKIPPED_KEYS,
|
|
11873
|
+
var SKIPPED_KEYS, command28, resume_default;
|
|
11693
11874
|
var init_resume = __esm({
|
|
11694
11875
|
"src/commands/runs/resume.ts"() {
|
|
11695
11876
|
"use strict";
|
|
11696
11877
|
init_runs();
|
|
11697
11878
|
init_errors();
|
|
11698
11879
|
SKIPPED_KEYS = /* @__PURE__ */ new Set(["positionals", "yes", "dryRun", "dry-run", "help", "version"]);
|
|
11699
|
-
|
|
11880
|
+
command28 = {
|
|
11700
11881
|
resource: "runs",
|
|
11701
11882
|
action: "resume",
|
|
11702
11883
|
summary: "Continue an interrupted batch run (its command with --yes, no dry run)",
|
|
@@ -11751,7 +11932,7 @@ var init_resume = __esm({
|
|
|
11751
11932
|
}
|
|
11752
11933
|
}
|
|
11753
11934
|
};
|
|
11754
|
-
resume_default =
|
|
11935
|
+
resume_default = command28;
|
|
11755
11936
|
}
|
|
11756
11937
|
});
|
|
11757
11938
|
|
|
@@ -11859,7 +12040,7 @@ var create_exports = {};
|
|
|
11859
12040
|
__export(create_exports, {
|
|
11860
12041
|
default: () => create_default
|
|
11861
12042
|
});
|
|
11862
|
-
var
|
|
12043
|
+
var command29, create_default;
|
|
11863
12044
|
var init_create = __esm({
|
|
11864
12045
|
"src/commands/sandbox/create.ts"() {
|
|
11865
12046
|
"use strict";
|
|
@@ -11867,7 +12048,7 @@ var init_create = __esm({
|
|
|
11867
12048
|
init_exit_codes();
|
|
11868
12049
|
init_http();
|
|
11869
12050
|
init_shared();
|
|
11870
|
-
|
|
12051
|
+
command29 = {
|
|
11871
12052
|
resource: "sandbox",
|
|
11872
12053
|
action: "create",
|
|
11873
12054
|
summary: "Create your developer sandbox and save its test key as the sandbox profile",
|
|
@@ -11909,7 +12090,7 @@ var init_create = __esm({
|
|
|
11909
12090
|
return ExitCode.Ok;
|
|
11910
12091
|
}
|
|
11911
12092
|
};
|
|
11912
|
-
create_default =
|
|
12093
|
+
create_default = command29;
|
|
11913
12094
|
}
|
|
11914
12095
|
});
|
|
11915
12096
|
|
|
@@ -11918,7 +12099,7 @@ var delete_exports = {};
|
|
|
11918
12099
|
__export(delete_exports, {
|
|
11919
12100
|
default: () => delete_default
|
|
11920
12101
|
});
|
|
11921
|
-
var
|
|
12102
|
+
var command30, delete_default;
|
|
11922
12103
|
var init_delete = __esm({
|
|
11923
12104
|
"src/commands/sandbox/delete.ts"() {
|
|
11924
12105
|
"use strict";
|
|
@@ -11926,7 +12107,7 @@ var init_delete = __esm({
|
|
|
11926
12107
|
init_confirm();
|
|
11927
12108
|
init_exit_codes();
|
|
11928
12109
|
init_shared();
|
|
11929
|
-
|
|
12110
|
+
command30 = {
|
|
11930
12111
|
resource: "sandbox",
|
|
11931
12112
|
action: "delete",
|
|
11932
12113
|
summary: "Delete your sandbox and its test keys",
|
|
@@ -11953,7 +12134,7 @@ var init_delete = __esm({
|
|
|
11953
12134
|
return ExitCode.Ok;
|
|
11954
12135
|
}
|
|
11955
12136
|
};
|
|
11956
|
-
delete_default =
|
|
12137
|
+
delete_default = command30;
|
|
11957
12138
|
}
|
|
11958
12139
|
});
|
|
11959
12140
|
|
|
@@ -11962,14 +12143,14 @@ var key_exports = {};
|
|
|
11962
12143
|
__export(key_exports, {
|
|
11963
12144
|
default: () => key_default
|
|
11964
12145
|
});
|
|
11965
|
-
var
|
|
12146
|
+
var command31, key_default;
|
|
11966
12147
|
var init_key = __esm({
|
|
11967
12148
|
"src/commands/sandbox/key.ts"() {
|
|
11968
12149
|
"use strict";
|
|
11969
12150
|
init_exit_codes();
|
|
11970
12151
|
init_http();
|
|
11971
12152
|
init_shared();
|
|
11972
|
-
|
|
12153
|
+
command31 = {
|
|
11973
12154
|
resource: "sandbox",
|
|
11974
12155
|
action: "key",
|
|
11975
12156
|
summary: "Create a new test key for your sandbox and save it as the sandbox profile",
|
|
@@ -11989,7 +12170,7 @@ var init_key = __esm({
|
|
|
11989
12170
|
return ExitCode.Ok;
|
|
11990
12171
|
}
|
|
11991
12172
|
};
|
|
11992
|
-
key_default =
|
|
12173
|
+
key_default = command31;
|
|
11993
12174
|
}
|
|
11994
12175
|
});
|
|
11995
12176
|
|
|
@@ -11998,13 +12179,13 @@ var list_exports2 = {};
|
|
|
11998
12179
|
__export(list_exports2, {
|
|
11999
12180
|
default: () => list_default2
|
|
12000
12181
|
});
|
|
12001
|
-
var
|
|
12182
|
+
var command32, list_default2;
|
|
12002
12183
|
var init_list2 = __esm({
|
|
12003
12184
|
"src/commands/sandbox/list.ts"() {
|
|
12004
12185
|
"use strict";
|
|
12005
12186
|
init_exit_codes();
|
|
12006
12187
|
init_shared();
|
|
12007
|
-
|
|
12188
|
+
command32 = {
|
|
12008
12189
|
resource: "sandbox",
|
|
12009
12190
|
action: "list",
|
|
12010
12191
|
summary: "List your developer sandbox",
|
|
@@ -12020,7 +12201,7 @@ var init_list2 = __esm({
|
|
|
12020
12201
|
return ExitCode.Ok;
|
|
12021
12202
|
}
|
|
12022
12203
|
};
|
|
12023
|
-
list_default2 =
|
|
12204
|
+
list_default2 = command32;
|
|
12024
12205
|
}
|
|
12025
12206
|
});
|
|
12026
12207
|
|
|
@@ -12029,14 +12210,14 @@ var reset_exports = {};
|
|
|
12029
12210
|
__export(reset_exports, {
|
|
12030
12211
|
default: () => reset_default
|
|
12031
12212
|
});
|
|
12032
|
-
var
|
|
12213
|
+
var command33, reset_default;
|
|
12033
12214
|
var init_reset = __esm({
|
|
12034
12215
|
"src/commands/sandbox/reset.ts"() {
|
|
12035
12216
|
"use strict";
|
|
12036
12217
|
init_exit_codes();
|
|
12037
12218
|
init_http();
|
|
12038
12219
|
init_shared();
|
|
12039
|
-
|
|
12220
|
+
command33 = {
|
|
12040
12221
|
resource: "sandbox",
|
|
12041
12222
|
action: "reset",
|
|
12042
12223
|
summary: "Reset your sandbox to its seed data",
|
|
@@ -12054,7 +12235,7 @@ var init_reset = __esm({
|
|
|
12054
12235
|
return ExitCode.Ok;
|
|
12055
12236
|
}
|
|
12056
12237
|
};
|
|
12057
|
-
reset_default =
|
|
12238
|
+
reset_default = command33;
|
|
12058
12239
|
}
|
|
12059
12240
|
});
|
|
12060
12241
|
|
|
@@ -12314,7 +12495,7 @@ __export(pull_exports, {
|
|
|
12314
12495
|
});
|
|
12315
12496
|
import { mkdir, writeFile as writeFile4 } from "node:fs/promises";
|
|
12316
12497
|
import { dirname as dirname2, resolve as resolve11 } from "node:path";
|
|
12317
|
-
var
|
|
12498
|
+
var command34, pull_default;
|
|
12318
12499
|
var init_pull = __esm({
|
|
12319
12500
|
"src/commands/studio/pull.ts"() {
|
|
12320
12501
|
"use strict";
|
|
@@ -12324,7 +12505,7 @@ var init_pull = __esm({
|
|
|
12324
12505
|
init_common2();
|
|
12325
12506
|
init_folder();
|
|
12326
12507
|
init_transfer();
|
|
12327
|
-
|
|
12508
|
+
command34 = {
|
|
12328
12509
|
resource: "studio",
|
|
12329
12510
|
action: "pull",
|
|
12330
12511
|
summary: "Write a template version's files to a folder",
|
|
@@ -12371,7 +12552,7 @@ var init_pull = __esm({
|
|
|
12371
12552
|
return ExitCode.Ok;
|
|
12372
12553
|
}
|
|
12373
12554
|
};
|
|
12374
|
-
pull_default =
|
|
12555
|
+
pull_default = command34;
|
|
12375
12556
|
}
|
|
12376
12557
|
});
|
|
12377
12558
|
|
|
@@ -12404,7 +12585,7 @@ var push_exports = {};
|
|
|
12404
12585
|
__export(push_exports, {
|
|
12405
12586
|
default: () => push_default
|
|
12406
12587
|
});
|
|
12407
|
-
var BUILT_BY, DEFAULT_MESSAGE,
|
|
12588
|
+
var BUILT_BY, DEFAULT_MESSAGE, command35, push_default;
|
|
12408
12589
|
var init_push = __esm({
|
|
12409
12590
|
"src/commands/studio/push.ts"() {
|
|
12410
12591
|
"use strict";
|
|
@@ -12416,7 +12597,7 @@ var init_push = __esm({
|
|
|
12416
12597
|
init_read();
|
|
12417
12598
|
BUILT_BY = "customer_agent";
|
|
12418
12599
|
DEFAULT_MESSAGE = "Pushed with the Kenso CLI";
|
|
12419
|
-
|
|
12600
|
+
command35 = {
|
|
12420
12601
|
resource: "studio",
|
|
12421
12602
|
action: "push",
|
|
12422
12603
|
summary: "Save a folder's files to a template's draft and print the validation",
|
|
@@ -12508,7 +12689,7 @@ var init_push = __esm({
|
|
|
12508
12689
|
);
|
|
12509
12690
|
}
|
|
12510
12691
|
};
|
|
12511
|
-
push_default =
|
|
12692
|
+
push_default = command35;
|
|
12512
12693
|
}
|
|
12513
12694
|
});
|
|
12514
12695
|
|
|
@@ -12517,7 +12698,7 @@ var validate_exports = {};
|
|
|
12517
12698
|
__export(validate_exports, {
|
|
12518
12699
|
default: () => validate_default
|
|
12519
12700
|
});
|
|
12520
|
-
var
|
|
12701
|
+
var command36, validate_default;
|
|
12521
12702
|
var init_validate = __esm({
|
|
12522
12703
|
"src/commands/studio/validate.ts"() {
|
|
12523
12704
|
"use strict";
|
|
@@ -12526,7 +12707,7 @@ var init_validate = __esm({
|
|
|
12526
12707
|
init_columns();
|
|
12527
12708
|
init_common2();
|
|
12528
12709
|
init_read();
|
|
12529
|
-
|
|
12710
|
+
command36 = {
|
|
12530
12711
|
resource: "studio",
|
|
12531
12712
|
action: "validate",
|
|
12532
12713
|
summary: "Validate a folder's files against a template without saving them",
|
|
@@ -12555,7 +12736,7 @@ var init_validate = __esm({
|
|
|
12555
12736
|
throw validationFailed(validation, "The files have validation errors", commandLine2(ctx, "studio validate", args));
|
|
12556
12737
|
}
|
|
12557
12738
|
};
|
|
12558
|
-
validate_default =
|
|
12739
|
+
validate_default = command36;
|
|
12559
12740
|
}
|
|
12560
12741
|
});
|
|
12561
12742
|
|
|
@@ -12604,7 +12785,7 @@ function accountIds(value) {
|
|
|
12604
12785
|
}
|
|
12605
12786
|
return ids2.map(Number);
|
|
12606
12787
|
}
|
|
12607
|
-
var SHOWN,
|
|
12788
|
+
var SHOWN, command37, preview_default;
|
|
12608
12789
|
var init_preview = __esm({
|
|
12609
12790
|
"src/commands/studio/preview.ts"() {
|
|
12610
12791
|
"use strict";
|
|
@@ -12616,7 +12797,7 @@ var init_preview = __esm({
|
|
|
12616
12797
|
init_common2();
|
|
12617
12798
|
init_folder();
|
|
12618
12799
|
SHOWN = 5;
|
|
12619
|
-
|
|
12800
|
+
command37 = {
|
|
12620
12801
|
resource: "studio",
|
|
12621
12802
|
action: "preview",
|
|
12622
12803
|
summary: "Render a saved version for up to 3 accounts; for local edits, studio push them to the draft first",
|
|
@@ -12665,7 +12846,7 @@ var init_preview = __esm({
|
|
|
12665
12846
|
return ExitCode.Ok;
|
|
12666
12847
|
}
|
|
12667
12848
|
};
|
|
12668
|
-
preview_default =
|
|
12849
|
+
preview_default = command37;
|
|
12669
12850
|
}
|
|
12670
12851
|
});
|
|
12671
12852
|
|
|
@@ -12866,7 +13047,7 @@ function estimateOutput(templateId, target, estimate2) {
|
|
|
12866
13047
|
...target.campaignId !== void 0 ? { estimateNote: "An upper bound: it counts one page per lead, and a campaign run builds one page per company." } : {}
|
|
12867
13048
|
};
|
|
12868
13049
|
}
|
|
12869
|
-
var COMMAND6, sha2562,
|
|
13050
|
+
var COMMAND6, sha2562, command38, fill_default;
|
|
12870
13051
|
var init_fill = __esm({
|
|
12871
13052
|
"src/commands/studio/fill.ts"() {
|
|
12872
13053
|
"use strict";
|
|
@@ -12882,7 +13063,7 @@ var init_fill = __esm({
|
|
|
12882
13063
|
init_fill_runs();
|
|
12883
13064
|
COMMAND6 = "studio fill";
|
|
12884
13065
|
sha2562 = (data) => createHash8("sha256").update(data).digest("hex");
|
|
12885
|
-
|
|
13066
|
+
command38 = {
|
|
12886
13067
|
resource: "studio",
|
|
12887
13068
|
action: "fill",
|
|
12888
13069
|
summary: "Fill a template on many accounts or campaign leads (estimate first)",
|
|
@@ -12942,7 +13123,7 @@ var init_fill = __esm({
|
|
|
12942
13123
|
return outcome.exitCode;
|
|
12943
13124
|
}
|
|
12944
13125
|
};
|
|
12945
|
-
fill_default =
|
|
13126
|
+
fill_default = command38;
|
|
12946
13127
|
}
|
|
12947
13128
|
});
|
|
12948
13129
|
|
|
@@ -13093,7 +13274,7 @@ function readBody(req) {
|
|
|
13093
13274
|
function reply(res, status, body) {
|
|
13094
13275
|
res.writeHead(status, { "content-type": "application/json" }).end(JSON.stringify(body));
|
|
13095
13276
|
}
|
|
13096
|
-
var MIN_POLL_MS, MAX_POLL_MS, MAX_TRIGGER_BYTES,
|
|
13277
|
+
var MIN_POLL_MS, MAX_POLL_MS, MAX_TRIGGER_BYTES, command39, listen_default;
|
|
13097
13278
|
var init_listen = __esm({
|
|
13098
13279
|
"src/commands/webhooks/listen.ts"() {
|
|
13099
13280
|
"use strict";
|
|
@@ -13104,7 +13285,7 @@ var init_listen = __esm({
|
|
|
13104
13285
|
MIN_POLL_MS = 1e3;
|
|
13105
13286
|
MAX_POLL_MS = 6e4;
|
|
13106
13287
|
MAX_TRIGGER_BYTES = 1e6;
|
|
13107
|
-
|
|
13288
|
+
command39 = {
|
|
13108
13289
|
resource: "webhooks",
|
|
13109
13290
|
action: "listen",
|
|
13110
13291
|
summary: "Stream the workspace's events and forward them, signed, to a local handler",
|
|
@@ -13210,7 +13391,7 @@ var init_listen = __esm({
|
|
|
13210
13391
|
return ExitCode.Ok;
|
|
13211
13392
|
}
|
|
13212
13393
|
};
|
|
13213
|
-
listen_default =
|
|
13394
|
+
listen_default = command39;
|
|
13214
13395
|
}
|
|
13215
13396
|
});
|
|
13216
13397
|
|
|
@@ -13229,7 +13410,7 @@ function notRunning() {
|
|
|
13229
13410
|
next: LISTEN_NEXT
|
|
13230
13411
|
});
|
|
13231
13412
|
}
|
|
13232
|
-
var LISTEN_NEXT,
|
|
13413
|
+
var LISTEN_NEXT, command40, trigger_default;
|
|
13233
13414
|
var init_trigger = __esm({
|
|
13234
13415
|
"src/commands/webhooks/trigger.ts"() {
|
|
13235
13416
|
"use strict";
|
|
@@ -13238,7 +13419,7 @@ var init_trigger = __esm({
|
|
|
13238
13419
|
init_http();
|
|
13239
13420
|
init_local();
|
|
13240
13421
|
LISTEN_NEXT = "kenso webhooks listen --forward-to http://localhost:3000/hook";
|
|
13241
|
-
|
|
13422
|
+
command40 = {
|
|
13242
13423
|
resource: "webhooks",
|
|
13243
13424
|
action: "trigger",
|
|
13244
13425
|
summary: "Send a sample event of one type through the running kenso webhooks listen",
|
|
@@ -13295,7 +13476,7 @@ var init_trigger = __esm({
|
|
|
13295
13476
|
return ExitCode.Ok;
|
|
13296
13477
|
}
|
|
13297
13478
|
};
|
|
13298
|
-
trigger_default =
|
|
13479
|
+
trigger_default = command40;
|
|
13299
13480
|
}
|
|
13300
13481
|
});
|
|
13301
13482
|
|
|
@@ -13499,14 +13680,14 @@ var status_exports3 = {};
|
|
|
13499
13680
|
__export(status_exports3, {
|
|
13500
13681
|
default: () => status_default3
|
|
13501
13682
|
});
|
|
13502
|
-
var
|
|
13683
|
+
var command41, status_default3;
|
|
13503
13684
|
var init_status3 = __esm({
|
|
13504
13685
|
"src/commands/work/status.ts"() {
|
|
13505
13686
|
"use strict";
|
|
13506
13687
|
init_exit_codes();
|
|
13507
13688
|
init_http();
|
|
13508
13689
|
init_common3();
|
|
13509
|
-
|
|
13690
|
+
command41 = {
|
|
13510
13691
|
resource: "work",
|
|
13511
13692
|
action: "status",
|
|
13512
13693
|
summary: "Show the Kenso AI work waiting for your own agent, per kind",
|
|
@@ -13540,7 +13721,7 @@ var init_status3 = __esm({
|
|
|
13540
13721
|
return ExitCode.Ok;
|
|
13541
13722
|
}
|
|
13542
13723
|
};
|
|
13543
|
-
status_default3 =
|
|
13724
|
+
status_default3 = command41;
|
|
13544
13725
|
}
|
|
13545
13726
|
});
|
|
13546
13727
|
|
|
@@ -13672,9 +13853,9 @@ var init_files = __esm({
|
|
|
13672
13853
|
import { execFile, spawnSync as spawnSync2 } from "node:child_process";
|
|
13673
13854
|
import { readFileSync as readFileSync12 } from "node:fs";
|
|
13674
13855
|
import { isAbsolute as isAbsolute2 } from "node:path";
|
|
13675
|
-
function sudoArgs(user,
|
|
13856
|
+
function sudoArgs(user, command48, args, keep = [], set = {}) {
|
|
13676
13857
|
const assignments = Object.entries(set).map(([name, value]) => `${name}=${value}`);
|
|
13677
|
-
return ["-n", "-u", user, "-H", ...keep.length > 0 ? [`--preserve-env=${keep.join(",")}`] : [], ...assignments, "--",
|
|
13858
|
+
return ["-n", "-u", user, "-H", ...keep.length > 0 ? [`--preserve-env=${keep.join(",")}`] : [], ...assignments, "--", command48, ...args];
|
|
13678
13859
|
}
|
|
13679
13860
|
function agentKensoEnv(opts) {
|
|
13680
13861
|
return {
|
|
@@ -13684,12 +13865,12 @@ function agentKensoEnv(opts) {
|
|
|
13684
13865
|
AI_AGENT: opts.agentName
|
|
13685
13866
|
};
|
|
13686
13867
|
}
|
|
13687
|
-
function sudoExec(user,
|
|
13868
|
+
function sudoExec(user, command48, args, opts = {}) {
|
|
13688
13869
|
const [sudo = "/usr/bin/sudo", ...lead] = user.sudo;
|
|
13689
13870
|
return new Promise((resolve16) => {
|
|
13690
13871
|
execFile(
|
|
13691
13872
|
sudo,
|
|
13692
|
-
[...lead, ...sudoArgs(user.name,
|
|
13873
|
+
[...lead, ...sudoArgs(user.name, command48, args)],
|
|
13693
13874
|
{ env: { PATH: SUDO_PATH }, cwd: "/", timeout: opts.timeoutMs ?? PROBE_TIMEOUT_MS, maxBuffer: opts.maxBuffer ?? 1024 * 1024, encoding: "utf8", windowsHide: true, shell: false },
|
|
13694
13875
|
(err, stdout, stderr) => {
|
|
13695
13876
|
const code = err ? err.code : 0;
|
|
@@ -13799,9 +13980,9 @@ var init_folder2 = __esm({
|
|
|
13799
13980
|
init_redact();
|
|
13800
13981
|
init_agent_user();
|
|
13801
13982
|
WorkRunFolder = class {
|
|
13802
|
-
constructor(ctx,
|
|
13983
|
+
constructor(ctx, command48, args, outDir, shared = false) {
|
|
13803
13984
|
this.ctx = ctx;
|
|
13804
|
-
this.command =
|
|
13985
|
+
this.command = command48;
|
|
13805
13986
|
this.args = args;
|
|
13806
13987
|
this.outDir = outDir;
|
|
13807
13988
|
this.shared = shared;
|
|
@@ -13916,7 +14097,7 @@ var pull_exports2 = {};
|
|
|
13916
14097
|
__export(pull_exports2, {
|
|
13917
14098
|
default: () => pull_default2
|
|
13918
14099
|
});
|
|
13919
|
-
var MAX_FILES,
|
|
14100
|
+
var MAX_FILES, command42, pull_default2;
|
|
13920
14101
|
var init_pull2 = __esm({
|
|
13921
14102
|
"src/commands/work/pull.ts"() {
|
|
13922
14103
|
"use strict";
|
|
@@ -13925,7 +14106,7 @@ var init_pull2 = __esm({
|
|
|
13925
14106
|
init_common3();
|
|
13926
14107
|
init_folder2();
|
|
13927
14108
|
MAX_FILES = 100;
|
|
13928
|
-
|
|
14109
|
+
command42 = {
|
|
13929
14110
|
resource: "work",
|
|
13930
14111
|
action: "pull",
|
|
13931
14112
|
summary: "Claim waiting work into local work files, to answer by hand",
|
|
@@ -14003,7 +14184,7 @@ var init_pull2 = __esm({
|
|
|
14003
14184
|
return interrupted6 ? ExitCode.Interrupted : ExitCode.Ok;
|
|
14004
14185
|
}
|
|
14005
14186
|
};
|
|
14006
|
-
pull_default2 =
|
|
14187
|
+
pull_default2 = command42;
|
|
14007
14188
|
}
|
|
14008
14189
|
});
|
|
14009
14190
|
|
|
@@ -14145,7 +14326,7 @@ __export(submit_exports, {
|
|
|
14145
14326
|
default: () => submit_default
|
|
14146
14327
|
});
|
|
14147
14328
|
import { resolve as resolve14 } from "node:path";
|
|
14148
|
-
var
|
|
14329
|
+
var command43, submit_default;
|
|
14149
14330
|
var init_submit = __esm({
|
|
14150
14331
|
"src/commands/work/submit.ts"() {
|
|
14151
14332
|
"use strict";
|
|
@@ -14154,7 +14335,7 @@ var init_submit = __esm({
|
|
|
14154
14335
|
init_files();
|
|
14155
14336
|
init_answers();
|
|
14156
14337
|
init_common3();
|
|
14157
|
-
|
|
14338
|
+
command43 = {
|
|
14158
14339
|
resource: "work",
|
|
14159
14340
|
action: "submit",
|
|
14160
14341
|
summary: "Send answers files to Kenso and write each one's results",
|
|
@@ -14186,7 +14367,7 @@ var init_submit = __esm({
|
|
|
14186
14367
|
return totals.rejected > 0 ? ExitCode.Partial : ExitCode.Ok;
|
|
14187
14368
|
}
|
|
14188
14369
|
};
|
|
14189
|
-
submit_default =
|
|
14370
|
+
submit_default = command43;
|
|
14190
14371
|
}
|
|
14191
14372
|
});
|
|
14192
14373
|
|
|
@@ -14207,7 +14388,7 @@ function claimIdOf(arg) {
|
|
|
14207
14388
|
if (!CLAIM_ID.test(arg)) throw usageError(`"${arg}" is neither a claim id nor a work file.`, { field: "claim", hint: "Claim ids look like awc_8fK2..." });
|
|
14208
14389
|
return arg;
|
|
14209
14390
|
}
|
|
14210
|
-
var CLAIM_ID,
|
|
14391
|
+
var CLAIM_ID, command44, release_default;
|
|
14211
14392
|
var init_release = __esm({
|
|
14212
14393
|
"src/commands/work/release.ts"() {
|
|
14213
14394
|
"use strict";
|
|
@@ -14216,7 +14397,7 @@ var init_release = __esm({
|
|
|
14216
14397
|
init_files();
|
|
14217
14398
|
init_common3();
|
|
14218
14399
|
CLAIM_ID = /^[A-Za-z0-9_-]{1,64}$/;
|
|
14219
|
-
|
|
14400
|
+
command44 = {
|
|
14220
14401
|
resource: "work",
|
|
14221
14402
|
action: "release",
|
|
14222
14403
|
summary: "Give claimed work back to the queue now",
|
|
@@ -14235,7 +14416,7 @@ var init_release = __esm({
|
|
|
14235
14416
|
return ExitCode.Ok;
|
|
14236
14417
|
}
|
|
14237
14418
|
};
|
|
14238
|
-
release_default =
|
|
14419
|
+
release_default = command44;
|
|
14239
14420
|
}
|
|
14240
14421
|
});
|
|
14241
14422
|
|
|
@@ -14574,12 +14755,12 @@ function plain(text3) {
|
|
|
14574
14755
|
return text3.replace(/\x1b\[[0-9;?]*[A-Za-z]/g, "");
|
|
14575
14756
|
}
|
|
14576
14757
|
function runStatus(bin, args, env, adapter, runAs) {
|
|
14577
|
-
const
|
|
14758
|
+
const command48 = runAs ? runAs.sudo[0] ?? "/usr/bin/sudo" : bin;
|
|
14578
14759
|
const commandArgs2 = runAs ? [...runAs.sudo.slice(1), ...sudoArgs(runAs.name, bin, args)] : args;
|
|
14579
14760
|
const options = runAs ? { env: { PATH: SUDO_PATH }, cwd: "/" } : { env: childEnv(env, adapter) };
|
|
14580
14761
|
return new Promise((resolve16) => {
|
|
14581
14762
|
execFile2(
|
|
14582
|
-
|
|
14763
|
+
command48,
|
|
14583
14764
|
commandArgs2,
|
|
14584
14765
|
{ ...options, timeout: STATUS_TIMEOUT_MS, maxBuffer: 1024 * 1024, windowsHide: true, shell: false },
|
|
14585
14766
|
(err, stdout, stderr) => {
|
|
@@ -15661,7 +15842,7 @@ var run_exports = {};
|
|
|
15661
15842
|
__export(run_exports, {
|
|
15662
15843
|
default: () => run_default
|
|
15663
15844
|
});
|
|
15664
|
-
var FAILURES_IN_A_ROW,
|
|
15845
|
+
var FAILURES_IN_A_ROW, command45, run_default;
|
|
15665
15846
|
var init_run = __esm({
|
|
15666
15847
|
"src/commands/work/run.ts"() {
|
|
15667
15848
|
"use strict";
|
|
@@ -15682,7 +15863,7 @@ var init_run = __esm({
|
|
|
15682
15863
|
init_folder2();
|
|
15683
15864
|
init_stop();
|
|
15684
15865
|
FAILURES_IN_A_ROW = 3;
|
|
15685
|
-
|
|
15866
|
+
command45 = {
|
|
15686
15867
|
resource: "work",
|
|
15687
15868
|
action: "run",
|
|
15688
15869
|
summary: "Run your own coding agent on the waiting work until the queue is empty",
|
|
@@ -16007,7 +16188,7 @@ var init_run = __esm({
|
|
|
16007
16188
|
return exitCodeFor(reason, totals.rejected > 0 || jobsFailed > 0);
|
|
16008
16189
|
}
|
|
16009
16190
|
};
|
|
16010
|
-
run_default =
|
|
16191
|
+
run_default = command45;
|
|
16011
16192
|
}
|
|
16012
16193
|
});
|
|
16013
16194
|
|
|
@@ -16040,14 +16221,14 @@ function parseLimit(value) {
|
|
|
16040
16221
|
}
|
|
16041
16222
|
return limit;
|
|
16042
16223
|
}
|
|
16043
|
-
var MAX_LIMIT,
|
|
16224
|
+
var MAX_LIMIT, command46, list_default3;
|
|
16044
16225
|
var init_list3 = __esm({
|
|
16045
16226
|
"src/commands/workspace/list.ts"() {
|
|
16046
16227
|
"use strict";
|
|
16047
16228
|
init_errors();
|
|
16048
16229
|
init_exit_codes();
|
|
16049
16230
|
MAX_LIMIT = 200;
|
|
16050
|
-
|
|
16231
|
+
command46 = {
|
|
16051
16232
|
resource: "workspace",
|
|
16052
16233
|
action: "list",
|
|
16053
16234
|
summary: "List the workspaces your key can use",
|
|
@@ -16075,7 +16256,7 @@ var init_list3 = __esm({
|
|
|
16075
16256
|
return ExitCode.Ok;
|
|
16076
16257
|
}
|
|
16077
16258
|
};
|
|
16078
|
-
list_default3 =
|
|
16259
|
+
list_default3 = command46;
|
|
16079
16260
|
}
|
|
16080
16261
|
});
|
|
16081
16262
|
|
|
@@ -16084,7 +16265,7 @@ var use_exports = {};
|
|
|
16084
16265
|
__export(use_exports, {
|
|
16085
16266
|
default: () => use_default
|
|
16086
16267
|
});
|
|
16087
|
-
var
|
|
16268
|
+
var command47, use_default;
|
|
16088
16269
|
var init_use = __esm({
|
|
16089
16270
|
"src/commands/workspace/use.ts"() {
|
|
16090
16271
|
"use strict";
|
|
@@ -16092,7 +16273,7 @@ var init_use = __esm({
|
|
|
16092
16273
|
init_errors();
|
|
16093
16274
|
init_exit_codes();
|
|
16094
16275
|
init_http();
|
|
16095
|
-
|
|
16276
|
+
command47 = {
|
|
16096
16277
|
resource: "workspace",
|
|
16097
16278
|
action: "use",
|
|
16098
16279
|
summary: "Set the profile's default workspace",
|
|
@@ -16149,7 +16330,7 @@ var init_use = __esm({
|
|
|
16149
16330
|
return ExitCode.Ok;
|
|
16150
16331
|
}
|
|
16151
16332
|
};
|
|
16152
|
-
use_default =
|
|
16333
|
+
use_default = command47;
|
|
16153
16334
|
}
|
|
16154
16335
|
});
|
|
16155
16336
|
|
|
@@ -16706,8 +16887,8 @@ function startUpdateNotice(argv, opts = {}) {
|
|
|
16706
16887
|
if (!found) return;
|
|
16707
16888
|
writeCheck(file, { checkedAt: new Date(now).toISOString(), latest: found });
|
|
16708
16889
|
if (isNewer(found, version)) {
|
|
16709
|
-
const
|
|
16710
|
-
stderr.write(`kenso ${found} is out (you have ${version}): ${
|
|
16890
|
+
const command48 = updateCommand(install, opts.platform ?? process.platform);
|
|
16891
|
+
stderr.write(`kenso ${found} is out (you have ${version}): ${command48}
|
|
16711
16892
|
Turn this off with KENSO_NO_UPDATE_NOTIFIER=1.
|
|
16712
16893
|
`);
|
|
16713
16894
|
}
|