Skip to content

improvement(slack): merge slack_v2 auth into one credential picker for accounts and custom bots#5800

Merged
TheodoreSpeaks merged 3 commits into
stagingfrom
feat/simplify-slack-v2
Jul 21, 2026
Merged

improvement(slack): merge slack_v2 auth into one credential picker for accounts and custom bots#5800
TheodoreSpeaks merged 3 commits into
stagingfrom
feat/simplify-slack-v2

Conversation

@TheodoreSpeaks

Copy link
Copy Markdown
Collaborator

Summary

  • slack_v2's authMethod dropdown is gone — one credential picker (credentialKind: 'any') lists Slack OAuth accounts and custom bots together in a grouped dropdown, with a connect action per group; the credential's kind is resolved server-side from credential.type
  • slack_oauth trigger is custom-bot-only: removed the hidden appType field and the sim-mode OAuth picker, event dropdown is the full static catalog, deploy routing always uses routingKey = botCredentialId (native Sim-app path removed for now — ingest route stays for a future ship)
  • collapsed the ~13 dependsOn: { all: ['authMethod'], ... } gates to ['credential'] and dropped the dead sim-event constants
  • added customBotCredential/manualBotCredential to CREDENTIAL_SUBBLOCK_IDS so credential deletion cleans trigger references
  • no value migration: slack_v2 is preview-gated; old bot-auth action blocks fail loudly at required-field validation and re-pick from the merged dropdown

Type of Change

  • Improvement

Testing

Tested manually on a live canvas (merged picker groups + both connect actions, trigger shows no App Type, stale authMethod ignored on load). lint, check:api-validation:strict, typecheck, and slack/deploy/serializer test suites pass; added deploy tests for the bot-credential canonical collapse (branch previously untested).

Checklist

  • Code follows project style guidelines
  • Self-reviewed my changes
  • Tests added/updated and passing
  • No new warnings introduced
  • I confirm that I have read and agree to the terms outlined in the Contributor License Agreement (CLA)

🤖 Generated with Claude Code

@vercel

vercel Bot commented Jul 21, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated (UTC)
docs Skipped Skipped Jul 21, 2026 7:00pm

Request Review

@cursor

cursor Bot commented Jul 21, 2026

Copy link
Copy Markdown

PR Summary

Medium Risk
Webhook deploy routing for Slack triggers is simplified (Sim OAuth path removed), which can break existing sim-mode trigger configs outside preview-gated slack_v2; credential picker and deploy changes touch auth-adjacent workflow configuration.

Overview
slack_v2 drops the authMethod / raw bot-token / separate custom-bot fields in favor of one credentialKind: 'any' picker that groups Sim OAuth accounts and custom bots, with separate connect actions and optional credentialLabels copy.

The shared CredentialSelector gains merged-mode combobox groups (ComboboxOptionGroup), searchable non-editable UX, and a single ConnectServiceAccountModal path (including Slack bot onCreated); the dedicated custom-bot kind and inline ConnectSlackBotModal usage are removed.

slack_oauth is custom-bot-only: hidden appType, Sim OAuth trigger credential, and sim-event gating are removed; the event list is the full catalog; deploy always validates botCredential, sets routingKey to the bot credential id, and no longer supports the native Sim-app OAuth routing branch.

Supporting updates: subblock dependsOn gates move from authMethod to credential for v2; trigger bot credential ids are included in credential deletion cleanup; deploy tests cover botCredential canonical collapse.

Reviewed by Cursor Bugbot for commit 19769ef. Bugbot is set up for automated code reviews on this repo. Configure here.

@greptile-apps

greptile-apps Bot commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

This PR combines Slack v2 authentication into one credential flow. The main changes are:

  • Groups Slack OAuth accounts and custom bots in one credential picker.
  • Makes the Slack OAuth trigger use custom-bot credentials only.
  • Routes custom-bot events by credential ID during deployment.
  • Cleans deleted custom-bot references from saved workflows.

Confidence Score: 5/5

This looks safe to merge.

  • No blocking issues found in the changed code.

Important Files Changed

Filename Overview
apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/editor/components/sub-block/components/credential-selector/credential-selector.tsx Adds grouped selection and separate connection actions for Slack OAuth accounts and custom bots.
apps/sim/blocks/blocks/slack.ts Replaces Slack v2 authentication fields with one merged credential input.
apps/sim/triggers/slack/oauth.ts Makes the Slack trigger custom-bot-only and exposes the full event catalog.
apps/sim/lib/webhooks/deploy.ts Validates custom-bot credentials and routes deployed Slack triggers by credential ID.
apps/sim/lib/workflows/persistence/utils.ts Adds custom-bot fields to credential-reference cleanup.

Reviews (4): Last reviewed commit: "improvement(slack): move provider-specif..." | Re-trigger Greptile

Comment thread apps/sim/lib/webhooks/deploy.ts
@TheodoreSpeaks

Copy link
Copy Markdown
Collaborator Author

@greptile

@TheodoreSpeaks

Copy link
Copy Markdown
Collaborator Author

@cursor review

@cursor cursor 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.

✅ Bugbot reviewed your changes and found no new issues!

Comment @cursor review or bugbot run to trigger another review on this PR

Reviewed by Cursor Bugbot for commit 3669a0a. Configure here.

@TheodoreSpeaks

Copy link
Copy Markdown
Collaborator Author

@greptile

@TheodoreSpeaks

Copy link
Copy Markdown
Collaborator Author

@cursor review

@cursor cursor 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.

✅ Bugbot reviewed your changes and found no new issues!

Comment @cursor review or bugbot run to trigger another review on this PR

Reviewed by Cursor Bugbot for commit 85f40a4. Configure here.

@TheodoreSpeaks

Copy link
Copy Markdown
Collaborator Author

@greptile

@TheodoreSpeaks

Copy link
Copy Markdown
Collaborator Author

@cursor review

@cursor cursor 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.

✅ Bugbot reviewed your changes and found no new issues!

Comment @cursor review or bugbot run to trigger another review on this PR

Reviewed by Cursor Bugbot for commit 19769ef. Configure here.

@TheodoreSpeaks
TheodoreSpeaks merged commit 5be35b5 into staging Jul 21, 2026
20 checks passed
@TheodoreSpeaks
TheodoreSpeaks deleted the feat/simplify-slack-v2 branch July 21, 2026 19:15
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