Here's some code that I've used in the past:
https://gist.github.com/2789026
Then you would call:
message = self.read_protobuf(BufferTest, self.request.body)
The accepts() method just checks whether the given MIME type appears
in the client's Accept: header.