SalesMsg Hub

SalesMsg is the primary outbound/inbound SMS platform for all acquisition and dispo agent messaging. It handles local-presence dialing across 12 inboxes (163,199+ contacts), OAuth-authenticated API calls, and webhook delivery for real-time message routing. Read this hub before modifying any SMS workflow, webhook handler, blast configuration, or inbox assignment. Owned by Henry Hill; managed by acquisitions + dispo agents.

⚠️ P0 Security Alert (PF-A)

/etc/systemd/system/salesmsg-gateway.service hardcodes ANTHROPIC_API_KEY=sk-ant-api03-C4A75YcCl... as plaintext in a system-level unit file. This is a G-NO-PLAINTEXT-CREDS violation. Rotation is pending. Until rotated, do NOT redeploy this unit without first replacing the hardcoded key with op://Aurora/anthropic/api-key reference and updating the unit to use EnvironmentFile=/run/secrets/anthropic.env or equivalent 1Password CLI injection. See 1password for op run pattern.

Quick reference

FieldValue
VendorSalesMsg (salesmessage.com)
URLhttps://api.salesmessage.com/pub/v2.2
KB docAPI · WEBHOOKS · CREDENTIALS
Auth methodOAuth 2.0 Bearer Token (access token + refresh token auto-rotated every 6h)
Auth credentialop://Aurora/salesmsg/api-key — do NOT use plaintext
Cred-proxy portn/a (until B1-B6 ratified in openclaw-fragmentation-fix-2026-05-01)
Webhook port:18793
Webhook handlersalesmessage-handler-v4-complete
Webhook auth⚠️ query-param token ?secret=NOT HMAC (KB WEBHOOKS.md once said HMAC; KB was wrong; live is ?secret= query param only)
Webhook dedup tableprocessed_webhook_events (24h TTL)
Tunnel path (canonical)https://webhook.reri.co/webhook/salesmessage · alt: /webhooks/salesmessage
Tunnel path (fallback)https://srv1347501.tailb025a7.ts.net/webhook/salesmessage
Outbound API basehttps://api.salesmessage.com/pub/v2.2
Rate limitsNot documented; treat as standard SaaS (avoid burst >10 req/s)
Rate-limit action429 → exponential backoff (3 retries), Discord ops alert
Organization ID96638
Primary inboxDispo | A (ID: 128279) — 16 numbers, local presence enabled
OAuth token file/home/opsadmin/.openclaw/workspace/data/salesmessage-oauth.json (current access + refresh tokens)
Token refresh cronsm-token-refresh every 6h
CostPer-message SMS pricing (see SalesMsg billing)
Backup/recoveryVendor-owned (no local backup of message history)
Discord alert channelops
Drift cadenceWeekly (security-audit-funnel.timer)
Statusproduction

Components

  • webhooks/salesmessage-handler-v4-complete.js — inbound webhook handler on :18793; routes message.created, message.updated, conversation.*, contact.*, call.* events
  • /home/opsadmin/.openclaw/workspace/data/salesmessage-oauth.json — live OAuth access + refresh tokens; read this first before any API call
  • /home/opsadmin/.openclaw/workspace/data/salesmessage-credentials.json — client ID (1395) + client secret; do NOT commit
  • /home/opsadmin/.openclaw/workspace/data/salesmessage-aurora-oauth.json — Aurora-specific token for posting internal notes
  • scripts/sm-token-refresh.js — token refresh worker invoked by cron every 6h
  • /etc/systemd/system/salesmsg-gateway.service — ⚠️ CONTAINS PLAINTEXT ANTHROPIC KEY — see P0 alert above
  • systemd unit: salesmsg-webhook (PM2) — process manager for handler on :18793

Inbox map

IDNameNumsPrimary NumberUse case
128279Dispo | A16(949) 776-5077Default list blasts (CRMLS agents)
143887End Buyer/Cash Buyer1(949) 558-2868InvestorBase CH3 CA blasts
160031End Buyer (FL)1(407) 250-1332InvestorBase CH3 FL blasts
153323Dispo A (FL)1(407) 904-9008FL dispo outreach
210192Dispo (AZ)1(480) 400-5187AZ dispo outreach

Local presence (is_geomatch: true) is enabled on all 12 inboxes — SalesMsg auto-selects the outbound number matching the recipient’s area code. No per-message number selection needed.

How it’s used

  • Trigger: Inbound SMS fires message.created webhook → salesmessage-handler-v4-complete.js → Supabase write + agent dispatch via OpenClaw gateway (:18789)
  • Outbound workflow: Acquisitions or dispo agent calls POST /conversations with team_id (inbox ID) → SalesMsg selects local-presence number automatically
  • Agents involved: acquisitions agent (CH outreach Stages 1-4), dispo agent (buyer comms), Aurora (orchestration + note posting)
  • Blast workflow: dispo-blast-engine.js coordinates 4-channel blast; SalesMsg handles CRMLS agent list channel and InvestorBase end-buyer channels — see dispo-blast
  • Failure mode: OAuth token expiry → 401 on all API calls → sm-token-refresh auto-recovers within 6h; manual refresh: node scripts/sm-token-refresh.js --force
  • Success criteria: message.created webhook received within 5s of outbound send; Supabase openphone_messages (or equivalent table) row created; no 429s in handler logs

Agents that touch this

  • _summary — Stage 1-4 outreach, inbound reply classification (A-G)
  • _summary — orchestration, posting internal notes via Aurora OAuth token
  • _summary — buyer-side SMS comms post-blast

Skills that invoke this

Plans that govern this

Feedback rules

KB / source docs

  • API — full API reference, OAuth flow, inbox/contact/conversation endpoints
  • WEBHOOKS — event types, payload schemas, ?secret= auth pattern
  • CREDENTIALS — token storage, refresh flow, Aurora token

System maps

This hub is part of the SMS/Carrier compliance cluster. All three SMS/voice channels must be considered together for TCPA compliance, 10DLC registration, and blast safety.

  • cloudflare — tunnel + WAF governing this endpoint; FUNNEL-REGISTRY.md is authoritative
  • openphone-quo — sibling webhook handler on :18792
  • twilio — sibling webhook handler on :18797
  • hubspot — sibling webhook handler on :18790

Open issues / TODOs

  • P0 SECURITY: Rotate ANTHROPIC_API_KEY in /etc/systemd/system/salesmsg-gateway.service — replace hardcoded sk-ant-api03-C4A75YcCl... with 1Password-injected reference (per G-NO-PLAINTEXT-CREDS)
  • Verify SalesMsg webhook ?secret= token value matches FUNNEL-REGISTRY; audit processed_webhook_events dedup TTL still 24h
  • Confirm feedback_salesmsg_mention_syntax applies to Aurora note-posting via salesmessage-aurora-oauth.json
  • Document all 12 inboxes in this hub (currently 5 of 12 documented above)
  • Add SalesMsg to cred-proxy rotation plan when B1-B6 ratified

Recent activity

  • 2026-05-03: hub created (W1-S2)