Skip to content

Instantly share code, notes, and snippets.

@Surye
Created June 17, 2015 06:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Surye/33cee116fe8d1bbca67d to your computer and use it in GitHub Desktop.
Save Surye/33cee116fe8d1bbca67d to your computer and use it in GitHub Desktop.
import tgl
def cinfo(success, chat):
for userid in chat.user_list:
user = tgl.Peer(type=tgl.PEER_USER, id=userid)
print(user)
def dlist(success, dialog_list):
for dialog in dialog_list:
if dialog['peer'].type is tgl.PEER_CHAT:
chat = dialog['peer']
chat.info(cinfo)
tgl.get_dialog_list(dlist)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment