mirror of
https://github.com/aiogram/aiogram.git
synced 2025-12-09 09:22:03 +00:00
Remove bad comments.
This commit is contained in:
parent
07c7c1f32a
commit
5019a4f00b
3 changed files with 0 additions and 34 deletions
|
|
@ -13,17 +13,6 @@ class Chat(Deserializable):
|
|||
|
||||
@classmethod
|
||||
def de_json(cls, raw_data) -> 'Chat':
|
||||
"""
|
||||
id Integer Unique identifier for this chat. This number may be greater than 32 bits and some programming languages may have difficulty/silent defects in interpreting it. But it is smaller than 52 bits, so a signed 64 bit integer or double-precision float type are safe for storing this identifier.
|
||||
type String Type of chat, can be either “private”, “group”, “supergroup” or “channel”
|
||||
title String Optional. Title, for supergroups, channels and group chats
|
||||
username String Optional. Username, for private chats, supergroups and channels if available
|
||||
first_name String Optional. First name of the other party in a private chat
|
||||
last_name String Optional. Last name of the other party in a private chat
|
||||
all_members_are_administrators Boolean Optional. True if a group has ‘All Members Are Admins’ enabled.
|
||||
:param raw_data:
|
||||
:return:
|
||||
"""
|
||||
raw_data = cls.check_json(raw_data)
|
||||
|
||||
id: int = raw_data.get('id')
|
||||
|
|
|
|||
|
|
@ -23,20 +23,6 @@ class Update(Deserializable):
|
|||
|
||||
@classmethod
|
||||
def de_json(cls, raw_data):
|
||||
"""
|
||||
update_id Integer The update‘s unique identifier. Update identifiers start from a certain positive number and increase sequentially. This ID becomes especially handy if you’re using Webhooks, since it allows you to ignore repeated updates or to restore the correct update sequence, should they get out of order.
|
||||
message Message Optional. New incoming message of any kind — text, photo, sticker, etc.
|
||||
edited_message Message Optional. New version of a message that is known to the bot and was edited
|
||||
channel_post Message Optional. New incoming channel post of any kind — text, photo, sticker, etc.
|
||||
edited_channel_post Message Optional. New version of a channel post that is known to the bot and was edited
|
||||
inline_query InlineQuery Optional. New incoming inline query
|
||||
chosen_inline_result ChosenInlineResult Optional. The result of an inline query that was chosen by a user and sent to their chat partner.
|
||||
callback_query CallbackQuery Optional. New incoming callback query
|
||||
shipping_query ShippingQuery Optional. New incoming shipping query. Only for invoices with flexible price
|
||||
pre_checkout_query PreCheckoutQuery Optional. New incoming pre-checkout query. Contains full information about checkout
|
||||
:param raw_data:
|
||||
:return:
|
||||
"""
|
||||
raw_data = cls.check_json(raw_data)
|
||||
|
||||
update_id = raw_data.get('update_id')
|
||||
|
|
|
|||
|
|
@ -13,15 +13,6 @@ class User(Deserializable):
|
|||
|
||||
@classmethod
|
||||
def de_json(cls, raw_data: str or dict) -> 'User':
|
||||
"""
|
||||
id Integer Unique identifier for this user or bot
|
||||
first_name String User‘s or bot’s first name
|
||||
last_name String Optional. User‘s or bot’s last name
|
||||
username String Optional. User‘s or bot’s username
|
||||
language_code String Optional. IETF language tag of the user's language
|
||||
:param raw_data:
|
||||
:return:
|
||||
"""
|
||||
raw_data = cls.check_json(raw_data)
|
||||
|
||||
id = raw_data.get('id')
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue