example with optional cli abstraction