Skip to content

[IC3] Pluggable telemetry #2754

@compulim

Description

@compulim

VSTS #1653417

Feature Request

Web Chat should send telemetry data points to DirectLineJS object.

We will discuss more about what data points. And it will be up to DirectLineJS object to decide what to do with the telemetry data (e.g. queueing/batching, etc.)

How to hook

renderWebChat({
  onTelemetry: (event: TelemetryEvent) => {
  }
});

type TelemetryEvent = IncomingActivityEvent;

type IncomingActivityEvent {
  name: 'incoming activity';
  contentType: string;
  numAttachments: number;
}

Data points

(TBD)

  • Typing
  • Send event
    • Also log: activity size
  • Send message
    • Also log: activity size, content type (text/plain, text/markdown, application/json)
  • Send attachments
    • Also log: number of attachments sent
  • Connecting
    • Also log: max connections before this connection (0 = initial, > 1 = reconnect)
  • Connect success
  • Connect fail
  • Image downscaling
    • Also log: Web Worker or main thread, image quality
  • Incoming activity
    • Also log: Content type, number of attachments
  • Incoming event
  • Incoming attachment
    • Also log: Content type, attachment size

Ambient

  • Start time and end time of an action
  • UI language
  • Version

Samples

Should have a sample showing how to send telemetry data to one of these platforms. Although Web Chat just emit events, the sample might need to convert telemetry event into a format that fit best on these platforms. I.e. tracking event is good, but tracking metric or exception is better.

How to allow developers who customize Web Chat to add events

For example, developers customized download button, they want to capture how long does it take for the user to download the file.

Do we have any guidelines on privacy policy telling them what to do or not?

[Enhancement]

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions