Skip to main content

auth export

Export realm from source Keycloak, clean it, and save to disk.

Usage

postkit auth export

Options

OptionDescription
-v, --verboseEnable verbose output
--jsonOutput as JSON

What It Does

  1. Authenticates with source Keycloak (admin token via REST API)
  2. Exports realm config via partial-export API
  3. Saves raw export to .tmp-config/
  4. Cleans config (strips IDs, secrets, keys, credentials)
  5. Saves cleaned config to realm-config/

Requirements

  • Source Keycloak must be accessible
  • Environment variables must be configured (see Configuration)
  • import - Import to target
  • sync - Export + import in one command