Skip to content

feat: announce new submissions in the guild review channel (bot)#52

Merged
Musiker15 merged 1 commit into
mainfrom
feat/slice-8b-review-embed
Jun 20, 2026
Merged

feat: announce new submissions in the guild review channel (bot)#52
Musiker15 merged 1 commit into
mainfrom
feat/slice-8b-review-embed

Conversation

@Musiker15

Copy link
Copy Markdown
Member

Phase 1 finish — Task 2/5: New-submission review embed

When a form is submitted, the bot posts a review embed (applicant + answer preview + an Open in dashboard link) to the guild's configured review channel (concept §11 / §5.1 step 7).

Changes

  • DB migrationNotification.user_id is now nullable and gains an optional guild_id (+ index), so the outbox can target a guild channel, not only a user DM. (prisma migrate deploy applies it.)
  • sharedsubmission_review notification type + SubmissionReviewNotification payload (submissionId, formTitle, applicantName, preview lines).
  • submit route — best-effort queues a submission_review Notification (guildId + payload) after the submission is created; a queue failure never breaks the submit.
  • botdeliverReview resolves the guild's botConfig.reviewChannelId and posts the embed; drops cleanly when there's no guild/channel or on permanent channel errors (Unknown Channel / Missing Access / Missing Permissions), retries transient ones. dashboardSubmissionUrl helper (+ test).

Notes

Verification

  • pnpm typecheck ✅ (web + bot) · pnpm lint ✅ · pnpm test ✅ · pnpm build ✅ · bot loads under tsx ✅

When a form is submitted, the bot posts a review embed (applicant + answer
preview + 'Open in dashboard' link) to the guild's configured review channel.

- db migration: Notification.user_id is now nullable and gains an optional
  guild_id (+ index), so the outbox can target a guild channel, not only a
  user DM.
- shared: 'submission_review' notification type + SubmissionReviewNotification
  payload (submissionId, formTitle, applicantName, preview lines).
- submit route: best-effort queues a submission_review Notification (guildId +
  payload) after the submission is created; failure never breaks the submit.
- bot: deliverReview resolves the guild's botConfig.reviewChannelId and posts
  the embed; drops cleanly when no guild/channel or on permanent channel errors
  (Unknown Channel / Missing Access / Missing Permissions), retries transient.

Accept/Reject buttons + role grant land in the next task.
@Musiker15 Musiker15 merged commit e8a1537 into main Jun 20, 2026
3 checks passed
@Musiker15 Musiker15 deleted the feat/slice-8b-review-embed branch June 20, 2026 16:02
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