Printing Out Raw Request

2,966 views
Skip to first unread message

hwrdprkns

unread,
Dec 27, 2010, 9:57:02 PM12/27/10
to HTTParty Gem
Hello,

I have been using HTTParty for the past few days and I am very
satisfied with it. I just have one question about the gem. Is there
any way to print out the raw request that the gem is making? Like I
want to see if all of my headers, URL and Post Body is correct?

Does anyone know of a way to do this?

Thanks in advance.

hwrd

Sandro

unread,
Dec 27, 2010, 10:50:14 PM12/27/10
to HTTParty Gem

Taylor Perkins

unread,
Dec 27, 2010, 10:59:00 PM12/27/10
to httpar...@googlegroups.com
Do you have an example for this? I am kind of new to rails(but loving it -- and HTTParty). Sorry for the inexperience/noobness. 




--
You received this message because you are subscribed to the Google Groups "HTTParty Gem" group.
To post to this group, send email to httpar...@googlegroups.com.
To unsubscribe from this group, send email to httparty-gem...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/httparty-gem?hl=en.


Taylor Perkins

unread,
Dec 27, 2010, 11:03:21 PM12/27/10
to httpar...@googlegroups.com
Acutally, I just figured it out -.-

Sorry again. If you like I can add some examples to the docs. Let me know. I'll post them to the gist/issues on the github page. 

Thanks.

Taylor Perkins

unread,
May 3, 2011, 9:52:23 AM5/3/11
to httpar...@googlegroups.com
For future people who need help, all I did was add the line -- 

debug_output $stdout

under the line where I had the 'include HTTParty' 

Dave Koopman

unread,
Apr 3, 2014, 6:06:53 PM4/3/14
to httpar...@googlegroups.com

This worked for me:

response = HTTParty.post(url, :body => post, :basic_auth => auth, :headers => {"X-Custom" => "foo"}, :debug_output => $stdout)
Reply all
Reply to author
Forward
0 new messages