Pinter
ENID
Reference
View as Markdown

Artifacts and projects

The five artifact kinds, their API, their routes, and how PINTER Space projects moved to the server.

Artifacts replace the old dashboard-only store. One table holds five kinds, and every kind has the same metadata shape, so a list page, a share link, and a desktop deep link work the same way for all of them.

Artifact kinds

kindContentOpened by
dashboardPanels and saved queries in specDashboard renderer on /artefacts/{id}
noteMarkdown in spec.markdownPINTER Desktop editor
visualHTML in spec.htmlPINTER Desktop editor
imageBytes in object storage, mime and size_bytes setDownload
fileBytes in object storage, mime and size_bytes setDownload

image and file never go through POST /api/artifacts; they are created by the upload endpoint and are rejected elsewhere with kind_requires_upload. The API path uses artifact in code. Only user-facing Indonesian text says “Artefak”.

Routes

RouteContents
/artefactsArtifact list.
/artefacts/{artifactId}Artifact detail.
/share/a/{artifactId}Artifact detail through a share link.
/dashboardsRedirects to /artefacts.
/dashboards/{dashboardId}Redirects to /artefacts/{dashboardId}.
/share/dash/{dashboardId}Redirects to /share/a/{dashboardId}.
/spaceProject hub. Desktop renders SpacePage, web renders ProjectsHubPage.

Redirects run in beforeLoad with throw redirect({ to: ... }), never in a useEffect.

pinter://artifact/{id} opens PINTER Desktop on /artefacts/{id}. The id must be a UUID; anything else is ignored instead of crashing the app.

The web detail page shows Buka di PINTER for dashboard, note, and visual. image and file only offer a download.

Projects

Projects moved from the desktop file projects.json to projects rows owned by the API.

  • GET /api/projects, POST /api/projects, GET|PATCH|DELETE /api/projects/{id}.
  • GET|POST /api/projects/{id}/files and DELETE /api/projects/{id}/files/{document_id} link Knowledge Hub documents. A project file is a document link, not a copy.
  • PATCH /api/projects/{id}/share sets internal grants only. Projects have no public link in this release.

Project files feed the chat through three things: a manifest in the system prompt, the search_project_files tool, and @ mentions. Mentions must be resolved from the file slug, because composer mention tokens stop at a space.

Moving desktop projects

POST /api/projects/import takes archived desktop projects and is idempotent on (owner_id, legacy_id):

{
  "projects": [
    {
      "legacy_id": "p-1730",
      "name": "Proyek Pupuk",
      "description": "",
      "instructions": "",
      "conversation_ids": ["c-1", "c-2"]
    }
  ]
}

The response is {"created": 1, "skipped": 0, "id_map": {"p-1730": "uuid"}}. Conversations whose project_id still holds a legacy id are moved to the new UUID, which is why conversations.project_id stays TEXT.

What moves and what does not:

MovesStays behind
Name, description, instructionsAttached local files
Conversation idsEverything under the old Space folder

After a successful import the API is the only writer. PINTER Desktop keeps projects.json as a read-only archive and stores the returned id_map in projects.imported.json, so a rollback needs no file surgery. When the network fails the import writes nothing.

The project Files tab then starts empty, with a Tautkan dari Knowledge Hub action. Old project files are not uploaded and are not reachable from the project until they are linked as Knowledge Hub documents.

Errors

Errors arrive as detail: {"code": "...", "message": "..."}.

CaseStatuscode
Note or visual above 262144 bytes413artifact_too_large
File above 26214400 bytes413file_too_large
User artifact bytes above 1073741824409artifact_quota_exceeded
Extension or mime outside the allowlist415file_type_not_allowed
spec does not match the kind422kind_content_mismatch
POST /api/artifacts with kind image or file422kind_requires_upload
spec change on image or file409kind_immutable
/query or /export on a non-dashboard kind422kind_mismatch
project_id not owned by the caller403project_forbidden
More than 50 project files409project_files_limit
More than 3 mentions or 32768 bytes413mention_too_large