class_docstr: This handler handles connection and execution of the FaunaDB statements.
class_docstr_tok: ["This","handler","handles","connection","and","execution","of","the","FaunaDB","statements","."]
code: def __init__(self, name: str, **kwargs):
      super().__init__(name)
  
      self._connection_data = kwargs.get("connection_data")
  
      self._client_config = {
          "fauna_secret": self._connection_data.get("fauna_secret"),
          "fauna_scheme": self._connection_data.get("fauna_scheme"),
          "fauna_domain": self._connection_data.get("fauna_domain"),
          "fauna_port": self._connection_data.get("fauna_port"),
          "fauna_endpoint": self._connection_data.get("fauna_endpoint"),
      }
  
      scheme, domain, port, endpoint = (
          self._client_config["fauna_scheme"],
          self._client_config["fauna_domain"],
          self._client_config["fauna_port"],
          self._client_config["fauna_endpoint"],
      )
  
      # should have the secret
      if (self._client_config["fauna_secret"]) is None:
          raise Exception(
              "FaunaDB secret is required for FaunaDB connection!"
          )
      # either scheme + domain + port or endpoint is required
      # but not both
      if not endpoint and not (scheme and domain and port):
          raise Exception(
              "Either scheme + domain + port or endpoint is required for FaunaDB connection!"
          )
      elif endpoint and (scheme or domain or port):
          raise Exception(
              "Either scheme + domain + port or endpoint is required for FaunaDB connection, but not both!"
          )
  
      self._client = None
      self.is_connected = False
      self.connect()
  
imports: import json
  import pandas
  from collections import OrderedDict
  from typing import List
  from faunadb import query
  from faunadb.client import FaunaClient
  from mindsdb_sql import Select, Insert, CreateTable, Delete
  from mindsdb_sql.parser.ast.select.star import Star
  from mindsdb_sql.parser.ast.base import ASTNode
  from mindsdb.integrations.libs.const import HANDLER_CONNECTION_ARG_TYPE
  from mindsdb.integrations.libs.response import RESPONSE_TYPE, HandlerResponse, HandlerStatusResponse
  from mindsdb.integrations.libs.base import DatabaseHandler
  from mindsdb.utilities import log
label_desc: Use image node_id 1 to create a new FaunaDBHandler object from inherited base classes: DatabaseHandler with example: obj = FaunaDBHandler(name)