Replace APIException with ParseError

ParserError is a better exception than APIError