Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Ismail Mayat 4511 posts 10090 karma points MVP 2x admin c-trib
    Sep 07, 2015 @ 09:58
    Ismail Mayat
    0

    Valid version mix

    Hi Anders,

    I am working on umbraco 6.1.6 site, i need to do the following:

    Get hash tag counts for a given tag for

    twitter instagram facebook

    I was going to nuget Skybrud.Social 0.9.4.1 and install skybrud social for umbraco package for umbraco v6 will this mix work?

    Or do i need to use older version of skybrud.social if so then does that older version support getting hashtag counts?

    Regards

    Ismail

  • Anders Bjerner 487 posts 2989 karma points MVP 7x admin c-trib
    Sep 07, 2015 @ 10:08
    Anders Bjerner
    0

    It depends.

    If you're using the Umbraco package from 6.1.x, it think there are some breaking changes that will keep you from using the latest version of Skybrud.Social.

    However Skybrud.Social itself doesn't have any dependencies, so if you use that directly, it shouldn't be a problem using 0.9.4.1.

    0.9.4 also supports using a client ID as an alternative to an access token for Instagram, so you don't need to set up an authentication page.

  • Ismail Mayat 4511 posts 10090 karma points MVP 2x admin c-trib
    Sep 07, 2015 @ 10:37
    Ismail Mayat
    0

    The clientid is only for Instagram? The others I will need authentication page?

  • Anders Bjerner 487 posts 2989 karma points MVP 7x admin c-trib
    Sep 07, 2015 @ 11:06
    Anders Bjerner
    100

    You can do something similar with the other services as well.

    With Facebook, if you're just accessing public information, you can use what is called an app access token, whereas what you get from the authentication page is a user access token. To find your app access token, you can go to this page:

    https://developers.facebook.com/tools/accesstoken/

    A benefit of using an app access token is that it wont expire after two months like user access tokens.

    You can then create a new instance of FacebookService like:

    FacebookService service = FacebookService.CreateFromAccessToken(appAccessToken);
    

    With Twitter (also if you just need public stuff), you can just specify the consumer key and consumer secret:

    TwitterOAuthClient client = new TwitterOAuthClient {
        ConsumerKey = "123",
        ConsumerSecret = "456"
    };
    
    TwitterService service = TwitterService.CreateFromOAuthClient(client);
    

    Google also allows you to specify a server key instead, which is now also supported in Skybrud.Social with the latest version.

    For us, this is the preferred approach since we don't need to obtain a user context (via authentication), but can just make calls on behalf of the app instead.

    Actually we haven't used the Umbraco package for any of our projects yet, since we're usually setting this up for our clients anyways.

  • Ismail Mayat 4511 posts 10090 karma points MVP 2x admin c-trib
    Sep 07, 2015 @ 11:36
    Ismail Mayat
    0

    Anders,

    Excellent, I will go down route of just using api directly with consumer key and secret as I am only interested in public info.

    Regards

    Ismail

Please Sign in or register to post replies

Write your reply to:

Draft