accept a config object