Commit Graph
2567 Commits
Author SHA1 Message Date
Matthew Meszaros d2165f2b8e fix(connectlink): refuse a sign-in when the link's required address cannot be read
RequiredAddress went through the best-effort LoginHint, so a failed lookup of a
store sign-in link read as "any account may sign in". It now returns an error,
the chain passes it on, and FinishOAuth refuses the sign-in before connecting:
nothing is stored and the link stays unused. Follow-up to #1325 (CodeRabbit).
2026-11-27 10:40:31 +01:00
Matthew Meszaros d668202708 fix(store): refuse a sign-in link signed in as another account
A store sign-in link is for one purchased mailbox, but any account that signed in
through it was connected: Inboxlogy signed jordan@stagovahq.com's link in as the
tenant's admin@stagovahqcom.onmicrosoft.com, which connected that account into the
customer's workspace, used up the link ("This link is complete") and never reached
GraphKit, so the purchase stayed unconnected until the link neared expiry.

- connectlink.PartnerLinks gains RequiredAddress: store links require their mailbox;
  partner API links keep a pre-fill-only hint ("").
- email.OAuthConnectWithCodeAs checks the signed-in address right after the owner
  lookup and refuses another account (signed_in_as_other) before storing anything,
  so the slot is released and the link stays usable. The connect page shows
  "You signed in to Microsoft as X, but this link is for Y ...".
2026-11-27 10:24:30 +01:00
Matthew Meszaros 4120368ae4 feat: show GraphKit's mailbox order pause up front on the buy page and in GET /v1/store/status as mailbox_orders_paused, and refuse a quote or order with mailboxes during it with mailbox_orders_paused instead of telling the buyer to choose another provider 2026-11-25 16:50:10 +01:00
Matthew Meszaros 289af903d5 feat(store): connect purchased Microsoft mailboxes by vendor sign-in
Register the Outlook app as GraphKit's microsoft.sign_in_client_id and mint
Outlook single-mailbox sign-in links for oauth Microsoft mailboxes, as for
Google. The store no longer needs the admin mailbox's password to approve its
app in the tenant. Admin Retry connect now also mints a missing sign-in link.
2026-11-25 08:12:11 +01:00
Matthew Meszaros 239e8839d3 fix(store): mint the sign-in link while the vendor still sets the mailbox up
GraphKit now reports a Google mailbox as oauth, not ready while it is still
provisioning (the mail vendor's API stays in LICENSING / SETUP_IN_PROGRESS
after its team has finished the Workspace). Mint and register the sign-in
link for provisioning mailboxes too, so the vendor can sign them in.
2026-11-24 13:32:50 +01:00
Matthew Meszaros 008cad865e feat: add an operator switch that pauses new domain and mailbox purchases, keeping the Buy new mailboxes row in the Add account menu marked Paused with "Will be available again soon", refusing new quotes, orders and domain connects with 503 store_sales_paused while existing purchases keep renewing, and make the instance settings patch save the social seat prices 2026-11-23 18:55:07 +01:00
Matthew Meszaros f945ffe044 feat: stop the campaign send plan charging a closed sending window to the behaviour plan's hourly limit, so a campaign before its start date reports the sending window, and name the start date in the send plan card's headline 2026-11-23 17:07:24 +01:00
Matthew Meszaros 539a4e23fc Merge remote-tracking branch 'origin/main' into feat/linkedin-addon-billing 2026-11-21 21:48:16 +01:00
Matthew Meszaros 38c4147615 feat: turn the LinkedIn add-on into a channel-neutral social add-on on GraphKit's partner API: LinkedIn, Instagram, WhatsApp, Telegram and Facebook accounts at one price per account under Settings > Social accounts with setup links instead of a sidebar item, QR, pairing-code, cookie and password sign-in, one Social campaign step with every GraphKit action per channel (invites, messages, InMail, voice notes, visits, follows, reactions, comments, endorsements, withdrawals) plus versions and consent bases, social_* branch conditions, /v1/social routes with READ_SOCIAL and MANAGE_SOCIAL, contact_social_identities, a Social unibox scope and contact tab, store social conversations with their channel, refresh the account list when a QR sign-in finishes by polling, and renumber the add-on migrations to 000416-000421 after main 2026-11-21 21:48:09 +01:00
Matthew Meszaros db3ae43467 feat: cache Gmail and Outlook message-map answers in the worker so held delta walks stop re-asking the control plane (#1308)
* feat: cache each Gmail and Outlook mailbox's message-map answers in the worker (found and not found, dropped on every Add, Del and arrival admission) so delta and history walks re-reading pages held behind a fair-use deferral stop asking the control plane about the same ids every pass

* feat: hold the worker's per-mailbox message-map cache to its 5,000-entry limit while inserting a large read, still returning every answer to the caller
2026-11-21 20:18:00 +01:00
Matthew Meszaros 41c592e045 feat: serve warmup partner selection from per-process pool-wide snapshots (#1307)
* feat: serve warmup partner selection from per-process pool-wide snapshots (own-tier and borrowable cohorts per pool, today's new-thread counts and bounced recipients at 20s, seven-day counts at 1m) instead of per-call id-array scans, recounting a revalidated reserved send's recipient live so it is never held against itself

* feat: describe the warmup partner snapshot as refreshed every 20s with the last good copy served while a refresh runs or fails, and say only the caller's own context ending fails a first read
2026-11-21 19:57:59 +01:00
Matthew Meszaros 58ca837244 feat: index send-recovery and reply-intent lookups, default log level to info, quiet batched map lookups in the access log (#1306)
* feat: index outbound_attempts by task and reply_intents by unibox message so send recovery and reply lookups stop scanning those tables, default the Go services' log level to info outside dev with a documented LOG_LEVEL override, and drop successful batched message-map lookups from the access log

* feat: say in the configuration docs that LOG_LEVEL filters the Go services' structured log lines and leaves startup messages and the access log alone

* feat: pass LOG_LEVEL through the self-host compose env to the backend, consumer, worker and forms containers
2026-11-21 19:44:32 +01:00
Matthew Meszaros aed90a961d feat: say seats are not charged on the LinkedIn page, connect wizard, account rows and Billing tab when the instance does not bill (metered on GET /v1/linkedin/status), name LinkedIn in the header breadcrumb, quote lead finder keywords with curly quotes so boolean searches read cleanly, widen the compact usage meters, and add the LinkedIn proof flows 2026-11-21 19:10:29 +01:00
Matthew Meszaros dea0a785e3 feat: harden the LinkedIn add-on: skip social events for workspaces this instance does not have instead of blocking the store feed, cancel queued LinkedIn actions on reply, unsubscribe, removal and campaign pause with a 72-hour expiry, defer only the blocked contact on a LinkedIn step that cannot run (campaign_contact_progress.retry_at, migrations 000418-000419), retry resuming paid seats, refund an unstarted month when a seat is removed, start a revived seat's month at connect, never revive a removed seat from a stale event, refuse to price a seat without the plan, back off on GraphKit outages and hold contacts on unknown action types 2026-11-21 18:44:33 +01:00
Matthew Meszaros b77b37fe06 feat: LinkedIn add-on phase 2: LinkedIn invite, message, InMail, visit, follow, like and withdraw steps in sequences queued as paced GraphKit actions with exactly-once reservation, linkedin_connected, linkedin_replied and linkedin_invite_pending branches, LinkedIn replies stopping contacts on every channel, campaign LinkedIn senders and launch checks, LinkedIn campaign analytics, a LinkedIn scope in the unibox, contact LinkedIn activity, background LinkedIn imports that find work emails, and stage 1 of email-less contacts (a partial unique index on present emails, tolerant readers and senders; migrations 000416-000417) 2026-11-21 18:44:33 +01:00
Matthew Meszaros 25e2df677e feat: LinkedIn add-on phase 1: GraphKit social client and dev simulator, linkedin_* tables and contacts.linkedin_url (migrations 000414-000415), LinkedIn seats billed monthly from the balance in the store billing run at $49, $32 on Agency and $19 on Agency Pro, free when a workspace links its own GraphKit workspace, connect sessions with checkpoints, account settings, Sales Navigator and LinkedIn search with Warmbly annotations, AI query builder on the AI balance, saved searches, conversations, /v1/linkedin routes with READ_LINKEDIN and MANAGE_LINKEDIN, realtime events, the LinkedIn page, connect wizard, ported lead finder, admin seat prices and docs 2026-11-21 18:44:32 +01:00
Matthew Meszaros 0e037e0f9c fix: send the pre-fee invoice parameters unchanged on retries of charges the previous release started, and keep AI top-up refunds counting only when the whole charge is refunded so every release in the rollout reverses them the same way 2026-11-21 17:36:25 +01:00
Matthew Meszaros b8519ecff5 feat: add a 3% processing fee on top of every card payment into the workspace balance and the agency AI balance (one-click, Checkout, automatic reload and AI auto top-up), billed as its own invoice line with the balance credited the chosen amount, and show the fee and total in the add funds, auto top-up, store round-up and agency billing UI and docs 2026-11-21 17:21:14 +01:00
Matthew Meszaros c5eb25348d feat(store): purchased Google mailboxes connect by the mail vendor's sign-in (GraphKit oauth method)
GraphKit's oauth connection method: the store registers its Google OAuth client
(google.sign_in_client_id, live only), mints a single-mailbox connect link per
waiting mailbox (store_signin_links, migration 000413) and registers it with
GraphKit, which shows it to the mail vendor's team. The connect lands through
connectlink's partner hooks (login hint = the mailbox), the store links it to the
purchase, starts warmup and reports it signed in. Delegation/token/password are
unchanged; additive table only, so the previous release keeps working.
2026-11-21 09:45:48 +01:00
Matthew Meszaros 41c7906508 feat: flag a processing store order as stuck in the admin panel only after 72 hours, the longest GraphKit may hold one on DNS and then on the mailbox vendor 2026-11-20 21:54:44 +01:00
Matthew Meszaros f9e53441ba feat: cut CI to Go lint, Go unit tests and a Migrations job that applies every migration to an empty Postgres 16, delete every Postgres- and Redis-backed test, warm the Go cache from main, parallelize the CLI cross-compile, cache the tracking image's Rust dependencies in their own layer, roll the AWS deploy in two waves with a 120s default bake, and make tests opt-in in AGENTS.md 2026-11-20 18:00:50 +01:00
Matthew Meszaros 5a9d798829 Merge pull request #1295 from warmbly/feat/microsoft-tenant-consent
feat: Microsoft 365 tenant consent for purchased mailboxes (automatic with the admin mailbox, partner consent links, store approval fallback, action_required)
2026-11-20 16:12:37 +01:00
Matthew Meszaros 876f7ece7f feat: list POST /v1/store/domains/:id/microsoft-consent in the store route scope table with MANAGE_STORE and manage_emails 2026-11-20 15:34:51 +01:00
Matthew Meszaros 089d4d0c35 feat: approve purchased Microsoft 365 tenants in the background with the domain's admin mailbox (password grant through a Microsoft first-party public client, tid and admin-role proof, idempotent Graph service principal and app role assignments, verified and recorded through the same finisher as the callback, one run per workspace and tenant), park a mailbox on the Approve in Microsoft 365 card only after a non-transient refusal with its reason in store_mailboxes.action_reason, never sign in again on a domain that fell back, and update the buy-mailboxes guide and store endpoint reference 2026-11-20 13:59:32 +01:00
Matthew Meszaros 5391ddf177 feat: connect Microsoft 365 mailboxes bought through GraphKit with Warmbly's own Entra app after a session-less tenant admin consent (adminconsent plus administrator sign-in, verified against Graph, grant recorded and waiting connects woken), with POST /v1/partner/organizations/:external_id/microsoft-consent-links, POST /v1/store/domains/:id/microsoft-consent, action_required microsoft_consent on partner and store mailboxes (migration 000412), an Approve in Microsoft 365 step on the store order page, and docs 2026-11-20 12:36:41 +01:00
Matthew Meszaros 9ff91a4daa feat: age the single-snapshot monitoring live test's sync row past the widened full check stale window so it still reads as stale (#1294) 2026-11-20 12:32:08 +01:00
Matthew Meszaros 6b18ab8d2d feat: sync mailboxes through narrow push/IDLE checks and a 15 to 60 minute full check scaled by mailboxes against the plan allowance (#1293)
* feat: run a narrow check (Graph inbox and junk delta, IMAP INBOX and junk from their cursors, Gmail history only) on a push or IDLE wake at most every 30 seconds while the full sync pass keeps its own timer, and resolve each Graph delta page and Gmail history page through one batched message-map lookup including the immutable-id regular fallback

* feat: give every mailbox without a live push channel or IMAP IDLE watch a jittered 5-minute narrow check (Graph inbox and junk, IMAP INBOX and junk, Gmail history) that starts the moment IDLE drops or a push channel lapses and stops when the signal is back

* feat: run every mailbox's full sync check every 15 to 60 minutes scaled by mailboxes held against the plan allowance (operator-editable sync.full_check_min_minutes and full_check_max_minutes, shipped as SyncPolicy.full_check_seconds with seeds and pool-linked mailboxes kept at one minute), give errors their own backoff in nextSyncDelay, retire SYNC_PUSH_FALLBACK_INTERVAL, and widen the sync_stale monitor and provider hold recovery freshness windows to match

* feat: document that mailboxes without push or IDLE see new mail within about 5 minutes through the narrow check while every folder gets the 15 to 60 minute full check, in the mailboxes guide, realtime mailbox sync, configuration and architecture pages, and list the narrow poll interval under effective limits

* feat: keep the full sync pass on a one-minute catch-up cadence while an import or Graph, Gmail or IMAP recovery is unfinished and pull it forward when a narrow check meets such work, add a 15-minute safety narrow check behind live push channels, treat a zero mailbox allowance with mailboxes held as the slowest full check, widen the stale backfill monitor to the full check window, and correct the IMAP_IDLE admin text
2026-11-20 12:15:37 +01:00
Matthew Meszaros 24f2fd6e5f feat: route fleet node control-plane calls over the backend's private TLS listener instead of Cloudflare (#1291)
* feat: offer fleet nodes the backend's private TLS address through opt-in NODE_BACKEND_INTERNAL_URL and NODE_BACKEND_INTERNAL_CA (rendered as WARMBLY_BACKEND_INTERNAL_URL and a base64 CA beside the unchanged public address), have workers and consumers probe it at startup and route every control-plane client through one CA-pinned transport or fall back to the public URL, and add the workers root's backend_internal_port rule and the runtime root's nodes_private_backend switch

* feat: replace a node's private control-plane connections every 2 minutes over HTTP/1.1 so new backend tasks behind the Cloud Map name get node traffic, resend a request whose private dial, DNS or TLS handshake failed once to the public address (replayable bodies only, never after the request was written), and route all node calls to the public address for 5 minutes after 3 dial failures in a row, logging each switch once

* feat: keep a node's control-plane call from being resent to the public address once any private attempt wrote its headers, send the caller's own body on a first send during a public window, and mark the backend's NODE_BACKEND_INTERNAL_URL and CA settings as needing a backend restart in the configuration docs
2026-11-20 12:04:25 +01:00
Matthew Meszaros bebc0c2490 Merge pull request #1290 from warmbly/feat/contact-segments
feat: let Apollo and Salesforce imports and lead-capture forms pin every contact into chosen segments
2026-11-20 06:40:24 +00:00
Matthew Meszaros 55529c2b86 feat: check a form's segment count before touching its campaign, retry a form submission's contact with the segments still linked when one was deleted mid-submit, hold the import dialogs' submit while a new segment is being created, keep removals made during a segment create, and guard the source-segments proof fixture to QA databases 2026-11-20 07:25:28 +01:00
Matthew Meszaros 43d365e073 feat: let Apollo and Salesforce imports and lead-capture forms pin every contact into chosen segments (with inline create-named-after-import in the import dialogs, segment chips on saved imports, a form Settings picker, form API and AI tool support, workspace export of form segments and migration 000411) 2026-11-20 07:05:38 +01:00
Matthew Meszaros e68f659766 feat: always offer Microsoft 365 mailboxes in the store instead of only the providers GraphKit's live price list carries, and show a domain search's exact matches first through an exact-only search (suggestions=false) that the dashboard runs alongside the full one 2026-11-20 06:50:14 +01:00
Matthew Meszaros bb92395872 feat: register the instance's Google identity with GraphKit on its own when GraphKit refuses the Microsoft one, so Google mailboxes connect by delegation regardless 2026-11-19 20:16:24 +01:00
Matthew Meszaros 836caee500 feat: offer only the mailbox providers GraphKit's live price list carries, refuse an unlisted provider before quoting with provider_unavailable, treat GraphKit's provider refusal as final so a charged order is refunded instead of retried, and move a saved cart off a provider that is no longer offered 2026-11-19 18:58:36 +01:00
Matthew Meszaros e9042b8545 feat: refuse deleting a workspace or account while it holds running store purchases, replay a same-key ledger debit that committed while waiting on the lock, refund a paid month on a mailbox that ended under an unpaid cancellation, bill and settle every open mailbox instead of the newest 500, keep an in-flight renewal on its own charge key through auto-renew toggles and refund it when the domain can no longer renew, and keep CI fast and minimal in AGENTS.md 2026-11-19 18:30:36 +01:00
Matthew Meszaros 2644d7e4e0 Merge pull request #1284 from warmbly/feat/domain-mailbox-commerce
feat: in-app store for domains and Google Workspace or Microsoft 365 mailboxes through GraphKit, with a shared prepaid balance, bundled mailbox billing and partner add-on
2026-11-19 18:17:57 +01:00
Matthew Meszaros b6e90b6803 feat: add an in-app store to buy and renew domains and Google Workspace or Microsoft 365 mailboxes through GraphKit with a one-screen checkout, automatic DNS, tracking, forwarding, photo and signature setup, a shared prepaid balance with a $10 minimum, $100 default and auto top-up, bundled monthly mailbox billing charged before fulfilment, a plan gate that keeps purchased mailboxes readable but stops sending and warmup when the plan lapses, AI overage opt-in, admin, API, CLI, MCP, agency and partner add-on coverage, and a locked store for self-hosts until a GraphKit API key is set 2026-11-19 17:10:23 +01:00
Matthew Meszaros 000d2e752f feat: give up a warmup retention delete or removal check at once when the mailbox's IMAP server cannot be reached, instead of redelivering it five times through connect timeouts that hold a worker command slot for minutes (#1281) 2026-11-18 21:28:00 +01:00
Matthew Meszaros 62e960456b feat: run Kafka worker commands from per-mailbox queues so one slow command no longer stalls every mailbox on a worker, raise the default worker command concurrency to 32, keep a campaign lead on its mailbox while that mailbox's last send is still in flight, and drop the morning and lunch push that idled a whole campaign for up to two hours (#1280) 2026-11-18 21:08:17 +01:00
Matthew Meszaros 319e169c32 feat: keep AI copy another write stored first unless the write is a rewrite, refuse a null contact list on the paid AI write pass, release unsent reservations on a bounded context, and confirm before review links, approvals or turning review off can drop a draft or release leads 2026-11-18 14:44:31 +01:00
Matthew Meszaros 2c9691356a feat: hold a lead's own copy and AI copy to the send that claims them, keep the review hold through manual and CRM pauses, refuse an empty contact list on the paid AI write pass, round-robin background write-ahead across campaigns, and tighten the review panel's drafts, keyboard, batching and error states 2026-11-18 14:12:54 +01:00
Matthew Meszaros 77933bc216 feat: add a Review tab to every campaign email step that shows each lead's real copy with AI parts written ahead, an Approve before sending hold with approve and bulk approve, a lead preview stepper in the step editor, and a review panel on Steps when no email step is left 2026-11-18 12:54:04 +01:00
Matthew Meszaros 3f515a98b3 feat: count separators as empty in spreadsheet.Parse's leading-row check so a separator-only line above a header in another delimiter is dropped, agreeing with spreadsheet.Delimiter about which line is the header 2026-11-18 06:40:18 +01:00
Matthew Meszaros 00296d0778 feat: read the CSV delimiter off the first line with content in spreadsheet.Delimiter and treat a cell of only whitespace and byte-order marks as blank, so separator-only or BOM-padded rows above the header no longer pick the wrong delimiter or header 2026-11-18 06:30:47 +01:00
Matthew Meszaros c55651d169 feat: skip leading blank rows in spreadsheet.Parse for CSV and XLSX so an import whose sheet starts lower down gets real headers instead of a null column list that crashed the contact import mapper, with a regression test and the contacts and mailbox import guides updated 2026-11-18 06:16:00 +01:00
Matthew Meszaros 0f5cf14409 feat: send warmup replies under a "Re:" subject (mailhdr.ReplySubject) with the matching token subject while lineage keeps the thread subject, consolidate the three reply-subject helpers, add a live HandleEmailTask regression to the live-3 CI job, and update the warmup guide 2026-11-17 19:50:53 +01:00
Matthew Meszaros 08b52fe7b8 feat: hold the warmup reply share at the mailbox's reply rate by sending a reply only while one is due (warmupramp.ReplyDue) on both the arrival reply-back and the plain-send paths, at half again the target while due and never while ahead, so new threads refused by full recipient inboxes no longer push the seven-day share above the setting, with a simulation covering low new-thread reach and the warmup guide updated 2026-11-16 09:51:47 +01:00
Matthew Meszaros 26c81de39a feat: leave a failed campaign pass active for keepChainAfterFailure when moving its retry slot fails, instead of marking it pending at its old due slot 2026-11-14 16:41:44 +01:00
Matthew Meszaros 6080d95f1b feat: count a sending profile's sends through the tasks partial indexes instead of a full table scan, read each mailbox range once per scheduling pass, and give a failed campaign pass's retry and failure-log writes their own deadline 2026-11-14 16:30:21 +01:00
Matthew Meszaros 811ea880bb feat: record a mailbox's daily warmup target on the row for its local calendar date, so a local day that straddles UTC midnight adds its plan once and every date carries exactly one day's target 2026-11-13 19:44:05 +01:00