[twitter-dev] Re: A new permission level

2011-05-18 Thread Jon Colverson
Hello.

For my app, it's inconvenient that the DM permission is only available
lumped in with the write permission, because now I have to request
both even though my app has no facility for posting (it's a
notification-only app), and I expect users will (rightly) be
suspicious about that.

Also on the subject of granularity, it would be great if the app could
request DM access but make it optional, such that users can turn it
off on the authorization page. If the user declines it then the app
would be able to ask them to reauthorize if they later try to use the
DM feature of the app.

Thank you.

 - Jon

-- 
Twitter developer documentation and resources: https://dev.twitter.com/doc
API updates via Twitter: https://twitter.com/twitterapi
Issues/Enhancements Tracker: https://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
https://groups.google.com/forum/#!forum/twitter-development-talk


[twitter-dev] Re: Hello with OAuth connection

2011-03-27 Thread Jon
Can someone please help with the above code?

Thanks,

Jon

On Mar 25, 3:57 pm, Jon j...@whotweet.net wrote:
 Thanks... I should've posted the whole thing because now I'm getting
 another error! This is what I'm trying to do (I really appreciate your
 help!):

       ?php
      /* Load required lib files. */
      require_once('twitteroauth/twitteroauth.php'); /* This is the
 library for connecting with oAuth */
      require_once('config.php'); /* This is the file that contains
 the oAuth credentials - this will be different for each app */
     //$twitterUser = 'YOUR_FRIENDS_USERNAME';
     $twitterUser = $field_twitter_url;
      /* Create a TwitterOauth object with consumer/user tokens. */
      $connection = new TwitterOAuth(CONSUMER_KEY, CONSUMER_SECRET,
 OAUTH_TOKEN, OAUTH_TOKEN_SECRET);
      $statuses = $connection-get('statuses/user_timeline',
 array('screen_name' = $twitterUser'));

      //create a time display like '1 hour ago'
      function twitterTime($time) {
            $delta = time() - $time;
            if ($delta  60) {
               return 'less than a minute ago.';
            } else if ($delta  120) {
              return 'about a minute ago.';
            } else if ($delta  (45 * 60)) {
              return floor($delta / 60) . ' minutes ago.';
            } else if ($delta  (90 * 60)) {
              return 'about an hour ago.';
            } else if ($delta  (24 * 60 * 60)) {
              return 'about ' . floor($delta / 3600) . ' hours ago.';
            } else if ($delta  (48 * 60 * 60)) {
              return '1 day ago.';
            } else {
              return floor($delta / 86400) . ' days ago.';
            }
      }
      //this is an empty string container we're going to pass the
 result of our loop into
      $twitterString = ;

                       foreach ($xml-status as $entry)
                       {

  // there are more elements to choose from 
 see:http://apiwiki.twitter.com/REST+API+Documentation#Statuselement
                   $status               = $entry-text;
                   $profilePic   = $entry-user-profile_image_url;
                   $profileName  = $entry-user-screen_name;
                   $statusRealName       = $entry-user-name;
                   $profileURL   = $entry-user-url;
                   $statusDate   = $entry-created_at;
                   $statusSource         = $entry-source;
                   $statusDateFormatted = twitterTime(strtotime($statusDate));
                   $profileBio   = $entry-user-description;
                   $statusFollowCount    = $entry-user-followers_count;

                   echo div class=\post hentry\\n;
                   echo div class=\image-box\\n;
                   echo img class=\photo\\n;
                   echo a href=\http://www.twitter.com/$profileName\; 
 target=
 \_blank\img class=\userPicThumb\ src=\$profilePic\ alt=
 \$profileRealName\ //a\n;
                   echo /div\n;
                   echo div class=\text-box\\n;
                   echo div class=\meta\\n;
                   echo strong class=\post-link\\n;
                   echo a class=\entry-title\ 
 href=\http://www.twitter.com/
 $profileName\ target=\_blank\$profileName/a\n;
                   echo /strong\n;
                   echo span class=\vcard\span class=\fn\ 
 $statusRealName/
 span/span\n;
                   echo /div\n;
                   echo p class=\entry-content\$status/p\n;
                   echo div class=\time\\n;
                   echo span$statusDateFormatted from 
 $statusSource/span\n;
                   echo /div\n;
                   echo /div\n;
                   echo div class=\clear\/div\n;
                   echo /span\n;
                   echo /div\n;

                       }
                  ?

 On Mar 25, 3:52 pm, Abraham Williams 4bra...@gmail.com wrote:







  Oops. I had a type. The = needs a  directly after it like =

  Abraham
  -
  Abraham Williams | Hacker Advocate | abrah.am
  http://abrah.amJust launched from Answerly http://answerly.com:
  InboxQhttp://inboxq.comfor Chrome
  @abraham https://twitter.com/abraham | github.com/abraham | blog.abrah.am
  This email is: [ ] shareable [x] ask first [ ] private.

  On Fri, Mar 25, 2011 at 15:44, Jon j...@whotweet.net wrote:
   Thanks Abraham,

   I'm getting an error on the last line there though:

   Parse error: syntax error, unexpected '=', expecting ')' in ...

   On Mar 25, 3:33 pm, Abraham Williams 4bra...@gmail.com wrote:
You are not formatting the GET request correctly and TwitterOAuth
automatically parses the JSON response for you.

?php
     /* Load required lib files. */
     require_once('twitteroauth/twitteroauth.php'); /* This is the
library for connecting with oAuth */
     require_once('config.php'); /* This is the file that contains
the oAuth credentials - this will be different for each app */

    //$twitterUser = 'YOUR_FRIENDS_USERNAME

[twitter-dev] Re: Hello with OAuth connection

2011-03-27 Thread Jon
All I'm trying to do is pull the user timeline or latest tweets for a
given user that I follow. I think I have the code 99% correct, but I
am horrible with PHP and am getting an error: Parse error: syntax
error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting ')'

Can someone please let me know where my error may be?

Thanks,

Jon

On Mar 27, 9:12 am, Blaaze blaazet...@gmail.com wrote:
 what exactly you want to implement, am a freelancer and you can hire
 me at good rates.

-- 
Twitter developer documentation and resources: http://dev.twitter.com/doc
API updates via Twitter: http://twitter.com/twitterapi
Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
http://groups.google.com/group/twitter-development-talk


[twitter-dev] Re: Hello with OAuth connection

2011-03-27 Thread Jon
The exact code is posted above... you can see the error here:
http://realestateagentswhotweet.com/kristan-cole/

I think it's something structurally though with the PHP, as line 65
itself should be fine, it's just the standard time display code below:

 //create a time display like '1 hour ago'
 function twitterTime($time) {
   $delta = time() - $time;
   if ($delta  60) {
  return 'less than a minute ago.';
   } else if ($delta  120) {
 return 'about a minute ago.';
   } else if ($delta  (45 * 60)) {
 return floor($delta / 60) . ' minutes ago.';
   } else if ($delta  (90 * 60)) {
 return 'about an hour ago.';
   } else if ($delta  (24 * 60 * 60)) {
 return 'about ' . floor($delta / 3600) . ' hours ago.';
   } else if ($delta  (48 * 60 * 60)) {
 return '1 day ago.';
   } else {
 return floor($delta / 86400) . ' days ago.';
   }
 }


I don't think the error is from the above, it's something structurally
above or below this code. Am I missing some brackets or something
somewhere? I'm not good enough with PHP to be able to tell.

Thanks,

Jon
On Mar 27, 10:14 am, Blaaze Artifex blaazet...@gmail.com wrote:
 can you post the exact code and exact error that you are seeing on your
 browser







 On Sun, Mar 27, 2011 at 11:38 PM, Jon j...@whotweet.net wrote:
  All I'm trying to do is pull the user timeline or latest tweets for a
  given user that I follow. I think I have the code 99% correct, but I
  am horrible with PHP and am getting an error: Parse error: syntax
  error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting ')'

  Can someone please let me know where my error may be?

  Thanks,

  Jon

  On Mar 27, 9:12 am, Blaaze blaazet...@gmail.com wrote:
   what exactly you want to implement, am a freelancer and you can hire
   me at good rates.

  --
  Twitter developer documentation and resources:http://dev.twitter.com/doc
  API updates via Twitter:http://twitter.com/twitterapi
  Issues/Enhancements Tracker:
 http://code.google.com/p/twitter-api/issues/list
  Change your membership to this group:
 http://groups.google.com/group/twitter-development-talk

-- 
Twitter developer documentation and resources: http://dev.twitter.com/doc
API updates via Twitter: http://twitter.com/twitterapi
Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
http://groups.google.com/group/twitter-development-talk


[twitter-dev] Re: Hello with OAuth connection

2011-03-27 Thread Jon
 div class=\time\\n;
  echo span$statusDateFormatted from $statusSource/span\n;
  echo /div\n;
  echo /div\n;
  echo div class=\clear\/div\n;
  echo /span\n;
  echo /div\n;


  }
 ?


It says the error is on line 78, which is:

foreach ($xml-status as $entry)

The error is:

Warning: Invalid argument supplied for foreach() in ... on line 78

Thanks,

Jon



On Mar 27, 1:44 pm, Blaaze blaazet...@gmail.com wrote:
 in this code above especially in your function twitterTime

 please remove single quotes and replace them with double quotes and
 also remove that first line of comment, then try it will work

-- 
Twitter developer documentation and resources: http://dev.twitter.com/doc
API updates via Twitter: http://twitter.com/twitterapi
Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
http://groups.google.com/group/twitter-development-talk


[twitter-dev] Re: Hello with OAuth connection

2011-03-27 Thread Jon
Thanks Abraham, I changed it to $satuses, but will get the same error
on that line: Warning: Invalid argument supplied for foreach() in ...
on line 78

On Mar 27, 5:36 pm, Abraham Williams 4bra...@gmail.com wrote:
 The variable name $xml was changed to $statuses further up and you didn't
 change the later $xml to $statuses.

 Abraham
 -
 Abraham Williams | Hacker Advocate | abrah.am
  http://abrah.amJust launched from Answerly http://answerly.com:
 InboxQhttp://inboxq.comfor Chrome
 @abraham https://twitter.com/abraham | github.com/abraham | blog.abrah.am
 This email is: [ ] shareable [x] ask first [ ] private.







 On Sun, Mar 27, 2011 at 15:15, Jon j...@whotweet.net wrote:
  Thanks Blaze... I think we're getting closer, now the error is on like
  78 (You can see it here:http://realestateagentswhotweet.com/kristan-cole/
  )

  Here is the code:

  ?php get_header(); ?
         div id=content class=hfeed
                 ?php
                 if(function_exists('bcn_display'))
                 {
                         echo 'ul class=breadcrumbsli';
                         bcn_display();
                         echo '/li/ul';
                 }
                 ?
                 ?php dynamic_sidebar('page_top'); ?
                 ?php if (have_posts()) : ?
                 !-- heading --
                 div class=heading-box
                         div class=heading
                                 h1AGENT PROFILE/h1
                         /div
                 /div
                 ?php while (have_posts()) : the_post();
                 //init custom fields
                 $pid = get_the_ID();
                 $field_about    = get_post_meta($pid, field_about, true);
                 ?
                         div class=text-section
                                 pThe profile of ?php the_category(', ');
  ? real estate agent ?
  php the_title(); ?./p
                         /div
                         div class=profile-box
                                 div class=text-holder vcard
                                         div class=name-holder
                                                 strong class=namespan
  class=fn?php the_title(); ? /
  span/strong em class=joba href=http://www.twitter.com/?php
  echo get_the_content(); ? target=_blank?php echo
  get_the_content(); ?/a/em
                                         /div
                                         ?php if($field_about): ?
                                         p class=entry-content?php echo
  $field_about; ?/p
                                         ?php endif; ?
                                         ?php the_tags('div
  class=tagsspanAreas Served:/
  spanulli', ',/lili', '/li/ul/div'); ?
                                 /div
                         /div
                 ?php endwhile; ?
                 !-- heading --
                 div class=heading-box
                         div class=heading
                                 h2AGENT TWEETS/h2
                         /div
                 /div
                 div class=text-section
                         pThe latest tweets from ?php the_title(); ?.
  /p
                 /div
       ?php

      require_once(twitteroauth/twitteroauth.php);
      require_once(config.php);
      $twitterUser = get_the_content();

      $connection = new TwitterOAuth(CONSUMER_KEY, CONSUMER_SECRET,
  OAUTH_TOKEN, OAUTH_TOKEN_SECRET);
      $statuses = $connection-get(statuses/user_timeline,
  array(screen_name = $twitterUser));

      function twitterTime($time) {
            $delta = time() - $time;
            if ($delta  60) {
               return less than a minute ago.;
            } else if ($delta  120) {
              return about a minute ago.;
            } else if ($delta  (45 * 60)) {
              return floor($delta / 60) .  minutes ago.;
            } else if ($delta  (90 * 60)) {
              return about an hour ago.;
            } else if ($delta  (24 * 60 * 60)) {
              return about  . floor($delta / 3600) .  hours ago.;
            } else if ($delta  (48 * 60 * 60)) {
              return 1 day ago.;
            } else {
               return floor($delta / 86400) .  days ago.;
             }
      }

      $twitterString = ;

                       foreach ($xml-status as $entry)
                       {

                    $status               = $entry-text;
                   $profilePic   = $entry-user-profile_image_url;
                   $profileName  = $entry-user-screen_name;
                   $statusRealName       = $entry-user-name;
                   $profileURL   = $entry-user-url;
                   $statusDate   = $entry-created_at;
                   $statusSource         = $entry-source;
                   $statusDateFormatted =
  twitterTime(strtotime($statusDate));
                   $profileBio   = $entry-user-description;
                   $statusFollowCount    = $entry-user-followers_count

[twitter-dev] Hello with OAuth connection

2011-03-25 Thread Jon
Hello,

I am having trouble with the below code... I am trying to pull a
user's timeline. Can someone please let me know where I've gone wrong?

?php
  /* Load required lib files. */
  require_once('twitteroauth/twitteroauth.php'); /* This is the
library for connecting with oAuth */
  require_once('config.php'); /* This is the file that contains
the oAuth credentials - this will be different for each app */

 //$twitterUser = 'YOUR_FRIENDS_USERNAME';
 $twitterUser = $field_twitter_url;


  /* Create a TwitterOauth object with consumer/user tokens. */
  $connection = new TwitterOAuth(CONSUMER_KEY, CONSUMER_SECRET,
OAUTH_TOKEN, OAUTH_TOKEN_SECRET);

  $xml = $connection-get('statuses/user_timeline.xml?screen_name=
$twitterUser');
  $xml = new SimpleXMLElement($xml);


Thanks,

Jon

-- 
Twitter developer documentation and resources: http://dev.twitter.com/doc
API updates via Twitter: http://twitter.com/twitterapi
Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
http://groups.google.com/group/twitter-development-talk


[twitter-dev] Re: Hello with OAuth connection

2011-03-25 Thread Jon
Thanks Abraham,

I'm getting an error on the last line there though:

Parse error: syntax error, unexpected '=', expecting ')' in ...

On Mar 25, 3:33 pm, Abraham Williams 4bra...@gmail.com wrote:
 You are not formatting the GET request correctly and TwitterOAuth
 automatically parses the JSON response for you.

 ?php
      /* Load required lib files. */
      require_once('twitteroauth/twitteroauth.php'); /* This is the
 library for connecting with oAuth */
      require_once('config.php'); /* This is the file that contains
 the oAuth credentials - this will be different for each app */

     //$twitterUser = 'YOUR_FRIENDS_USERNAME';
     $twitterUser = $field_twitter_url;

      /* Create a TwitterOauth object with consumer/user tokens. */
      $connection = new TwitterOAuth(CONSUMER_KEY, CONSUMER_SECRET,
 OAUTH_TOKEN, OAUTH_TOKEN_SECRET);

      $statuses = $connection-get('statuses/user_timeline',
 array('screen_name' = $twitterUser'));

 Abraham
 -
 Abraham Williams | Hacker Advocate | abrah.am
 http://abrah.amJust launched from Answerly http://answerly.com:
 InboxQhttp://inboxq.comfor Chrome
 @abraham https://twitter.com/abraham | github.com/abraham | blog.abrah.am
 This email is: [ ] shareable [x] ask first [ ] private.







 On Fri, Mar 25, 2011 at 14:50, Jon j...@whotweet.net wrote:
  Hello,

  I am having trouble with the below code... I am trying to pull a
  user's timeline. Can someone please let me know where I've gone wrong?

     ?php
       /* Load required lib files. */
       require_once('twitteroauth/twitteroauth.php'); /* This is the
  library for connecting with oAuth */
       require_once('config.php'); /* This is the file that contains
  the oAuth credentials - this will be different for each app */

      //$twitterUser = 'YOUR_FRIENDS_USERNAME';
      $twitterUser = $field_twitter_url;

       /* Create a TwitterOauth object with consumer/user tokens. */
       $connection = new TwitterOAuth(CONSUMER_KEY, CONSUMER_SECRET,
  OAUTH_TOKEN, OAUTH_TOKEN_SECRET);

       $xml = $connection-get('statuses/user_timeline.xml?screen_name=
  $twitterUser');
       $xml = new SimpleXMLElement($xml);

  Thanks,

  Jon

  --
  Twitter developer documentation and resources:http://dev.twitter.com/doc
  API updates via Twitter:http://twitter.com/twitterapi
  Issues/Enhancements Tracker:
 http://code.google.com/p/twitter-api/issues/list
  Change your membership to this group:
 http://groups.google.com/group/twitter-development-talk

-- 
Twitter developer documentation and resources: http://dev.twitter.com/doc
API updates via Twitter: http://twitter.com/twitterapi
Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
http://groups.google.com/group/twitter-development-talk


[twitter-dev] Re: Hello with OAuth connection

2011-03-25 Thread Jon
Thanks... I should've posted the whole thing because now I'm getting
another error! This is what I'm trying to do (I really appreciate your
help!):

  ?php
 /* Load required lib files. */
 require_once('twitteroauth/twitteroauth.php'); /* This is the
library for connecting with oAuth */
 require_once('config.php'); /* This is the file that contains
the oAuth credentials - this will be different for each app */
//$twitterUser = 'YOUR_FRIENDS_USERNAME';
$twitterUser = $field_twitter_url;
 /* Create a TwitterOauth object with consumer/user tokens. */
 $connection = new TwitterOAuth(CONSUMER_KEY, CONSUMER_SECRET,
OAUTH_TOKEN, OAUTH_TOKEN_SECRET);
 $statuses = $connection-get('statuses/user_timeline',
array('screen_name' = $twitterUser'));

 //create a time display like '1 hour ago'
 function twitterTime($time) {
   $delta = time() - $time;
   if ($delta  60) {
  return 'less than a minute ago.';
   } else if ($delta  120) {
 return 'about a minute ago.';
   } else if ($delta  (45 * 60)) {
 return floor($delta / 60) . ' minutes ago.';
   } else if ($delta  (90 * 60)) {
 return 'about an hour ago.';
   } else if ($delta  (24 * 60 * 60)) {
 return 'about ' . floor($delta / 3600) . ' hours ago.';
   } else if ($delta  (48 * 60 * 60)) {
 return '1 day ago.';
   } else {
 return floor($delta / 86400) . ' days ago.';
   }
 }
 //this is an empty string container we're going to pass the
result of our loop into
 $twitterString = ;

  foreach ($xml-status as $entry)
  {



 // there are more elements to choose from see:
http://apiwiki.twitter.com/REST+API+Documentation#Statuselement
  $status   = $entry-text;
  $profilePic   = $entry-user-profile_image_url;
  $profileName  = $entry-user-screen_name;
  $statusRealName   = $entry-user-name;
  $profileURL   = $entry-user-url;
  $statusDate   = $entry-created_at;
  $statusSource = $entry-source;
  $statusDateFormatted = twitterTime(strtotime($statusDate));
  $profileBio   = $entry-user-description;
  $statusFollowCount= $entry-user-followers_count;

  echo div class=\post hentry\\n;
  echo div class=\image-box\\n;
  echo img class=\photo\\n;
  echo a href=\http://www.twitter.com/$profileName\; target=
\_blank\img class=\userPicThumb\ src=\$profilePic\ alt=
\$profileRealName\ //a\n;
  echo /div\n;
  echo div class=\text-box\\n;
  echo div class=\meta\\n;
  echo strong class=\post-link\\n;
  echo a class=\entry-title\ href=\http://www.twitter.com/
$profileName\ target=\_blank\$profileName/a\n;
  echo /strong\n;
  echo span class=\vcard\span class=\fn\ 
$statusRealName/
span/span\n;
  echo /div\n;
  echo p class=\entry-content\$status/p\n;
  echo div class=\time\\n;
  echo span$statusDateFormatted from $statusSource/span\n;
  echo /div\n;
  echo /div\n;
  echo div class=\clear\/div\n;
  echo /span\n;
  echo /div\n;


  }
 ?

On Mar 25, 3:52 pm, Abraham Williams 4bra...@gmail.com wrote:
 Oops. I had a type. The = needs a  directly after it like =

 Abraham
 -
 Abraham Williams | Hacker Advocate | abrah.am
 http://abrah.amJust launched from Answerly http://answerly.com:
 InboxQhttp://inboxq.comfor Chrome
 @abraham https://twitter.com/abraham | github.com/abraham | blog.abrah.am
 This email is: [ ] shareable [x] ask first [ ] private.







 On Fri, Mar 25, 2011 at 15:44, Jon j...@whotweet.net wrote:
  Thanks Abraham,

  I'm getting an error on the last line there though:

  Parse error: syntax error, unexpected '=', expecting ')' in ...

  On Mar 25, 3:33 pm, Abraham Williams 4bra...@gmail.com wrote:
   You are not formatting the GET request correctly and TwitterOAuth
   automatically parses the JSON response for you.

   ?php
        /* Load required lib files. */
        require_once('twitteroauth/twitteroauth.php'); /* This is the
   library for connecting with oAuth */
        require_once('config.php'); /* This is the file that contains
   the oAuth credentials - this will be different for each app */

       //$twitterUser = 'YOUR_FRIENDS_USERNAME';
       $twitterUser = $field_twitter_url;

        /* Create a TwitterOauth object with consumer/user tokens. */
        $connection = new TwitterOAuth(CONSUMER_KEY, CONSUMER_SECRET,
   OAUTH_TOKEN, OAUTH_TOKEN_SECRET

[twitter-dev] Twitter stream shuts off every 60 seconds

2011-02-25 Thread jon
Hi,

If I try:
curl -d @tracking http://stream.twitter.com/1/statuses/filter.json -
uUsername:Password  tweets.json

This shuts off in exactly 60 seconds.  If I try the same command with
another account... it'll keep on going.

Is there any way I can check the status of my account and know when
I'll have full access to the stream again?  I'm trying to figure out
what's cutting off my stream.

Thanks!

-- 
Twitter developer documentation and resources: http://dev.twitter.com/doc
API updates via Twitter: http://twitter.com/twitterapi
Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
http://groups.google.com/group/twitter-development-talk


[twitter-dev] Question on Lists

2011-01-06 Thread Jon
Hello,

I have a script in which I am pulling my friends timeline from Twitter
and putting it on my web site. I do so with the following:

  $xml = $connection-get('statuses/friends_timeline');

My question is, how do I grab a friends timeline based on a list?

Help is greatly appreciated!

Thanks,

Jon

-- 
Twitter developer documentation and resources: http://dev.twitter.com/doc
API updates via Twitter: http://twitter.com/twitterapi
Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
http://groups.google.com/group/twitter-development-talk


[twitter-dev] Re: Snowflake: An update and some very important information

2010-10-19 Thread jon
Hi,

Will user ids be generated by snowflake in the near future?  Is it
safe to parse and store them as signed 64bit integers?

Thanks.

On Oct 18, 8:34 pm, themattharris thematthar...@twitter.com wrote:
 Thanks to @gotwalt for spotting the missing commas.

 Fixed JSON sample ...

 [
   {
     coordinates: null,
     truncated: false,
     created_at: Thu Oct 14 22:20:15 + 2010,
     favorited: false,
     entities: {
       urls: [
       ],
       hashtags: [
       ],
       user_mentions: [
         {
           name: Matt Harris,
           id: 777925,
           id_str: 777925,
           indices: [
             0,
             14
           ],
           screen_name: themattharris
         }
       ]
     },
     text: @themattharris hey how are things?,
     annotations: null,
     contributors: [
       {
         id: 819797,
         id_str: 819797,
         screen_name: episod
       }
     ],
     id: 12738165059,
     id_str: 12738165059,
     retweet_count: 0,
     geo: null,
     retweeted: false,
     in_reply_to_user_id: 777925,
     in_reply_to_user_id_str: 777925,
     in_reply_to_screen_name: themattharris,
     user: {
       id: 6253282,
       id_str: 6253282
     },
     source: web,
     place: null,
     in_reply_to_status_id: 12738040524,
     in_reply_to_status_id_str: 12738040524
   }
 ]

 Best,
 @themattharris

 On Oct 18, 5:19 pm, Matt Harris thematthar...@twitter.com wrote:



  Last week you may remember Twitter planned to enable the new Status ID
  generator - 'Snowflake' but didn't. The purpose of this email is to explain
  the reason why this didn't happen, what we are doing about it, and what the
  new release plan is.

  So what is Snowflake?
  --
  Snowflake is a service we will be using to generate unique Tweet IDs. These
  Tweet IDs are unique 64bit unsigned integers, which, instead of being
  sequential like the current IDs, are based on time. The full ID is composed
  of a timestamp, a worker number, and a sequence number.

  The problem
  -
  Before launch it came to our attention that some programming languages such
  as Javascript cannot support numbers with 53bits. This can be easily
  examined by running a command similar to: (90071992547409921).toString() in
  your browsers console or by running the following JSON snippet through your
  JSON parser.

      {id: 10765432100123456789, id_str: 10765432100123456789}

  In affected JSON parsers the ID will not be converted successfully and will
  lose accuracy. In some parsers there may even be an exception.

  The solution
  
  To allow javascript and JSON parsers to read the IDs we need to include a
  string version of any ID when responding in the JSON format. What this means
  is Status, User, Direct Message and Saved Search IDs in the Twitter API will
  now be returned as an integer and a string in JSON responses. This will
  apply to the main Twitter API, the Streaming API and the Search API.

  For example, a status object will now contain an id and an id_str. The
  following JSON representation of a status object shows the two versions of
  the ID fields for each data point.

  [
    {
      coordinates: null,
      truncated: false,
      created_at: Thu Oct 14 22:20:15 + 2010,
      favorited: false,
      entities: {
        urls: [
        ],
        hashtags: [
        ],
        user_mentions: [
          {
            name: Matt Harris,
            id: 777925,
            id_str: 777925,
            indices: [
              0,
              14
            ],
            screen_name: themattharris
          }
        ]
      },
      text: @themattharris hey how are things?,
      annotations: null,
      contributors: [
        {
          id: 819797,
          id_str: 819797,
          screen_name: episod
        }
      ],
      id: 12738165059,
      id_str: 12738165059,
      retweet_count: 0,
      geo: null,
      retweeted: false,
      in_reply_to_user_id: 777925,
      in_reply_to_user_id_str: 777925,
      in_reply_to_screen_name: themattharris,
      user: {
        id: 6253282
        id_str: 6253282
      },
      source: web,
      place: null,
      in_reply_to_status_id: 12738040524
      in_reply_to_status_id_str: 12738040524
    }
  ]

  What should you do - RIGHT NOW
  --
  The first thing you should do is attempt to decode the JSON snippet above
  using your production code parser. Observe the output to confirm the ID has
  not lost accuracy.

  What you do next depends on what happens:

  * If your code converts the ID successfully without losing accuracy you are
  OK but should consider converting to the _str versions of IDs as soon as
  possible.
  * If your code has lost accuracy, convert your code to using the _str
  version immediately. If you do not do this your code will be unable to
  interact with the Twitter API reliably.
  * In some language parsers, the 

[twitter-dev] Re: Snowflake: An update and some very important information

2010-10-19 Thread jon
Hi,

You wrote that the IDs are unsigned 64 bit ints, but the IdWorker is
pumping out java Longs which are signed.  I'm assuming that was a
typo, but please clarify.

http://github.com/twitter/snowflake/blob/master/src/main/scala/com/twitter/service/snowflake/IdWorker.scala

Thanks,

- Jon

On Oct 18, 8:19 pm, Matt Harris thematthar...@twitter.com wrote:
 Last week you may remember Twitter planned to enable the new Status ID
 generator - 'Snowflake' but didn't. The purpose of this email is to explain
 the reason why this didn't happen, what we are doing about it, and what the
 new release plan is.

 So what is Snowflake?
 --
 Snowflake is a service we will be using to generate unique Tweet IDs. These
 Tweet IDs are unique 64bit unsigned integers, which, instead of being
 sequential like the current IDs, are based on time. The full ID is composed
 of a timestamp, a worker number, and a sequence number.

 The problem
 -
 Before launch it came to our attention that some programming languages such
 as Javascript cannot support numbers with 53bits. This can be easily
 examined by running a command similar to: (90071992547409921).toString() in
 your browsers console or by running the following JSON snippet through your
 JSON parser.

     {id: 10765432100123456789, id_str: 10765432100123456789}

 In affected JSON parsers the ID will not be converted successfully and will
 lose accuracy. In some parsers there may even be an exception.

 The solution
 
 To allow javascript and JSON parsers to read the IDs we need to include a
 string version of any ID when responding in the JSON format. What this means
 is Status, User, Direct Message and Saved Search IDs in the Twitter API will
 now be returned as an integer and a string in JSON responses. This will
 apply to the main Twitter API, the Streaming API and the Search API.

 For example, a status object will now contain an id and an id_str. The
 following JSON representation of a status object shows the two versions of
 the ID fields for each data point.

 [
   {
     coordinates: null,
     truncated: false,
     created_at: Thu Oct 14 22:20:15 + 2010,
     favorited: false,
     entities: {
       urls: [
       ],
       hashtags: [
       ],
       user_mentions: [
         {
           name: Matt Harris,
           id: 777925,
           id_str: 777925,
           indices: [
             0,
             14
           ],
           screen_name: themattharris
         }
       ]
     },
     text: @themattharris hey how are things?,
     annotations: null,
     contributors: [
       {
         id: 819797,
         id_str: 819797,
         screen_name: episod
       }
     ],
     id: 12738165059,
     id_str: 12738165059,
     retweet_count: 0,
     geo: null,
     retweeted: false,
     in_reply_to_user_id: 777925,
     in_reply_to_user_id_str: 777925,
     in_reply_to_screen_name: themattharris,
     user: {
       id: 6253282
       id_str: 6253282
     },
     source: web,
     place: null,
     in_reply_to_status_id: 12738040524
     in_reply_to_status_id_str: 12738040524
   }
 ]

 What should you do - RIGHT NOW
 --
 The first thing you should do is attempt to decode the JSON snippet above
 using your production code parser. Observe the output to confirm the ID has
 not lost accuracy.

 What you do next depends on what happens:

 * If your code converts the ID successfully without losing accuracy you are
 OK but should consider converting to the _str versions of IDs as soon as
 possible.
 * If your code has lost accuracy, convert your code to using the _str
 version immediately. If you do not do this your code will be unable to
 interact with the Twitter API reliably.
 * In some language parsers, the JSON may throw an exception when reading the
 ID value. If this happens in your parser you will need to ‘pre-parse’ the
 data, removing or replacing ID parameters with their _str versions.

 Summary
 -
 1) If you develop in Javascript, know that you will have to update your code
 to read the string version instead of the integer version.

 2) If you use a JSON decoder, validate that the example JSON, above, decodes
 without throwing exceptions. If exceptions are thrown, you will need to
 pre-parse the data. Please let us know the name, version, and language of
 the parser which throws the exception so we can investigate.

 Timeline
 ---
 by 22nd October 2010 (Friday): String versions of ID numbers will start
 appearing in the API responses
 4th November 2010 (Thursday) : Snowflake will be turned on but at ~41bit
 length
 26th November 2010 (Friday) : Status IDs will break 53bits in length and
 cease being usable as Integers in Javascript based languages

 We understand this isn’t as seamless a transition as we had planned and
 appreciate for some of you this change requires an update to your code.
 We’ve tried to give as much time

[twitter-dev] Is the authorized user count for apps still available?

2010-10-05 Thread Jon Colverson
Hello.

I remember seeing somewhere a stat showing how many users had
authorized API access for my app, but I can't seem to find it anymore.
Is this number no longer available, or is it still there and I'm a
dunce for not being able to find it?

Thanks.

--
Jon

-- 
Twitter developer documentation and resources: http://dev.twitter.com/doc
API updates via Twitter: http://twitter.com/twitterapi
Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
http://groups.google.com/group/twitter-development-talk


[twitter-dev] Re: Is the authorized user count for apps still available?

2010-10-05 Thread Jon Colverson
Oh, thank you. I did try searching the list, but didn't come up with
the right query to find it. I guess I'll go look into app analytics!

Thanks again.

--
Jon

On Oct 5, 7:01 pm, Thomas Mango tsma...@gmail.com wrote:
 Hey, Jon. This was actually just answered 
 recently:http://groups.google.com/group/twitter-development-talk/browse_thread...

 Basically, no it isn't readily available anymore and it would be better
 to track it yourself.

 Jon Colverson wrote:
  Hello.

  I remember seeing somewhere a stat showing how many users had
  authorized API access for my app, but I can't seem to find it anymore.
  Is this number no longer available, or is it still there and I'm a
  dunce for not being able to find it?

  Thanks.

  --
  Jon

 --
 Thomas Mango
 tsma...@gmail.com

-- 
Twitter developer documentation and resources: http://dev.twitter.com/doc
API updates via Twitter: http://twitter.com/twitterapi
Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
http://groups.google.com/group/twitter-development-talk


[twitter-dev] Need help getting previously registered application set up for OAuth at dev.twitter.com

2010-08-30 Thread Jon Galloway
Alex set Witty up as an application for us a long time ago, but it's
not associated with our Twitter accounts so we can't set up OAuth.
Alan Le (@a7an) originally worked with Alex on this. I've taken over
development (@jongalloway).

We're obviously in a rush to get OAuth set up before basic auth is
shut off. How can we get help with this?

- Jon

-- 
Twitter developer documentation and resources: http://dev.twitter.com/doc
API updates via Twitter: http://twitter.com/twitterapi
Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
http://groups.google.com/group/twitter-development-talk?hl=en


[twitter-dev] UTF-8 Encoding

2010-06-09 Thread Jon OM
Hi

I am using Twitter Rest API method(statuses/update) and trying to set
the status with the string öäüõ.
But the status is updated as ö on Twitter.
I am using UTF-8 encoding before making the request.
Am i missing a point..
Can anyone please help me

TIA,
Jon Om


[twitter-dev] Problem with since_id in search API

2010-05-29 Thread Jon Lazar
Heyas.  I have a server based app that runs at regular intervals to
get the latest updates for certain search queries. When it runs with
the since_id in the url, it will begin failing on that search after a
few days with a 404 error.

Is there a problem with using the since_id for longer searches? Will I
need to regularly run the search thru the API without the since_id to
create the search page for the since_id API search?

Thanks.

-Jon


[twitter-dev] Re: Do the twttr.anywhere.tweetBox() boxes actually post tweets for anyone?

2010-04-18 Thread Jon
so, they work for you? Because, after the twitter guys posted about
the default read-only settings, I changed my app to rw, regenerated
the key and still can't get it to post a tweet. The examples still
don't post to my feed either.

On Apr 17, 3:28 pm, Abraham Williams 4bra...@gmail.com wrote:
 Make sure the app is set to read and write and that you have authorized a
 read and write token on your connections page.

 Abraham

 On Fri, Apr 16, 2010 at 15:52, Jon j...@jgubman.com wrote:
  So, I've got the tweetBoxes rendering just fine and doing the onTweet
  callbacks, but they don't actually post anything to my twitter profile
  (and, yes, I've authorized the app). Even the example boxes on
 http://dev.twitter.com/anywhere/begin#tweetboxthat post as the My
  Pet Monster app don't create tweets...

  --
  Subscription settings:
 http://groups.google.com/group/twitter-development-talk/subscribe?hl=en

 --
 Abraham Williams | Developer for hire |http://abrah.am
 PoseurTech Labs | Projects |http://labs.poseurtech.com
 This email is: [ ] shareable [x] ask first [ ] private.


[twitter-dev] Re: parent.twttr.anywhere._signedOutCookiePresent

2010-04-16 Thread Jon
I was getting that same error earlier. Clearing out my cookies seemed
to fix it, but doesn't instill confidence...

On Apr 16, 2:25 pm, Craig cbernst...@gmail.com wrote:
 Hello,

 @Anywhere (just a simple install following the Getting Started
 instructions) worked on my site yesterday. Today, it is dead:

 platform0.twitter.com/1/javascripts/client.js:1:

 Uncaught TypeError: Object function (Z,b){if(typeof Z==function)
 {b=Z;Z=twttr.anywhere._config.defaultVersion}if(!
 twttr.anywhere._config.clientID){return alert(To set up @anywhere,
 please provide a client ID)}if(D==callback||D==headless){return }
 var Y;var a=twttr.anywhere._instances;if(typeof Z===string||typeof
 Z===number){Z={version:Z}}Z.version=(Z.version)?
 Z.version.toString():twttr.anywhere._config.defaultVersion;Z=E({window:window},Z);if((Y=a[Z.version]))
 {if(Y.contentWindow._ready){Y.contentWindow._init(b,Z)}
 else{U(Y.contentWindow,b,Z)}}else{T(Z,b)}} has no method
 '_signedOutCookiePresent'

 Oops?
 Craig

 --
 Subscription 
 settings:http://groups.google.com/group/twitter-development-talk/subscribe?hl=en


[twitter-dev] Re: parent.twttr.anywhere._signedOutCookiePresent

2010-04-16 Thread Jon
I was getting the same error earlier. Clearing all my cookies seemed
to fix it, but doesn't instill confidence...

On Apr 16, 2:25 pm, Craig cbernst...@gmail.com wrote:
 Hello,

 @Anywhere (just a simple install following the Getting Started
 instructions) worked on my site yesterday. Today, it is dead:

 platform0.twitter.com/1/javascripts/client.js:1:

 Uncaught TypeError: Object function (Z,b){if(typeof Z==function)
 {b=Z;Z=twttr.anywhere._config.defaultVersion}if(!
 twttr.anywhere._config.clientID){return alert(To set up @anywhere,
 please provide a client ID)}if(D==callback||D==headless){return }
 var Y;var a=twttr.anywhere._instances;if(typeof Z===string||typeof
 Z===number){Z={version:Z}}Z.version=(Z.version)?
 Z.version.toString():twttr.anywhere._config.defaultVersion;Z=E({window:window},Z);if((Y=a[Z.version]))
 {if(Y.contentWindow._ready){Y.contentWindow._init(b,Z)}
 else{U(Y.contentWindow,b,Z)}}else{T(Z,b)}} has no method
 '_signedOutCookiePresent'

 Oops?
 Craig

 --
 Subscription 
 settings:http://groups.google.com/group/twitter-development-talk/subscribe?hl=en


[twitter-dev] Do the twttr.anywhere.tweetBox() boxes actually post tweets for anyone?

2010-04-16 Thread Jon
So, I've got the tweetBoxes rendering just fine and doing the onTweet
callbacks, but they don't actually post anything to my twitter profile
(and, yes, I've authorized the app). Even the example boxes on
http://dev.twitter.com/anywhere/begin#tweetbox that post as the My
Pet Monster app don't create tweets...


-- 
Subscription settings: 
http://groups.google.com/group/twitter-development-talk/subscribe?hl=en


[twitter-dev] Re: What's up with OAuth?

2010-02-13 Thread jon
FYI, if anyone wants to get an to do a poor man's version of xAuth,
I'd written a script a few months ago to exchange credentials:

http://gist.github.com/108144

http://groups.google.com/group/twitter-development-talk/browse_thread/thread/2985c36158742455/6a179766f32f4d50#6a179766f32f4d50

- Jon


On Feb 12, 8:52 pm, Norio Nomura norio.nom...@gmail.com wrote:
 Hi,

 I tested xAuth with below 
 codes,http://github.com/norio-nomura/ntlniph/tree/xAuth
 and succeeded.

 I want to know about xAuth's current status and roadmap.

 Thanks,

 --
 Norio Nomura

 On 2月12日, 午後12:18, Raffi Krikorian ra...@twitter.com wrote:



  hi all.

  this is a long overdue e-mail, but i wanted to tease out some of the
  directions that Twitter is going with OAuth.  i want to touch upon four
  topics: delegation, OAuth WRAP/2.0, username/password OAuth token exchange,
  and basic authentication deprecation.

  *DELEGATION - OAuth Echo*

  twitter users love posting media on third-party sites, and delegation in
  identity verification is one of the major hurdles for an OAuth-enabled
  twitter client to succeed.  i started a series of blog posts around the
  following problem:

  You're an OAuth enabled Twitter client, and you've already authorized your

   user.  Your user wants to use a media providing service like TwitPic.
    TwitPic, currently, asks for the username and password of your user so it
   can store the photo on behalf of the Twitter user.  You don't have that
   username and password, so how do you give the ability to TwitPic to verify
   the identity of your user?

  check out the proposal for what we're calling OAuth Echo 
  athttp://mehack.com/OAuth-echo-delegation-in-identity-verificatio.  please
  feel free to comment there, or on the twitter development talk mailing
  listhttp://groups.google.com/group/twitter-development-talk(or, even
  just reach out to me directly).  i think this experiment in
  engaging the community around designing this security/identity workflow has
  been definitely a success, and i feel we're rapidly converging on a solution
  for identity verification delegation.  in parallel, we're going to start the
  process to engage our media providers in the conversation as well, and we're
  hopeful we can move this forward quickly.

  *OAUTH WRAP/2.0*

  OAuth is evolving, and we at Twitter are keeping up with it.  that being
  said, we're keeping our eyes on OAuth WRAP and OAuth
  2.0http://wiki.oauth.net/OAuth-WRAP.
  we like a lot about it:

     - it requires the use of SSL;
     - there is no custom signing mechanism -- you simply pass us a token, and
     that token is secured by SSL; and
     - it formalizes a bunch of profiles that we've been actively thinking
     about (e.g. a username/password exchange)

  in general, we really like WRAP/2.0 because it's just *so* easy to implement
  from the client side.  there are no longer questions around creating the
  proper signature base string, etc.  we're sure that developers will like it
  as well.  we've started work on an internal implementation of OAuth WRAP and
  we envision that we'll simultaneously support both OAuth 1.0a and WRAP/2.0
  for a while.  our hope is to get WRAP out the door soon (and before we
  finally deprecate basic authentication).

  *USERNAME/PASSWORD TO OAUTH TOKEN EXCHANGE - xAuth*

  @rsarver and @noradio announced that we are going to support a mechanism
  where a username and a password can be directly exchanged for an OAuth token
  and secret -- we're calling this xAuth.  if you've been watching the mailing
  list, Seesmic Look http://seesmic.com/look has been a beta partner in
  testing xAuth exchange (and @abraham has already detailed how it
  workshttp://the.hackerconundrum.com/2010/02/sneak-peek-at-twitters-browser...).

  because we're moving everybody off basic authentication, we originally
  envisioned this as a mechanism for developers to exchange all the username
  and passwords they have in their databases for OAuth tokens en masse.
   that's still one of our use cases.  another use case is around environments
  where software can't bring up a web browser (e.g. set top boxes, game
  consoles, embedded devices).  we want to support those as well.

  you're going to have to apply to get access to this exchange mechanism (by
  sending e-mail to a...@twitter.com), but, in general, all applications 
  except
  web applications will get access.  we feel that the xAuth exchange allows
  for the best mix of security and user experience for desktop and possibly
  mobile applications.  web applications will simply have to use OAuth as it
  was designed, and send their users through the web flow.

  *BASIC AUTHENTICATION DEPRECATION*

  yup - it's still happening.  we're targeting June 2010.  everybody,
  including legacy applications, will have to move over.

  for those who are building new applications, use OAuth.  save yourself the
  transition time later, and start thinking about it now.  for those who

[twitter-dev] Re: What's up with OAuth?

2010-02-13 Thread jon
It worked for a one time oauth conversion for about 3000 accounts (i
ran a batch job across five processes and think it took an hour or so
to finish)-- however, that was back in may.  the script was also
written pre oauth 1.0a, so there's no oauth_verifier. I'm not sure if
that's required now.

On Feb 13, 11:41 am, Dewald Pretorius dpr...@gmail.com wrote:
 Mmmm it looks as if you're scraping the pre-login Allow/Deny page.
 That might just get your IP address blackholed.

 On Feb 13, 11:44 am, jon jonhoff...@gmail.com wrote:



  FYI, if anyone wants to get an to do a poor man's version of xAuth,
  I'd written a script a few months ago to exchange credentials:

 http://gist.github.com/108144

 http://groups.google.com/group/twitter-development-talk/browse_thread...

  - Jon

  On Feb 12, 8:52 pm, Norio Nomura norio.nom...@gmail.com wrote:

   Hi,

   I tested xAuth with below 
   codes,http://github.com/norio-nomura/ntlniph/tree/xAuth
   and succeeded.

   I want to know about xAuth's current status and roadmap.

   Thanks,

   --
   Norio Nomura

   On 2月12日, 午後12:18, Raffi Krikorian ra...@twitter.com wrote:

hi all.

this is a long overdue e-mail, but i wanted to tease out some of the
directions that Twitter is going with OAuth.  i want to touch upon four
topics: delegation, OAuth WRAP/2.0, username/password OAuth token 
exchange,
and basic authentication deprecation.

*DELEGATION - OAuth Echo*

twitter users love posting media on third-party sites, and delegation in
identity verification is one of the major hurdles for an OAuth-enabled
twitter client to succeed.  i started a series of blog posts around the
following problem:

You're an OAuth enabled Twitter client, and you've already authorized 
your

 user.  Your user wants to use a media providing service like TwitPic.
  TwitPic, currently, asks for the username and password of your user 
 so it
 can store the photo on behalf of the Twitter user.  You don't have 
 that
 username and password, so how do you give the ability to TwitPic to 
 verify
 the identity of your user?

check out the proposal for what we're calling OAuth Echo 
athttp://mehack.com/OAuth-echo-delegation-in-identity-verificatio.  
please
feel free to comment there, or on the twitter development talk mailing
listhttp://groups.google.com/group/twitter-development-talk(or, even
just reach out to me directly).  i think this experiment in
engaging the community around designing this security/identity workflow 
has
been definitely a success, and i feel we're rapidly converging on a 
solution
for identity verification delegation.  in parallel, we're going to 
start the
process to engage our media providers in the conversation as well, and 
we're
hopeful we can move this forward quickly.

*OAUTH WRAP/2.0*

OAuth is evolving, and we at Twitter are keeping up with it.  that being
said, we're keeping our eyes on OAuth WRAP and OAuth
2.0http://wiki.oauth.net/OAuth-WRAP.
we like a lot about it:

   - it requires the use of SSL;
   - there is no custom signing mechanism -- you simply pass us a 
token, and
   that token is secured by SSL; and
   - it formalizes a bunch of profiles that we've been actively 
thinking
   about (e.g. a username/password exchange)

in general, we really like WRAP/2.0 because it's just *so* easy to 
implement
from the client side.  there are no longer questions around creating the
proper signature base string, etc.  we're sure that developers will 
like it
as well.  we've started work on an internal implementation of OAuth 
WRAP and
we envision that we'll simultaneously support both OAuth 1.0a and 
WRAP/2.0
for a while.  our hope is to get WRAP out the door soon (and before we
finally deprecate basic authentication).

*USERNAME/PASSWORD TO OAUTH TOKEN EXCHANGE - xAuth*

@rsarver and @noradio announced that we are going to support a mechanism
where a username and a password can be directly exchanged for an OAuth 
token
and secret -- we're calling this xAuth.  if you've been watching the 
mailing
list, Seesmic Look http://seesmic.com/look has been a beta partner in
testing xAuth exchange (and @abraham has already detailed how it
workshttp://the.hackerconundrum.com/2010/02/sneak-peek-at-twitters-browser...).

because we're moving everybody off basic authentication, we originally
envisioned this as a mechanism for developers to exchange all the 
username
and passwords they have in their databases for OAuth tokens en masse.
 that's still one of our use cases.  another use case is around 
environments
where software can't bring up a web browser (e.g. set top boxes, game
consoles, embedded devices).  we want to support those as well.

you're going to have to apply to get

[twitter-dev] Feed page sometimes not actually returning a feed

2009-08-15 Thread Jon Leighton

Hiya,

I am displaying a twitter feed on a website. Unfortunately sometimes
when my website requests the feed, it doesn't get a feed, but the
following instead:

HTML
HEAD
META HTTP-EQUIV=Refresh CONTENT=0.1
META HTTP-EQUIV=Pragma CONTENT=no-cache
META HTTP-EQUIV=Expires CONTENT=-1
TITLE/TITLE
/HEAD
BODYP/BODY
/HTML

It happens somewhat erratically. Any ideas?

Cheers


[twitter-dev] Re: Mixing basic auth with OAuth

2009-06-18 Thread jon

Hi,

I had posted that script:
http://groups.google.com/group/twitter-development-talk/browse_thread/thread/2985c36158742455/6a179766f32f4d50

I think it ran at around 1000 conversions/hour, but you can easily
parallelize to get more throughput.

- Jon

On Jun 17, 4:20 pm, Abraham Williams 4bra...@gmail.com wrote:
 You have the code already finished for basic auth and maybe for oauth as
 well. it is pretty much just a simple if statment in your code to choose
 which one to run.
 Someone also posted a ruby script that I think screenscraped the oauth
 authorize page to automate a switch from basic auth to oauth. I don't know
 what Twitters view is on practice though.

 Abraham





 On Wed, Jun 17, 2009 at 14:49, Simon tro...@gmail.com wrote:

   You can stop taking peoples accounts, use sign in with twitter and for
  all
   the existing user who have not done it yet basic auth is still around.

  I have that basically set up, but the problem is getting the basic
  auth users switched... I can't run both. The user must either be on
  one, or the other. So adding OAuth must go hand in hand with deleting
  basic auth, which is just unnecessary steps for me to code and the
  user to do. Speaking from an ease of use point of view, I don't WANT
  to users to return to switch to OAuth. Simple.

  What will Twitter do when it will supposedly switch off basic auth?
  What about services like twitpic that still runs on basic auth? The
  crap thing is, is that a service like twitpic, users DO come back and
  switching to OAuth will be easier. Mine isn't. Users don't enter their
  details ever again. I'm sure they'll make it easier to switch to OAuth
  no doubt. I hope.

  I'll probably add the OAuth, and then have to direct users who want to
  switch to OAuth, through the laborious steps. :(

   Paul

   2009/6/17 Simon tro...@gmail.com

On Jun 16, 2:58 pm, Paul Kinlan paul.kin...@gmail.com wrote:
 Hi,
 Since you have all the passwords, could you not just log into the
  users
 account and authorise access to your oauth based application?

No, it's way too many users. I don't have that time. But see that's
exactly my point. I HAVE the password, instead of manually going
through the motions (which I can), why can't there be an API method
that can do it automatically?

 Looking at what you have done, other than letting the user tweet what
they
 are listenting too you don't need any authentication, would it not be
easier
 to get the user to follow you, in response you send a DM to them with
  a
url
 in that contains a unique url in that they can then enter their
  lastFM
 username in.  Because they are following you, you can still DM the
  stats
 that you send.

The goal is to automatically tweet what the people are listening to.
That method won't work.

  Hi. I made a mashup in the beginning of the year (before OAuth).
  You
  can check it out here:http://www.tweekly.fm.

  I really want to switch to OAuth (for the sake of security), but
  Twitter isn't exactly making it easy. I've read through some old
  threads, but couldn't precisely find what I wanted to say. Sorry,
  if
  its been said before.

  My mashup only requires the user to enter their details once. The
  only
  time they enter it again, is to delete it. It's an automation
  service.
  It sends data from last.fm to twitter.

  Switching to OAuth is a nightmare for both me (as a coder) and the
  user. I can't run both basic auth and OAuth for the same user (its
  the
  way my mashup works). So if a user wants to switch to OAuth, they
  have
  to delete the old basic auth details. Its unnecessary hurdles.

  Its been said before. All I want is an API method to use basic auth
  to
  get the OAuth access tokens. This way, I can easily write one
  script,
  to convert all my users to OAuth. No hassles for me, and no hassles
  for the users.

 --
 Abraham Williams | Community |http://web608.org
 Hacker |http://abrah.am|http://twitter.com/abraham
 Project |http://fireeagle.labs.poseurtech.com
 This email is: [ ] blogable [x] ask first [ ] private.


[twitter-dev] Sample code to automate the basic to oauth credentials exchange

2009-05-07 Thread jon

Hi,

We recently converted our site to use twitter oauth over basic
authentication and automated the exchange of credentials so that we
didn't have to keep multiple workflows around nor bother our users.

Here's a helpful script in ruby which makes use of the great twitter
and mechanize gems.
(this is obviously a little bit brittle, so I wouldn't rely on it for
anything other than batch conversion)

Also, the script makes multiple http calls to twitter and is subject
to timeouts, backhoes, and other ill effects, so expect it to be slow
and fail often.  We loaded up pending conversions into a persistent
transactional queue and ran multiple processes in parallel.

http://gist.github.com/108144

- Jon


Twitter Developer Nest - An event for our community

2009-02-20 Thread Jon

Hi Everyone

I'm please to announce a new community event for people doing the
things we do - developing Twitter apps.

It's called the Twitter Developer Nest and the first event will be in
London on the evening of 24th March. You can find out more and grab a
ticket here:

http://twitterdevelopernest.com/2009/02/london-launch-event/

Or follow @devnest for updates.

If you are not in the UK and are interested in running an event like
this in your part of the world please let me know and we'll see what
we can do to help.

Best wishes,

Jon / @madmotive

--
Jonathan Markwell
Engineer | Founder | Connector

Inuda Innovations Ltd, Brighton, UK

Web application development  support
Twitter  Facebook integration specialists
http://inuda.com http://twitter.com/inuda

Providing a nice place to work in the heart of Brighton - http://theskiff.org

Helping people make a difference with technology  - http://inuda.org

Measuring your brand's visibility on the social web - http://HowSociable.com

mob: 07766 021 485 | tel: 01273 704 549 | fax: 01273 376 953
skype: jlmarkwell | twitter: http://twitter.com/madmotive


Secure Login from Flash SWF

2009-01-14 Thread Jon

I am adding my twitter timeline to my website (online flash portfolio)
and have been successful in getting the data using SWX. I currently
have the username and password set in the SWF however, and need to
change this for obvious security reasons. I am new to PHP and am
trying to search the web and decide whether i need to store my
username and password in a database to query or if I can put them in a
php file on my server and get them that way. I just need to get it
done while not exposing my login info. Anyone have a link to share or
advice. Note: I'm working in AS3...


Re: Is SSL (TLS/https) officially supported?

2008-11-30 Thread Jon Colverson

Great! Thanks for your reply.

--
Jon

On Nov 29, 8:09 pm, John Adams [EMAIL PROTECTED] wrote:
 Officially supported, and recommended.


Is SSL (TLS/https) officially supported?

2008-11-28 Thread Jon Colverson

Hello.

I've just started playing around with the REST API and I noticed that
https requests work, but I couldn't find this documented in the API
docs. Is it officially supported, or something that works accidentally
and might go away without warning?

Thank you.

--
Jon