I think $this->getResponse()->setContentType('application/json'); is preferable to prevent loading the page decorations.