CREATE TABLE arimelody.blogpost (
    id TEXT NOT NULL UNIQUE, 
    title TEXT NOT NULL,
    description TEXT NOT NULL,
    visible BOOLEAN NOT NULL DEFAULT FALSE,
    created_at TIMESTAMP NOT NULL DEFAULT current_timestamp,
    author UUID NOT NULL, 
    markdown TEXT NOT NULL,
    bluesky_actor TEXT,
    bluesky_record TEXT,
    fediverse_account TEXT,
    fediverse_status TEXT
);
ALTER TABLE arimelody.blogpost ADD CONSTRAINT blogpost_pk PRIMARY KEY (id);
ALTER TABLE arimelody.blogpost ADD CONSTRAINT blogpost_author_fk FOREIGN KEY (author) REFERENCES account(id) ON DELETE CASCADE;
