diff --git a/changes/feat-signin-methods.md b/changes/feat-signin-methods.md new file mode 100644 index 0000000..0d78a3e --- /dev/null +++ b/changes/feat-signin-methods.md @@ -0,0 +1,6 @@ +### Added + +- **WireCat Desktop signs beeline in in its own window.** The manifest now says how (cli-base's `signIn.methods`): + Desktop asks for the API token in a hidden field and passes it to `beeline session start --json` on + stdin, so no terminal is needed. It needs a Desktop that shows a token field for such a sign-in; an older Desktop + offers the window but cannot finish it, so sign in at a terminal there. diff --git a/contracts/wirecat.json b/contracts/wirecat.json index d4ffa18..f928adf 100644 --- a/contracts/wirecat.json +++ b/contracts/wirecat.json @@ -652,7 +652,20 @@ ], "signIn": { "gives": "Lets your agent read the recorded calls of your Beeline Cloud PBX, transcribed on this computer.", - "asks": "A Beeline Cloud PBX API token, from the Beeline cabinet: Услуги → Интеграция по API." + "asks": "A Beeline Cloud PBX API token, from the Beeline cabinet: Услуги → Интеграция по API.", + "methods": [ + { + "id": "token", + "label": "API token", + "words": [ + "{profile}", + "session", + "start", + "--json" + ], + "stdin": true + } + ] }, "skill": { "status": [ diff --git a/package.json b/package.json index 7cea1c9..e45de23 100644 --- a/package.json +++ b/package.json @@ -60,7 +60,7 @@ "docs:spell": "cspell lint --config cspell.json --no-progress --no-summary README.md README.ru.md SECURITY.md CHANGELOG.md AGENTS.md CLAUDE.md 'docs/*.md' 'skills/**/*.md'" }, "dependencies": { - "@wirecat/cli-base": "0.104.0", + "@wirecat/cli-base": "0.117.0", "@wirecat/cli-core": "0.674.0", "commander": "15.0.0", "valibot": "1.5.0" diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 0497771..55aff95 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -13,11 +13,11 @@ importers: .: dependencies: '@wirecat/cli-base': - specifier: 0.104.0 - version: 0.104.0(commander@15.0.0)(esbuild@0.28.2)(typescript@7.0.2)(vitest@5.0.5) + specifier: 0.117.0 + version: 0.117.0(commander@15.0.0)(esbuild@0.28.2)(typescript@7.0.2)(vitest@5.0.5) '@wirecat/cli-core': specifier: 0.674.0 - version: 0.674.0(@wirecat/cli-base@0.104.0(commander@15.0.0)(esbuild@0.28.2)(typescript@7.0.2)(vitest@5.0.5))(commander@15.0.0)(typescript@7.0.2)(zod@4.6.7) + version: 0.674.0(@wirecat/cli-base@0.117.0(commander@15.0.0)(esbuild@0.28.2)(typescript@7.0.2)(vitest@5.0.5))(commander@15.0.0)(typescript@7.0.2)(zod@4.6.7) commander: specifier: 15.0.0 version: 15.0.0 @@ -1155,19 +1155,25 @@ packages: '@wasm-audio-decoders/opus-ml@0.0.3': resolution: {integrity: sha512-SEeTmk0eb3q5etJA/NHCRWW6BivTx9tqvNTmG0kg2ynuATEQRUZnwQE6Ibvl1BBvqIGHqI57+qyJMWmJBwb5XQ==} - '@wirecat/cli-base@0.104.0': - resolution: {integrity: sha512-560dJern2N83/TTiosi9g8jlotzF3U3bvTv8rGp0/DOm+wBfT/5Dt33W+vDj2K2odXvhZzX7+CQWM9woi5bwNw==} + '@wirecat/cli-base@0.117.0': + resolution: {integrity: sha512-EvvT9thrZihJc+s2taT1rwww5k1bITBG/7CtucjSMsNi1Y89JRARWVSa94/QR/o7002761+b1v5TXoyMJGFTdg==} engines: {node: '>=22'} hasBin: true peerDependencies: + '@scalar/openapi-upgrader': ^0.4.6 commander: '>=15' esbuild: ^0.28.0 + swagger-converter: ^2.1.0 vitest: '>=5' peerDependenciesMeta: + '@scalar/openapi-upgrader': + optional: true commander: optional: true esbuild: optional: true + swagger-converter: + optional: true vitest: optional: true @@ -3164,7 +3170,7 @@ snapshots: dependencies: '@wasm-audio-decoders/common': 9.0.7 - '@wirecat/cli-base@0.104.0(commander@15.0.0)(esbuild@0.28.2)(typescript@7.0.2)(vitest@5.0.5)': + '@wirecat/cli-base@0.117.0(commander@15.0.0)(esbuild@0.28.2)(typescript@7.0.2)(vitest@5.0.5)': dependencies: '@valibot/to-json-schema': 1.8.0(valibot@1.5.0(typescript@7.0.2)) cli-table3: 0.6.5 @@ -3184,7 +3190,7 @@ snapshots: '@wirecat/cli-core-sqlite@1.1.0': {} - '@wirecat/cli-core@0.674.0(@wirecat/cli-base@0.104.0(commander@15.0.0)(esbuild@0.28.2)(typescript@7.0.2)(vitest@5.0.5))(commander@15.0.0)(typescript@7.0.2)(zod@4.6.7)': + '@wirecat/cli-core@0.674.0(@wirecat/cli-base@0.117.0(commander@15.0.0)(esbuild@0.28.2)(typescript@7.0.2)(vitest@5.0.5))(commander@15.0.0)(typescript@7.0.2)(zod@4.6.7)': dependencies: '@anthropic-ai/sdk': 1.3.0(zod@4.6.7) '@bomb.sh/tab': 0.0.22(commander@15.0.0) @@ -3194,7 +3200,7 @@ snapshots: '@valibot/to-json-schema': 1.8.0(valibot@1.5.0(typescript@7.0.2)) '@wasm-audio-decoders/flac': 0.2.11 '@wasm-audio-decoders/ogg-vorbis': 0.1.20 - '@wirecat/cli-base': 0.104.0(commander@15.0.0)(esbuild@0.28.2)(typescript@7.0.2)(vitest@5.0.5) + '@wirecat/cli-base': 0.117.0(commander@15.0.0)(esbuild@0.28.2)(typescript@7.0.2)(vitest@5.0.5) '@wirecat/cli-core-onnx': 1.2.0 '@wirecat/cli-core-sqlite': 1.1.0 '@xmldom/xmldom': 0.9.12 diff --git a/src/identity.ts b/src/identity.ts index 795d874..e2efc7a 100644 --- a/src/identity.ts +++ b/src/identity.ts @@ -27,6 +27,7 @@ export const DESKTOP: ManifestIdentity & { hosts: readonly string[] } = { signIn: { gives: "Lets your agent read the recorded calls of your Beeline Cloud PBX, transcribed on this computer.", asks: "A Beeline Cloud PBX API token, from the Beeline cabinet: Услуги → Интеграция по API.", + methods: [{ id: "token", label: "API token", words: ["{profile}", "session", "start", "--json"], stdin: true }], }, hosts: ["cloudpbx.beeline.ru"], }