Skip to content

Publishing Packages

Each runtime package is published independently using GitHub Actions workflows triggered by tags. Push annotated tags to trigger the appropriate workflow.

RuntimeTag FormatExample
Emitter/npmemitter-v{version}emitter-v0.2.0-beta.6
C#/NuGetcsharp-v{version}csharp-v1.0.0-beta.6
Python/PyPIpython-v{version}python-v1.0.0b6
TypeScript/npmtypescript-v{version}typescript-v1.0.0-beta.6
Gogo-v{version}go-v1.0.0-beta.6
Docsdocs-v{version}docs-v1.0.0-beta.6

Before publishing, verify all runtime tests pass:

Terminal window
cd runtime/csharp && dotnet test
cd runtime/python/agentschema && uv run pytest tests/
cd runtime/typescript/agentschema && npm test
cd runtime/go/agentschema && go test ./...

Always use annotated tags with a descriptive message:

Terminal window
# TypeSpec Emitter / npm (agentschema-emitter)
git tag -a "emitter-v0.1.11" -m "Emitter v0.1.11: description of changes"
# C# / NuGet
git tag -a "csharp-v1.0.0-beta.6" -m "C# SDK v1.0.0-beta.6: description of changes"
# Python / PyPI (note PEP 440 format)
git tag -a "python-v1.0.0b6" -m "Python SDK v1.0.0-beta.6: description of changes"
# TypeScript / npm
git tag -a "typescript-v1.0.0-beta.6" -m "TypeScript SDK v1.0.0-beta.6: description of changes"
# Go
git tag -a "go-v1.0.0-beta.6" -m "Go SDK v1.0.0-beta.6: description of changes"
# Documentation
git tag -a "docs-v1.0.0-beta.6" -m "Docs v1.0.0-beta.6: description of changes"

Push the tag(s) to trigger the corresponding workflow(s):

Terminal window
# Push a single tag
git push origin csharp-v1.0.0-beta.6
# Or push all tags at once
git push origin --tags

Check the Actions tab to monitor the publish workflows.

To publish a version for all runtimes at once (example for beta.6):

Terminal window
# Create all tags
git tag -a "csharp-v1.0.0-beta.6" -m "C# SDK v1.0.0-beta.6"
git tag -a "python-v1.0.0b6" -m "Python SDK v1.0.0-beta.6"
git tag -a "typescript-v1.0.0-beta.6" -m "TypeScript SDK v1.0.0-beta.6"
git tag -a "go-v1.0.0-beta.6" -m "Go SDK v1.0.0-beta.6"
# Push all tags
git push origin --tags

You can also trigger workflows manually from the GitHub Actions UI:

  1. Go to Actions
  2. Select the appropriate workflow (e.g., “Publish C# to NuGet”)
  3. Click “Run workflow”
  4. Enter the version number if prompted
  5. Click “Run workflow”

If you need to recreate a tag:

Terminal window
# Delete local tag
git tag -d csharp-v1.0.0-beta.6
# Delete remote tag
git push origin :refs/tags/csharp-v1.0.0-beta.6
# Create new tag
git tag -a "csharp-v1.0.0-beta.6" -m "C# SDK v1.0.0-beta.6"
git push origin csharp-v1.0.0-beta.6
  1. Check the Actions tab for error details
  2. Common issues:
    • Tests failed - fix the tests and create a new tag
    • Authentication issues - check that secrets (NPM_TOKEN, NUGET_API_KEY) are configured
    • PyPI OIDC - ensure Trusted Publisher is configured on PyPI