Projects are the core organisational unit in PrintHeritage, grouping sensor datasets and team members around a monitored heritage structure. Every project has an owner and a set ofDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/joaomonteir0/printheritage/llms.txt
Use this file to discover all available pages before exploring further.
ProjectPermission records that control which users can access it. SUPER_ADMIN and GENERAL_ADMIN users see all projects by default; all other roles see only projects they have been explicitly granted ACCEPTED membership in. All write operations emit audit log entries.
POST /projects
Creates a new project. The authenticated user is automatically added as a member withACCEPTED status and an access_level matching their global_role. A PROJECT_CREATE entry is written to the audit log on success.
Authentication: Bearer token required.
Content-Type: application/json
Human-readable name for the project. Must be non-empty.
Optional free-text description of the monitored structure or project scope.
ProjectResponse
Unique identifier of the newly created project.
Name of the project as provided.
Project description, or
null if not provided.UUID of the user who created the project.
List of sensor dataset objects attached to the project. Empty (
[]) on creation.ISO 8601 timestamp of when the project was created.
| Status | Meaning |
|---|---|
401 Unauthorized | Token is missing, expired, or invalid. |
GET /projects
Returns the list of projects visible to the authenticated user.SUPER_ADMIN and GENERAL_ADMIN users receive all projects via an outer join, meaning they see projects even without an explicit membership. All other roles see only projects where they hold an ACCEPTED ProjectPermission. Results are ordered by is_favorite DESC, then created_at DESC. An optional name search narrows results.
Authentication: Bearer token required.
Optional case-insensitive name filter. Applies SQL
ILIKE '%q%' to the project name column.List[dict]
Each item is a ProjectResponse plus an is_favorite boolean.
Unique identifier of the project.
Project name.
Project description.
UUID of the project owner.
List of dataset objects attached to this project.
ISO 8601 creation timestamp.
Whether the authenticated user has marked this project as a favorite.
false when no ProjectPermission record exists for admin users browsing projects they have not explicitly joined.| Status | Meaning |
|---|---|
401 Unauthorized | Token is missing, expired, or invalid. |
GET /projects/
Retrieves the full detail record for a single project. Access is validated viavalidate_project_access: SUPER_ADMIN and GENERAL_ADMIN users are permitted unconditionally; all other users must hold an ACCEPTED ProjectPermission for the requested project.
Authentication: Bearer token required. Caller must have project access.
UUID of the project to retrieve.
ProjectResponse
Unique identifier of the project.
Project name.
Project description.
UUID of the project owner.
List of sensor dataset objects attached to the project.
ISO 8601 creation timestamp.
| Status | Meaning |
|---|---|
401 Unauthorized | Token is missing, expired, or invalid. |
403 Forbidden | Caller does not have ACCEPTED access to this project. |
GET /projects//members
Lists all users who hold aProjectPermission record for the given project, regardless of membership status. Access is validated with the same validate_project_access check used by other project-scoped endpoints.
Authentication: Bearer token required. Caller must have project access.
UUID of the project whose members should be listed.
Unique identifier of the member.
Email address of the member.
Display name of the member.
Profile picture URL of the member.
Platform-wide role of the member:
SUPER_ADMIN, GENERAL_ADMIN, PROJECT_ADMIN, or VISUALIZER.The
access_level from the member’s ProjectPermission record, which mirrors global_role values.Membership status:
PENDING, ACCEPTED, or REJECTED.| Status | Meaning |
|---|---|
401 Unauthorized | Token is missing, expired, or invalid. |
403 Forbidden | Caller does not have access to this project. |
DELETE /projects//members/
Removes a user from a project by deleting theirProjectPermission record. The project owner cannot be removed — attempting to do so returns HTTP 400. On success, a PROJECT_MEMBER_REMOVE entry is written to the audit log.
Authentication: Bearer token required.
UUID of the project from which the user should be removed.
UUID of the user to remove. Must not be the project owner.
Always
true when the member was successfully removed.| Status | Meaning |
|---|---|
400 Bad Request | The target user is the project owner and cannot be removed. |
401 Unauthorized | Token is missing, expired, or invalid. |
PATCH /projects//favorite
Toggles theis_favorite flag on the calling user’s ProjectPermission for the given project. If no permission record exists for the user (e.g. an admin who has never explicitly joined the project), a new ACCEPTED permission record is created with is_favorite set to true. Subsequent calls flip the flag between true and false.
Authentication: Bearer token required.
UUID of the project to toggle as a favorite.
The new value of the
is_favorite flag after the toggle. true means the project is now a favorite; false means it has been unfavorited.| Status | Meaning |
|---|---|
401 Unauthorized | Token is missing, expired, or invalid. |