Interface SendMessageViewMetrics

Informs TDLib about details of a message view by the user from a chat, a message thread or a forum topic history. The method must be called if the message wasn't seen for more than 300 milliseconds, the viewport was destroyed, or the total view duration exceeded 5 minutes. Request type for Tdjson#sendMessageViewMetrics.

interface SendMessageViewMetrics {
    @type: "sendMessageViewMetrics";
    active_time_in_view_ms: number;
    chat_id: number;
    height_to_viewport_ratio_per_mille: number;
    message_id: number;
    seen_range_ratio_per_mille: number;
    time_in_view_ms: number;
}

Properties

@type: "sendMessageViewMetrics"
active_time_in_view_ms: number

The amount of time the message was seen by at least 1 pixel within 15 seconds after any action from the user; in milliseconds.

chat_id: number

Chat identifier.

height_to_viewport_ratio_per_mille: number

The ratio of the post height to the viewport height in 1/1000 fractions.

message_id: number

The identifier of the message being viewed.

seen_range_ratio_per_mille: number

The ratio of the viewed post height to the full post height in 1/1000 fractions; 0-1000.

time_in_view_ms: number

The amount of time the message was seen by at least 1 pixel; in milliseconds.