Skip to content

docs: add opt-in survey recruitment banner to the docs site #42528

Description

@jayjdub

Summary

Adds an opt-in, dismissible research recruitment banner to the docs site (docs/) that links
to a survey and is shown only to recruited participants. Adapted from the
github/research-accelerator recruitment-banner skill.

Survey: GitHub Agentic Workflows (Alchemer) · Slug: gh-aw-docs-research-2026q3

Contributing path

I'm not on the core team, so per CONTRIBUTING.md this is an issue rather than a PR (non-core PR
creation is blocked). The change is fully implemented on a fork branch — diff ready to review:
👉 https://github.com/github/gh-aw/compare/main...jayjdub:gh-aw:add-docs-recruitment-banner?expand=1
(branch jayjdub:gh-aw@add-docs-recruitment-banner). A core-team member can open the PR or
cherry-pick the branch.

Why this design (static-site targeting)

The stafftools recruitment banner targets current_user server-side. This docs site is static
GitHub Pages
(github.github.com/gh-aw/) — no server, no current_user. Targeting is enforced
by who the recruitment link is distributed to (the dotcom_id audience):

  • The link carries ?recruit=gh-aw-docs-research-2026q3 (optionally &uid=<dotcom_id>).
  • Only recipients see the banner; eligibility is remembered per-browser (localStorage) and
    persists across docs pages; dismissal sticks.
  • The audience list is never committed (committing participant IDs to a public repo would
    expose them).
  • CTA gets utm_source=inproduct_banner&utm_medium=docs&utm_campaign=<slug> (+ pid); a
    banner_research_cta event fires on click.

Proposed changes (all under docs/)

File Purpose
docs/src/config/recruitmentBanner.ts Knobs: enabled, slug, copy, ctaUrl, path scope, frequency
docs/src/components/RecruitmentBanner.astro Banner UI + client eligibility; overrides Starlight's Banner slot (preserves native frontmatter banners)
docs/astro.config.mjs One line wiring the Banner override
docs/RECRUITMENT_BANNER.md Config guide + go-live checklist

Safe by default

  • Ships OFF (enabled: false) — landing it does not make the banner visible; turning it
    on is a deliberate follow-up change.
  • No auto-cap — monitor and flip enabled: false at quota.
  • No participant IDs committed; the gift-card incentive is stated honestly in the copy (payout
    is a separate flow).

Test plan

With enabled: true on a preview build, open any docs page with
?recruit=gh-aw-docs-research-2026q3&uid=<own-dotcom_id> → banner renders, CTA points at the
survey with UTM params, dismiss persists. Without ?recruit=, the banner never shows.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions