Skip to main content

Class: Social

Social API is a part of the Dashboard SDK used to access social media related data. Use global enplug.social object to access these methods.

Methods#

addFacebookPage#

addFacebookPage(feedId, pageId, accessToken): Promise<any>

Parameters#

NameType
feedIdstring
pageIdstring
accessTokenstring

Returns#

Promise<any>


approveItem#

approveItem(itemId, assetId): Promise<any>

Parameters#

NameType
itemIdstring
assetIdstring

Returns#

Promise<any>


authInstagram#

authInstagram(accessToken): Promise<any>

Parameters#

NameType
accessTokenstring

Returns#

Promise<any>


authSlack#

authSlack(verificationCode, redirectUrl): Promise<any>

Parameters#

NameType
verificationCodestring
redirectUrlstring

Returns#

Promise<any>


authenticateSlack#

authenticateSlack(verificationCode, redirectUrl): Promise<any>

Parameters#

NameType
verificationCodestring
redirectUrlstring

Returns#

Promise<any>


authenticateTeamsAdmin#

authenticateTeamsAdmin(tenantId): Promise<any>

Saves Teams Admin token to backend.

Parameters#

NameTypeDescription
tenantIdstringA user id returned from MS Teams after authenticating.

Returns#

Promise<any>


authenticateTeamsUser#

authenticateTeamsUser(verificationCode, redirectUrl): Promise<any>

Parameters#

NameType
verificationCodestring
redirectUrlstring

Returns#

Promise<any>


banItem#

banItem(itemId, assetId): Promise<any>

Parameters#

NameType
itemIdstring
assetIdstring

Returns#

Promise<any>


clearQueryString#

clearQueryString(): Promise<any>

Returns#

Promise<any>


deleteFeed#

deleteFeed(feedId): Promise<any>

Parameters#

NameType
feedIdstring

Returns#

Promise<any>


favoriteItem#

favoriteItem(itemId, assetId, network): Promise<void>

Parameters#

NameType
itemIdstring
assetIdstring
networkstring

Returns#

Promise<void>


getFeeds#

getFeeds(assetId): Promise<any>

Parameters#

NameType
assetIdstring

Returns#

Promise<any>


getInstagramAccounts#

getInstagramAccounts(userId): Promise<any>

Parameters#

NameType
userIdstring

Returns#

Promise<any>


getSlackChannels#

getSlackChannels(teamId): Promise<any>

Parameters#

NameType
teamIdstring

Returns#

Promise<any>


getSlackTeams#

getSlackTeams(): Promise<any>

Returns#

Promise<any>


getTeamsChannels#

getTeamsChannels(tenantId): Promise<any>

Returns Channels available for a given user ID.

Parameters#

NameTypeDescription
tenantIdstringAn ID returned after authenticating the user with MS Teams.

Returns#

Promise<any>


loadAllItems#

loadAllItems(assetId): Promise<SocialItemsResponse>

Parameters#

NameType
assetIdstring

Returns#

Promise<SocialItemsResponse>


loadBlacklist#

loadBlacklist(accountId, socialNetwork): Promise<any>

Parameters#

NameType
accountIdstring
socialNetworkstring

Returns#

Promise<any>


lookupTwitterId#

lookupTwitterId(username): Promise<any>

Parameters#

NameType
usernamestring

Returns#

Promise<any>


openPreapprovalDialog#

openPreapprovalDialog(feed, iconUrl, options?): Promise<any>

Parameters#

NameType
feedany
iconUrlstring
options?PreapprovalDialogOptions

Returns#

Promise<any>


refreshFeed#

refreshFeed(feedId): Promise<any>

Gets new Facebook posts

Parameters#

NameType
feedIdstring

Returns#

Promise<any>


removeItem#

removeItem(itemId, assetId): Promise<any>

Parameters#

NameType
itemIdstring
assetIdstring

Returns#

Promise<any>


saveFeed#

saveFeed(feed): Promise<any>

Parameters#

NameType
feedany

Returns#

Promise<any>


twitterSubscriptionStatus#

twitterSubscriptionStatus(): Promise<TwitterSubscriptionStatusResponse>

Returns#

Promise<TwitterSubscriptionStatusResponse>


unbanUser#

unbanUser(username, socialNetwork, accountId): Promise<any>

Parameters#

NameType
usernamestring
socialNetworkstring
accountIdstring

Returns#

Promise<any>


unfavoriteItem#

unfavoriteItem(itemId, assetId, network): Promise<any>

Parameters#

NameType
itemIdstring
assetIdstring
networkstring

Returns#

Promise<any>