updated API signature to match discussion with @meryn