2022-10-04 22:03:09 +00:00
|
|
|
package telebot
|
|
|
|
|
|
|
|
import "time"
|
|
|
|
|
2023-11-20 14:06:31 +00:00
|
|
|
type (
|
|
|
|
// VideoChatStarted represents a service message about a video chat
|
|
|
|
// started in the chat.
|
|
|
|
VideoChatStarted struct{}
|
2022-10-04 22:03:09 +00:00
|
|
|
|
2023-11-20 14:06:31 +00:00
|
|
|
// VideoChatEnded represents a service message about a video chat
|
|
|
|
// ended in the chat.
|
|
|
|
VideoChatEnded struct {
|
|
|
|
Duration int `json:"duration"` // in seconds
|
|
|
|
}
|
2022-10-04 22:03:09 +00:00
|
|
|
|
2023-11-20 14:06:31 +00:00
|
|
|
// VideoChatParticipants represents a service message about new
|
|
|
|
// members invited to a video chat
|
|
|
|
VideoChatParticipants struct {
|
|
|
|
Users []User `json:"users"`
|
|
|
|
}
|
2022-10-04 22:03:09 +00:00
|
|
|
|
2023-11-20 14:06:31 +00:00
|
|
|
// VideoChatScheduled represents a service message about a video chat scheduled in the chat.
|
|
|
|
VideoChatScheduled struct {
|
|
|
|
Unixtime int64 `json:"start_date"`
|
|
|
|
}
|
|
|
|
)
|
2022-10-04 22:03:09 +00:00
|
|
|
|
|
|
|
// StartsAt returns the point when the video chat is supposed to be started by a chat administrator.
|
|
|
|
func (v *VideoChatScheduled) StartsAt() time.Time {
|
|
|
|
return time.Unix(v.Unixtime, 0)
|
|
|
|
}
|