init commit
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
import pydantic
|
||||
import pydantic_settings
|
||||
|
||||
|
||||
class Config(pydantic_settings.BaseSettings):
|
||||
model_config = pydantic_settings.SettingsConfigDict(
|
||||
env_file='../.env',
|
||||
env_ignore_empty=True,
|
||||
extra='ignore',
|
||||
)
|
||||
|
||||
TOKEN_TELEGRAM_API: str = pydantic.fields.Field(default=None)
|
||||
WEB_APP_URL: str = pydantic.fields.Field(default=None)
|
||||
|
||||
|
||||
config = Config()
|
||||
@@ -0,0 +1,15 @@
|
||||
import aiogram.types
|
||||
|
||||
from app.core.config import config
|
||||
|
||||
inline_web_app_buttons = [
|
||||
[
|
||||
aiogram.types.InlineKeyboardButton(
|
||||
text='Запустить',
|
||||
web_app=aiogram.types.WebAppInfo(url=config.WEB_APP_URL),
|
||||
)
|
||||
]
|
||||
]
|
||||
inline_web_app = aiogram.types.InlineKeyboardMarkup(
|
||||
inline_keyboard=inline_web_app_buttons
|
||||
)
|
||||
@@ -0,0 +1,4 @@
|
||||
GREETING = """
|
||||
Добро пожаловать в CoPay!
|
||||
Используйте web-app для управления аккаунтом.
|
||||
"""
|
||||
Reference in New Issue
Block a user