| | |
| | | from app.models.base_model import SessionLocal |
| | | from app.service.v2.initialize_data import dialog_menu_sync, default_group_sync, default_role_sync, \ |
| | | basic_agent_sync, admin_account_sync |
| | | basic_agent_sync, admin_account_sync, sync_rg_api_token |
| | | from app.task.sync_account_token import sync_token |
| | | |
| | | |
| | | async def sync_default_data(): |
| | |
| | | # await app_register_sync(db) # 注册的应用 |
| | | await basic_agent_sync(db) # 开发的agent |
| | | await admin_account_sync(db) # |
| | | await sync_rg_api_token(db) # |
| | | await sync_token() # 启动同步token任务 |
| | | |
| | | except Exception as e: |
| | | print(e) |