input: 
  from flask import Flask
  import datetime
  
  app = Flask(__name__)
  
  @app.route('/datetime')
  def get_datetime():
      """Create a web API using Flask to return the current date and time.
      The API should be accessible at '/datetime' and should return the current date and time in the format 'YYYY-MM-DD HH:MM:SS'.
      
      Example:
      If the current date and time is 2023-10-05 14:30:45, calling the API at '/datetime' should return '2023-10-05 14:30:45'.
      """
      return datetime.datetime.now().strftime("%Y-%m-%d %H:%M:%S")
  
  if __name__ == '__main__':
      app.run()
  
output:     
      current_time = datetime.datetime.now()
      return current_time.strftime("%Y-%m-%d %H:%M:%S")
  