Skip to main content

asc bulk

Apply subscription configurations from YAML files. This is the recommended way to manage multiple subscriptions, pricing, and offers.

Commands

init

Generate an example configuration file.

asc bulk init
asc bulk init --output my-subscriptions.yaml
asc bulk init --force # Overwrite existing file

Options:

  • --output, -o - Output file path (default: subscriptions.yaml)
  • --force, -f - Overwrite existing file

validate

Validate a configuration file without applying changes.

asc bulk validate subscriptions.yaml

Shows a summary of what would be configured.

apply

Apply subscription configuration from a YAML file.

asc bulk apply subscriptions.yaml
asc bulk apply subscriptions.yaml --dry-run

Options:

  • --dry-run - Preview changes without applying

schema

Export JSON schema for IDE autocomplete and validation.

asc bulk schema
asc bulk schema --output subscriptions.schema.json

Configuration File Format

# subscriptions.yaml
app_bundle_id: live.yooz.whisper

# Set to true to preview changes without applying
dry_run: false

subscriptions:
# Pro Monthly subscription
- product_id: live.yooz.whisper.pro.monthly
name: Pro Monthly
price_usd: 2.99
territories: all # Apply to all 175 territories
equalize: true # Use Apple's automatic price equalization
offers:
# 2-week free trial for new subscribers
- type: free-trial
duration: 2w
territories: all

# $1.99/month for first 3 months
- type: pay-as-you-go
duration: 3m
price_usd: 1.99
territories: all

# Pro Yearly subscription
- product_id: live.yooz.whisper.pro.yearly
name: Pro Yearly
price_usd: 29.99
territories: all
equalize: true
offers:
- type: free-trial
duration: 1w
territories: all

# Pro Family Monthly
- product_id: live.yooz.whisper.pro.family.monthly
name: Pro Family Monthly
price_usd: 6.99
territories: all
offers:
- type: free-trial
duration: 2w

# $3.99/month for first 3 months promo
- type: pay-as-you-go
duration: 3m
price_usd: 3.99

Schema Reference

Root Configuration

FieldTypeRequiredDescription
app_bundle_idstringYesApp bundle identifier
subscriptionsarrayYesList of subscription configurations
dry_runbooleanNoPreview mode (default: false)

Subscription Configuration

FieldTypeRequiredDescription
product_idstringYesApp Store product ID
namestringNoDisplay name
price_usdnumberYesBase price in USD
territoriesstring/arrayNo"all" or list of territory codes
equalizebooleanNoUse price equalization (default: true)
offersarrayNoList of introductory offers

Introductory Offer

FieldTypeRequiredDescription
typestringYesfree-trial, pay-as-you-go, or pay-up-front
durationstringYesDuration: 3d, 1w, 2w, 1m, 3m, 6m, 1y
price_usdnumberConditionalRequired for paid offers
territoriesstring/arrayNo"all" or list of territory codes

IDE Integration

Export the JSON schema for autocomplete in VS Code or other editors:

asc bulk schema --output .vscode/subscriptions.schema.json

Then reference it in your YAML file:

# yaml-language-server: $schema=.vscode/subscriptions.schema.json
app_bundle_id: live.yooz.whisper
# ...

Advanced Examples

Multiple Subscription Tiers

app_bundle_id: com.example.app

subscriptions:
# Basic tier
- product_id: com.example.app.basic.monthly
price_usd: 1.99
territories: all
offers:
- type: free-trial
duration: 1w

# Pro tier
- product_id: com.example.app.pro.monthly
price_usd: 4.99
territories: all
offers:
- type: free-trial
duration: 2w
- type: pay-as-you-go
duration: 3m
price_usd: 2.99

- product_id: com.example.app.pro.yearly
price_usd: 39.99
territories: all
offers:
- type: free-trial
duration: 1w

Regional Pricing

app_bundle_id: com.example.app

subscriptions:
- product_id: com.example.app.premium.monthly
price_usd: 9.99
territories:
- USA
- CAN
- GBR
- DEU
- FRA
equalize: true
offers:
- type: free-trial
duration: 2w

Then apply lower prices for other regions via CLI.

Development Workflow

# subscriptions.dev.yaml
app_bundle_id: com.example.app
dry_run: true # Always preview in development

subscriptions:
- product_id: com.example.app.premium.monthly
price_usd: 9.99
territories: all
# Development: preview only
asc bulk apply subscriptions.dev.yaml

# Production: copy and set dry_run: false
cp subscriptions.dev.yaml subscriptions.yaml
# Edit to set dry_run: false
asc bulk apply subscriptions.yaml

Error Handling

Continue on Error

app_bundle_id: com.example.app
continue_on_error: true # Don't stop on first error

subscriptions:
- product_id: com.example.app.sub1
price_usd: 2.99
- product_id: com.example.app.sub2
price_usd: 4.99

Partial Failure Recovery

# If apply fails partway through
asc bulk apply subscriptions.yaml --resume

Learn More