Added response type handling for `text`.