# Generated by Plain 0.52.2 on 2025-07-08 01:17

from plain import models
from plain.models import migrations


class Migration(migrations.Migration):
    initial = True

    dependencies = []

    operations = [
        migrations.CreateModel(
            name="Session",
            fields=[
                ("id", models.PrimaryKeyField()),
                ("session_key", models.CharField(max_length=40)),
                ("session_data", models.JSONField(default=dict, required=False)),
                ("created_at", models.DateTimeField(auto_now_add=True)),
                ("expires_at", models.DateTimeField(allow_null=True)),
            ],
        ),
        migrations.AddIndex(
            model_name="session",
            index=models.Index(
                fields=["expires_at"], name="plainsessio_expires_d87cb5_idx"
            ),
        ),
        migrations.AddConstraint(
            model_name="session",
            constraint=models.UniqueConstraint(
                fields=("session_key",), name="unique_session_key"
            ),
        ),
    ]
