Skip to content

Epic 8.5 — Job Flier Generator

(Add-on to Epic 5 / Job Board — renumbered from a previously conflicting "Epic 9" so it no longer collides with the Groups epic below.)


BE-FLIER-001 — Job flier AI generation (full implementation)

  • [x] Implemented

Files:

  • Edit: src/services/ai/flierGenerator.ts — implement real OpenAI call
  • Edit: src/graphql/resolvers/job.tsgenerateJobFlier calls real service

Description: Call OpenAI GPT-4o with the job details. Prompt extracts: title, key requirements, compensation, deadline, production type. Returns a structured flier spec JSON: { template, headline, subheadline, bullets[], colors, logoUrl }. Store the spec in job.flierSpec (add JSON field to schema). The frontend renders this spec into images.

Output variants: Instagram 1080×1080, Twitter 1600×900, LinkedIn 1200×627, Facebook 1200×630, Story 1080×1920. All generated via a canvas render function on the frontend.

Add to Prisma: flierSpec Json? on Job model.


FE-FLIER-001 — Job flier generator UI (producer)

  • [x] Implemented

Files:

  • Create: apps/app/src/pages/jobs/JobFlierPage.tsx
  • Create: apps/app/src/lib/canvas/renderFlier.ts — HTML Canvas rendering of flier spec
  • Edit: apps/app/src/App.tsx — add route /jobs/:id/flier

Description: Producer view after posting a job. "Generate Flier" button calls generateJobFlier mutation. Shows loading state. When spec is returned, renders previews for each social media size using Canvas. Allows download as PNG/JPG. Shows QR code (use qrcode.react) that deep-links to the job. Matches "Job Flier" section in spec doc.


FE-FLIER-002 — Flier sharing: hashtag suggestions, social share, email/DM

  • [x] Implemented

Files:

  • Edit: apps/app/src/pages/jobs/JobFlierPage.tsx — add sharing panel below flier previews
  • Edit: src/services/ai/flierGenerator.ts — extend GPT-4o prompt to also return { hashtags[], captionSuggestion }
  • Edit: src/graphql/schema/index.ts — add hashtags and captionSuggestion to flier spec type

Description:

  • Hashtag suggestions: GPT-4o returns 5–10 relevant hashtags alongside the flier spec. Shown as copyable chips below the flier.
  • Caption suggestion: a short social-ready caption (1–2 sentences) also returned by the AI. One-click copy.
  • One-click social share: Web Share API on mobile for Instagram, TikTok, Twitter/X, LinkedIn. Desktop fallback: opens share dialog with pre-filled caption + hashtags.
  • Email flier: "Email to candidates" button opens a modal with a to-address input + pre-filled subject/body and an inline flier image attachment. Calls a sendFlierEmail(jobId, toEmails: [String!]!) mutation (backend sends via SMTP/Resend).
  • Direct message: "Send via DM" button opens a talent-search modal to pick a recipient, then sends the flier image URL as a message (ties into Messaging epic).