Can only be called from CLI