Adding Factory api