Skip to content

Add simultaneous calls to calls settings and claim output - #77

Draft
purpshell wants to merge 3 commits into
mainfrom
claude/calls-simultaneous-calls-20261011
Draft

purpshell wants to merge 3 commits into
mainfrom
claude/calls-simultaneous-calls-20261011

Conversation

@purpshell

@purpshell purpshell commented Oct 11, 2026 •

Copy link
Copy Markdown
Member

Summary

The held coverage-output candidate is now included in this owning draft. When simultaneous calls are off and the server supplies a valid future simultaneousCallsCoverageExcludedUntil, human output prints that exact exclusion-end timestamp. JSON preserves the server field. The field is never sent in a settings update. The output does not establish current insurance coverage.

Adds simultaneous calls to calls settings and shows the new Ban Insurance claim fields. Contract source: polymorfa/polymorfa#559 (merged source). SDK types: polymorfa/sdks#346 (merged source). This branch still pins the older SDK version below; matching published SDK adoption and deployed acceptance remain merge/release gates.

  • calls settings set --simultaneous-calls=<true|false> follows the existing --host-cloud-api-calls=<true|false> flag style.
  • --simultaneous-calls=true requires --acknowledge-risk. Without it the command exits with code 2 (configuration) before any request. The message says that Ban Insurance does not cover the number while the setting is on and for 30 days after it is turned off, and says to re-run with --acknowledge-risk. There is no interactive prompt; the flag is required in every mode.
  • --acknowledge-risk without --simultaneous-calls=true exits with code 2, because the API rejects acknowledgeRisk on its own.
  • --simultaneous-calls=false needs no acknowledgment.
  • calls settings get and set print Simultaneous calls off, or on (Ban Insurance does not cover this number). JSON passes simultaneousCalls through unchanged.
  • bansafe claim view prints Simultaneous calls on in window yes|no when the claim records evidence.simultaneousCalls. Verdict simultaneous_calls already prints as-is. JSON passes through unchanged.

Blocked: SDK bump. The pinned SDK (@polymorfa/sdk 0.1.0-dev.20261004024706) predates these fields. The CLI widens the SDK types locally (CallSettings and CallSettingsUpdateBody in src/services/calls.ts, simultaneousCallsEvidence in src/services/bansafe.ts). There is no any, and comments mark the code for removal. The pinned SDK also rejects an update whose only setting is simultaneousCalls ("Send at least one call setting to change."), so calls settings set --session s --simultaneous-calls=true --acknowledge-risk fails today before any request. Combined with another setting it sends the right body. Before merge:

  1. The backend and SDK source merges are complete. Select an accepted, published SDK dev prerelease containing the required fields and standalone-setting validation. The current exact pin has not adopted that contract.
  2. Change package.json "@polymorfa/sdk": "0.1.0-dev.20261004024706" to that exact 0.1.0-dev.<timestamp>, and run npm install --save-exact.
  3. Drop the local type widenings and add a test for --simultaneous-calls=true --acknowledge-risk on its own.

Impact

Coverage-output impact table

Area Status Limit
API Consumer only Reads an optional server response field; no backend source is changed and matching producer acceptance is not established here.
SDKs Adoption blocked Exact published pin remains unchanged; local response type extension is preserved.
CLI Updated Conditional exclusion-end line, JSON passthrough, no new write field.
Documentation Updated Existing README and command help describe overlap-based exclusion and the server timestamp.
Feature release Blocked Draft source publication establishes no coverage, package or product availability.
Admin Unaffected No staff command, Temporal capability or Admin source change in this candidate.

Original feature impact table

Area Status Details
CLI calls settings set Updated New --simultaneous-calls, --acknowledge-risk flags, help text, examples, local risk refusal (exit 2). src/commands/calls/settings/set.ts, src/services/calls.ts
CLI settings output Updated Simultaneous calls line in human output. JSON unchanged in shape (field passes through).
CLI bansafe claim view Updated Evidence line for simultaneousCalls. src/services/bansafe.ts
README and command research Updated README.md calls settings and BanSafe sections, docs/command-research/calls.md
SDK dependency Blocked Matching accepted published SDK pin adoption remains pending. The current exact pin rejects a simultaneous-calls-only change client-side.
API contract Source merged; acceptance blocked polymorfa/polymorfa#559 is merged. No matching deployed API acceptance is established by this mechanical refresh.
Feature release Blocked Availability follows the backend release record in polymorfa/polymorfa#559. No CLI flag gating; the API enforces credential rules (project tokens get 403, exit 3). No CLI publication in this PR.

No impact table

Area Reason Evidence
bansafe claim list Prints verdict as a raw string column, so simultaneous_calls shows without change. No evidence column. renderClaims in src/services/bansafe.ts
calls settings get command code Uses the same renderer and service type; only the shared renderer changed. src/commands/calls/settings/get.ts
MCP server and skills No tool or skill reads or writes call settings. rg "updateCallSettings|call-settings" src/mcp skills returns no matches
Other credentials Client tokens are still refused by the Platform environment before any request; existing test unchanged. rejects client tokens and invalid values for call settings in test/commands/calls.test.ts
Admin controls The CLI has no staff surface. Staff turn-off lives in Admin (admin-call-settings v2) in polymorfa/polymorfa#559. Contract
UI Terminal output only. n/a

Verification

Source readiness attempt, 2026-10-30

Ready: no. The exact failed Node 22 job is 123171055252. Its 118 test files / 1,168 tests and build passed, then scripts/cli-reference.mjs:122 rejected stale contracts/cli-reference.json. These remain historical results for the named failed run, not qualification of a successor.

Live intake confirmed published head 9fae00c78c5b2c25ff0519590ceaa5a8a13bd064 and actual main 044f8b75ae8b0689664fe489c22d4a3c64486717. The owned worktree was clean. Both published coverage-output commits remain preserved.

The single standard source-repair claim (session 2054, owner calls-cli77-readiness-source, queue bound 900 seconds, execution bound 180 seconds) expired with exit 75 before admission. No child command, backup/rebase, generator, source edit, build, test or push started in that claim. No installer or repeated queue was attempted.

The required fix is to incorporate actual current main, regenerate the reference with its real npm run docs:reference producer and run focused matching-environment checks. The smallest missing action is one admitted bounded shared-validation window for that prepared repair/qualification command. The PR stays draft until the source is actually repaired and qualified.

The exact SDK pin and its standalone-setting limitation remain explicit below. No API, SQL, legal, SDK adoption, package publication, feature availability or Admin change was made by this attempt. Release retains merge and release gates.

Draft publication, 2026-10-29

Current head 9fae00c78c5b2c25ff0519590ceaa5a8a13bd064 fast-forwards published cb1fb9946b1c7bfec4f022ea525b9f5a64172715. Held 2f0864d606ed99eab3b348b381378aceec9b0493 maps to 7b1edac; held d006004292e39667a1547d5ae368a548120b2898 maps to 9fae00c. Both range-diff entries are unchanged. The original d7995763 feature commit was already represented by cb1fb994 and was not replayed.

  • Source/index/old refs were preserved before the two-commit carry. It completed without conflicts and the push was a normal fast-forward. Original author/message attribution and held source refs remain preserved.
  • No implementation, tests, builds, dependency installs, review rounds or availability checks were added before publication. No checks have been rerun at this new head. Earlier results below apply only to the named historical revisions.
  • Historical held-source evidence: 2f0864d6 had focused regression and broader local checks recorded in round12/cli77/RECEIPT.md; d0060042 had copy/format/syntax checks recorded in root-cli77-coverage-copy-20261023/RECEIPT.json. These are not fresh-head acceptance.
  • Current SDK pin remains exactly 0.1.0-dev.20261004024706. Typed SDK adoption and standalone simultaneous-calls update validation remain blocked. No accepted package version is guessed.
  • Publication receipt: simultaneous-calls/publication-sweep-20261029/CLI77-PUBLICATION.json, with preserved source/index, before-containment and range-diff evidence beside it.
  • This is a draft handback. New-head CI/review, producer/SDK compatibility, package, legal, feature and live acceptance remain Release gates. No merge, tag, publication, activation or deployment is authorized here.

Historical source refresh, 2026-10-28

Published head cb1fb9946b1c7bfec4f022ea525b9f5a64172715, directly rebased onto actual live main a9a19cd68eecf7f33eae495665c1f389b6906a5e (CLI Zod #91). Old head d7995763d58b5252faf8a3e0ef4bbfd7aecbbdda, old parent 1869d421892173d9ccd662fc785b39ed30bbd9d2. The old PR base snapshot was not used as current target authority.

  • git rebase --rebase-merges --onto completed without conflicts. range-diff reports the single Calls commit unchanged; old/new stable patch ID is c682519aad08a83d13a3e57293d85ff8a642261b. Original author, date, message and coauthor are preserved.
  • Old remote/head/base refs, raw index, source archive and patches were preserved before mutation. Unpublished coverage candidates 2f0864d6 and d0060042 remain held and are excluded.
  • New source uses locked Zod 4.6.7 and MCP server 2.3.1. SDK remains exactly 0.1.0-dev.20261004024706; no guessed adoption or installer ran.
  • One short standard lease verified the complete applicable installed dependency graph against the new lock, then reused a private copy of that existing tree. Only explicitly foreign-platform optional packages were excluded from the graph check.
  • Passed at the new head: diff whitespace check; Prettier for all seven feature files; TypeScript typecheck; build; focused Calls and BanSafe command tests with one worker and no file parallelism; release-evidence Node tests; production package-lock audit.
  • The focused command tests used OCLIF_TEST_ROOT set to this worktree. No assertion, deadline or source change was introduced by verification.
  • Immediately before push, live main was still a9a19cd6 and the PR branch was still d7995763. Push used the exact expected-old --force-with-lease; remote readback confirmed cb1fb994 and the worktree stayed clean.
  • Full-suite, hosted new-head CI/review, SDK adoption, live API and package acceptance remain separate gates. Old CI/reviews do not qualify this rewritten head. No dispatch, rerun, review request, merge, publication or deployment occurred.

Durable private evidence: simultaneous-calls/cli77-rebase-20261028/, including BACKUP-BEFORE.json, PATCH-AUTHOR-PROOF.json, DEPENDENCY-PROOF.json, FOCUSED-REPLACEMENT-RECEIPT.json, per-check logs and the one-time natural run manifest.

Historical verification at d799576

Revision d7995763d58b5252faf8a3e0ef4bbfd7aecbbdda, pinned SDK 0.1.0-dev.20261004024706.

  • npm run format:check, npm run lint, npm run typecheck: pass.
  • npm run build, npm pack --dry-run --ignore-scripts, npm run audit:prod (0 vulnerabilities): pass.
  • npx vitest run test/commands/calls.test.ts test/commands/bansafe.test.ts: 56 passed. New tests:
    • turns simultaneous calls on only with --acknowledge-risk: refusal without the flag (exit 2, configuration category, message names Ban Insurance and --acknowledge-risk, no request sent); --acknowledge-risk without true and with false refused (exit 2); request bodies {acknowledgeRisk: true, conferenceMode: true, simultaneousCalls: true} (plus expectedRevision case) and {conferenceMode: true, simultaneousCalls: false}; human and JSON output.
    • shows the simultaneous calls verdict and evidence on a claim: human Verdict simultaneous_calls, Simultaneous calls on in window yes, JSON passthrough. The existing claim test checks that older claims without the field print no evidence line.
  • Full suite (--maxWorkers=2 --testTimeout=60000, machine load average about 90): 1034 passed, 4 failed. The failures are in test/commands/event-stream-process.test.ts (SIGINT/SIGTERM) and test/commands/voice-wait-timeout.test.ts. They fail the same way on origin/main (1869d42) on this machine and do not touch the changed code. CI is the reference.
  • Probe against the pinned SDK: calls settings set --session support --simultaneous-calls=true --acknowledge-risk prints Error: Send at least one call setting to change. with no request. This is the SDK blocker above.

Not exercised: a real API (backend unmerged), project-token 403 path against a live server.

Terminal output rendered by calls settings set for the turn-on test fixture (same renderer as get):

Session	support
Calls	on
Conference mode	on
Incoming calls	clients
Cloud API calls answered by	your Graph API integration
Simultaneous calls	on (Ban Insurance does not cover this number)
Revision	2
Updated	2026-10-11T10:00:00.000Z

Session provenance and UI evidence

The 2026-10-28 mechanical refresh was performed by the existing Calls owner using Codex gpt-6.1-sol. Original commit attribution and the terminal behavior below are preserved. No new product behavior or coverage-output candidate was added.

Agent registration PR: https://github.com/polymorfa/polymorfa/pull/540; delegated subagent of thread 707f87c6-ff4d-4525-8150-0815c879e03a; transcript checkpoint will be published by the coordinating agent. UI unaffected (terminal output shown in Verification).

Dependencies: polymorfa/polymorfa#559, polymorfa/sdks#346.

Rollout and rollback

  • Backend #559 and SDK #346 source merges are complete. This PR remains blocked on adoption of a matching accepted published SDK and its required qualification. Release owns any merge; source refresh grants no publication or activation authority. Staging remains deferred.
  • No publication in this PR. CLI nightlies and stable packages follow the repository's release gates.
  • Rollback: revert this PR. The API keeps enforcing the acknowledgment and credential rules without the CLI.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 11, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-11T01:07:59.254128Z d799576 PR opened
🔒 Security Review ✅ Completed 2026-10-11T01:08:52.942657Z d799576 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@coderabbitai

coderabbitai Bot commented Oct 11, 2026 •

Copy link
Copy Markdown

Important

Draft PR not reviewed

Draft PRs are not automatically reviewed by default.

  • Trigger a manual review

To automatically review draft PRs, update your CodeRabbit configuration:

reviews:
  auto_review:
    drafts: true
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Comment @coderabbitai help to get the list of available commands.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: d7995763d5

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/services/calls.ts
...(expectedRevision === undefined ? {} : {expectedRevision}),
})
}
const response = await client.voip.updateCallSettings(name, body)

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Upgrade the SDK before exposing standalone simultaneous calls

With the pinned @polymorfa/sdk version, voip.updateCallSettings still validates requests against the old settings fields and throws Send at least one call setting to change. when the body contains only simultaneousCalls (plus acknowledgeRisk). Consequently the newly documented standalone enable and disable commands fail before sending an HTTP request; the added success tests conceal this by always including --conference-mode. Upgrade the SDK or otherwise bypass its obsolete validator before exposing these commands.

Useful? React with 👍 / 👎.

calls settings set gains --simultaneous-calls=<true|false> and
--acknowledge-risk. Turning simultaneous calls on without the
acknowledgment exits with code 2 before any request. Settings output and
claim view show the new fields from polymorfa/polymorfa#559.

Co-Authored-By: Claude <noreply@anthropic.com>
@purpshell
purpshell force-pushed the claude/calls-simultaneous-calls-20261011 branch from d799576 to cb1fb99 Compare October 28, 2026 04:16
@purpshell
purpshell marked this pull request as draft October 28, 2026 23:45
calls settings get and set print "Ban Insurance exclusion ends" with the
server's simultaneousCallsCoverageExcludedUntil while simultaneous calls
are off and that time has not passed. Nothing is printed while on, for a
null or missing end, or once it passes. --json passes the field through
unchanged, and it is never sent in an update.

The field is typed locally as response-only until an accepted, published
SDK supplies it; the SDK pin is unchanged.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant