ghostguild-org/tests/server
Jennie Robinson Faber 55029e7eb7 feat(activation): wire autoFlagPreExistingSlackAccess into self-serve paths
Replaces the per-file inviteToSlack helpers with a single auto-flag
call. Self-serve activation paths now check for pre-existing workspace
membership (silent on miss) instead of attempting an admin-only invite.

- helcim/subscription.post.js: removed local inviteToSlack; both
  free- and paid-tier activation branches now call the helper, then
  notifyNewMember with the canonical 'manual_invitation_required' arg.
- members/create.post.js: same shape — helper + canonical notify arg.
- invite/accept.post.js (free-tier branch): added the helper call after
  member creation. Free-tier had no prior Slack call (audit confirmed);
  paid-tier remains untouched and activates via the Helcim webhook.

Admin-created and CSV-imported members intentionally do NOT call the
helper — admins flip the flag manually after sending the invite.

Test stub for autoFlagPreExistingSlackAccess added to server setup.
2026-04-29 12:21:12 +01:00
..
api feat(activation): wire autoFlagPreExistingSlackAccess into self-serve paths 2026-04-29 12:21:12 +01:00
config feat(launch): security and correctness fixes for 2026-05-01 launch 2026-04-25 18:42:36 +01:00
helpers Add Vitest security test suite and update security evaluation doc 2026-03-01 12:30:06 +00:00
middleware refactor(rate-limit): delegate auth limiting to handlers, add dev bypass 2026-04-27 19:18:34 +01:00
models feat(slack): autoFlagPreExistingSlackAccess helper 2026-04-29 12:13:59 +01:00
tasks feat(slack): add background job to detect Slack workspace joins 2026-04-09 22:32:48 +01:00
utils feat(slack): autoFlagPreExistingSlackAccess helper 2026-04-29 12:13:59 +01:00
setup.js feat(activation): wire autoFlagPreExistingSlackAccess into self-serve paths 2026-04-29 12:21:12 +01:00