Nodes/Trinetra Image Host Uploader/Trinetra: Upload Image
ComfyUI Node

Trinetra: Upload Image

Your ComfyUI output, as a URL — upload straight from the canvas

By Oratorian·Created 2 months ago·Updated 2 months ago· 0
Trinetra: Upload Image
  • images
  • url
  • all_urls
  • json_report
api_key
base_urlhttps://trinetra.mahesvara.cloud
auth_schemebearer
formatPNG
quality92
folder-1
expiryNever (permanent)
ttl_at
max_attempts6
base_delay_seconds1.0
max_delay_seconds60
timeout_seconds60

So you've rendered something good and now you want to actually show it to someone - paste it in a Discord chat, drop a link in a forum post, or push a preview to a client. ComfyUI's stock SaveImage writes a file to your disk, and that's where it stays. Trinetra: Upload Image is the node that skips the "email me the PNG" step: you wire your IMAGE into it, it pushes the pixels to a hosted image service, and it hands you back a URL.

What this actually is

The node is an HTTP client wearing a ComfyUI costume. It doesn't load a model, doesn't use your GPU, and doesn't call any inference API - this is the upload side of the API-node family. The destination is Trinetra (trinetra.mahesvara.cloud), a small, self-hostable image host with an API-key model; the "mahesvara" in the domain and the "Trinetra" name (Shiva's third eye) tell you this is somebody's personal infrastructure they've opened up. It's not a big-name service, and you need a tri_... key from the Trinetra app's API tab first. No key, dead on arrival - but if you have one, it's a genuinely nice convenience.

The one thing the author clearly sweated over is rate-limit hygiene. Most DIY uploader scripts fire off images and hope. This one honors Retry-After on a 429, retries transient 5xx with exponential backoff plus full jitter, and - the clever part - watches X-RateLimit-Remaining headers and pre-emptively sleeps before it would slam into a wall of 429s mid-batch. Backoff decisions get printed to the ComfyUI console as [Trinetra] ... lines so you can watch it behave. For a batch uploader, that's the difference between "works" and "works on someone else's server."

The inputs that matter

Most of the fields you can ignore until you need them. The ones you'll actually set:

  • images - the IMAGE tensor, single frame or a whole batch. Each frame is uploaded individually and sequentially.
  • api_key - your tri_... key. Plain text, no way around it.
  • format - PNG (default, lossless, keeps alpha), JPEG, or WEBP. Pick JPEG/WEBP to shrink uploads; quality (default 92) applies to those two. Note the nice touch: JPEG flattens alpha over white instead of dumping transparent pixels into a format that can't hold them.
  • expiry - auto-delete: permanent, 1 hour, 6 hours, 1 day, 7 days, 30 days, or "On date..." for a specific time. Set this for throwaway previews, keep it on "Never (permanent)" for anything you might want in six months.

Everything else is genuinely optional. folder puts the upload into a Trinetra folder (a web dropdown of your actual folders replaces the raw number field - -1 means root). auth_scheme swaps Authorization: Bearer for X-API-Key if your host prefers it. base_url exists mainly so the pack works against a self-hosted Trinetra instance instead of the default. The retry knobs - max_attempts, base_delay_seconds, max_delay_seconds, timeout_seconds - are tuned sanely out of the box; leave them alone unless you're banging against a server's limits.

What comes out

Three STRING outputs, all wired from the same run:

  • url - the first uploaded image's URL. What you'll actually use.
  • all_urls - newline-joined URLs for the whole batch.
  • json_report - per-image lines with URL and attempt count, handy for scripting.

Because it's an output node, it also shows the report inline on the node itself, so you can read the URL without dragging a text node around.

Installing it

Zero heavy dependencies - the pack leans only on Pillow and numpy, which already ship with ComfyUI. Either search "Trinetra Image Host Uploader" in ComfyUI Manager, or:

cd ComfyUI/custom_nodes
git clone https://github.com/Oratorian/comfyui-trinetra-imagehost

Restart ComfyUI and the node shows up under image/Trinetra. That's the whole install; there's no model to download.

The trap, and the fix

The security note in the README is worth taking literally: your API key sits on the node as plain text, and it's serialized into the workflow JSON - which then gets embedded into every PNG you save with metadata on, exactly how ComfyUI sharing culture works. A leaked key is someone else's bill. Before you export a workflow or post a saved image, clear the key field and tell the recipient to paste their own. A node that holds a credential and phones home is also, by its nature, the shape of something already weaponized once in this ecosystem - so install from the official repo, not a fork.

The one gotcha that'll actually bite mid-workflow: a 401 (bad key), 400, or 413 (too big) fails fast with the server's own message, so read it. And that ttl_at field is hidden for a reason - only the date picker writes it, so don't hand-type an expiry in there.

Categoryimage/Trinetra

Inputs (13)

NameTypeDefaultDescription
imagesIMAGE
api_keySTRING
base_urloptSTRINGhttps://trinetra.mahesvara.cloud
auth_schemeoptCOMBObearer2 options: bearer, x-api-key
formatoptCOMBOPNG3 options: PNG, JPEG, WEBP
qualityoptINT921–100
folderoptINT-1-1–2147483647
expiryoptCOMBONever (permanent)When the uploaded image auto-deletes. Pick 'On date...' to choose an exact date/time.
ttl_atoptSTRING
max_attemptsoptINT61–15
base_delay_secondsoptFLOAT1.00.1–30
max_delay_secondsoptFLOAT601–600
timeout_secondsoptFLOAT605–600

Outputs (3)

NameTypeDescription
urlSTRING
all_urlsSTRING
json_reportSTRING