Skip to content

ci: trigger amp-common Go type regeneration on API spec changes#365

Merged
jlimatampersand merged 1 commit into
mainfrom
eng/trigger-amp-common-openapi-gen
Jul 1, 2026
Merged

ci: trigger amp-common Go type regeneration on API spec changes#365
jlimatampersand merged 1 commit into
mainfrom
eng/trigger-amp-common-openapi-gen

Conversation

@jlimatampersand

Copy link
Copy Markdown
Contributor

What

Adds .github/workflows/trigger-amp-common-gen.yml. On a push to main that touches api/**, it fires a repository_dispatch (event_type: gen-openapi-types) at amp-labs/amp-common.

Why

We want the Go structs derived from api/api.yaml's component schemas to stay in sync automatically. This trigger is the openapi-side half; the amp-common side (receiver workflow that regenerates openapi/api.gen.go and opens a PR) is in a companion PR on amp-common.

Mirrors the existing trigger-docs-gen.yml and trigger-postman.yml workflows.

Prerequisite

Relies on the org AMPERSAND_OPS_PAT secret (already used by the sibling trigger workflows) having permission to dispatch to amp-common.

🤖 Generated with Claude Code

When api/** changes on main, dispatch a repository_dispatch event to
amp-common so it regenerates the Go types derived from api/api.yaml and
opens a PR. Mirrors the existing trigger-docs-gen / trigger-postman workflows.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@jlimatampersand jlimatampersand requested review from a team, eberle1080 and laurenzlong and removed request for a team July 1, 2026 22:25
@jlimatampersand jlimatampersand merged commit 3e9cee6 into main Jul 1, 2026
2 checks passed
@jlimatampersand jlimatampersand deleted the eng/trigger-amp-common-openapi-gen branch July 1, 2026 22:48
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