Skip to content

Home > @theweave/api > WeaveServices

WeaveServices interface

Signature:

typescript
export interface WeaveServices

Properties

Property

Modifiers

Type

Description

appletInfo

(appletHash: any) => Promise<AppletInfo | undefined>

Returns Applet info of the specified Applet

appletParticipants

() => Promise<AgentPubKey[]>

Gets all the agents that joined the Tool instance of the Tool calling this function

assetInfo

(wal: WAL) => Promise<AssetLocationAndInfo | undefined>

Gets information about an entry in any other Applet in We

dragWal

(wal: WAL) => Promise<void>

Request to drop a WAL into the pocket

groupProfile

(groupHash: any) => Promise<any>

Get the group profile of the specified group

mossVersion

() => string

myGroupPermissionType

() => Promise<GroupPermissionType>

Gets the group permission type. May be used to restrict certain actions in the UI.

notifyFrame

(notifications: Array<FrameNotification>) => Promise<any>

Sends notifications to We and depending on user settings and urgency level further to the operating system.

onPeerStatusUpdate

(callback: (payload: PeerStatusUpdate) => any) => UnsubscribeFunction

Event handler for peer status updates.

openAppletBlock

(appletHash: any, block: string, context: any) => Promise<void>

Open the specified block view of the specified Applet

openAppletMain

(appletHash: EntryHash) => Promise<void>

Open the main view of the specified Applet

openCrossAppletBlock

(appletBundleId: ActionHash, block: string, context: any) => Promise<void>

Open the specified block view of the specified Applet Type

openCrossAppletMain

(appletBundleId: ActionHash) => Promise<void>

Open the cross-applet main view of the specified Applet Type.

openWal

(wal: WAL, mode?: OpenWalMode) => Promise<void>

Open the specified WAL

requestBind

(srcWal: WAL, dstWal: WAL) => Promise<void>

Request the applet holding the destination WAL (dstWal) to bind the source WAL (srcWal) to it. The source WAL must belong to the requesting applet.

requestClose

() => Promise<void>

Requests to close the containing window. Will only work if the applet is being run in its own window

userSelectScreen

() => Promise<string>

Let's the user select a Screen or Window and returns the selected id. Useful for screen sharing applications.

userSelectWal

() => Promise<WAL | undefined>

Prompts the user with the search bar and We clipboard to select a WAL. Returns a WAL as soon as the user has selected a WAL or undefined if the user cancels the selection process.

walToPocket

(wal: WAL) => Promise<void>

Adds the specified HRL to the We-internal clipboard