Skip to content

Developer docs

Uploading images

Presigned uploads for reference and edit images.

Input images can be any public https URL. If your images are private, upload them to Poremu first.

1. Ask for an upload slot

text
POST /v1/uploads/presign
{ "contentType": "image/jpeg", "sizeBytes": 418233 }
json
{
  "assetId": "b7…",
  "key": "uploads/…/9f2e….jpg",
  "url": "https://cdn.poremu.ai/uploads/…/9f2e….jpg",
  "upload": { "method": "PUT", "url": "https://poremu-assets.s3….amazonaws.com/…?X-Amz-…", "headers": { "Content-Type": "image/jpeg" } }
}

Accepted types: image/jpeg, image/png, image/webp, up to 20 MB.

2. PUT the bytes

bash
curl -X PUT "$UPLOAD_URL" -H "Content-Type: image/jpeg" --data-binary @photo.jpg

3. Use url as an input image

json
{ "model": "gpt-image", "prompt": "Remove the background, keep soft shadow", "inputImages": ["https://cdn.poremu.ai/uploads/…/9f2e….jpg"] }

Uploads are stored under your account and deleted when you delete the asset (DELETE /v1/assets/{assetId}).