Skip to content

Latest commit

 

History

History
430 lines (241 loc) · 15.2 KB

DirectThreadEntity.md

File metadata and controls

430 lines (241 loc) · 15.2 KB

instagram-private-api / entities / DirectThreadEntity

Class: DirectThreadEntity

entities.DirectThreadEntity

Hierarchy

  • Entity

    DirectThreadEntity

Table of contents

Constructors

Properties

Methods

Constructors

constructor

new DirectThreadEntity(client)

Parameters

Name Type
client IgApiClient

Inherited from

Entity.constructor

Defined in

src/core/repository.ts:7

Properties

threadId

threadId: string = null

Defined in

src/entities/direct-thread.entity.ts:16


userIds

userIds: string[] = null

Defined in

src/entities/direct-thread.entity.ts:17

Methods

addUser

addUser(userIds): Promise<DirectThreadRepositoryAddUserResponseRootObject>

Parameters

Name Type
userIds string[] | number[]

Returns

Promise<DirectThreadRepositoryAddUserResponseRootObject>

Defined in

src/entities/direct-thread.entity.ts:239


broadcastLink

broadcastLink(link_text, link_urls): Promise<DirectThreadRepositoryBroadcastResponseRootObject | DirectThreadRepositoryBroadcastResponsePayload>

Parameters

Name Type
link_text string
link_urls string[]

Returns

Promise<DirectThreadRepositoryBroadcastResponseRootObject | DirectThreadRepositoryBroadcastResponsePayload>

Defined in

src/entities/direct-thread.entity.ts:95


broadcastPhoto

broadcastPhoto(options): Promise<DirectThreadRepositoryBroadcastResponseRootObject | DirectThreadRepositoryBroadcastResponsePayload>

Parameters

Name Type
options DirectThreadBroadcastPhotoOptions

Returns

Promise<DirectThreadRepositoryBroadcastResponseRootObject | DirectThreadRepositoryBroadcastResponsePayload>

Defined in

src/entities/direct-thread.entity.ts:105


broadcastPost

broadcastPost(mediaId): Promise<DirectThreadRepositoryBroadcastResponseRootObject | DirectThreadRepositoryBroadcastResponsePayload>

Parameters

Name Type
mediaId string

Returns

Promise<DirectThreadRepositoryBroadcastResponseRootObject | DirectThreadRepositoryBroadcastResponsePayload>

Defined in

src/entities/direct-thread.entity.ts:119


broadcastProfile

broadcastProfile(id): Promise<DirectThreadRepositoryBroadcastResponseRootObject | DirectThreadRepositoryBroadcastResponsePayload>

Parameters

Name Type
id string | number

Returns

Promise<DirectThreadRepositoryBroadcastResponseRootObject | DirectThreadRepositoryBroadcastResponsePayload>

Defined in

src/entities/direct-thread.entity.ts:86


broadcastReel

broadcastReel(options): Promise<DirectThreadRepositoryBroadcastResponseRootObject | DirectThreadRepositoryBroadcastResponsePayload>

This is used when replying to a story (swiping up) and it's creator

Parameters

Name Type
options DirectThreadBroadcastReelOptions

Returns

Promise<DirectThreadRepositoryBroadcastResponseRootObject | DirectThreadRepositoryBroadcastResponsePayload>

Defined in

src/entities/direct-thread.entity.ts:52


broadcastStory

broadcastStory(input): Promise<any>

Uploads a story to the thread The story is either destroyable (view 'once') or 'replayable'

Parameters

Name Type
input Buffer | DirectThreadBroadcastPhotoStoryOptions | DirectThreadBroadcastVideoStoryOptions

Returns

Promise<any>

Defined in

src/entities/direct-thread.entity.ts:195


broadcastText

broadcastText(text, skipLinkCheck?): Promise<DirectThreadRepositoryBroadcastResponseRootObject | DirectThreadRepositoryBroadcastResponsePayload>

Sends a text message to the thread. If the message contains links, these links will be properly displayed (turn off with {@param skipLinkCheck})

Parameters

Name Type Description
text string The text to send
skipLinkCheck? boolean May be omitted; skips checking for links. This was added to only require url-regex-safe if it's necessary as it may cause problems (See #1328).

Returns

Promise<DirectThreadRepositoryBroadcastResponseRootObject | DirectThreadRepositoryBroadcastResponsePayload>

Defined in

src/entities/direct-thread.entity.ts:33


broadcastUserStory

broadcastUserStory(options): Promise<DirectThreadRepositoryBroadcastResponseRootObject | DirectThreadRepositoryBroadcastResponsePayload>

This is used when sharing a story (app: plane/share button) to a thread

Parameters

Name Type
options DirectThreadBroadcastReelOptions

Returns

Promise<DirectThreadRepositoryBroadcastResponseRootObject | DirectThreadRepositoryBroadcastResponsePayload>

Defined in

src/entities/direct-thread.entity.ts:71


broadcastVideo

broadcastVideo(options): Promise<DirectThreadRepositoryBroadcastResponseRootObject | DirectThreadRepositoryBroadcastResponsePayload>

Parameters

Name Type
options DirectThreadBroadcastVideoOptions

Returns

Promise<DirectThreadRepositoryBroadcastResponseRootObject | DirectThreadRepositoryBroadcastResponsePayload>

Defined in

src/entities/direct-thread.entity.ts:131


broadcastVoice

broadcastVoice(options): Promise<DirectThreadRepositoryBroadcastResponseRootObject | DirectThreadRepositoryBroadcastResponsePayload>

Parameters

Name Type
options DirectThreadBroadcastVoiceOptions

Returns

Promise<DirectThreadRepositoryBroadcastResponseRootObject | DirectThreadRepositoryBroadcastResponsePayload>

Defined in

src/entities/direct-thread.entity.ts:159


deleteItem

deleteItem(itemId): Promise<StatusResponse>

Parameters

Name Type
itemId string | number

Returns

Promise<StatusResponse>

Defined in

src/entities/direct-thread.entity.ts:19


hide

hide(): Promise<StatusResponse>

Returns

Promise<StatusResponse>

Defined in

src/entities/direct-thread.entity.ts:231


leave

leave(): Promise<StatusResponse>

Returns

Promise<StatusResponse>

Defined in

src/entities/direct-thread.entity.ts:235


markItemSeen

markItemSeen(threadItemId): Promise<StatusResponse>

Parameters

Name Type
threadItemId string

Returns

Promise<StatusResponse>

Defined in

src/entities/direct-thread.entity.ts:243


mute

mute(): Promise<StatusResponse>

Returns

Promise<StatusResponse>

Defined in

src/entities/direct-thread.entity.ts:223


unmute

unmute(): Promise<StatusResponse>

Returns

Promise<StatusResponse>

Defined in

src/entities/direct-thread.entity.ts:227


updateTitle

updateTitle(title): Promise<DirectThreadRepositoryUpdateTitleResponseRootObject>

Parameters

Name Type
title string

Returns

Promise<DirectThreadRepositoryUpdateTitleResponseRootObject>

Defined in

src/entities/direct-thread.entity.ts:219