Skip to main content

GitHub Actions Integration

v0.1.0~5 min

Official stemsplit-github-action for CI/CD pipelines

When to use this action

Use the GitHub Action when your audio is already hosted at a public HTTPS URL (S3, R2, CDN, release asset). The action calls POST /api/v1/jobs with sourceUrl. For local files in a runner, use the CLI or Node.js SDK (upload flow) instead.

Prerequisites

  • StemSplit account with verified email
  • API key (Settings → API Keys)
  • Public URL to an audio file (MP3, WAV, FLAC, etc.)

1Add your API key secret

In GitHub: Settings → Secrets and variables → Actions, create STEMSPLIT_API_KEY with your sk_live_... key.

2Add the workflow step

Separate stems and wait for completion
jobs:
  separate-stems:
    runs-on: ubuntu-latest
    steps:
      - uses: StemSplit/stemsplit-github-action@v0.1.0
        id: stems
        with:
          api-key: ${{ secrets.STEMSPLIT_API_KEY }}
          source-url: https://example.com/song.mp3
          output-type: FOUR_STEMS
          quality: BEST
          wait: "true"
          timeout-seconds: "600"

      - name: Use download URLs
        run: echo "${{ steps.stems.outputs.result-json }}"

Repository: StemSplit/stemsplit-github-action

3Inputs and outputs

InputDefaultNotes
operationcreate-jobUse balance to read credits
source-urlRequired for create-job
output-typeBOTHVOCALS, INSTRUMENTAL, BOTH, FOUR_STEMS, SIX_STEMS
waitfalsePoll until COMPLETED or FAILED

Outputs: job-id, status, result-json (includes presigned outputs when complete). See API reference.

Check balance

- uses: StemSplit/stemsplit-github-action@v0.1.0
  id: balance
  with:
    operation: balance
    api-key: ${{ secrets.STEMSPLIT_API_KEY }}

- run: echo "Credits ${{ steps.balance.outputs.balance-formatted }}"

Download URLs in result-json expire after one hour. Download artifacts in a follow-up step or trigger a downstream workflow with the URLs immediately.