added options dict for the second param to specify advanced options