Sending GET parameters via twurl


#1

Hello everyone,

I trying to send request via twurl that contain additional GET parameters and always getting error “no matches found” - dont even send request to twitter api.

Example:
twurl /1.1/statuses/user_timeline.json?count=20

Response:
no matches found: /1.1/statuses/user_timeline.xml?count=20

Example:
twurl /1.1/statuses/user_timeline.json

response is valid…


TIME_INVALID_WINDOW for correct start date?
#2

This call works fine for me.

BUT, when I try to send more than one parameter, the API cannot recognize the ones after the first.
Example:
twurl -t -H ads-api.twitter.com /0/stats/accounts/qfd7iv/campaigns/2hzvt?granularity=DAY&start_time=2015-05-22T00:00:00-0200&end_time=2015-05-22T23:59:59Z

It does not get the “start_time” parameter.
How should I call?


#3

Have you tried wrapping the URL path and parameters in quotes? e.g. "/0/stats/accounts/qfd7iv/campaigns/2hzvt?granularity=DAY&start_time=2015-05-22T00:00:00-0200&end_time=2015-05-22T23:59:59Z"

(NB I haven’t tried this specific call myself, but when I use twurl with parameters, I usually find myself wrapping the call to avoid issues with parameters like this)


#4

Thanks a lot @andypiper! That worked. (but I had to switch from double quotes to single quotes).

Now, TWURL is showing that I discovered a possible bug on the API:

Happy christmas!