Thrixel API

Projects & Sources

Projects CRUD and submission management PATCH endpoints.

Group related submissions into projects, give them nicknames, pin favorites, and archive older work. All endpoints below require authentication and act on resources owned by your API key.

Projects


List projects

GET /api/v1/projects

Requires API key.

Returns all projects owned by the authenticated API key.

Query Parameters

NameTypeDescription
include_archivedbooleanInclude archived projects. Default: false.

Example Request

curl -H "Authorization: Bearer sk-thrixel-<YOUR_KEY>" \
  https://api.thrixel.com/api/v1/projects

Example Response

{
  "projects": [
    {
      "id": "p1q2r3s4-...",
      "name": "Gargoyle variations",
      "description": "Stylistic experiments",
      "is_archived": false,
      "created_at": "2026-04-18T09:00:00Z",
      "updated_at": "2026-04-20T14:00:00Z",
      "submission_count": 7
    }
  ],
  "count": 1
}

Create a project

POST /api/v1/projects

Requires API key.

Request Body

NameTypeDescription
namestring (required)Project name. 1–255 characters.
descriptionstringOptional description. Max 2000 characters.

Example Request

curl -X POST https://api.thrixel.com/api/v1/projects \
  -H "Authorization: Bearer sk-thrixel-<YOUR_KEY>" \
  -H "Content-Type: application/json" \
  -d '{"name": "Gargoyle variations"}'

Get a project

GET /api/v1/projects/{project_id}

Requires API key.

Returns project metadata plus an embedded list of its submissions (soft-deleted excluded).

Path Parameters

NameTypeDescription
project_idstring (required)UUID of the project.

Update a project

PATCH /api/v1/projects/{project_id}

Requires API key.

Rename or re-describe. At least one field required.

Path Parameters

NameTypeDescription
project_idstring (required)UUID of the project.

Request Body

NameTypeDescription
namestringNew name. 1–255 characters.
descriptionstringNew description. Max 2000 characters.

Delete a project

DELETE /api/v1/projects/{project_id}

Requires API key.

Permanently deletes the project. Submissions in the project are unlinked (project_id set to null) — they are not deleted.

Path Parameters

NameTypeDescription
project_idstring (required)UUID of the project.

Project Sources


Each project can carry up to 256 KB of plain-text reference material split across files (max 64 KB per file). Allowed extensions: .md, .markdown, .txt, .text. When you submit a new generation inside the project, the parsed text of every source file is injected into the LLM's system prompt — so this is where you put your style guide, glossary of in-world names, dimensions you want respected ("chairs are always 45 cm tall"), or any other context the model should treat as constant.

Use case: building a coherent series

Drop a style.md in a "Gargoyle variations" project that describes your preferred polycount, the materials you want, and the silhouette rules. Every Phase 1 prompt in that project will be evaluated against those constants without you re-typing them.

List source files

GET /api/v1/projects/{project_id}/sources

Requires API key.

Path Parameters

NameTypeDescription
project_idstring (required)UUID of the project.

Example Response

{
  "project_id": "p1q2r3s4-...",
  "sources": [
    {
      "id": "src-9a8b...",
      "project_id": "p1q2r3s4-...",
      "filename": "style.md",
      "mime_type": "text/markdown",
      "size_bytes": 1842,
      "created_at": "2026-04-20T14:00:00Z"
    }
  ],
  "count": 1,
  "total_bytes": 1842
}

total_bytes is the sum across the whole project — useful for checking how much of the 256 KB budget is left before uploading more.


Get a single source

GET /api/v1/projects/{project_id}/sources/{source_id}

Requires API key.

Returns the metadata plus the parsed text of the file (what actually gets injected into the prompt — line endings normalized, content decoded UTF-8).

Path Parameters

NameTypeDescription
project_idstring (required)UUID of the project.
source_idstring (required)UUID of the source file.

Upload a source file

POST /api/v1/projects/{project_id}/sources

Requires API key. multipart/form-data.

The file is parsed at upload time and stored in the database; the raw upload is also mirrored to S3. The parsed content is injected into the system prompt for every new submission created in the project.

Path Parameters

NameTypeDescription
project_idstring (required)UUID of the project.

Form Fields

NameTypeDescription
filefile (required).md, .markdown, .txt, or .text. Max 64 KB per file.

Example Request

curl -X POST https://api.thrixel.com/api/v1/projects/$PROJECT_ID/sources \
  -H "Authorization: Bearer sk-thrixel-<YOUR_KEY>" \
  -F "file=@style.md"

Errors

CodeMeaning
400Empty file, or invalid UTF-8 content.
413File exceeds 64 KB, or the project would exceed 256 KB total.
415Unsupported file extension.

Update a source file

PATCH /api/v1/projects/{project_id}/sources/{source_id}

Requires API key.

Rename or rewrite the file's content. At least one of filename / content must be present. Per-file and per-project caps still apply.

Request Body

NameTypeDescription
filenamestringNew filename including an allowed extension.
contentstringReplacement UTF-8 text.

Delete a source file

DELETE /api/v1/projects/{project_id}/sources/{source_id}

Requires API key.

Removes the DB row and the S3 mirror. Submissions already created in the project are unaffected; only new submissions after this point will see the reduced source set in the system prompt.

Submission Management


Set or clear the nickname

PATCH /api/v1/{submission_id}/nickname

Requires API key.

Path Parameters

NameTypeDescription
submission_idstring (required)UUID of the submission.

Request Body

NameTypeDescription
nicknamestring | nullDisplay label. Pass null to clear. Max 255 characters.

Archive or unarchive

PATCH /api/v1/{submission_id}/archive

Requires API key.

Path Parameters

NameTypeDescription
submission_idstring (required)UUID of the submission.

Request Body

NameTypeDescription
is_archivedboolean (required)true to archive, false to restore.

Toggle visibility

PATCH /api/v1/{submission_id}/visible

Requires API key.

Hides or shows the submission in list endpoints without deleting it.

Path Parameters

NameTypeDescription
submission_idstring (required)UUID of the submission.

Request Body

NameTypeDescription
is_visibleboolean (required)true to show, false to hide.

Pin or unpin

PATCH /api/v1/{submission_id}/pin

Requires API key.

Pinned submissions sort to the top of lists.

Path Parameters

NameTypeDescription
submission_idstring (required)UUID of the submission.

Request Body

NameTypeDescription
is_pinnedboolean (required)true to pin, false to unpin.

Assign to a project

PATCH /api/v1/{submission_id}/project

Requires API key.

Move the submission into a project, or pass null to remove. Both the submission and the target project must belong to your API key.

Path Parameters

NameTypeDescription
submission_idstring (required)UUID of the submission.

Request Body

NameTypeDescription
project_idstring | nullUUID of the target project, or null to unassign.

Soft-delete a submission

DELETE /api/v1/{submission_id}

Requires API key.

Hides the submission from listings but preserves its data. Include soft-deleted items in /submissions via include_deleted=true.

Path Parameters

NameTypeDescription
submission_idstring (required)UUID of the submission.