test infinite recursion error and return the last API response