2024-07-18 00:56:13 +03:00

19 lines
569 B
Python
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import asyncio
import config
from post_manager import create_new_account, create_post, update_post, telegraph
from utillies import check_tags
### Создание aккаунта в telegraph
account = asyncio.run(create_new_account(short_name=config.AUTHOR_DATA["short_name"]))
### Создание поста в telegraph
article_file = open("content.txt", "r", encoding="utf-8")
article_file = article_file.read()
checked_article = asyncio.run(check_tags(content=article_file))
new_post = asyncio.run(create_post(title="test_title", content=checked_article))