Skip to content

feat(api): add release channels that cap which modules a deployment runs - #2220

Draft
Windscar wants to merge 1 commit into
mainfrom
sagar/channels-manifest
Draft

Windscar wants to merge 1 commit into
mainfrom
sagar/channels-manifest

Conversation

@Windscar

@Windscar Windscar commented Oct 5, 2026

Copy link
Copy Markdown
Contributor

Important

Do not merge until solana-foundation/sdp-infra#202 is merged and applied to stage and prod (stage by hand, prod via an sdp-infra release; check SDP_RELEASE_CHANNEL on the API service, worker and job templates). Without it the API refuses to boot in managed production.

PR 1 of 5. SDP_RELEASE_CHANNEL (dev | beta | stable) caps which modules a deployment runs. Design: ADR 0005; proposal: SDP-020.

  • Module stages live in packages/sdp-types/src/release-channels.ts; ramp providers have their own stages, and Ramps is in a channel when one provider is.
  • dev changes nothing: every module, the default, and what every environment runs first.
  • Boot check: an unknown channel fails everywhere; managed production must set one.
  • Existing module flags now also respect the channel; /health reports it.

API before/after

GET /health  main (reconstructed): {"environment":"development"}
             dev:    {"environment":"development","releaseChannel":"dev"}
             stable: {"environment":"development","releaseChannel":"stable"}

Verification: typecheck + Biome clean; API 6825 (1 Earn audit flake, 58/58 alone), web 3062, sdp-policy 90; boot-check calls mutation-tested; local API on dev and stable.

🤖 Generated with Claude Code

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@vercel

vercel Bot commented Oct 5, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
sdp-docs Ready Ready Preview Oct 5, 2026 8:40pm UTC
sdp-web Ready Ready Preview Oct 5, 2026 8:40pm UTC

Request Review

@Windscar

Windscar commented Oct 5, 2026

Copy link
Copy Markdown
Contributor Author

@greptileai review

@greptile-apps

greptile-apps Bot commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 5/5

[Critical risk] Adds release channels that gate which modules the API runs.

The code appears safe to merge once Windscar's stated infrastructure prerequisite is satisfied.

What we checked:

  • Channel survives startup: getProcessEnv() returns the full process environment. Both supported entrypoints call the channel check before doing their work.
  • New setting passes drift rules: The check requires example keys to have form fields, not every API key. Adding the channel to the API list does not create either kind of drift.

Summary

Adds shared release channels and applies their limits to existing API feature flags.

  • Defines module and ramp-provider stages, with dev preserving existing flag behavior.
  • Checks channel settings when the API and scheduled job start.
  • Adds releaseChannel to /health and passes the setting through Compose and local environment tooling.
  • No actionable issues found in this PR.
  • Windscar explicitly acknowledged that managed production cannot boot until the infrastructure prerequisite supplies SDP_RELEASE_CHANNEL. Dashboard and remaining API gates are deferred to later PRs in the supplied stack.
  • Windscar's added ADR explicitly makes stopping excluded-module exits intentional and requires open positions to be settled before removing a module.

Reviews (1) · Last reviewed commit: "feat(api): add release channels that cap..."

This branch was successfully deployed

2 active deployments
Preview – sdp-web — c7881a48 Deployed Oct 5, 2026 by vercel[bot]
Preview – sdp-docs — c7881a48 Deployed Oct 5, 2026 by vercel[bot]
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