added rescue to API