Guides

Publish your packages

Publish generated packages to npm, PyPI, and as a Go module under your own name. The packages are yours. typeship maintains them; you own the registry.

Publishing the generated packages under your organization is supported and expected. It is your code: readable source, zero runtime dependencies, and nothing that depends on typeship at runtime. typeship's job is to keep the packages current through pull requests. Releasing them is your normal release process.

Every generated package carries a header comment and README credit naming typeship as the generator, on every plan.

Set the names first

For AI agentstypeship projects update <project_id> --package-names '{"typescript":"@acme/sdk","python":"acme","go":"github.com/acme/acme-go"}'.

Set package names per language in project settings under package names, or with package_names on the API, so pull requests arrive publish-ready:

  • npm: @acme/sdk or acme
  • PyPI: acme
  • Go: github.com/acme/acme-go (derived from the Go destination repository)

Version

The package version follows info.version in your spec. Bump the version in the spec and the next pull request carries it. When info.version is not semver, the version is 0.1.0, and you set it yourself before publishing.

The regeneration pull request checks the version against what changed: its typeship/semver status fails when the diff has breaking changes and the major did not bump, and the body names the version to set. See Breaking changes.

cd packages/acme
npm run build     # prepublishOnly runs this too
npm publish --access public   # --access public for a scoped package

The files field ships dist/ and src/, so consumers get compiled output and readable source. When the CLI platform is on, npm install -g @acme/sdk puts the acme bin on the PATH, and the CLI's upgrade command starts working against your registry.

Release from the pull request

A tidy loop for a dedicated SDK repository:

  1. typeship opens a pull request with the regenerated package and the API changes in the body.
  2. Review, merge.
  3. A release workflow in that repository publishes on merge to the default branch, or on tag.

Because CHANGELOG.md is maintained in the destination, release notes are already written.

Registry publishing by typeship

typeship does not hold registry tokens or publish on your behalf. Packages reach registries through your pull requests and your release workflow.

On this page