Coder Social home page Coder Social logo

Comments (6)

inovacode avatar inovacode commented on June 18, 2024

Oh . . . found it. You have each social network separated into a separate repo. https://github.com/abjerner/Skybrud.Social.Instagram

Would you like me to make the changes and submit a pull request? Or would you rather make the changes?

from skybrud.social.

inovacode avatar inovacode commented on June 18, 2024

It looks like the latest Instagram code does support a scope collection GetAuthorizationUrl(string state, InstagramScopeCollection scope). Maybe the nuget package is not up to date with GitHub and that's why I'm not getting that in my dll?

from skybrud.social.

abjerner avatar abjerner commented on June 18, 2024

@inovacode It is a little complicated.

In the past, the package has been released as single package named Skybrud.Social containing both some core functionality as well as the implementation for each service. This has been the case all the way up to v0.9.4.1 (which is the latest stable release).

Since v0.9.4.1 was released, I've been working on improving the codebase. This will eventually be released as v1.0, but the code is now split into multiple packages. There will now be a Skybrud.Social.Core package, and then a package for each implementation. Eg. if you need to integrate with the Instagram API, you simply install the Skybrud.Social.Instagram package, for the Facebook Graph API you install the Skybrud.Social.Facebook package and so forth. My work towards v1.0 is still not complete, so it is currently in beta.

If you fine playing around with beta releases, you try installing Skybrud.Social.Instagram v1.0.0-beta1 package, which has the updated code. As far as I remember, I haven't encountered any issues, but still keep in mind that this is beta code.

If you're more into the using latest stable, you can have a look at the v0.9.x branch. The latest commit in that branch corresponds with the commit that the release for v0.9.4.1 is based on.

I the above makes sense, and it haven't mumbled too much ;)

from skybrud.social.

inovacode avatar inovacode commented on June 18, 2024

I follow exactly what you're saying. I've been exploring your new repos in Beta and like what I see. Getting an error when updating nuget packages and building the Core project.

NuGet Package restore failed for project Skybrud.Social: Unable to find version '1.0.0-alpha2' of package 'Skybrud.Social.Core'..

No worries though, I'm going to stick with the stable version for now but looking forward to the new and improved Skybrud.Social libraries. For now, I can always make a straight HTTP call and serialize the Json response manually for the endpoints that aren't supported. Not a big deal.

Thanks for all your work with this. If our startup is a big success, I'll send you a $$$ contribution. :-)

from skybrud.social.

abjerner avatar abjerner commented on June 18, 2024

@inovacode I will check whether I've messed something up with the beta releases.

Anyways, I hand't thought about this yesterday, but the GetAuthorizationUrl method really just returns the authorization URL - it doesn't make any calls to the Instagram API. So you could just generate the authorization URL manually like this:

string authorizationUrl = String.Format(
    "https://api.instagram.com/oauth/authorize/?client_id={0}&redirect_uri={1}&response_type=code&state={2}&scope={3}",
    HttpUtility.UrlEncode(client.ClientId),
    HttpUtility.UrlEncode(client.RedirectUri),
    HttpUtility.UrlEncode(state),
    HttpUtility.UrlEncode("public_content+follower_list")
);

Then when you need to authenticate the user, simply redirect him/her to authorizationUrl ;)

from skybrud.social.

inovacode avatar inovacode commented on June 18, 2024

Perfect. Thanks for your help!

from skybrud.social.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.