Tags Table
Description: Stores detailed information about each tag.
Table Definition:
CREATE TABLE Tags (
id INT PRIMARY KEY AUTO_INCREMENT,
name VARCHAR(255) NOT NULL UNIQUE,
color VARCHAR(50) NULL,
allowAgent BOOLEAN NOT NULL DEFAULT TRUE,
allowBot BOOLEAN NOT NULL DEFAULT TRUE,
allowSuggestions BOOLEAN NOT NULL DEFAULT TRUE,
isDeleted BOOLEAN NOT NULL DEFAULT FALSE
);
Fields:
| Field Name | Data Type | Nullability | Constraints | Description |
|---|---|---|---|---|
| id | INT | NOT NULL | PRIMARY KEY, AUTO_INCREMENT | Unique identifier for each tag. |
| name | VARCHAR(255) | NOT NULL | UNIQUE | Name of the tag. |
| color | VARCHAR(50) | NULL | Color associated with the tag. | |
| allowAgent | BOOLEAN | NOT NULL, DEFAULT TRUE | Indicates if agents can use the tag. | |
| allowBot | BOOLEAN | NOT NULL, DEFAULT TRUE | Indicates if bots can use the tag. | |
| allowSuggestions | BOOLEAN | NOT NULL, DEFAULT TRUE | Indicates if tag allows suggestions. | |
| isDeleted | BOOLEAN | NOT NULL, DEFAULT FALSE | Indicates if the tag is deleted (soft delete). |