Agent ingest
Use this guide when an agent, automation, or external service needs to send images into Pindeck from another system. The common path is:- Find a public image URL.
- Build a stable
externalIdfor deduplication. - Send the image to
/ingestExternal. - Let Pindeck persist the file to RustFS, create the image record, extract colors, and put moderated sources into review.
Endpoint
Required fields
| Field | Description |
|---|---|
imageUrl | Public URL that Pindeck can download. |
userId | Pindeck user id that owns the imported image. |
Recommended fields
| Field | Description |
|---|---|
sourceType | Use discord, pinterest, upload, or ai. Moderated sources such as discord and pinterest enter review before publishing. |
externalId | Stable idempotency key, such as pinterest:<board-id>:<pin-id> or discord:<guild-id>:<message-id>:<attachment-id>. |
sourceUrl | Original page, pin, post, or message URL. |
title | Human-readable title. |
description | Short context for search and review. |
tags | Array of searchable tags. |
category | Broad classification, usually General when unknown. |
importBatchId | Optional batch id for grouping one automation run. |
sref | Style reference id when the import came from an SREF workflow. |
Minimal request
imageId and resolved userId.
JavaScript agent example
Moderated sources
Images withsourceType set to discord or pinterest are created as draft/moderated imports. They are available to the review workflow before becoming active in the main library.
For Discord-specific review tooling, use /discordQueue to list queued items and /discordModerate to approve, reject, or generate variations for a queued image.
Integration checklist
- Use
externalIdon every automated import. - Keep
INGEST_API_KEYserver-side only. - Use a source-specific
importBatchIdfor scheduled sync jobs. - Send
sourceUrlso reviewers can trace where an image came from. - Prefer direct image URLs that do not require browser cookies.
- Retry
502responses with backoff; they can mean the upstream image host or RustFS persistence step failed.