NuGet staged publishing: let the pipeline upload, keep the Promote button for a human
NuGet.org can now hold an uploaded package private until a person promotes it. What that changes for release pipelines an agent touches, and the gaps the announcement leaves open.

A coding agent that can run dotnet nuget push can publish to the public NuGet feed. That’s the uncomfortable sentence in a lot of release pipelines, and until now the options were to hand the agent that power or to keep the push on a human’s laptop. NuGet.org’s new staged publishing, announced on the .NET blog on 17 November
, adds a third: the pipeline uploads, NuGet.org validates, and nothing goes public until a person promotes it.
It’s opt-in, and existing dotnet nuget push workflows keep working. That last detail matters, because it means turning staging on for a package doesn’t protect you if an old key and an old push step are still lying around.
What a staged package is
A staged upload goes through the same checks as any other: malware scanning, signature checks and repository signing. Then it waits. According to the announcement, staged packages stay out of package pages, search results and restore, for everyone.
That’s stricter than unlisted. An unlisted package can still be restored by anyone who asks for the exact version. A staged one can’t, and the owner gets no private feed to restore it from either. If you want to test the package and its dependencies before promoting, do it from a local or private feed, with the same .nupkg file.
Two ways in. On the website, choose the staging option under Publishing Mode on the upload page. From the command line, dotnet package stage push does the same thing, and the post says it’s available in the .NET 11 RC2 SDK. A plain pipeline step looks like this:
dotnet package stage push ./artifacts/Contoso.Library.1.2.0.nupkg \
--source https://api.nuget.org/v3/index.json \
--api-key "$NUGET_API_KEY"
To collect the packages of one release, add --group. If the group doesn’t exist, NuGet.org creates it:
dotnet package stage push ./artifacts/Contoso.Library.1.2.0.nupkg \
--source https://api.nuget.org/v3/index.json \
--api-key "$NUGET_API_KEY" \
--group november-release
Those are the only flags the announcement shows. An accepted upload doesn’t mean validation has finished or that the package is public, so don’t treat a zero exit code as “released”.
Why this fits agent-driven releases
The useful property is the separation of two powers. Uploading becomes something automation can do. Making the package public needs an authorised user with two-factor authentication enabled, and promotion is a website action. No CLI approval command is planned.
The announcement’s advice is to go further than a flag. Use a staging-only API key, or restrict Trusted Publishing policies to staging. That’s the part that turns this from a convention into a control. If the credential in CI can only stage, a prompt-injected agent, a compromised workflow or a leaked secret can put a package in the queue and nothing more. Somebody still has to look at the queue.
That’s the same shape as npm’s staged publishing , which holds a version until a maintainer approves it. If a repo ships to both registries, the release process can now be the same on both: automation proposes, a person disposes.
It also pairs with the consumer-side control from the .NET 11 minimum publish age . One protects the people who restore packages, the other protects the people who publish them.
What the announcement leaves open
Staging is a hold point, not a review. The validation that runs is the validation that always ran. Nothing in the post says NuGet.org inspects what the package does, so the question a human is answering at the Promote button is “is this the build I meant to ship?”, not “is this safe?”.
For that to be a real question, the reviewer needs something to compare against. A few things the post doesn’t solve, and what to do about each:
- Group promotion isn’t atomic. Packages in a group may become restorable at different times, so a release of three interdependent libraries can briefly be half-visible. Publish dependencies first, or accept that consumers might see a window where one package’s dependency isn’t there yet.
- Staged content expires if it isn’t promoted, but the post doesn’t say after how long. Don’t build a Friday-afternoon release process on an unknown timer. Stage on the day you plan to promote.
- Approval is an authenticated session, not a fresh two-factor challenge for each promotion. The 2FA requirement is on the account. A person who’s signed in on a shared or unlocked machine can promote.
- Permissions follow the staging owner, a user or an organisation. Being a co-owner of a package doesn’t grant access to content staged for a different owner, so decide up front which owner the pipeline stages under.
dotnet package stage listand the group commands (group create,group list,group add) are on the roadmap and not final syntax. Scripts that depend on them are scripts against a guess.
None of this is a reason to skip staging. It’s a reason not to oversell it internally as “releases are now reviewed”.
What to make the reviewer look at
The Promote click is only worth anything if it’s informed. Have the pipeline attach the facts before the person gets there: the package ID and version, the commit SHA it was built from, the list of dependencies, and a diff of the public API against the last published version. The announcement tells reviewers to confirm that package IDs, versions and dependencies match the release plan, so write the release plan down somewhere the pipeline can print it.
An agent can draft that summary, and it’s a reasonable job for one. It can’t be the thing that approves it, and the staging-only key is what enforces that. Keep the two apart in the pipeline too: the job that builds the summary shouldn’t hold the API key at all.
When it isn’t worth the friction
A package consumed by one team, rebuilt on every merge and published to a private feed, has no use for a public hold point. Staging is for packages other people restore, where a bad version can’t be recalled once it’s been installed. Even there, a library that ships once a quarter can live with a manual promote. One that ships daily will find the click turns into a reflex, and a reflex isn’t a review.
The other cost is the missing private restore. Pipelines that smoke-test the published package by restoring it from nuget.org need a rethink, because staged packages can’t be restored by anyone until promotion. Run that smoke test against a local feed before the stage step instead.
Try it this week
Pick one internal or low-stakes package, create a staging-only API key, and push it from CI with the dotnet package stage push command above on a .NET 11 RC2 SDK or later. Promote it by hand once, and note what the reviewer actually had in front of them. If the answer is “a version number”, fix that before moving any important package over.