Representational State Transfer (REST) web services has gained popular acceptance over the world-wide-web as a straightforward choice to the traditional or SOAP-based services. However, at present the REST-based service implementation does not have pre-defined security protection methods. In this paper, we present a defense mechanism against REST-based web service attacks called the REST-IDS, for a defense-in-depth network security in web service layer. REST-IDS is an intelligent mechanism that employs statistical approach to the stateof-the-art Text Mining-Based Anomaly Detection (TMAD) model to detect unknown novel vulnerabilities, which is sensitive to payload attacks.