Skip to main content

Documentation 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.

These endpoints give privileged users tools for administering the PrintHeritage user directory. Listing all users is restricted to GENERAL_ADMIN and SUPER_ADMIN roles; individual profile lookups and searches are available to any authenticated user. All write operations — updates and deletions — are recorded in the audit log. Every path that accepts a {user_id} segment expects a valid UUID.

GET /users

Returns the complete list of platform users, optionally filtered by a search string. Access is restricted to users with the GENERAL_ADMIN or SUPER_ADMIN role. Each item in the response includes the user’s full profile plus a permissions array listing all of their project memberships. Authentication: Bearer token required. Minimum role: GENERAL_ADMIN.
q
string
Optional case-insensitive search string. Filters results where email or full_name matches %q% (SQL ILIKE). Omit to return all users.
Response — 200 OKList[UserDetailResponse]
id
string (UUID)
Unique identifier of the user.
email
string
User’s email address.
global_role
string
Platform-wide role: SUPER_ADMIN, GENERAL_ADMIN, PROJECT_ADMIN, or VISUALIZER.
full_name
string | null
Display name, or null if not set.
birth_date
string | null
ISO 8601 datetime, or null.
profile_pic_url
string | null
Profile picture URL, or null.
is_public
boolean
Whether the profile is publicly visible.
permissions
array
List of ProjectPermissionResponse objects.
Error responses
StatusMeaning
401 UnauthorizedToken is missing, expired, or invalid.
403 ForbiddenCaller does not have the required role.
curl -X GET "https://api.printheritage.com/users?q=jane" \
  -H "Authorization: Bearer <access_token>"
[
  {
    "id": "f47ac10b-58cc-4372-a567-0e02b2c3d479",
    "email": "jane@example.com",
    "global_role": "VISUALIZER",
    "full_name": "Jane Doe",
    "birth_date": null,
    "profile_pic_url": null,
    "is_public": true,
    "permissions": [
      {
        "id": "a1b2c3d4-0000-0000-0000-000000000001",
        "user_id": "f47ac10b-58cc-4372-a567-0e02b2c3d479",
        "project_id": "c9d8e7f6-0000-0000-0000-000000000002",
        "access_level": "VISUALIZER",
        "status": "ACCEPTED",
        "is_read": true,
        "is_favorite": false,
        "project_name": null,
        "inviter_email": null
      }
    ]
  }
]

PATCH /users/

Updates one or more fields on a user account. Only the fields present in the request body are applied — omitted fields are left unchanged. If password is supplied it is hashed before storage. On success, a USER_UPDATE entry is written to the audit log attributed to the calling user. Authentication: Bearer token required.
user_id
string (UUID)
required
UUID of the user account to update.
Content-Type: application/json — All body fields are optional.
email
string
New email address. Must be a valid email format.
password
string
New password in plain text. Hashed with bcrypt before being stored.
global_role
string
New platform-wide role. One of SUPER_ADMIN, GENERAL_ADMIN, PROJECT_ADMIN, VISUALIZER.
full_name
string
New display name.
birth_date
string
New birth date as an ISO 8601 datetime string.
profile_pic_url
string
New profile picture URL.
is_public
boolean
Update the profile visibility setting.
Response — 200 OKUserResponse
id
string (UUID)
Unique identifier of the updated user.
email
string
Current email address after the update.
global_role
string
Current platform-wide role after the update.
full_name
string | null
Current display name after the update.
birth_date
string | null
Current birth date after the update.
profile_pic_url
string | null
Current profile picture URL after the update.
is_public
boolean
Current profile visibility setting.
Error responses
StatusMeaning
401 UnauthorizedToken is missing, expired, or invalid.
404 Not FoundNo user exists with the given user_id.
curl -X PATCH https://api.printheritage.com/users/f47ac10b-58cc-4372-a567-0e02b2c3d479 \
  -H "Authorization: Bearer <access_token>" \
  -H "Content-Type: application/json" \
  -d '{
    "full_name": "Jane M. Doe",
    "global_role": "PROJECT_ADMIN"
  }'
{
  "id": "f47ac10b-58cc-4372-a567-0e02b2c3d479",
  "email": "jane@example.com",
  "global_role": "PROJECT_ADMIN",
  "full_name": "Jane M. Doe",
  "birth_date": null,
  "profile_pic_url": null,
  "is_public": true
}

DELETE /users/

Permanently deletes a user account. Before removing the user record, the endpoint deletes all ProjectPermission records associated with that user, cleanly removing them from every project. The operation is rejected if the caller attempts to delete their own account. On success, a USER_DELETE entry is written to the audit log. Authentication: Bearer token required.
This action is irreversible. The user and all of their project memberships are permanently removed from the database.
user_id
string (UUID)
required
UUID of the user account to delete. Must not be the same UUID as the authenticated caller.
Response — 200 OK
ok
boolean
Always true when the deletion was successful.
Error responses
StatusMeaning
400 Bad RequestCaller attempted to delete their own account, or the user_id was not found.
401 UnauthorizedToken is missing, expired, or invalid.
curl -X DELETE https://api.printheritage.com/users/f47ac10b-58cc-4372-a567-0e02b2c3d479 \
  -H "Authorization: Bearer <access_token>"
{
  "ok": true
}

GET /users/search

Performs a lightweight user search returning only public-facing profile fields. Intended for use in invitation flows and member-picker UI components. The query must be at least 3 characters long — shorter queries return an empty array immediately without hitting the database.
This endpoint searches only the email field using a case-insensitive ILIKE match. It does not search full_name. Return fewer than 3 characters in q to receive an empty array with no error.
Authentication: Bearer token required.
q
string
required
Search string. Must be at least 3 characters. Shorter values return [] without error.
Response — 200 OK Returns an array of matching user objects. Each item contains only public profile fields.
email
string
Email address of the matching user.
full_name
string | null
Display name, or null if not set.
profile_pic_url
string | null
Profile picture URL, or null if not set.
Error responses
StatusMeaning
401 UnauthorizedToken is missing, expired, or invalid.
curl -X GET "https://api.printheritage.com/users/search?q=jan" \
  -H "Authorization: Bearer <access_token>"
[
  {
    "email": "jane@example.com",
    "full_name": "Jane Doe",
    "profile_pic_url": null
  }
]

GET /users//profile

Returns the public profile of a specific user by their UUID. Unlike GET /users, this endpoint is available to all authenticated users and is intended for viewing member profiles within project contexts. Authentication: Bearer token required.
user_id
string (UUID)
required
UUID of the user whose profile should be returned.
Response — 200 OK
email
string
Email address of the user.
full_name
string | null
Display name, or null if not set.
birth_date
string | null
Birth date as an ISO 8601 datetime, or null if not set.
profile_pic_url
string | null
Profile picture URL, or null if not set.
global_role
string
Platform-wide role of the user: SUPER_ADMIN, GENERAL_ADMIN, PROJECT_ADMIN, or VISUALIZER.
Error responses
StatusMeaning
401 UnauthorizedToken is missing, expired, or invalid.
curl -X GET https://api.printheritage.com/users/f47ac10b-58cc-4372-a567-0e02b2c3d479/profile \
  -H "Authorization: Bearer <access_token>"
{
  "email": "jane@example.com",
  "full_name": "Jane Doe",
  "birth_date": null,
  "profile_pic_url": null,
  "global_role": "VISUALIZER"
}

Build docs developers (and LLMs) love