Views
Views are saved filter presets that let you organize thogits into reusable collections. Each view has a name, an icon, a filter definition, and display settings.
GET /views
Section titled “GET /views”List all views for the authenticated user.
Auth required: Yes
curl https://app.thogits.com/api/views \ -b cookies.txt -c cookies.txtResponse (200):
[ { "id": "01HQ6V9W2XYZABCDEF3GHIJK4L", "name": "Active Tasks", "icon": "📋", "filter": {"has_tag": {"name": {"eq": "Task"}}}, "view_type": "list", "settings": {}, "created_at": "2025-01-15T10:30:00Z", "updated_at": "2025-01-15T10:30:00Z" }]POST /views
Section titled “POST /views”Create a new view.
Auth required: Yes
Request body:
| Field | Type | Required | Description |
|---|---|---|---|
name | string | Yes | View name |
icon | string | No | Emoji icon (default: clipboard emoji) |
filter | ThogitFilter | Yes | Filter defining which thogits appear in this view |
view_type | string | No | Display type (default: "list") |
settings | object | No | Additional display settings |
curl -X POST https://app.thogits.com/api/views \ -H "Content-Type: application/json" \ -b cookies.txt -c cookies.txt \ -d '{ "name": "Active Tasks", "icon": "🔥", "filter": {"has_tag": {"name": {"eq": "Task"}}}, "view_type": "list" }'Response (200): The full view object.
{ "id": "01HQ6V9W2XYZABCDEF3GHIJK4L", "name": "Active Tasks", "icon": "🔥", "filter": {"has_tag": {"name": {"eq": "Task"}}}, "view_type": "list", "settings": {}, "created_at": "2025-01-15T10:30:00Z", "updated_at": "2025-01-15T10:30:00Z"}GET /views/{view_id}
Section titled “GET /views/{view_id}”Retrieve a single view by ID.
Auth required: Yes
curl https://app.thogits.com/api/views/01HQ6V9W2XYZABCDEF3GHIJK4L \ -b cookies.txt -c cookies.txtResponse (200): The full view object.
Errors:
| Status | Cause |
|---|---|
| 404 | View not found |
PUT /views/{view_id}
Section titled “PUT /views/{view_id}”Update a view’s name, icon, filter, or settings.
Auth required: Yes
Request body:
| Field | Type | Required | Description |
|---|---|---|---|
name | string | Yes | View name |
icon | string | Yes | Emoji icon |
filter | ThogitFilter | Yes | Updated filter |
settings | object | No | Updated display settings |
curl -X PUT https://app.thogits.com/api/views/01HQ6V9W2XYZABCDEF3GHIJK4L \ -H "Content-Type: application/json" \ -b cookies.txt -c cookies.txt \ -d '{ "name": "All Tasks", "icon": "📋", "filter": {"has_tag": {"name": {"eq": "Task"}}} }'Response (200): The updated view object.
Errors:
| Status | Cause |
|---|---|
| 404 | View not found |
DELETE /views/{view_id}
Section titled “DELETE /views/{view_id}”Delete a view. This is a hard delete — views are not soft-deleted.
Auth required: Yes
curl -X DELETE https://app.thogits.com/api/views/01HQ6V9W2XYZABCDEF3GHIJK4L \ -b cookies.txt -c cookies.txtResponse (200): The deleted view object.
Errors:
| Status | Cause |
|---|---|
| 404 | View not found |