Search code examples
scalaakkasprayspray-json

error - Spray-http: not found: type HttpBody


I am using till now spray - 1.1-M7 but now I changed to 1.3.3. There is HttpBody in 1.1-M7 but that was not exist in 1.3.3 version. So what is the alternative I have to do in my code.

My code looks like this: What do I have to do to get:

implicit def json4sUnmarshaller[T: Manifest] = {
    Unmarshaller[T](`application/json`) {
      case x: HttpBody ⇒
        read[T](cleanupString(x.asString))
    }
  }

Solution

  • The type you are looking for is HttpEntity