Skip to content

Calls: document WhatsApp number restrictions in the calls commands - #27

Merged
purpshell merged 9 commits into
devfrom
t3code/calls-bansafe
Sep 23, 2026
Merged

purpshell merged 9 commits into
devfrom
t3code/calls-bansafe

Conversation

@purpshell

@purpshell purpshell commented Sep 20, 2026 •

Copy link
Copy Markdown
Member

Explains and verifies the Calls behavior when WhatsApp restricts a Number to people it has already chatted with. calls place and calls invite preserve the API's number_restricted code, request ID and exit status 3 in human and JSON output. Call watch output preserves call_restricted; the README and help explain the restriction and session.restriction_updated event.

The CLI now pins the exact published @polymorfa/sdk@0.1.0-dev.20260923101121 produced by merged SDK #282. Existing Calls and BanSafe services use typed SDK APIs; no raw adapter remains in this change. CLI dev is merged normally.

Verification

Full npm run verify passes: format, lint, typecheck, 637 tests across 73 files, build, package check and production audit with zero vulnerabilities. Restricted place/invite behavior, human/JSON classification, request ID, exit status and watch output have focused regressions. A live call against a deployed API was not exercised.

Contract and release assessment

Part Status and evidence
API Unaffected here; merged monorepo #231 owns the BanSafe Calls contract.
SDKs Consumes the exact published SDK #282 prerelease; no SDK source is changed in this repository.
CLI Updated help, README, exact SDK dependency and regressions. Existing output and exit rules are preserved.
Docs CLI README updated; customer API guide remains with monorepo #231.
Feature releases No flag, entitlement or rollout change. Calls remains unreleased to customers.
Admin Unaffected: no staff capability or Admin runtime change.

Current-head CI and automated reviews remain merge gates.


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith with what you need. Autofix is disabled.

@coderabbitai

coderabbitai Bot commented Sep 20, 2026 •

Copy link
Copy Markdown

Warning

Review limit reached

  • Ask an admin to enable usage-based reviews

Open in CodeRabbit

Reviews can continue after your included limit without a manual trigger. An admin must approve usage-based billing.

Next included review available in 51 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available. Your 73 included PR review attempts over the past 7 days set your current allowance at 1 review per hour.

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

Learn how review limits work.

Review configuration:

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Team

Run ID: 9cd924d8-4e4b-4240-ab60-480191da2362

📥 Commits

Reviewing files that changed from the base of the PR and between c78687d and 8a53961.

⛔ Files ignored due to path filters (1)
  • package-lock.json is excluded by !**/package-lock.json
📒 Files selected for processing (6)
  • README.md
  • package.json
  • src/commands/calls/invite.ts
  • src/commands/calls/place.ts
  • test/commands/calls-sockets.test.ts
  • test/commands/calls.test.ts

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

@purpshell

Copy link
Copy Markdown
Member Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Sep 20, 2026 •

Copy link
Copy Markdown
⚠️ Action not completed

Review rate limited.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@purpshell

Copy link
Copy Markdown
Member Author

@codex review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 22, 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-09-23T11:52:13.681947Z 8a53961 Manual request
ℹ️ 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.

@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: ed5130ea45

ℹ️ 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 README.md Outdated
`code: "number_restricted"` for anyone else; calls to existing contacts still
work. A call WhatsApp refuses for that reason ends with
`reason: "call_restricted"` in `calls watch`. `polymorfa listen
--events session.restriction_updated` reports the restriction starting and

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Use the singular listen event flag

The documented monitoring command cannot run because src/commands/listen.ts defines only the singular, repeatable --event flag; oclif will reject --events as an unknown option. Anyone following this instruction therefore cannot subscribe to restriction updates without consulting the separate command help. Change this to polymorfa listen --event session.restriction_updated.

Useful? React with 👍 / 👎.

@purpshell

Copy link
Copy Markdown
Member Author

Codex follow-up: the README now uses the singular, repeatable --event flag: polymorfa listen --event session.restriction_updated (7bf1aae). Also merged dev.

@purpshell

Copy link
Copy Markdown
Member Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Delightful!

Reviewed commit: 191ab028a0

ℹ️ 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".

@purpshell

Copy link
Copy Markdown
Member Author

@codex review

Current head 5880cd3 merges CLI dev c78687d and pins the exact published BanSafe SDK @polymorfa/sdk@0.1.0-dev.20260923101121. Restricted place/invite human and JSON error paths, exit status and request ID have regressions. Full npm verify passed locally (637 tests, build, package check, production audit). Please review this head.

@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: 5880cd3fa3

ℹ️ 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 README.md Outdated
Comment on lines +686 to +687
`code: "number_restricted"` for anyone else; calls to existing contacts still
work. A call WhatsApp refuses for that reason ends with

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Describe the allowlist as prior chats, not contacts

For a saved or otherwise known contact that has never had a direct chat with the Number, this sentence promises that the call will work even though the preceding restriction says only people previously chatted with are allowed. Replace “existing contacts” with “people it has already chatted with” (or equivalent) so operators do not treat address-book/contact membership as sufficient.

Useful? React with 👍 / 👎.

@purpshell

Copy link
Copy Markdown
Member Author

Current-head local codex review --base origin/dev completed on clean head 5880cd3 and found no actionable regression. It also ran focused Calls command tests (43 pass) and typecheck. The GitHub Codex mention remains pending; Node 22 current-head CI is green. CodeRabbit has not supplied a clean review because its bot remains rate-limited, so no CodeRabbit clearance is claimed.

@purpshell

Copy link
Copy Markdown
Member Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. You're on a roll.

Reviewed commit: 8a539610ec

ℹ️ 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".

@purpshell

Copy link
Copy Markdown
Member Author

Merge gate for 8a539610ec28697fc8e15b4d3f9970f1c5185349 against dev (c78687da59f1cc59f954faa28d3d66aa0bff1b64): Node 22 CI run 35856722799 passed. The current-head Codex review reported no major issues; its earlier README finding was corrected in this head. CodeRabbit reported Review rate limited, so no clean CodeRabbit review is claimed. The owner explicitly authorized merging CLI #27 with current-head CI and Codex in place of the handoff's CodeRabbit gate. No production deployment or feature release is implied.

@purpshell
purpshell merged commit d7cb76c into dev Sep 23, 2026
3 checks passed
@purpshell
purpshell deleted the t3code/calls-bansafe branch October 26, 2026 15:52
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