Skip to content

TIGER-332: TigerSMS — provider-agnostic SMS primitive + Twilio/SNS adapters (v1.25.0) - #343

Merged
WebTigers merged 3 commits into
mainfrom
feat/tiger-332-tigersms
Oct 19, 2026
Merged

WebTigers merged 3 commits into
mainfrom
feat/tiger-332-tigersms

Conversation

@WebTigers

Copy link
Copy Markdown
Owner

What

A provider-agnostic SMS send primitive — the SMS sibling of Tiger_Mail. One facade, pluggable adapters, config-selected, graceful (unconfigured or a provider error returns ['ok'=>false,'error'=>…], never throws). E.164 normalization built in. Ships with core as a public module.

Library (engine — always available, like Tiger_Mail/Tiger_Location)

  • Tiger_Sms — send() / isConfigured() / providers() / register() / e164().
  • Tiger_Sms_Adapter_Abstract — base (config, _secret decrypt, _http, fields() for the UI).
  • Tiger_Sms_Adapter_Twilio — REST, Basic auth, From or Messaging Service SID.
  • Tiger_Sms_Adapter_Sns — Amazon SNS Publish, self-contained SigV4 (no SDK), static keys or the EC2 instance role via IMDSv2 (zero-key on AWS, the same move as the fleet's SES mail).

Module (modules/sms) — operator surface

Admin → Settings → SMS: provider picker + each adapter's own fields (rendered from fields(), secrets encrypted + blank-keeps-current) + a live test-send. ACL admin+, i18n, admin docs. Auto-discovered as a first-party core module.

Consumers

Auth OTP / 2FA, the Fleet Observer's sev-1 SMS pages (TIGER-328), consent-gated campaigns.

Tests

5 unit tests (22 assertions): E.164 normalization, Twilio request-shaping / response / error, SNS SigV4 signing — all network-free via the _http seam. Version → 1.25.0, CAPABILITIES regenerated.

🤖 Generated with Claude Code

https://claude.ai/code/session_01ASauLLscjqdsNqBNsx2Typ

WebTigers and others added 3 commits October 19, 2026 12:40
…apters (v1.25.0)

The SMS sibling of Tiger_Mail: one facade, pluggable adapters, config-selected,
graceful (unconfigured/error → ['ok'=>false,'error'=>…], never a throw). E.164
normalization built in. Ships with core as a public module.

Library (engine, always available):
- Tiger_Sms — facade: send()/isConfigured()/providers()/register()/e164().
- Tiger_Sms_Adapter_Abstract — base (config, _secret decrypt, _http, fields()).
- Tiger_Sms_Adapter_Twilio — REST, Basic auth, From or Messaging Service SID.
- Tiger_Sms_Adapter_Sns — Amazon SNS Publish, self-contained SigV4 (no SDK),
  static keys OR the EC2 instance role via IMDSv2 (zero-key on AWS, like SES).

modules/sms (operator surface): Admin → Settings → SMS — provider picker + each
adapter's own fields (rendered from fields(), secrets encrypted + blank-keeps) +
a live test-send. ACL admin+, i18n, admin docs.

Powers auth OTP/2FA, the Fleet Observer's sev-1 pages, and consent-gated campaigns.
5 unit tests (22 assertions): e164, Twilio request/response/error, SNS SigV4 — all
network-free via the _http seam.

Co-Authored-By: Claude Opus 4.8 <[email protected]>
Claude-Session: https://claude.ai/code/session_01ASauLLscjqdsNqBNsx2Typ
… fixes 599 risky tests

Every loaded ini must declare all four environment sections (ARCHITECTURE Sec 5) or
Zend_Config_Ini($file, $env) can't find the current section; the warning on each ACL
load marked every booting test risky. No logic change.

Co-Authored-By: Claude Opus 4.8 <[email protected]>
Claude-Session: https://claude.ai/code/session_01ASauLLscjqdsNqBNsx2Typ
…hes (coverage floor)

Adds facade config-routing (provider/isConfigured/send + E.164 normalization +
invalid-number/empty-message guards via a stub adapter), Twilio Messaging-Service-SID
fallback, and the SNS no-credentials path — lifting line coverage back over the 71% floor.

Co-Authored-By: Claude Opus 4.8 <[email protected]>
Claude-Session: https://claude.ai/code/session_01ASauLLscjqdsNqBNsx2Typ
@WebTigers
WebTigers merged commit 14be403 into main Oct 19, 2026
14 checks passed
@WebTigers
WebTigers deleted the feat/tiger-332-tigersms branch October 19, 2026 16:54
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