Reputation: 185
Sometimes when I use functions in pyrogram
I receive the following output:
{
"_": functionName,
"argName" : value,
"arg2Name" : value2,
# etc.
}
For instance, If I write:
functions.users.GetFullUser(types.InputUserSelf())
I receive:
{
"_": "functions.users.GetFullUser",
"id": {
"_": "types.InputUserSelf"
}
}
Why do I receive this result? How should I properly use the functions?
Upvotes: 0
Views: 1944
Reputation: 427
Client.send()
method is now deprecated (Pyrogram v2.0), you should use Client.invoke()
.
Upvotes: 1
Reputation: 48
You should use send():
from pyrogram import Client
from pyrogram.api import functions
app = Client("test")
result = app.send(functions.users.GetFullUser(types.InputUserSelf()))
print(result)
Upvotes: 2