# summary

Sync Salesforce documentation for profiles to local cache.

# description

Downloads documentation from developer.salesforce.com and caches it locally in `.setup-agents/docs/<profile>/` so sub-agents can read it on demand during workflow execution.

# examples

- Sync all registered profiles:

  <%= config.bin %> <%= command.id %>

- Sync a specific profile:

  <%= config.bin %> <%= command.id %> --profile loyalty

- Force re-download even if cached:

  <%= config.bin %> <%= command.id %> --profile fsc --force

# flags.profile.summary

Profile to sync documentation for.

# flags.profile.description

When omitted, syncs documentation for all profiles that have registered doc sources. Use this to sync a single profile.

# flags.force.summary

Re-download even if documentation is already cached.

# flags.force.description

By default, previously synced documentation is skipped. Use --force to re-download and overwrite.

# flags.max-pages.summary

Maximum pages to download per doc source.

# flags.max-pages.description

Controls how many sub-pages are fetched from each documentation source. Higher values provide more detail but take longer. Default is 5.

# info.syncing

Syncing docs for profile: %s

# info.complete

Sync complete: %d synced, %d failed, %d files written

# info.no-sources

No doc sources registered for profile: %s

# info.list-header

Syncable profiles (%d):

# info.already-synced

%s — already synced (use --force to re-download)

# info.skipped

Skipped (already cached): %s
