very crude API implementation to serve as "usecase" fodder to tweek the api to better suit real uses; will be cleaned up