BusinessWorkHours

class pyrogram.raw.types.BusinessWorkHours

Specifies a set of Telegram Business opening hours.

Constructor of BusinessWorkHours.

Details:
  • Layer: 223

  • ID: 8C92B098

Parameters:
  • timezone_id (str) – An ID of one of the timezones returned by help.getTimezonesList. The timezone ID is contained timezone.id, a human-readable, localized name of the timezone is available in timezone.name and the timezone.utc_offset field contains the UTC offset in seconds, which may be displayed in hh:mm format by the client together with the human-readable name (i.e. $name UTC -01:00).

  • weekly_open (List of BusinessWeeklyOpen) – A list of time intervals (max 28) represented by businessWeeklyOpen », indicating the opening hours of their business.

  • open_now (bool, optional) – Ignored if set while invoking account.updateBusinessWorkHours, only returned by the server in userFull.business_work_hours, indicating whether the business is currently open according to the current time and the values in weekly_open and timezone.

TL Schema

businessWorkHours#8c92b098
flags:#
open_now:flags.0?true
timezone_id:string
weekly_open:Vector<BusinessWeeklyOpen>

= BusinessWorkHours

Parameter Tree

BusinessWorkHours
├── open_nowtrue (optional)
├── timezone_idstring
└── weekly_openVector < BusinessWeeklyOpen >
├── start_minuteint
└── end_minuteint

Example

BusinessWorkHours(
    timezone_id="text",
    weekly_open=[
            BusinessWeeklyOpen(
                start_minute=0,
                end_minute=0
            )
        ],
)