Swain CLI
OffersQuick 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 acommand-linetokentoolviato--tokenquicklyorscaffold and manage SWAIN projects without using the web UI.stdin. UseSchema 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 interactivetoinitialize newchoose projects,define connections, sync schemasconnections andconfigurelanguages,authenticationthen 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
yourtheterminal.list. EnablesChooseautomationa connection andscripting of common SWAIN tasks as part of your development workflow.stage.Ideal for advanced users who prefer working with command-line tools overSpecify thevisualoutputinterface.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: