{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://catalog.lintel.tools/schemas/schemastore/eidolon-resource/_shared/latest--SqlAlchemy.json",
  "title": "SqlAlchemy",
  "description": "A client for executing SQL queries using SQLAlchemy.\nSee <https://docs.sqlalchemy.org/> for connection configuration details.\n\nPerforms cursory checks when `select_only` is set to True. Additionally ensure user is restricted to allowed permissions.",
  "x-lintel": {
    "source": "https://www.eidolonai.com/json_schema/v1/schemas/SqlClient/SqlAlchemy.json",
    "sourceSha256": "af5b29c16c71dad377d0dbda86ac5e26768b2916a7b1a7d4aaa76c338b3f1f36"
  },
  "type": "object",
  "properties": {
    "implementation": {
      "const": "SqlAlchemy",
      "title": "Implementation"
    },
    "protocol": {
      "default": null,
      "title": "Protocol",
      "type": "string"
    },
    "connection_string": {
      "default": "sqlite+aiosqlite:///:memory:",
      "description": "SQLAlchemy connection string. See <https://docs.sqlalchemy.org/en/20/core/engines.html> for more information.",
      "title": "Connection String",
      "type": "string"
    },
    "engine_kwargs": {
      "default": {},
      "title": "Engine Kwargs",
      "type": "object"
    },
    "select_only": {
      "default": false,
      "title": "Select Only",
      "type": "boolean"
    },
    "metadata": {
      "default": [
        {
          "name": "tables",
          "metadata": [],
          "remove_falsy_metadata": true
        }
      ],
      "items": {
        "$ref": "#/$defs/MetadataAttribute"
      },
      "title": "Metadata",
      "type": "array"
    }
  },
  "additionalProperties": false,
  "$defs": {
    "MetadataAttribute": {
      "properties": {
        "name": {
          "title": "Name",
          "type": "string"
        },
        "metadata": {
          "anyOf": [
            {
              "items": {
                "$ref": "#/$defs/MetadataAttribute"
              },
              "type": "array"
            },
            {
              "items": {
                "type": "string"
              },
              "type": "array"
            }
          ],
          "default": [],
          "title": "Metadata"
        },
        "remove_falsy_metadata": {
          "default": true,
          "title": "Remove Falsy Metadata",
          "type": "boolean"
        }
      },
      "required": [
        "name"
      ],
      "title": "MetadataAttribute",
      "type": "object"
    }
  },
  "required": [
    "implementation"
  ],
  "reference_details": {
    "clz": "eidolon_ai_sdk.agent.sql_agent.client.SqlAlchemy",
    "groups": [
      "SqlClient"
    ],
    "name": "SqlAlchemy",
    "overrides": {}
  }
}
