Skip to content

Uploading Releases

Uploading a new release involves two steps: uploading the file, then registering the metadata.

Why Two Steps?

To support files of any size (even GBs), we use a secure upload process: - The API provides you with a temporary, secure upload URL - You upload your file directly to our storage using that URL - Then you register the release metadata so users can find it

Step 1: Request a Signed Upload URL

Endpoint: POST /api/patcher/cdn-upload

Headers:

Authorization: Bearer nuve_YOUR_API_KEY
Content-Type: application/json

Body:

{
  "dev_name": "acme-corp",
  "app_name": "one.example.app",
  "version": "1.2.0"
}

Response:

{
  "success": true,
  "upload_url": "https://...",
  "key": "downloads/acme-corp/one.example.app/v1.2.0.zip",
  "message": "Upload URL generated. Please PUT your file to 'upload_url'."
}

cURL Example:

curl -X POST "https://apis.novasuite.one/api/patcher/cdn-upload" \
  -H "Authorization: Bearer nuve_YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{"dev_name": "acme-corp", "app_name": "one.example.app", "version": "1.2.0"}'

PowerShell Example:

$body = @{
  dev_name = "acme-corp"
  app_name = "one.example.app"
  version = "1.2.0"
} | ConvertTo-Json

$response = Invoke-RestMethod -Uri "https://apis.novasuite.one/api/patcher/cdn-upload" `
  -Method Post `
  -Headers @{ "Authorization" = "Bearer nuve_YOUR_KEY" } `
  -ContentType "application/json" `
  -Body $body

$uploadUrl = $response.upload_url

Step 2: Upload Your File

Use the upload_url from Step 1 to upload your file directly to storage.

cURL Example:

curl -X PUT "$UPLOAD_URL" \
  -H "Content-Type: application/zip" \
  --upload-file "myapp-v1.2.0.zip"

PowerShell Example:

Invoke-RestMethod -Uri $uploadUrl -Method Put -InFile "myapp-v1.2.0.zip" -ContentType "application/zip"

Important Notes: - The URL expires in 15 minutes - Must use PUT method (not POST) - Must set Content-Type: application/zip

Step 3: Register Release Metadata

Endpoint: POST /api/patcher/upload

Headers:

Authorization: Bearer nuve_YOUR_API_KEY
Content-Type: application/json

Body:

{
  "dev_name": "acme-corp",
  "app_name": "one.example.app",
  "version": "1.2.0",
  "build": "142",
  "platform": "Windows",
  "sha256": "a4b3c2d1e5f6...",
  "release_notes": "Fixed critical bugs and improved performance",
  "channel": "production",
  "auto_publish": true,
  "is_latest": true,
  "install_action": "unzip",
  "update_action": "replace",
  "display_mode": "active"
}

Response:

{
  "success": true,
  "message": "Release published and marked as Latest.",
  "data": {
    "download_url": "https://serve.novasuite.one/downloads/acme-corp/one.example.app/v1.2.0.zip",
    "channel": "production",
    "status": "live",
    "is_latest": true
  }
}

cURL Example:

curl -X POST "https://apis.novasuite.one/api/patcher/upload" \
  -H "Authorization: Bearer nuve_YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d @metadata.json

Field Reference

Required Fields

  • dev_name: Your developer identifier
  • app_name: Your app's unique ID
  • version: Semantic version (e.g., 1.2.0)
  • build: Build number or identifier
  • platform: Target platform (Windows, macOS, Linux, Universal)
  • sha256: SHA-256 hash of the uploaded file (for integrity verification)

Optional Fields

  • release_notes: Changelog or description
  • channel: Distribution channel (default: production)
  • auto_publish: Immediately make visible to users (default: false)
  • is_latest: Mark as the current recommended version (default: equals auto_publish)
  • install_action: How to process the file (default: unzip)
  • update_action: How to apply the update (default: replace)
  • display_mode: UI behavior during update (default: active)

Complete Example Script

See example_full_workflow.yml for a complete GitHub Actions workflow that automates this entire process.