|
Using restclient for streaming multipart uploads
Hello RestClient list,
I am trying to use the RestClient library to do a multipart upload from a StringIO, not from a file. After scouring the code, it seems that this is not possible. It should be
Hello RestClient list,
I am trying to use the RestClient library to do a multipart upload from a StringIO, not from a file. After scouring the code, it seems that this is not possible. It should be
|
By
Anthony Rowlands <draftomatic@...>
·
#263
·
|
|
Re: How To See the Request URL?
Thanks guys!
That's perfect.
- Keith
Thanks guys!
That's perfect.
- Keith
|
By
Keith Bennett <keithrbennett@...>
·
#262
·
|
|
Re: How To See the Request URL?
yeah, RESTCLIENT_LOG is the env var. The great thing about that is you can use that infront of any other gems that happen to use restclient
$ RESTCLIENT_LOG=stdout heroku addons:list
yeah, RESTCLIENT_LOG is the env var. The great thing about that is you can use that infront of any other gems that happen to use restclient
$ RESTCLIENT_LOG=stdout heroku addons:list
|
By
will leinweber <will@...>
·
#261
·
|
|
Re: How To See the Request URL?
require "logger"
RestClient.log = Logger.new(STDOUT)
That should get you most of the way there. There's also an environment variable you can use (maybe RESTCLIENT_LOG?) which does the same
require "logger"
RestClient.log = Logger.new(STDOUT)
That should get you most of the way there. There's also an environment variable you can use (maybe RESTCLIENT_LOG?) which does the same
|
By
"François Beausoleil <francois@...>
·
#260
·
|
|
How To See the Request URL?
Hello, I'm just starting to use rest-client.
I'm not getting back what I expected when I call RestClient.get. It
would be helpful to see the URL that is being sent. Is there any way
for me to see
Hello, I'm just starting to use rest-client.
I'm not getting back what I expected when I call RestClient.get. It
would be helpful to see the URL that is being sent. Is there any way
for me to see
|
By
Keith Bennett <keithrbennett@...>
·
#259
·
|
|
Re: BDD with REST Client
I never used FakeWeb but I used webmock and found it better than directly using the API directly since it better describes the contract the tests are supposed to check,
I never used FakeWeb but I used webmock and found it better than directly using the API directly since it better describes the contract the tests are supposed to check,
|
By
Archiloque <code@...>
·
#258
·
|
|
BDD with REST Client
Hello all,
I'm building a Ruby client for our very new, very alpha alpha API (at developer.urtak.com) and would like to attack it with BDD.
Since I know I'll be using REST Client as my HTTP client, I
Hello all,
I'm building a Ruby client for our very new, very alpha alpha API (at developer.urtak.com) and would like to attack it with BDD.
Since I know I'll be using REST Client as my HTTP client, I
|
By
Kunal Shah <me@...>
·
#257
·
|
|
Re: Trying to figure out an elegant way to handle basicauth
In case anyone wants to know how this turned out, thanks to Archiloque's help, I got it working with:
def get_collection(path)
#RestClient.log = 'stdout'
response = RestClient::Request.new(:method
In case anyone wants to know how this turned out, thanks to Archiloque's help, I got it working with:
def get_collection(path)
#RestClient.log = 'stdout'
response = RestClient::Request.new(:method
|
By
Brian Gupta <brian.gupta@...>
·
#256
·
|
|
Re: Trying to figure out an elegant way to handle basicauth
sorry:
try RestClient::Request.new(......).execute
I'm on ruby's IRC if you have other questions
A.
sorry:
try RestClient::Request.new(......).execute
I'm on ruby's IRC if you have other questions
A.
|
By
Archiloque <code@...>
·
#255
·
|
|
Re: Trying to figure out an elegant way to handle basicauth
(In way of background, I am learning ruby for this project). I guess the issue is I don't understand what "Request.execute" is, or how to actually call it? I tried plugging it in as replacement for
(In way of background, I am learning ruby for this project). I guess the issue is I don't understand what "Request.execute" is, or how to actually call it? I tried plugging it in as replacement for
|
By
Brian Gupta <brian.gupta@...>
·
#254
·
|
|
Re: Trying to figure out an elegant way to handle basicauth
I don't think, do you have any question about the API ?
A.
I don't think, do you have any question about the API ?
A.
|
By
Archiloque <code@...>
·
#253
·
|
|
Re: Trying to figure out an elegant way to handle basicauth
Cool and thank you. Is there a more fleshed out example of this somewhere?
Thanks,
Brian
Cool and thank you. Is there a more fleshed out example of this somewhere?
Thanks,
Brian
|
By
Brian Gupta <brian.gupta@...>
·
#252
·
|
|
Re: Trying to figure out an elegant way to handle basicauth
Hi,
not directly with RestClient.get but
Request.execute(:method => :get, :url => url, :login => login, :password => password, :headers => { :accept => :json, :content_type => :json })
should do the
Hi,
not directly with RestClient.get but
Request.execute(:method => :get, :url => url, :login => login, :password => password, :headers => { :accept => :json, :content_type => :json })
should do the
|
By
Archiloque <code@...>
·
#251
·
|
|
Trying to figure out an elegant way to handle basicauth
In the main body of my code I parse args and set class variables for username and password, as well as set the basic url via an instance that I pass to rest_client. I got basicauth working by brute
In the main body of my code I parse args and set class variables for username and password, as well as set the basic url via an instance that I pass to rest_client. I got basicauth working by brute
|
By
Brian Gupta <brian.gupta@...>
·
#250
·
|
|
Re: rest-client and RPC
Hi,
I think so, you probably just need to add a small wrapper to automate the serialization/deserialization
A.
Hi,
I think so, you probably just need to add a small wrapper to automate the serialization/deserialization
A.
|
By
Archiloque <code@...>
·
#249
·
|
|
rest-client and RPC
Is it possible to make JSON-RPC calls using Rest-Client ?
Is it possible to make JSON-RPC calls using Rest-Client ?
|
By
anderson leite <andersonlfl@...>
·
#248
·
|
|
Re: Welcome to rest.client list.
OK, same problem, I've contacted their support. Thanks!
OK, same problem, I've contacted their support. Thanks!
|
By
Emiliano Heyns <Emiliano.Heyns@...>
·
#247
·
|
|
Re: Welcome to rest.client list.
Sorry I was unclear, just add multipart as a parameter in the request:
project = 'redmine-backlogs'
root = "http://api.crowdin.net/api/project/#{project}/"
r = RestClient.post("#{root}/update-file",
Sorry I was unclear, just add multipart as a parameter in the request:
project = 'redmine-backlogs'
root = "http://api.crowdin.net/api/project/#{project}/"
r = RestClient.post("#{root}/update-file",
|
By
Archiloque <code@...>
·
#246
·
|
|
Re: Welcome to rest.client list.
I'll go check. To be sure, the code below ought to do the trick?
project = 'redmine-backlogs'
root = "http://api.crowdin.net/api/project/#{project}/"
r = RestClient.post("#{root}/update-file",
:key
I'll go check. To be sure, the code below ought to do the trick?
project = 'redmine-backlogs'
root = "http://api.crowdin.net/api/project/#{project}/"
r = RestClient.post("#{root}/update-file",
:key
|
By
Emiliano Heyns <Emiliano.Heyns@...>
·
#245
·
|
|
Re: Welcome to rest.client list.
Hi,
no idea: when trying locally the log seems ok, could you try to check with their support to see if they see anything, or perhaps anybody else on the list has an idea ?
A.
Hi,
no idea: when trying locally the log seems ok, could you try to check with their support to see if they see anything, or perhaps anybody else on the list has an idea ?
A.
|
By
Archiloque <code@...>
·
#244
·
|