2022-04-02 01:06:59 +02:00
|
|
|
from tofu_api.common.rest import BaseBlueprint
|
2022-03-26 01:07:47 +01:00
|
|
|
from .tasks import TaskApiBlueprint
|
|
|
|
|
|
|
|
|
|
|
2022-04-02 01:06:59 +02:00
|
|
|
class TofuApiBlueprint(BaseBlueprint):
|
2022-03-26 01:07:47 +01:00
|
|
|
"""
|
|
|
|
|
Main blueprint for the Tofu REST API.
|
|
|
|
|
"""
|
|
|
|
|
|
2022-04-02 01:06:59 +02:00
|
|
|
name = 'rest_api'
|
|
|
|
|
import_name = __name__
|
|
|
|
|
url_prefix = '/api'
|
2022-03-26 01:07:47 +01:00
|
|
|
|
2022-04-02 01:06:59 +02:00
|
|
|
def init_blueprint(self) -> None:
|
|
|
|
|
self.register_blueprint(TaskApiBlueprint(self.app))
|