0

I want to see what I'm actually POSTing when executing a Net::HTTP::Post from my Rails app, headers and all. How can I inspect the actual request the app is making?

bevanb
  • 8,201
  • 10
  • 53
  • 90
  • I believe you get the request object back when you call this: you can then call `inspect` on it and log the results. Is this what you meant? – Max Williams Nov 09 '15 at 11:08

1 Answers1

0

If you want to see that at your view then you can do:

 <%= request.env.inspect %>

If you want to do that using logger at controller:

def show
    logger.info request.env
  end
sadaf2605
  • 7,332
  • 8
  • 60
  • 103