OpenUPMOpenUPM
Packages
Docs
Blog
  • Support OpenUPM
  • Contributors
  • Uptime Status
  • Queue Status
  • Trends
  • GitHub
  • Twitter
  • Discord
  • Contact Us
  • Package Updates
  • Blog RSS
CLI
Loading...
Stars ... Donate
Packages Stars ... Donate
Packages
Docs
Blog
  • Support OpenUPM
  • Contributors
  • Uptime Status
  • Queue Status
  • Trends
  • GitHub
  • Twitter
  • Discord
  • Contact Us
  • Package Updates
  • Blog RSS
CLI
  • User Guide

    • OpenUPM Unity Package Manager Registry Docs
    • Getting Started with Unity Editor
    • Getting Started with OpenUPM-CLI
    • Unity Scoped Registry Troubleshooting
    • Frequently Asked Questions
  • Package Creator Guide

    • Adding UPM Package
    • Publishing with GitHub Actions
    • Signing UPM Packages
    • Adding Badges
    • Troubleshooting Build Errors
    • Modifying UPM Package
    • Reclaiming Package Ownership
    • Opt-out From OpenUPM
    • Managing UPM Project like a Pro
  • Host Your Private Registry

    • Quick Guide: Host Your Private Unity Scoped Registry in Just 15 Minutes
  • NuGet

    • NuGet Packages
  • Support US

    • Support OpenUPM
    • Contributors
    • Contributor Badges
  • Resources

    • Team
    • Terms of Use
    • Code of Conduct
    • Privacy Q&A
  • Home
  • Docs
  • Publishing with GitHub Actions

Publishing with GitHub Actions

OpenUPM can publish a package version automatically after you push a Git tag or publish a GitHub Release. The official GitHub Action triggers an OpenUPM package scan and waits until the matching version is published, fails, or reaches the workflow timeout.

Use this when you maintain the package repository and want the tag workflow to report whether the OpenUPM registry has accepted the new package version. This does not replace the normal OpenUPM package submission process: the package must already be registered on OpenUPM, and the registered repoUrl must point to the same public GitHub repository that runs the workflow.

What the Action Does

The action performs three steps:

  1. Request a short-lived GitHub Actions OIDC token from GitHub.
  2. Send the package name and Git tag to OpenUPM.
  3. Poll OpenUPM until the version is installable from the registry, fails, or reaches the configured timeout.

You do not need an OpenUPM account, an OpenUPM token, a GitHub personal access token, or a shared webhook secret. OpenUPM verifies the GitHub OIDC token and checks that the workflow repository matches the package repoUrl.

Tag Push Workflow

Only send tags that contain a parseable semver package version to the action, for example 1.2.3, v1.2.3, upm/1.2.3, or com.example.package@v1.2.3. Other tags are rejected by the action before it contacts OpenUPM.

Add this workflow to the package repository:

name: OpenUPM

on:
  push:
    tags:
      - '**'

permissions:
  id-token: write
  contents: read

jobs:
  publish:
    runs-on: ubuntu-latest
    steps:
      - uses: openupm/openupm-action@v1
        with:
          package: com.example.openupm-action
          tag: ${{ github.ref_name }}

The id-token: write permission lets the action request a GitHub OIDC token. The token is scoped to the workflow run and expires quickly.

GitHub Release Workflow

You can also trigger OpenUPM after a GitHub Release is published:

name: OpenUPM

on:
  release:
    types: [published]

permissions:
  id-token: write
  contents: read

jobs:
  publish:
    runs-on: ubuntu-latest
    steps:
      - uses: openupm/openupm-action@v1
        with:
          package: com.example.openupm-action
          tag: ${{ github.event.release.tag_name }}

Inputs

InputRequiredDefaultDescription
packageYesOpenUPM package name, such as com.company.tool.
tagYesGit tag that triggered the workflow. It must contain an OpenUPM-compatible package version.
timeout-minutesNo15Maximum time to wait before failing the workflow.
poll-interval-secondsNo15Delay between status checks.

Outputs

OutputDescription
stateFinal OpenUPM release state, such as succeeded or failed.
reasonPublic failure reason when OpenUPM reports one.
published-versionRegistry version reported by OpenUPM when available.
signedWhether OpenUPM reports the package version as signed.
package-urlOpenUPM package page URL.
status-urlOpenUPM release status API URL.

Failure Behavior

The workflow fails when OpenUPM rejects the trigger request, the package version fails to build, or the timeout is reached before the version becomes installable.

A successful action run means the requested version is available from the OpenUPM registry. The package detail page and website search may update through their own refresh cycle after the registry publish completes.

If the action reports a build failure, use the package page's build history and the Troubleshooting Build Errors guide to fix the package, then create a new version tag or re-tag a failed version when your repository policy allows it.

Example Repository

The openupm/com.example.openupm-action repository demonstrates a minimal Unity package that publishes through the openupm/openupm-action workflow.

Edit this page
Adding UPM Package Signing UPM Packages