Options
All
  • Public
  • Public/Protected
  • All
Menu

The ScreenMeetAPI class is your primary surface for performing operations on the ScreenMeet platform. It provides API's to create, close, and monitor ScreenMeet sessions.

Hierarchy

  • ScreenMeetAPI

Index

Constructors

constructor

  • The ScreenMeetAPI constructor takes an optional API key as the 1st prameter parameter. It can also be set later via setKey

    Parameters

    • key: string = ''

    Returns ScreenMeetAPI

Properties

Private endpoint

endpoint: string = 'https://api-v3.screenmeet.com/v3'

The endpoint is the API URI prefix for which ScreenMeet API version to target.

Private key

key: string = ''

This is the key to interact with the ScreenMeet API. It is generally a user session token identifying the user

Methods

authWithOauthCode

  • authWithOauthCode(provider: string, code: string, instance_url?: string, state?: string): Promise<MeResponse>
  • Exchanges an O-Auth authorization token for an access token on the back-end, establishes a user session, and returns a user session {@link MeResponse} object.

    Parameters

    • provider: string
    • code: string
    • Optional instance_url: string
    • Optional state: string

    Returns Promise<MeResponse>

authWithToken

  • authWithToken(provider: string, session_token: string): Promise<MeResponse>
  • Authenticates the user with a session token

    Parameters

    • provider: string
    • session_token: string

    Returns Promise<MeResponse>

closeSession

  • closeSession(code: string): Promise<{ success: boolean }>
  • Closes the session with the given alpha-numeric ID.

    Parameters

    • code: string

    Returns Promise<{ success: boolean }>

createSession

Private delete

  • delete(path: string, params?: {}): Promise<any>
  • Parameters

    • path: string
    • Optional params: {}
      • [key: string]: any

    Returns Promise<any>

Private get

  • get(path: string, params?: {}): Promise<any>
  • Parameters

    • path: string
    • Optional params: {}
      • [key: string]: any

    Returns Promise<any>

getBaseUrl

  • getBaseUrl(): string
  • Returns the API end-point base URL

    Returns string

getCobrowseDeployments

  • Returns cobrowse deployments configuration for the organization

    Parameters

    • org_id: number

    Returns Promise<CobrowseDeployment[]>

getConfiguration

  • getConfiguration(configTypeId: any): Promise<any>
  • Returns configuration data for the given config

    Parameters

    • configTypeId: any

    Returns Promise<any>

Private getDefaultHeaders

  • getDefaultHeaders(): { Content-Type: string; Session-id: string; client-app: string }
  • Returns { Content-Type: string; Session-id: string; client-app: string }

    • Content-Type: string
    • Session-id: string
    • client-app: string

getEndpointsConfig

  • Returns endpoint configurations for an organization

    Parameters

    • org_id: number

    Returns Promise<EndpointConfig>

getSession

  • Parameters

    • code: string

    Returns Promise<SupportSession>

listRelatedObjectSessions

  • listRelatedObjectSessions(externalObjectMappingKey: string): Promise<SupportSession[]>
  • Returns a promise that resolves with an array of sessions associated with the related object mapping key

    Parameters

    • externalObjectMappingKey: string

    Returns Promise<SupportSession[]>

listUserSessions

me

  • This method returns information about the currently authenticated user. The response object is a {@link MeResponse}

    Returns Promise<MeResponse>

parseResponse

  • parseResponse(response: any, options: any): Promise<any>
  • Parameters

    • response: any
    • options: any

    Returns Promise<any>

pollDiscoveryState

  • Polls the discovery service with a list of session ID's (max 20) and will return a DiscoveryResponse which will include any sessions that have an active state

    Parameters

    • sessionIdList: string[]

    Returns Promise<DiscoveryResponse>

Private post

  • post(path: string, params?: {}): Promise<any>
  • Parameters

    • path: string
    • Optional params: {}
      • [key: string]: any

    Returns Promise<any>

Private put

  • put(path: string, params?: {}): Promise<any>
  • Parameters

    • path: string
    • Optional params: {}
      • [key: string]: any

    Returns Promise<any>

setBaseUrl

  • setBaseUrl(url: any): void
  • Changes the BASE API URL. Generally used to change to a pre-production ScreenMeet environment.

    Parameters

    • url: any

    Returns void

setKey

  • setKey(key: string): void
  • This is a setter method to update the key

    Parameters

    • key: string

    Returns void

signout

  • signout(): Promise<any>
  • Clears the key from the ScreenMeetAPI instance and signals the back-end to end the agent session

    Returns Promise<any>

Generated using TypeDoc