- 
                Notifications
    You must be signed in to change notification settings 
- Fork 245
User
        Ramtin Jokar edited this page Dec 16, 2018 
        ·
        5 revisions
      
    You can find all user functions in IInstaApi.UserProcessor class.
There are many functions exists for user. You can see some of it in here:
var currentUser = await InstaApi.UserProcessor.GetCurrentUserAsync();Note: I suggest you to use InstaApi.UserProcessor.GetUserInfoByIdAsync or InstaApi.UserProcessor.GetUserInfoByUsernameAsync to get current user information.
var currentUser = await InstaApi
    .UserProcessor.GetUserInfoByIdAsync(InstaApi.GetLoggedUser().LoggedInUser.Pk);var user = await InstaApi.UserProcessor.GetUserAsync("username");Note: don't use GetUserAsync, it doesn't have a lot of properties. Use InstaApi.UserProcessor.GetUserInfoByIdAsync or InstaApi.UserProcessor.GetUserInfoByUsernameAsync instead.
var userInfo = await InstaApi.UserProcessor
    .GetUserInfoByUsernameAsync("username");var userInfo = await InstaApi
    .UserProcessor.GetUserInfoByIdAsync(1647718432);var currentFollowsers = await InstaApi.UserProcessor
    .GetCurrentUserFollowersAsync(PaginationParameters.MaxPagesToLoad(1));var userFollowers = await InstaApi.UserProcessor
    .GetUserFollowersAsync("username", PaginationParameters.MaxPagesToLoad(1));var userFollowings = await InstaApi.UserProcessor
    .GetUserFollowingAsync("username", PaginationParameters.MaxPagesToLoad(1));var recentActivity = await InstaApi.UserProcessor
    .GetRecentActivityFeedAsync(PaginationParameters.MaxPagesToLoad(1));var friendshipStatus = await InstaApi.UserProcessor.GetFriendshipStatusAsync(1647718432);var userMedias = await InstaApi.UserProcessor
    .GetUserMediaAsync("username", PaginationParameters.MaxPagesToLoad(1));This will returns you: user info, feeds, stories, broadcasts
var fullUserInfo = await InstaApi.UserProcessor.GetFullUserInfoAsync(1647718432);var pendingFriendRequests = await InstaApi.UserProcessor.GetPendingFriendRequestsAsync();var acceptFriendship = await InstaApi.UserProcessor.AcceptFriendshipRequestAsync(1647718432);var ignoreFriendship = await InstaApi.UserProcessor.IgnoreFriendshipRequestAsync(1647718432);var followUser = await InstaApi.UserProcessor.FollowUserAsync(1647718432);var unfollowUser = await InstaApi.UserProcessor.UnFollowUserAsync(1647718432);var blockedUsers = await InstaApi.UserProcessor.GetBlockedUsersAsync(PaginationParameters.MaxPagesToLoad(1));var blockUser = await InstaApi.UserProcessor.BlockUserAsync(1647718432);var unblockUser = await InstaApi.UserProcessor.UnBlockUserAsync(1647718432);var userTags = await InstaApi.UserProcessor
    .GetUserTagsAsync("username", PaginationParameters.MaxPagesToLoad(1));var userTags = await InstaApi.UserProcessor
    .GetUserTagsAsync(1647718432, PaginationParameters.MaxPagesToLoad(1));Iranian Developers (c) 2021 | Bahar 1400