Adjusted character limit count logic?

10 views
Skip to first unread message

StarCreator

unread,
Aug 31, 2011, 10:53:20 AM8/31/11
to Chromed Bird
I don't know if this group is still monitored anymore, but...

A couple things bother me about the current character limit count
logic:

1) When sending users a direct message, the d <username> command is
counted against the character limit - this limitation doesn't exist on
Twitter's own client.
2) Twitter now shortens all URLs using their t.co shortener, even if
the URL is already shorter than what the t.co URL would be. Knowing
that the URL will be shortened on Twitter's end, is it possible to
adjust the character limit to take that into account? (Of course I
don't know the Twitter API so I don't know if it would take a >140
character post with a long URL and I don't know if there's an API call
to find out how long the t.co URL would be...) On a related note, is
it possible to auto-resolve the t.co URL similar to how the website/
official client does?

Thanks as always! This is still my favorite client :3

David Vo

unread,
Aug 31, 2011, 11:26:28 PM8/31/11
to chrom...@googlegroups.com
On Thu, Sep 1, 2011 at 00:53, StarCreator <starc...@gmail.com> wrote:
> I don't know if this group is still monitored anymore, but...
>
> A couple things bother me about the current character limit count
> logic:
>
> 1) When sending users a direct message, the d <username> command is
> counted against the character limit - this limitation doesn't exist on
> Twitter's own client.
Is this actually a command on Twitter's side? I thought that there was
a seperate
DM button in Chromed Bird and the API call was seperate.

> 2) Twitter now shortens all URLs using their t.co shortener, even if
> the URL is already shorter than what the t.co URL would be.  Knowing
> that the URL will be shortened on Twitter's end, is it possible to
> adjust the character limit to take that into account?  (Of course I
> don't know the Twitter API so I don't know if it would take a >140
> character post with a long URL and I don't know if there's an API call
> to find out how long the t.co URL would be...)  On a related note, is
> it possible to auto-resolve the t.co URL similar to how the website/
> official client does?

Firstly, Chromed Bird has not opted into t.co (AFAIK), therefore, links
shorter than the t.co link length will not be shortened... yet.

Of course, there is an API call to check the t.co link length (sort of).
You fetch a JSON file describing t.co links, then check the maximum
link length. You then assume all links either that length or longer will be
exactly that length. There's a t.co FAQ for developers somewhere,
but I can't access Twitter and company from work, so I can't get a link.

This information is only off the top of my head, feel free to prove me wrong.

StarCreator

unread,
Sep 2, 2011, 12:07:35 PM9/2/11
to Chromed Bird
On Aug 31, 11:26 pm, David Vo <david....@gmail.com> wrote:
> On Thu, Sep 1, 2011 at 00:53, StarCreator <starcrea...@gmail.com> wrote:
> > 1) When sending users a direct message, the d <username> command is
> > counted against the character limit - this limitation doesn't exist on
> > Twitter's own client.
>
> Is this actually a command on Twitter's side? I thought that there was
> a seperate
> DM button in Chromed Bird and the API call was seperate.

Hitting the reply button on one of my DMs does nothing except insert
the "d <username>" command into the Compose Tweet box.

> > 2) Twitter now shortens all URLs using their t.co shortener, even if
> > the URL is already shorter than what the t.co URL would be.  Knowing
> > that the URL will be shortened on Twitter's end, is it possible to
> > adjust the character limit to take that into account?  (Of course I
> > don't know the Twitter API so I don't know if it would take a >140
> > character post with a long URL and I don't know if there's an API call
> > to find out how long the t.co URL would be...)  On a related note, is
> > it possible to auto-resolve the t.co URL similar to how the website/
> > official client does?
>
> Firstly, Chromed Bird has not opted into t.co (AFAIK), therefore, links
> shorter than the t.co link length will not be shortened... yet.

As of several weeks ago, Twitter converts all links to t.co,
regardless of what client is used to post. Silver Bird, TwitPic,
direct API calls, everything. It's explained in their FAQ why they
did this and why there's no option to opt out.

> Of course, there is an API call to check the t.co link length (sort of).
> You fetch a JSON file describing t.co links, then check the maximum
> link length. You then assume all links either that length or longer will be
> exactly that length. There's a t.co FAQ for developers somewhere,
> but I can't access Twitter and company from work, so I can't get a link.
>
> This information is only off the top of my head, feel free to prove me wrong.

Could use more info on this, I haven't been able to locate any public
APIs for t.co itself...
Reply all
Reply to author
Forward
0 new messages