You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
12 lines
388 B
Python
12 lines
388 B
Python
from mastodon import Mastodon
|
|
|
|
with open('token.txt','r') as token:
|
|
mastodon = Mastodon(access_token=token.read(),api_base_url="https://post.lurk.org/")
|
|
|
|
mycreds = mastodon.account_verify_credentials() #dictionary with my user info
|
|
print(mycreds)
|
|
myname = mycreds['display_name']
|
|
|
|
toot_text = '{} whishes you a good hello world'.format(myname)
|
|
mastodon.toot(toot_text)
|
|
print(toot_text) |