Usage

Python API

Convenience function

from flync_converter import convert

convert(
    source="path/to/source",
    destination="path/to/output",
    destination_type="json",
    source_type="yaml",     # omit to auto-detect
)

Converter class

For more control, use the Converter class directly:

from flync_converter import Converter
from flync_converter.base import ConverterConfig

source_cfg = ConverterConfig(config_path="path/to/source")
dest_cfg   = ConverterConfig(config_path="path/to/output")

Converter().convert(
    source="path/to/source",
    destination="path/to/output",
    source_type="yaml",
    destination_type="json",
    source_config=source_cfg,
    destination_config=dest_cfg,
)

When source_type is omitted the registry auto-detects the format from the source path.

CLI

Two entry points are available after installation:

Command

Purpose

flync-converter

Scriptable subcommands

flync-converter-interactive

Launches the interactive TUI directly

See CLI Reference for the full command reference.

Interactive TUI

flync-converter-interactive, flync-converter tui, or flync-converter -i all open the same full terminal UI powered by Textual.

flync-converter -i

The TUI is a single split-panel screen: source on the left, destination on the right. Pick a format from each dropdown and the config fields for that converter appear immediately below. Fill them in and click Convert — the conversion runs in a background thread and streams output into a log panel at the bottom.

Configuration forms are built automatically from each converter’s Pydantic config model — no flags to remember, and validation errors appear inline. Plugin converters with extra fields (e.g. output_structure, encoding, indent) have those fields rendered as inputs automatically, with no changes required to the TUI.

Supported Formats

Name

Key

Reads

Writes

FLYNC

flync

yes

yes

JSON

json

yes

yes

YAML

yaml

yes

yes

DBC

dbc

no

yes

Additional formats can be added through plugins.