httptools icon indicating copy to clipboard operation
httptools copied to clipboard

How to get request body with httptools?

Open agiUnderground opened this issue 8 years ago • 1 comments

How to get access to request body? Something like this: httptools.HttpRequestParser.get_body()

agiUnderground avatar Aug 27 '17 12:08 agiUnderground

You'll have to set a callback in the protocol you pass to the parser for when a chunk of the body is received and accumulate the body somewhere if you want this exact functionality. The function name to define in the protocol is on_body(data)

sethmlarson avatar Aug 28 '17 13:08 sethmlarson