from flask import Flask
from flask_sqlalchemy import SQLAlchemy

app = Flask(__name__)
# set database name
app.database = "agents.db"
# load the config
app.config["DEBUG"] = False
app.config["SECRET_KEY"] = <KEY>'
app.config["SQLALCHEMY_DATABASE_URI"] = 'sqlite:///agents.db'
app.config["SQLALCHEMY_TRACK_MODIFICATIONS"] = False
# create the sqlalchemy object
db = SQLAlchemy(app)

from c2.models import Agent, Commands

db.create_all()
db.session.commit()

from c2.api.bot_communication import bp, app

app.register_blueprint(bp)

from flask import Flask
from flask_sqlalchemy import SQLAlchemy

app = Flask(__name__)
# set database name
app.database = "agents.db"
# load the config
app.config["DEBUG"] = False
app.config["SECRET_KEY"] = <KEY>'
app.config["SQLALCHEMY_DATABASE_URI"] = 'sqlite:///agents.db'
app.config["SQLALCHEMY_TRACK_MODIFICATIONS"] = False
# create the sqlalchemy object
db = SQLAlchemy(app)

from c2.models import Agent, Commands

db.create_all()
db.session.commit()

from c2.api.bot_communication import bp, app

app.register_blueprint(bp)

# set database name # load the config # create the sqlalchemy object