freshOS / ws-deprecated

⚠️ Deprecated - (in favour of Networking) :cloud: Elegantly connect to a JSON api. (Alamofire + Promises + JSON Parsing)
MIT License
353 stars 32 forks source link

is there a way to get the headers of a request's reply ? #50

Open glaurent opened 6 years ago

glaurent commented 6 years ago

I'm looking for something like

ws.get("/users").then { (headers, JSON) in

...
   let header = headers["X-WP-TotalPages"]
...
}

but apparently I can only get the JSON payload ?