Do cli header arg parsing in cli module, not api