CREATE TABLE resource_access_tokens (
    token_hash VARCHAR(64) PRIMARY KEY,
    resource_kind VARCHAR(16) NOT NULL,
    resource_slug VARCHAR(255) NOT NULL,
    expires_at VARCHAR(40) NOT NULL,
    created_at TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
    INDEX idx_resource_access_tokens_resource (resource_kind, resource_slug),
    INDEX idx_resource_access_tokens_expires (expires_at)
);
