import uuid
from datetime import datetime
from typing import Optional, List

import pydantic
from sqlalchemy import Column, JSON
from sqlmodel import Field, Relationship

from api.db.models.base import BaseModel, BaseTable


class SchemaDef(pydantic.BaseModel):
    id: Optional[str] = None
    name: Optional[str] = None
    version: Optional[str] = None
    attributes: Optional[List[str]] = []


class Governance(pydantic.BaseModel):
    schema_def: Optional[SchemaDef] = None
    cred_def_id: Optional[str] = None
    cred_def_tag: Optional[str] = None


class SandboxBase(BaseModel):
    tag: Optional[str] = 