Instagram Authentication
Instagram Platform API deprecation
As of April 4th, Instagram has suddenly decided to close down most of their Platform API. This unfortunately also means that many of the features in this package are no longer working. You can read more about the changes to the Instagram Platform API via the links below:

Platform Changelog

API and Other Platform Product Changes

Authentication

In order to make requests to the Instagram API you first need to register an application (Instagram calls it a client). The developer section at Instagram.com lets you register a new client or simply manage existing clients.

An application has a client ID that is used to identify your app when making request to the API. An application also has a client secret that together with the client ID is used during authentication.

For endpoint methods that doesn't require a user context, the client ID is sufficient. This includes getting the media of a user with a known ID.

Getting started

The InstagramService class is the entry point in Skybrud.Social for accessing the Instagram, so if you already have a access token, you can initialize a new instance like:

@using Skybrud.Social.Instagram

@{

    InstagramService service = InstagramService.CreateFromAccessToken("your access token");

}

The examples within this documentation are mostly based on an instance of this class.

If you don't have an access token - or need to get access tokens on behalf of your users - you can also set up an authentication page instead.