Reusable GitHub Actions workflow that posts a survey link to a pull request when it is merged, if the author is a new contributor. Used to gather feedback from new contributors about their OpenTelemetry contribution experience.
The survey link automatically includes the caller repository as a query parameter (entry.1540511742=<owner/repo>), so responses collected in the shared OpenTelemetry Google Form are tagged with the source repo.
Confirm that your repository is one of the options in the survey's first question — a select/dropdown that identifies which repository the response is about. Open the survey form and check whether your repository appears in that list.
If your repository is not listed, request its addition by posting a message in the #contributor-experience channel on CNCF Slack. A maintainer will add your repository to the form's options. Wait until your repository appears in the dropdown before enabling this workflow.
Add a caller workflow to your repository, for example .github/workflows/survey-on-merged-pr.yml:
name: Survey on merged PR
on:
pull_request_target: # zizmor: ignore[dangerous-triggers] — this workflow only calls the reusable shared workflow; no PR code is checked out or executed.
types: [closed]
branches: [main]
permissions: {}
jobs:
survey:
uses: open-telemetry/shared-workflows/.github/workflows/survey-on-merged-pr.yml@<sha-or-tag>
with:
client_id: ${{ vars.OTELBOT_CLIENT_ID }}
secrets:
private_key: ${{ secrets.OTELBOT_PRIVATE_KEY }}Pin <sha-or-tag> to a commit SHA or release tag in this repository. Substitute the variable/secret names on the right-hand sides to match whatever your repo uses.
The zizmor: ignore[dangerous-triggers] inline comment on the pull_request_target: line is only relevant if your repo runs zizmor; it silences the false-positive finding since this caller doesn't check out any PR-controlled code — it just invokes the shared workflow which itself operates entirely through the GitHub API.
| Input | Required | Type | Description |
|---|---|---|---|
client_id |
yes | string |
OTELBOT app Client ID for the caller repo. Pass the value of your OTELBOT_CLIENT_ID-style variable. |
| Secret | Required | Description |
|---|---|---|
private_key |
yes | PEM private key for the OTELBOT app referenced by client_id. |
- Not idempotent per author: the workflow posts a survey comment on every merged PR by a non-member, not just the first. If the same external contributor gets several PRs merged, they receive the survey comment on each one.