asc-workflow
Original:🇺🇸 English
Translated
Define, validate, and run lane-style multi-step automation sequences using `asc workflow` and a repo-local `.asc/workflow.json`. Use when migrating from lane-based automation, building enterprise CI flows, or orchestrating multi-command `asc` runs.
5installs
Added on
NPX Install
npx skill4agent add rudrankriyam/app-store-connect-cli-skills asc-workflowTags
Translated version includes tags in frontmatterSKILL.md Content
View Translation Comparison →ASC Workflows (lane-style automation)
Use this skill when you need to create or run workflows via:
.asc/workflow.jsonasc workflow runasc workflow validateasc workflow list
Workflows are a lane-style "lanes" replacement: named, multi-step automation sequences that compose existing commands and normal shell commands.
ascCommand discovery
- Always use to confirm flags and subcommands:
--helpasc workflow --helpasc workflow run --helpasc workflow validate --helpasc workflow list --help
Key commands (typical flow)
- Validate the workflow file (CI gate):
asc workflow validate
- Dry-run a workflow (no side effects):
asc workflow run --dry-run beta
- Run the workflow with runtime parameters:
asc workflow run beta BUILD_ID:123456789 GROUP_ID:abcdef
- List available workflows (for discovery):
asc workflow list- Include private workflows:
asc workflow list --all
File location and format
- Default file path: (repo-local; commit it with your code).
.asc/workflow.json - The workflow file supports JSONC comments (and
//)./* */
Output contract (agent-friendly)
- stdout: JSON-only (structured result)
- stderr: step/hook command output and dry-run previews
This makes it safe to do:
bash
asc workflow run beta BUILD_ID:123 GROUP_ID:xyz | jq -e '.status == "ok"'Runtime params (KEY:VALUE / KEY=VALUE)
- supports both separators:
asc workflow run <name> [KEY:VALUE ...]VERSION:2.1.0VERSION=2.1.0
- In steps, reference params via (shell expansion).
$VAR - Avoid putting secrets in ; pass them via CI secrets/env.
.asc/workflow.json
Hooks
Workflows support definition-level hooks:
- : runs once before any steps
before_all - : runs once after all steps (only if steps succeeded)
after_all - : runs on any failure
error
When hook output matters, keep hooks simple and write their logs to stderr.
Conditionals (if
)
if- Add to a step to skip it when
"if": "VAR_NAME"is falsy.VAR_NAME - The conditional checks workflow env/params first, and then falls back to .
os.Getenv(VAR_NAME) - Truthy values: ,
1,true,yes,y(case-insensitive).on
Sub-workflows and private workflows
- A step can call another workflow via .
"workflow": "<name>" - env overrides are only valid on workflow steps (not run steps).
"with" - workflows:
"private": true- cannot be run directly from the CLI
- can be called by other workflows as sub-workflows
- are hidden from unless
asc workflow listis used--all
Recommended authoring approach (enterprise-friendly)
- Keep steps deterministic and explicit (prefer IDs where possible).
- Validate early () and keep the file in version control.
asc workflow validate - Start with before enabling real runs in CI.
--dry-run - Use existing commands for the actual work (build upload, TestFlight distribution, submission).
asc - Use on destructive operations inside steps; workflows should never add interactive prompts.
--confirm
Example .asc/workflow.json
template
.asc/workflow.jsonThis is a practical starting point for lane migration; adapt step commands to your org.
json
{
"env": {
"APP_ID": "123456789",
"VERSION": "1.0.0"
},
"before_all": "asc auth status",
"after_all": "echo workflow_done",
"error": "echo workflow_failed",
"workflows": {
"beta": {
"description": "Distribute a build to a TestFlight group",
"env": {
"GROUP_ID": ""
},
"steps": [
{
"name": "list_builds",
"run": "asc builds list --app $APP_ID --sort -uploadedDate --limit 5"
},
{
"name": "list_groups",
"run": "asc testflight beta-groups list --app $APP_ID --limit 20"
},
{
"name": "add_build_to_group",
"if": "BUILD_ID",
"run": "asc builds add-groups --build $BUILD_ID --group $GROUP_ID"
}
]
},
"release": {
"description": "Submit a version for App Store review",
"steps": [
{
"workflow": "sync-metadata",
"with": {
"METADATA_DIR": "./metadata"
}
},
{
"name": "submit",
"run": "asc submit create --app $APP_ID --version $VERSION --build $BUILD_ID --confirm"
}
]
},
"sync-metadata": {
"private": true,
"description": "Private helper workflow (callable only via workflow steps)",
"steps": [
{
"name": "migrate_validate",
"run": "echo METADATA_DIR_is_$METADATA_DIR"
}
]
}
}
}