Swain CLI
-
Quick Start
Install once, generate everywhere.
- Install:
pipx install swain_cli(Python 3.8+ or via virtual environment). - Authenticate: Run
swain_cli auth loginto sign in with your Swain username and password (the interactive wizard uses this credential flow when no token exists). For automation, pass a token via--tokenor stdin. - Schema source: Without flags, the CLI discovers your dynamic swagger. You can target a specific project with
--swain-project-id/--swain-connection-idor supply a local file using-i ./openapi.yaml. - Interactive mode: Launch
swain_cli interactiveto choose projects, connections and languages, then preview (and optionally run) the assembled command. - Generators: Repeat
-v/--langfor every SDK you need and forward extra OpenAPI Generator options via-g,-cor--generator-arg.
Interactive Mode Walkthrough
Use the interactive wizard to assemble commands without memorising flags:
- Run
swain_cli interactive. - Select your project from the list.
- Choose a connection and stage.
- Specify the output directory (e.g.,
sdks/) and select one or more languages (e.g., python, typescript). - Review the assembled command and run it to generate the SDK.
- Install:
No comments to display
No comments to display