from flask import Flask
from flask_restful import Resource, Api
from ..services.mongo_service import MongoService

app = Flask(__name__)
api = Api(app)


class HelloWorld(Resource):
    mongoService: MongoService

    def __init__(self):
        self.mongoService = MongoService()

    def get(self):
        return self.mongoService.getAllMovies()


api.add_resource(HelloWorld, '/')

if __name__ == '__main__':
    app.run(debug=True)
