My first ever forum post on here.
I need some help with working with the Skybrud.Social nuget package. It's known to be quite handy for Instagram related coding. In my application, basically all I am required to do, is fetch a definite number of the most popular insta_ posts [say 25] based on a definite search tag, say 'GlacialMelting'. And of course show them in my application.
Let me post some code::
- @using WTRD.UI.Models
- @using WTRD.UI.HelperClasses
- @using TweetSharp;
- @using TweetSharp.Model;
- @using Skybrud.Social;
- @using Skybrud.Social.Instagram
- @using Skybrud.Social.Instagram.Options.Tags
- @using Skybrud.Social.Instagram.Responses
- @inherits WebViewPage
- @{
- List
temp_1 = new List (); - InstagramService service = InstagramService.CreateFromClientId(System.Configuration.ConfigurationManager.AppSettings["instaID"].ToString());
- ----> InstagramGetTagRecentMediaOptions option1 = new InstagramGetTagRecentMediaOptions
- {
- Tag = "ClimateChange",
- Count = 15
- };
- InstagramGetRecentMediaResponse response1 = Model.Tags.GetRecentMedia(option1);
- temp_1.AddRange(response1.Body.Data);
- if (temp_1.Count == 0)
- {
- option1.MaxTagId = response1.Body.Pagination.NextMaxId;
- response1 = Model.Tags.GetRecentMedia(option1);
- temp_1.AddRange(response1.Body.Data);
- }
-
class="table list">
- @{
- int nr = 1;
- foreach (Skybrud.Social.Instagram.Objects.InstagramMedia media in temp_1)
- {
@(nr++). @media.Idclass="nw">@media.Created.ToLocalTime() "@media.Thumbnail" style="float: left;" />
"margin-left: 160px;">- @media.CaptionText
- }
- }
- InstagramGetTagRecentMediaOptions option1 = new InstagramGetTagRecentMediaOptions
- {
- Tag = "ClimateChange",
- Count = 15
- }
What assembly reference I have to add to get the InstagramGetTagRecentMediaOptions? I added more or less all the Skybrud.Social namespaces and hierarchial subnamespaces. But still not happening for me. Very unfortunately. Do any of you know how to work with this specific nuget pack? What am I missing? Kindly suggest something.
Many Thanks.
Many Thanks.
Replies
Know the answer? Post it — somebody with the same question will find it here.