[twitter-dev] Re: What is included In the "Queries are limited 140 URL encoded characters." restriction?

2009-10-18 Thread leonspencer

So the conclusion is:

1. DO NOT use the search operators that appear in the queries
generated by the Twitter Advanced Search tool. For example,

http://search.twitter.com/search?q=&ands=

Do not use "ands" in your queries.  The default interpretation of
spaces in yr queries is logical AND. And these do count against query
length.

2. The "query" is the q name/value pair. "?q=" (i.e. name q and
proceeding "=") are not counted toward the 140 limit. Everything else
up until the next parameter (delimited by "&") is counted toward the
140 character limited - including the search operators and their
delimiters. Parameters (e.g. rpp), as these are separate name value
pairs, are not part of the query thus not counted toward the max 140
character count.

NOTE: There are exceptions and some overlap that may cause confusion.
For example, Twitter defines "until:" as a search operator while
you'll also see a "&until=" (i.e. "until" parameter) in the queries
generated by the Advanced Search Tool. As a result, both "until:" and
"&until=" are counted toward the 140 max character limit.

The Twitter API is smart enough to see this overlap and recognize what
you are going. However, it isn't documented. So you save you the
trouble, if you are reading this, I'm noting this here.


Leon


On Oct 17, 9:52 pm, Scott Haneda  wrote:
> I brought that up the other day, "twitter eating their own dog food",  
> to which I was told they do, but only in some parts. It would be nice,  
> so that when the API is down, twitter is down, and we as developers  
> did not look like our apps suck, but that may not be a goal for  
> twitter, or it may be, I just do not know. I hope it is though.
> --
> Scott * If you contact me off list replace talklists@ with scott@ *


[twitter-dev] Re: What is included In the "Queries are limited 140 URL encoded characters." restriction?

2009-10-17 Thread Scott Haneda


I brought that up the other day, "twitter eating their own dog food",  
to which I was told they do, but only in some parts. It would be nice,  
so that when the API is down, twitter is down, and we as developers  
did not look like our apps suck, but that may not be a goal for  
twitter, or it may be, I just do not know. I hope it is though.

--
Scott * If you contact me off list replace talklists@ with scott@ *

On Oct 17, 2009, at 9:41 PM, Leon Spencer wrote:

Thanks Scott. Thats what another associate was suggesting last  
night. I figured the Twitter Advance Search Tool was wrapping around  
the Api and I could plug its queries into curl. I guess that is not  
the case.




[twitter-dev] Re: What is included In the "Queries are limited 140 URL encoded characters." restriction?

2009-10-17 Thread Scott Haneda


Yes, it seems a bit of a mess, but rely on the API, and the responses  
it gives you. The web based advanced search is a nice way to do a  
quick visual test, but as you have seen, can spit out some bizarre  
things.


I think the bash script will help you definitively answer anything you  
need to though, you can stuff pretty much anything into it, and at  
least run some solid tests against it.


Good luck
--
Scott * If you contact me off list replace talklists@ with scott@ *

On Oct 17, 2009, at 9:36 PM, Leon Spencer wrote:

Ahhh. I see what you are  doing. My confusion was based off the  
TWitter Advanced Search Tool. As you add more parameters and search  
operators, these seem to be counted toward the max 140 character  
length. But I was seeking definitive confirmation was someone.




[twitter-dev] Re: What is included In the "Queries are limited 140 URL encoded characters." restriction?

2009-10-17 Thread Leon Spencer
Thanks Scott. Thats what another associate was suggesting last night. I figured 
the Twitter Advance Search Tool was wrapping around the Api and I could plug 
its queries into curl. I guess that is not the case.

Thank you





From: Scott Haneda 
To: twitter-development-talk@googlegroups.com
Sent: Sat, October 17, 2009 9:33:24 PM
Subject: [twitter-dev] Re: What is included In the "Queries are limited 140 URL 
encoded  characters." restriction?


You are sending in empty query terms, if you stop doing that, it will stop 
reporting that error.  for example, if you find on = and replace with =x on 
your query, you get "Sorry, your query cannot be more than 140 characters long 
(it is 168 characters).".

I do not think you should be testing against the web search when the intention 
is to use the API, they are not in perfect parity, and the error messages do 
not seem to be perfectly accurate.

You get 140 url encoded characters to the search API, at least, that is what my 
previous test showed.  Anything outside of 140, would be unpredictable, and not 
to be relied on.
--Scott * If you contact me off list replace talklists@ with scott@ *

On Oct 17, 2009, at 9:24 PM, leonspencer wrote:

> Continuing to go it along with the Advanced Search Tool to see what
> defines the "query" and length of 140 chars. Latest try resulted in
> the following response from the tool:
> 
> "You must enter a query. "
> 
> This is the query I entered from using the advanced search tool:
> 
> http://search.twitter.com/search?q=&ands=12345678901234567890&phrase=12345678901234567890&ors=12345678901234567890¬s=12345678901234567890&tag=12345678901234567890〈=en&from=&to=&ref=&near=&within=15&units=mi&since=&until=&rpp=15
> 
> 
> I used order groups of 20 digits to examine the length -
> 12345678901234567890.

[twitter-dev] Re: What is included In the "Queries are limited 140 URL encoded characters." restriction?

2009-10-17 Thread Scott Haneda


I believe "Query string" is everything after the q=, not including the  
= of course.  So no matter how it is encoded or not, you just count up  
the chars, and that should be all you get.  It is somewhat limited,  
but I do not think entirely designed to do massively complex queries.


I used to try to negate certain twitter users in the #php area, by  
taking out things like "freelance" via query string.  I did not get  
very far before I breached the 140 limit.


Technically speaking, I am not sure why there needs to be a limitation  
based on length, it should be based on number of name/value pairs.   
Performance wise, the hit is going to come from multiple name value  
pairs, and not length.

--
Scott * If you contact me off list replace talklists@ with scott@ *

On Oct 17, 2009, at 9:31 PM, Leon Spencer wrote:

Thank you for your response. I'll run the lines to look at this  
further. The confusion is as whether "Query string" refers to HTTP  
query string (? until end) or the Twitter API "query" (?q=)  
value w/operators and parameters?


"

Usage Notes:
* Query strings should be URL encoded.
* Queries are limited 140 URL encoded characters."
When I check this against the Advanced Search Tool, it wasn't clear  
what was being included. And the tools seems to be somewhat buggy.


Leon





From: Scott Haneda 
To: twitter-development-talk@googlegroups.com
Sent: Sat, October 17, 2009 9:22:44 PM
Subject: [twitter-dev] Re: What is included In the "Queries are  
limited 140 URL encoded  characters." restriction?



I am not sure I understand the confusion, the API is 140 characters  
exactly in the query string.  You can run this, don't run it often,  
or put a sleep 1; in the loop if you do.


#!/bin/bash

# This script assumes you pre url encode your data.
# Request url
URL="http://search.twitter.com/search.json?q=";;

for (( i = 1; i < 200; i++ )); do
# Current position/length
echo "Query Length: "$i;

# Shove on another character
j=$j'A'

# The url we are about to poke
echo $URL$j

RESULT=$( curl -o /dev/null -s -w "%{http_code} % 
{size_request}" {$URL$j} )


# Show http_code
http_code=`echo $RESULT | awk '{print $1}'`
echo http_code: $http_code
# Show size_request
size_request=`echo $RESULT | awk '{print $2}'`
echo size_request: $size_request \(Sent bytes\)

echo ""
done

Here is a snip of the results, from the first, to the last bits  
around 140, right when you hit 141, it goes from http 200, to http  
403.  Though this script should make it rather easy to test what  
happens with url encoded characters.  I do not think it matters,  
each character is a character, so if it is a space, that will get  
url encoded into %20 taking up three characters.


Query Length: 1
http://search.twitter.com/search.json?q=A
http_code: 200
size_request: 163 (Sent bytes)

..


Query Length: 138
http://search.twitter.com/search.json?q=AA
http_code: 200
size_request: 300 (Sent bytes)

Query Length: 139
http://search.twitter.com/search.json?q=AAA
http_code: 200
size_request: 301 (Sent bytes)

Query Length: 140
http://search.twitter.com/search.json?q=
http_code: 200
size_request: 302 (Sent bytes)

Query Length: 141
http://search.twitter.com/search.json?q=A
http_code: 403
size_request: 303 (Sent bytes)

Query Length: 142
http://search.twitter.com/search.json?q=AA
http_code: 403
size_request: 304 (Sent bytes)
--Scott * If you contact me off list replace talklists@ with scott@ *

On Oct 17, 2009, at 7:39 PM, leonspencer wrote:



And still waiting on a response. More information from a associate:

Subject: Re: Do you know what is being counted toward "query length"

Yeah, because your using twitter search and not api!

An Api String would be

For Geo Locations
http://search.twitter.com/search.atom?geocode=40.757929%2C-73.985506%2C25km

Or
For Since...
http://search.twitter.com/search.atom?q=twitter&since_id=1520639490




On Oct 17, 2:29 pm, leonspencer  wrote:

Still waiting for a response here. I tried a query with the Twitter
Advanced Search 
tool:http://search.twitter.co

[twitter-dev] Re: What is included In the "Queries are limited 140 URL encoded characters." restriction?

2009-10-17 Thread Leon Spencer
Ahhh. I see what you are  doing. My confusion was based off the TWitter 
Advanced Search Tool. As you add more parameters and search operators, these 
seem to be counted toward the max 140 character length. But I was seeking 
definitive confirmation was someone.

I'll modify the Bash script to add parameters to if is this affects the length. 
Because the Advance Search Tool doesn't seem to functioning in the same manner 
per my earlier example:

--start of earlier post

Advanced Search tool: 

http://search.twitter.com/search?q=&ands=Allofthesewords&phrase=Thise...=en&from=leonspencer&to=leonspencer&ref=leonspencer&near=&within=15&units=mi&since=2009-10-07&until=2009-10-18&rpp=15
 


When I strip away the parameter names and operators, this is the
values stringed together: 


AllofthesewordsThisexactphraseAnyofthesewordsNoneofthesewordsThishashtagenleonspencerleonspencerleonspencer15mi2009-10-072009-10-1815
 


Length is at 133 but still getting error from the advanced search: 


http://search.twitter.com/search?q=&ands=Allofthesewords&phrase=Thise...=en&from=leonspencer&to=leonspencer&ref=leonspencer&near=&within=15&units=mi&since=2009-10-07&until=2009-10-18&rpp=15
 


"Sorry, your query cannot be more than 140 characters long (it is 161 
characters). " 


So I don't know what it is counting. 

--end of earlier post





From: Scott Haneda 
To: twitter-development-talk@googlegroups.com
Sent: Sat, October 17, 2009 9:22:44 PM
Subject: [twitter-dev] Re: What is included In the "Queries are limited 140 URL 
encoded  characters." restriction?


I am not sure I understand the confusion, the API is 140 characters exactly in 
the query string.  You can run this, don't run it often, or put a sleep 1; in 
the loop if you do.

#!/bin/bash

# This script assumes you pre url encode your data.
# Request url
URL="http://search.twitter.com/search.json?q=";;

for (( i = 1; i < 200; i++ )); do
 # Current position/length
 echo "Query Length: "$i;

 # Shove on another character
 j=$j'A'

 # The url we are about to poke
 echo $URL$j

 RESULT=$( curl -o /dev/null -s -w "%{http_code} %{size_request}" {$URL$j} )

 # Show http_code
 http_code=`echo $RESULT | awk '{print $1}'`
 echo http_code: $http_code
 # Show size_request
 size_request=`echo $RESULT | awk '{print $2}'`
 echo size_request: $size_request \(Sent bytes\)

 echo ""
done

Here is a snip of the results, from the first, to the last bits around 140, 
right when you hit 141, it goes from http 200, to http 403.  Though this script 
should make it rather easy to test what happens with url encoded characters.  I 
do not think it matters, each character is a character, so if it is a space, 
that will get url encoded into %20 taking up three characters.

Query Length: 1
http://search.twitter.com/search.json?q=A
http_code: 200
size_request: 163 (Sent bytes)

..


Query Length: 138
http://search.twitter.com/search.json?q=AA
http_code: 200
size_request: 300 (Sent bytes)

Query Length: 139
http://search.twitter.com/search.json?q=AAA
http_code: 200
size_request: 301 (Sent bytes)

Query Length: 140
http://search.twitter.com/search.json?q=
http_code: 200
size_request: 302 (Sent bytes)

Query Length: 141
http://search.twitter.com/search.json?q=A
http_code: 403
size_request: 303 (Sent bytes)

Query Length: 142
http://search.twitter.com/search.json?q=AA
http_code: 403
size_request: 304 (Sent bytes)
--Scott * If you contact me off list replace talklists@ with scott@ *

On Oct 17, 2009, at 7:39 PM, leonspencer wrote:

> 
> And still waiting on a response. More information from a associate:
> 
> Subject: Re: Do you know what is being counted toward "query length"
> 
> Yeah, because your using twitter search and not api!
> 
> An Api String would be
> 
> For Geo Locations
> http://search.twitter.com/search.atom?geocode=40.757929%2C-73.985506%2C25km
> 
> Or
> For Since...
> http://search.twitter.com/search.atom?q=twitter&since_id=1520639490
> 
> 
> 
>

[twitter-dev] Re: What is included In the "Queries are limited 140 URL encoded characters." restriction?

2009-10-17 Thread Scott Haneda


You are sending in empty query terms, if you stop doing that, it will  
stop reporting that error.  for example, if you find on = and replace  
with =x on your query, you get "Sorry, your query cannot be more than  
140 characters long (it is 168 characters).".


I do not think you should be testing against the web search when the  
intention is to use the API, they are not in perfect parity, and the  
error messages do not seem to be perfectly accurate.


You get 140 url encoded characters to the search API, at least, that  
is what my previous test showed.  Anything outside of 140, would be  
unpredictable, and not to be relied on.

--
Scott * If you contact me off list replace talklists@ with scott@ *

On Oct 17, 2009, at 9:24 PM, leonspencer wrote:


Continuing to go it along with the Advanced Search Tool to see what
defines the "query" and length of 140 chars. Latest try resulted in
the following response from the tool:

"You must enter a query. "

This is the query I entered from using the advanced search tool:

http://search.twitter.com/search?q=&ands=12345678901234567890&phrase=12345678901234567890&ors=12345678901234567890¬s=12345678901234567890&tag=12345678901234567890&lang=en&from=&to=&ref=&near=&within=15&units=mi&since=&until=&rpp=15


I used order groups of 20 digits to examine the length -
12345678901234567890.




[twitter-dev] Re: What is included In the "Queries are limited 140 URL encoded characters." restriction?

2009-10-17 Thread Leon Spencer
Thank you for your response. I'll run the lines to look at this further. The 
confusion is as whether "Query string" refers to HTTP query string (? until 
end) or the Twitter API "query" (?q=) value w/operators and parameters?

"

Usage Notes:
* Query strings should be URL encoded.
* Queries are limited 140 URL encoded characters."
When I check this against the Advanced Search Tool, it wasn't clear what was 
being included. And the tools seems to be somewhat buggy.

Leon





From: Scott Haneda 
To: twitter-development-talk@googlegroups.com
Sent: Sat, October 17, 2009 9:22:44 PM
Subject: [twitter-dev] Re: What is included In the "Queries are limited 140 URL 
encoded  characters." restriction?


I am not sure I understand the confusion, the API is 140 characters exactly in 
the query string.  You can run this, don't run it often, or put a sleep 1; in 
the loop if you do.

#!/bin/bash

# This script assumes you pre url encode your data.
# Request url
URL="http://search.twitter.com/search.json?q=";;

for (( i = 1; i < 200; i++ )); do
 # Current position/length
 echo "Query Length: "$i;

 # Shove on another character
 j=$j'A'

 # The url we are about to poke
 echo $URL$j

 RESULT=$( curl -o /dev/null -s -w "%{http_code} %{size_request}" {$URL$j} )

 # Show http_code
 http_code=`echo $RESULT | awk '{print $1}'`
 echo http_code: $http_code
 # Show size_request
 size_request=`echo $RESULT | awk '{print $2}'`
 echo size_request: $size_request \(Sent bytes\)

 echo ""
done

Here is a snip of the results, from the first, to the last bits around 140, 
right when you hit 141, it goes from http 200, to http 403.  Though this script 
should make it rather easy to test what happens with url encoded characters.  I 
do not think it matters, each character is a character, so if it is a space, 
that will get url encoded into %20 taking up three characters.

Query Length: 1
http://search.twitter.com/search.json?q=A
http_code: 200
size_request: 163 (Sent bytes)

..


Query Length: 138
http://search.twitter.com/search.json?q=AA
http_code: 200
size_request: 300 (Sent bytes)

Query Length: 139
http://search.twitter.com/search.json?q=AAA
http_code: 200
size_request: 301 (Sent bytes)

Query Length: 140
http://search.twitter.com/search.json?q=
http_code: 200
size_request: 302 (Sent bytes)

Query Length: 141
http://search.twitter.com/search.json?q=A
http_code: 403
size_request: 303 (Sent bytes)

Query Length: 142
http://search.twitter.com/search.json?q=AA
http_code: 403
size_request: 304 (Sent bytes)
--Scott * If you contact me off list replace talklists@ with scott@ *

On Oct 17, 2009, at 7:39 PM, leonspencer wrote:

> 
> And still waiting on a response. More information from a associate:
> 
> Subject: Re: Do you know what is being counted toward "query length"
> 
> Yeah, because your using twitter search and not api!
> 
> An Api String would be
> 
> For Geo Locations
> http://search.twitter.com/search.atom?geocode=40.757929%2C-73.985506%2C25km
> 
> Or
> For Since...
> http://search.twitter.com/search.atom?q=twitter&since_id=1520639490
> 
> 
> 
> 
> On Oct 17, 2:29 pm, leonspencer  wrote:
>> Still waiting for a response here. I tried a query with the Twitter
>> Advanced Search 
>> tool:http://search.twitter.com/search?q=&ands=Allofthesewords&phrase=Thise...=en&from=leonspencer&to=leonspencer&ref=leonspencer&near=&within=15&units=mi&since=2009-10-07&until=2009-10-18&rpp=15
>> 
>> When I strip away the parameter names and operators, this is the
>> values stringed together:
>> 
>> AllofthesewordsThisexactphraseAnyofthesewordsNoneofthesewordsThishashtagenleonspencerleonspencerleonspencer15mi2009-10-072009-10-1815
>> 
>> Length is at 133 but still getting error from the advanced search:
>> 
>> http://search.twitter.com/search?q=&ands=Allofthesewords&phrase=Thise...=en&from=leonspencer&to=leonspencer&ref=leonspencer&near=&within=15&units=mi&since=2009-10-07&until=2009-10-18&rpp=15
>> 
>> "Sorry, your query cannot be more than 140 characters long (it is 161
>> characters). "

[twitter-dev] Re: What is included In the "Queries are limited 140 URL encoded characters." restriction?

2009-10-17 Thread leonspencer

Continuing to go it along with the Advanced Search Tool to see what
defines the "query" and length of 140 chars. Latest try resulted in
the following response from the tool:

"You must enter a query. "

This is the query I entered from using the advanced search tool:

http://search.twitter.com/search?q=&ands=12345678901234567890&phrase=12345678901234567890&ors=12345678901234567890¬s=12345678901234567890&tag=12345678901234567890&lang=en&from=&to=&ref=&near=&within=15&units=mi&since=&until=&rpp=15


I used order groups of 20 digits to examine the length -
12345678901234567890.


[twitter-dev] Re: What is included In the "Queries are limited 140 URL encoded characters." restriction?

2009-10-17 Thread Scott Haneda


I am not sure I understand the confusion, the API is 140 characters  
exactly in the query string.  You can run this, don't run it often, or  
put a sleep 1; in the loop if you do.


#!/bin/bash

# This script assumes you pre url encode your data.
# Request url
URL="http://search.twitter.com/search.json?q=";;

for (( i = 1; i < 200; i++ )); do
 # Current position/length
 echo "Query Length: "$i;

 # Shove on another character
 j=$j'A'

 # The url we are about to poke
 echo $URL$j

 RESULT=$( curl -o /dev/null -s -w "%{http_code} % 
{size_request}" {$URL$j} )


 # Show http_code
 http_code=`echo $RESULT | awk '{print $1}'`
 echo http_code: $http_code
 # Show size_request
 size_request=`echo $RESULT | awk '{print $2}'`
 echo size_request: $size_request \(Sent bytes\)

 echo ""
done

Here is a snip of the results, from the first, to the last bits around  
140, right when you hit 141, it goes from http 200, to http 403.   
Though this script should make it rather easy to test what happens  
with url encoded characters.  I do not think it matters, each  
character is a character, so if it is a space, that will get url  
encoded into %20 taking up three characters.


Query Length: 1
http://search.twitter.com/search.json?q=A
http_code: 200
size_request: 163 (Sent bytes)

 ..


Query Length: 138
http://search.twitter.com/search.json?q=AA
http_code: 200
size_request: 300 (Sent bytes)

Query Length: 139
http://search.twitter.com/search.json?q=AAA
http_code: 200
size_request: 301 (Sent bytes)

Query Length: 140
http://search.twitter.com/search.json?q=
http_code: 200
size_request: 302 (Sent bytes)

Query Length: 141
http://search.twitter.com/search.json?q=A
http_code: 403
size_request: 303 (Sent bytes)

Query Length: 142
http://search.twitter.com/search.json?q=AA
http_code: 403
size_request: 304 (Sent bytes)
--
Scott * If you contact me off list replace talklists@ with scott@ *

On Oct 17, 2009, at 7:39 PM, leonspencer wrote:



And still waiting on a response. More information from a associate:

Subject: Re: Do you know what is being counted toward "query length"

Yeah, because your using twitter search and not api!

An Api String would be

For Geo Locations
http://search.twitter.com/search.atom?geocode=40.757929%2C-73.985506%2C25km

Or
For Since...
http://search.twitter.com/search.atom?q=twitter&since_id=1520639490




On Oct 17, 2:29 pm, leonspencer  wrote:

Still waiting for a response here. I tried a query with the Twitter
Advanced Search 
tool:http://search.twitter.com/search?q=&ands=Allofthesewords&phrase=Thise...=en&from=leonspencer&to=leonspencer&ref=leonspencer&near=&within=15&units=mi&since=2009-10-07&until=2009-10-18&rpp=15

When I strip away the parameter names and operators, this is the
values stringed together:

AllofthesewordsThisexactphraseAnyofthesewordsNoneofthesewordsThishashtagenleonspencerleonspencerleonspencer15mi2009 
-10-072009-10-1815


Length is at 133 but still getting error from the advanced search:

http://search.twitter.com/search?q=&ands=Allofthesewords&phrase=Thise...=en&from=leonspencer&to=leonspencer&ref=leonspencer&near=&within=15&units=mi&since=2009-10-07&until=2009-10-18&rpp=15

"Sorry, your query cannot be more than 140 characters long (it is 161
characters). "




[twitter-dev] Re: What is included In the "Queries are limited 140 URL encoded characters." restriction?

2009-10-17 Thread leonspencer

Do NOT respond or post to this thread unless you can answer the
question. And no, I am not "bumping" threads.

Get a life.

Leon

On Oct 17, 8:35 pm, JDG  wrote:
> You do realize that Twitter's employees take the weekends off, too, just
> like the rest of us? Please don't bump threads.
>
>
>
> On Sat, Oct 17, 2009 at 20:39, leonspencer  wrote:
>
> > And still waiting on a response. More information from a associate:
>
> > Subject: Re: Do you know what is being counted toward "query length"
>
> > Yeah, because your using twitter search and not api!
>
> > An Api String would be
>
> > For Geo Locations
>
> >http://search.twitter.com/search.atom?geocode=40.757929%2C-73.985506%...
>
> > Or
> > For Since...
> >http://search.twitter.com/search.atom?q=twitter&since_id=1520639490
>
> > On Oct 17, 2:29 pm, leonspencer  wrote:
> > > Still waiting for a response here. I tried a query with the Twitter
> > > Advanced Search tool:
> >http://search.twitter.com/search?q=&ands=Allofthesewords&phrase=Thise...
>
> > > When I strip away the parameter names and operators, this is the
> > > values stringed together:
>
> > AllofthesewordsThisexactphraseAnyofthesewordsNoneofthesewordsThishashtagenleonspencerleonspencerleonspencer15mi2009-10-072009-10-1815
>
> > > Length is at 133 but still getting error from the advanced search:
>
> >http://search.twitter.com/search?q=&ands=Allofthesewords&phrase=Thise...
>
> > > "Sorry, your query cannot be more than 140 characters long (it is 161
> > > characters). "
>
> > > So I don't know what it is counting.
>
> --
> Internets. Serious business.


[twitter-dev] Re: What is included In the "Queries are limited 140 URL encoded characters." restriction?

2009-10-17 Thread Leon Spencer
If you can't answer the question, save the smart response for your friends.

There were two Twitter employees on.

Don't be ignorant.





From: JDG 
To: twitter-development-talk@googlegroups.com
Sent: Sat, October 17, 2009 8:35:24 PM
Subject: [twitter-dev] Re: What is included In the "Queries are limited  140 
URL encoded characters." restriction?

You do realize that Twitter's employees take the weekends off, too, just like 
the rest of us? Please don't bump threads.


On Sat, Oct 17, 2009 at 20:39, leonspencer  wrote:


>>And still waiting on a response. More information from a associate:
>
>>Subject: Re: Do you know what is being counted toward "query length"
>
>>Yeah, because your using twitter search and not api!
>
>>An Api String would be
>
>>For Geo Locations
>> http://search.twitter.com/search.atom?geocode=40.757929%2C-73.985506%2C25km
>
>>Or
>>For Since...
>http://search.twitter.com/search.atom?q=twitter&since_id=1520639490
>
>
>
>
>
>>On Oct 17, 2:29 pm, leonspencer  wrote:
>>> Still waiting for a response here. I tried a query with the Twitter
>> Advanced Search 
>> tool:http://search.twitter.com/search?q=&ands=Allofthesewords&phrase=Thise...=en&from=leonspencer&to=leonspencer&ref=leonspencer&near=&within=15&units=mi&since=2009-10-07&until=2009-10-18&rpp=15
>
>>
>>> When I strip away the parameter names and operators, this is the
>>> values stringed together:
>>>
>>> AllofthesewordsThisexactphraseAnyofthesewordsNoneofthesewordsThishashtagenleonspencerleonspencerleonspencer15mi2009-10-072009-10-1815
>>>
>>> Length is at 133 but still getting error from the advanced search:
>>>
>> http://search.twitter.com/search?q=&ands=Allofthesewords&phrase=Thise...=en&from=leonspencer&to=leonspencer&ref=leonspencer&near=&within=15&units=mi&since=2009-10-07&until=2009-10-18&rpp=15
>
>>
>>> "Sorry, your query cannot be more than 140 characters long (it is 161
>>> characters). "
>>>
>>> So I don't know what it is counting.


-- 
Internets. Serious business.


[twitter-dev] Re: What is included In the "Queries are limited 140 URL encoded characters." restriction?

2009-10-17 Thread JDG
You do realize that Twitter's employees take the weekends off, too, just
like the rest of us? Please don't bump threads.

On Sat, Oct 17, 2009 at 20:39, leonspencer  wrote:

>
> And still waiting on a response. More information from a associate:
>
> Subject: Re: Do you know what is being counted toward "query length"
>
> Yeah, because your using twitter search and not api!
>
> An Api String would be
>
> For Geo Locations
>
> http://search.twitter.com/search.atom?geocode=40.757929%2C-73.985506%2C25km
>
> Or
> For Since...
> http://search.twitter.com/search.atom?q=twitter&since_id=1520639490
>
>
>
>
> On Oct 17, 2:29 pm, leonspencer  wrote:
> > Still waiting for a response here. I tried a query with the Twitter
> > Advanced Search tool:
> http://search.twitter.com/search?q=&ands=Allofthesewords&phrase=Thise...=en&from=leonspencer&to=leonspencer&ref=leonspencer&near=&within=15&units=mi&since=2009-10-07&until=2009-10-18&rpp=15
> >
> > When I strip away the parameter names and operators, this is the
> > values stringed together:
> >
> >
> AllofthesewordsThisexactphraseAnyofthesewordsNoneofthesewordsThishashtagenleonspencerleonspencerleonspencer15mi2009-10-072009-10-1815
> >
> > Length is at 133 but still getting error from the advanced search:
> >
> >
> http://search.twitter.com/search?q=&ands=Allofthesewords&phrase=Thise...=en&from=leonspencer&to=leonspencer&ref=leonspencer&near=&within=15&units=mi&since=2009-10-07&until=2009-10-18&rpp=15
> >
> > "Sorry, your query cannot be more than 140 characters long (it is 161
> > characters). "
> >
> > So I don't know what it is counting.
>



-- 
Internets. Serious business.


[twitter-dev] Re: What is included In the "Queries are limited 140 URL encoded characters." restriction?

2009-10-17 Thread leonspencer

And still waiting on a response. More information from a associate:

Subject: Re: Do you know what is being counted toward "query length"

Yeah, because your using twitter search and not api!

An Api String would be

For Geo Locations
 http://search.twitter.com/search.atom?geocode=40.757929%2C-73.985506%2C25km

Or
For Since...
http://search.twitter.com/search.atom?q=twitter&since_id=1520639490




On Oct 17, 2:29 pm, leonspencer  wrote:
> Still waiting for a response here. I tried a query with the Twitter
> Advanced Search 
> tool:http://search.twitter.com/search?q=&ands=Allofthesewords&phrase=Thise...=en&from=leonspencer&to=leonspencer&ref=leonspencer&near=&within=15&units=mi&since=2009-10-07&until=2009-10-18&rpp=15
>
> When I strip away the parameter names and operators, this is the
> values stringed together:
>
> AllofthesewordsThisexactphraseAnyofthesewordsNoneofthesewordsThishashtagenleonspencerleonspencerleonspencer15mi2009-10-072009-10-1815
>
> Length is at 133 but still getting error from the advanced search:
>
> http://search.twitter.com/search?q=&ands=Allofthesewords&phrase=Thise...=en&from=leonspencer&to=leonspencer&ref=leonspencer&near=&within=15&units=mi&since=2009-10-07&until=2009-10-18&rpp=15
>
> "Sorry, your query cannot be more than 140 characters long (it is 161
> characters). "
>
> So I don't know what it is counting.


[twitter-dev] Re: What is included In the "Queries are limited 140 URL encoded characters." restriction?

2009-10-17 Thread leonspencer

Still waiting for a response here. I tried a query with the Twitter
Advanced Search tool:
http://search.twitter.com/search?q=&ands=Allofthesewords&phrase=Thisexactphrase&ors=Anyofthesewords¬s=Noneofthesewords&tag=Thishashtag〈=en&from=leonspencer&to=leonspencer&ref=leonspencer&near=&within=15&units=mi&since=2009-10-07&until=2009-10-18&rpp=15


When I strip away the parameter names and operators, this is the
values stringed together:

AllofthesewordsThisexactphraseAnyofthesewordsNoneofthesewordsThishashtagenleonspencerleonspencerleonspencer15mi2009-10-072009-10-1815


Length is at 133 but still getting error from the advanced search:


http://search.twitter.com/search?q=&ands=Allofthesewords&phrase=Thisexactphrase&ors=Anyofthesewords¬s=Noneofthesewords&tag=Thishashtag〈=en&from=leonspencer&to=leonspencer&ref=leonspencer&near=&within=15&units=mi&since=2009-10-07&until=2009-10-18&rpp=15


"Sorry, your query cannot be more than 140 characters long (it is 161
characters). "


So I don't know what it is counting.




On Oct 15, 7:43 pm, leonspencer  wrote:
> What us being counted as part of the length of the query - entire
> query string? What names (of query string name/value pair), values
> (of query string name/value pair), and delimiters are counted in the
> Twitter API restriction "Queries are limited 140 URL encoded
> characters?" I've run the Twitter API Advanced Search Form to generate
> queries:
>
> http://search.twitter.com/advanced
>
> At some point it will say the query is too large - should be 140 but
> is 155
>
> Query 
> example:http://search.twitter.com/search?q=&ands=All+of+these+words&phrase=Th...
>
> What us being included in this length? The entire query string? (i.e. ?
> q to the end or just the length of the values?
>
> Thank you