"""add_playlist_config_table

Revision ID: 7e28cc511ef8
Revises: 5ed73db9bab9
Create Date: 2025-12-30 10:30:36.775553

"""
from typing import Sequence, Union

from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision: str = '7e28cc511ef8'
down_revision: Union[str, Sequence[str], None] = '5ed73db9bab9'
branch_labels: Union[str, Sequence[str], None] = None
depends_on: Union[str, Sequence[str], None] = None


def upgrade() -> None:
    """Upgrade schema."""
    # ### commands auto generated by Alembic - please adjust! ###
    op.create_table('playlist_config',
    sa.Column('key', sa.String(), nullable=False),
    sa.Column('spotify_id', sa.String(), nullable=False),
    sa.Column('last_updated', sa.DateTime(), nullable=True),
    sa.Column('current_theme', sa.String(), nullable=True),
    sa.Column('description', sa.String(), nullable=True),
    sa.PrimaryKeyConstraint('key')
    )
    op.create_index(op.f('ix_playlist_config_key'), 'playlist_config', ['key'], unique=False)
    # ### end Alembic commands ###


def downgrade() -> None:
    """Downgrade schema."""
    # ### commands auto generated by Alembic - please adjust! ###
    op.drop_index(op.f('ix_playlist_config_key'), table_name='playlist_config')
    op.drop_table('playlist_config')
    # ### end Alembic commands ###
