MCPcopy Index your code
hub / github.com/eternnoir/pyTelegramBotAPI / de_json

Method de_json

telebot/types.py:398–404  ·  view source on GitHub ↗
(cls, json_string)

Source from the content-addressed store, hash-verified

396 """
397 @classmethod
398 def de_json(cls, json_string):
399 if json_string is None: return None
400 obj = cls.check_json(json_string)
401 obj['chat'] = Chat.de_json(obj['chat'])
402 obj['from_user'] = User.de_json(obj['from'])
403 obj['invite_link'] = ChatInviteLink.de_json(obj.get('invite_link'))
404 return cls(**obj)
405
406 def __init__(self, chat, from_user, user_chat_id, date, bio=None, invite_link=None, **kwargs):
407 self.chat: Chat = chat

Callers

nothing calls this directly

Calls 3

check_jsonMethod · 0.80
de_jsonMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected