Workflow

Release video workflow

Use this sequence when an agent needs to create a release video from script files, changelog context, and a selected publishing connection.

End-to-end command

PDS_API_URL=https://video.promptdriven.ai \
PDS_TOKEN="$PDS_RELEASE_TOKEN" \
pds release-video create \
  --project-name release-v1.8.0 \
  --script release_video_script.md \
  --release-notes CHANGELOG.md \
  --changelog CHANGELOG.full.md \
  --repo-url https://github.com/promptdriven/studio \
  --repo-name promptdriven/studio \
  --git-sha "$GITHUB_SHA" \
  --release-tag v1.8.0 \
  --preset release-notes \
  --target publish \
  --platform youtube \
  --privacy unlisted \
  --idempotency-key "release:v1.8.0:$GITHUB_SHA" \
  --wait \
  --json

Required inputs and scopes

  • Required input files: release_video_script.md, CHANGELOG.md, and CHANGELOG.full.md or equivalent paths.
  • Required project context: either an existing project id or permission to create a release project.
  • Required scopes: project:create, project:read, project:write, pipeline:run, artifact:read, distribution:package, distribution:publish.

Dry-run path

pds release-video create \
  --project-name release-v1.8.0 \
  --script release_video_script.md \
  --release-notes CHANGELOG.md \
  --changelog CHANGELOG.full.md \
  --target publish \
  --platform youtube \
  --privacy unlisted \
  --dry-run \
  --json

Fixed-project recovery

  • Use this only for a pre-authorized selected project that is missing outputs/agent/release-video/metadata.json.
  • Preflight must include --bootstrap-selected-project, --script, and --release-tag or --git-sha.
  • Missing-sidecar --bootstrap-selected-project requires server policy: either the exact project id is configured in PDS_RELEASE_VIDEO_BOOTSTRAP_PROJECT_IDS or trusted videoProjects/{projectId}.releaseVideo.bootstrapAllowed: true metadata exists.
  • Create must repeat the same bootstrap inputs and include --force-regenerate.
  • Inspect releaseMetadataSidecar.source: bootstrapped means the selected project sidecar will be initialized; existing means the project was already initialized. Already initialized selected-project sidecars do not need this bootstrap gate.
pds release-video preflight \
  --project pdd-release-bootstrap \
  --bootstrap-selected-project \
  --script release_video_script.md \
  --git-sha "$GITHUB_SHA" \
  --release-tag v0.0.279 \
  --target publish \
  --platform youtube \
  --privacy unlisted \
  --json
pds release-video create \
  --project pdd-release-bootstrap \
  --bootstrap-selected-project \
  --script release_video_script.md \
  --git-sha "$GITHUB_SHA" \
  --release-tag v0.0.279 \
  --target publish \
  --platform youtube \
  --privacy unlisted \
  --force-regenerate \
  --idempotency-key "release:v0.0.279:$GITHUB_SHA:fixed-project" \
  --wait \
  --json

Distribution connection prerequisite

  • List available connections with pds distribution connections list --json.
  • Select the publishing connection with pds distribution connection select --json when needed.
  • Do not manage OAuth credentials through the CLI.

Long-running status and retry

pds release-video status --run-id <id> --json
  • After a failed release-video run, preserve runId, failed stage, and error.code.
  • Use pds release-video status --run-id <id> --json to inspect durable status.
  • Use pds pipeline status --project <id> --json to inspect the 15-stage agent view.
  • Treat release-video idempotency keys as exact-payload retry keys; if idempotency_key_reused reports changed fields, inspect the owner run before using a distinct new-attempt key.
  • Retry a single failed stage with pipeline run --stage <stage> only when the service permits scoped release-video retries.

Verification checklist

  • CLI exit code is 0.
  • JSON or JSONL payload parses.
  • Returned ok, data, or a command-specific result field is present.
  • Long-running commands returned or resolved a runId.
  • Status or artifacts were verified with a follow-up command.

Common public failure modes

  • Missing input files or an unreadable changelog.
  • Token lacks project creation, pipeline, artifact, or distribution scopes.
  • No selected server-side publishing connection.
  • Audit, quota, timeout, or publish policy failures. Preserve error.code for triage.