input: Write a function to create a Flask web API that returns the current date and time in the format "YYYY-MM-DD HH:MM:SS". The function should define a route '/datetime' for this purpose. If the API is successfully created, it should return True, else return False.
  assert create_datetime_api() == True
output: 
  def create_datetime_api():
      try:
          from flask import Flask, jsonify
          import datetime
  
          app = Flask(__name__)
  
          @app.route('/datetime')
          def get_datetime():
              now = datetime.datetime.now()
              return jsonify({'datetime': now.strftime("%Y-%m-%d %H:%M:%S")})
  
          app.run(port=5000)
          return True
      except Exception as e:
          return False
  