added UI Media setApiResource method