# Post

**Kind:** Database Model

**Source:** [`atloria-monorepo/apps/database-parser/test/fixtures/sample.prisma`](https://github.com/sherkety/atloria/blob/main/atloria-monorepo/apps/database-parser/test/fixtures/sample.prisma#L29)

Blog post model

## Fields

| Field | Type | Required | Key |
|---|---|---|---|
| `id` | `String` | ✓ | PK |
| `title` | `String` | ✓ |  |
| `content` | `String` | - |  |
| `published` | `Boolean` | ✓ |  |
| `authorId` | `String` | ✓ |  |
| `createdAt` | `DateTime` | ✓ |  |
| `updatedAt` | `DateTime` | ✓ |  |

## Diagram

```mermaid
erDiagram
    Post {
        id String [PK]
        title String
        content String?
        published Boolean
        authorId String
        createdAt DateTime
        updatedAt DateTime
    }
    Post ||--|| User : "authorId"
    Post ||--}o Category : ""
```

## Relationships

- BELONGS_TO → `User`
- HAS_MANY → `Category`

## Referenced By

- `User` (HAS_MANY)
- `Category` (HAS_MANY)
