Skip to main content

Overview

Tencent Hunyuan Hy-Image 3.5 Preview (official model ID hy-image-v3.5-preview) is a preview image-generation model released by Tencent Hunyuan on 2026-09-22 (UTC+8). The native API uses a Chat/Messages protocol and supports text-to-image, reference-image generation, multi-turn editing, chain-of-thought rewriting, and search augmentation, with output up to 4096×4096 (4K). APIYI offers two fixed-resolution models through the Tencent Cloud official channel (official relay), both on the same OpenAI Images-compatible endpoint:
  • hy-image-v3.5-preview-2k: fixed 2048×2048, $0.022 per image
  • hy-image-v3.5-preview-4k: fixed 4096×4096, $0.030 per image
The official price is ¥0.15 per image for 1K/1.5K/2K and ¥0.20 for 4K. APIYI converts at a fixed 1:7 exchange rate and pins the output to 2K or 4K, so billing stays simple and the 2K model delivers the highest resolution in the official same-price tier.
🎨 Highlights: fixed 2K/4K output (-2k at 2048×2048, -4k at 4096×4096, regardless of size), accurate Chinese text rendering (poster titles, dates, and locations), multi-reference generation (the images array accepts URLs or data URIs), flat per-image pricing (reference count and response format do not add cost), and official price parity (fixed 1:7 conversion). Built for posters, e-commerce hero images, film assets, and social media visuals.
📌 Four things to know before you start
  1. Use /v1/images/generations (JSON) as the primary path. The multipart /v1/images/edits endpoint still works, but it only outputs 1536×1536 and does not use the 2K/4K override. It is not recommended.
  2. Do not pass size. -2k is fixed at 2048×2048 and -4k at 4096×4096. Values such as 1024x1024, 4096x4096, or invalid strings are all overridden by the model’s fixed resolution.
  3. Use the images array for reference images. The legacy image field goes through the edit path and outputs only 1536×1536 without size. Pass size explicitly for 2K/4K, but billing is still the model’s flat price.
  4. Responses default to b64_json. A 2K image is roughly 6–10 MB and a 4K image 20–26 MB after base64 encoding. Pass response_format: "url" to receive a CDN URL instead.

Text-to-Image API

POST /v1/images/generations generates 2K/4K images from a prompt, with an interactive Playground.

Reference-Image API

Pass 1–20 reference images in the images array with an instruction; output stays fixed at 2K/4K.

Agent Skill

Package Hunyuan image generation as a drop-in Agent Skill for Codex, Claude Code, or Cursor.

FAQ

images vs image, default base64, 4K timeouts, billing, and error codes.

Let an AI Agent Do the Integration

Copy this prompt and paste it into Codex / Claude Code / Cursor

It first fetches the plain-text version of this page (append .md to any docs URL), then writes code for your stack. It already accounts for the high-frequency traps: size is overridden, images and image produce different output sizes, default responses are large base64 payloads, and 4K needs a longer timeout.

Help me integrate / troubleshoot Tencent Hunyuan Hy-Image 3.5 Preview text-to-image and reference-image generation in this project.

Read the docs first: fetch https://docs.apiyi.com/en/api-capabilities/hunyuan-image/overview.md for the plain-text version of this page. For parameter details, append .md to the text-to-image and image-edit pages as well.

  1. Model IDs: hy-image-v3.5-preview-2k (fixed 2048×2048) or hy-image-v3.5-preview-4k (fixed 4096×4096). Do not pass size; it is overridden anyway.

10 requirements in total. Use the button below to copy the full prompt.

Why APIYI’s Hunyuan Hy-Image 3.5?

Tencent Cloud official relay

The same model as hy-image-v3.5-preview on Tencent Cloud TokenHub, exposed through the standard /v1/images/generations endpoint with an OpenAI Images-compatible response shape.

Official parity at 1:7

The official ¥0.15 / ¥0.20 prices convert to $0.022 / $0.030 at a fixed 1:7 exchange rate with no markup. Top-up bonuses stack on top.

Fixed 2K / 4K, simple billing

Two models pin the output at 2048×2048 and 4096×4096 and charge a flat per-image price. No pixel, area, or reference-count math.

Global access, no Tencent account

No Tencent Cloud account or overseas server required. Call api.apiyi.com from mainland China data centers, residential networks, or overseas nodes with one key.

A complete image stack

Hands-on support

The team knows Chinese visual production workflows for posters, e-commerce, and film assets, and supports everything from model selection to production rollout.

Key Features

Fixed 2K / 4K output

-2k always returns 2048×2048 and -4k always returns 4096×4096. Pick a model; no size math required.

Chinese text rendering

Poster titles, dates, locations, and signage come out character-accurate, ideal for Chinese movie posters, e-commerce hero images, and campaign assets.

Reference-image generation

The images array accepts 1–20 references as URLs or data URIs. Style transfer, composition preservation, and multi-image fusion are supported.

Multi-reference input

Send several references at once and refer to them as “image 1 / image 2” in the prompt. Reference count does not change the price.

Base64 by default, URL on request

Default responses are data[0].b64_json for server-side saving; pass response_format: "url" for a platform CDN URL suitable for web display.

OpenAI Images compatible

Call with model and prompt from Python, Node, or cURL. No need to learn Tencent’s native Chat/Messages protocol.

Synchronous responses

One request returns the image directly; no task submission, polling, or callbacks. Measured 2K latency is about 18–35 seconds and 4K about 45–58 seconds.

Flat per-image pricing

size, response_format, reference count, and actual output dimensions do not affect the price. Budget per image.

Sample Outputs

Chinese text rendering (hy-image-v3.5-preview-2k, prompt asks for the title “Between Mountains and Seas” and the subtitle “November 24, 2026, Beijing Premiere”):
Hunyuan Hy-Image 3.5 Preview Chinese movie poster sample with accurate title and date text
Reference-image watercolor (hy-image-v3.5-preview-2k, images receives a red circle and blue square reference, prompt asks to preserve composition):
Hunyuan Hy-Image 3.5 Preview reference-image sample: red circle and blue square restyled as watercolor

Pricing

Flat per-image pricing. The model list price matches the official list item by item at the 1:7 fixed exchange rate; the effective price depends on top-up bonuses:
Pricing follows the official list and may change. The table is for reference only; the Model Pricing tab in the top navigation is authoritative: Model Pricing.
List price vs effective price
  • List price matches the official list: ¥0.15 / ¥0.20 convert to $0.022 / $0.030 at the 1:7 fixed rate, with no markup.
  • The discount lives in top-up bonuses: current top-up bonuses bring the effective price to about 83–91% of list (17–9% off). This is a platform top-up benefit, not a model price cut, and it is not reflected in the model’s unit price.
  • Live terms come from the promotion page: see Top-up Bonuses for current tiers, validity, and stacking rules.
  • Flat per image, not per pixel: -2k and -4k each have a fixed price. size and actual output dimensions do not change it.
  • References are free: 1 or 20 reference images cost the same. Multipart edits bill at the same model price.
  • Failures are not billed: 400 / 401 / 500 / 503 errors produce no image and no charge; usage is a placeholder.

Group Setup

This series is available in the Default and SVIP groups, both at 1.0x. A new Token can call it directly; no dedicated group is required.
Token billing model: both Pay-as-you-go Priority and Pay-per-request work. We recommend Pay-as-you-go Priority so the same Token also covers token-billed models.Rate: two concurrent 2K requests completed normally in testing (23–35 seconds each). For large batches, send concurrent requests and watch for 429s; contact support in advance if you need more capacity.

Technical Specs

API Endpoints

Domains: api.apiyi.com is the primary domain. Other platform gateways such as b.apiyi.com behave identically.

Key Parameters

Size: fixed by model, do not pass size

size only works on the legacy image edit path. With the recommended images field, an explicit 1024x1024 is overridden to 2048×2048. The same applies to text-to-image. Choose -2k or -4k instead of trying to switch resolution with size.

Reference images: images, image, and multipart

Both reference styles bill at the model’s flat price. The legacy image field costs the same as -2k / -4k even when it returns only 1536×1536. Use images consistently.

response_format

  • Omitted: data[0].b64_json (plain base64, no data: prefix).
  • "url": data[0].url on hdcdn.agisuitepro.com. Works in <img>; HEAD returns 200, CORS preflight returns 403.
  • Invalid values (such as "webp"): silently fall back to b64_json. Do not rely on them.

Best Practices

1

Pick the model by use case

Use hy-image-v3.5-preview-2k for web images, social media, and general posters. Use hy-image-v3.5-preview-4k for print, film assets, and heavy cropping. Only the model name changes.
2

Do not pass size or n

size is overridden and n is fixed at 1. For multiple images, send concurrent requests. Two concurrent 2K requests completed normally in testing.
3

Use images for references

One reference: images: ["https://..."]. Multiple: images: ["url1", "url2"]. Convert local files to data:image/png;base64,.... Avoid image, which returns only 1536.
4

Quote text that must appear

Put text in quotes and state its position: main title “Between Mountains and Seas” centered, subtitle “November 24, 2026, Beijing Premiere”. The model follows quoted text closely.
5

Use URL mode for the web

A 4K base64 response can reach 26 MB. For web display, pass response_format: "url" and let <img> load the CDN image. Use the default base64 for server-side file writes.
6

Set timeouts by tier

Use at least 120 seconds for 2K, 240 seconds for 4K, and 360 seconds for 4K base64. Raise reverse-proxy and serverless response-size limits to at least 30 MB.
7

Do not retry moderation blocks

Content moderation returns 400 content_safety_violation. This is deterministic; rewrite the prompt instead of retrying.
8

Compress reference images

Keep each reference under 20MB. Resize the long edge to 2048px and use quality 0.9 before upload to reduce transfer and processing time.

Error Codes & Retries

Client guidance:
  • Use a timeout of ≥120s for 2K and ≥240s for 4K (360s for 4K base64).
  • Retry only 429s, network timeouts, and deterministic 5xx errors with exponential backoff. Do not retry moderation 400s.
  • Log x-oneapi-request-id and the response id for troubleshooting.
  • The API is synchronous: a client disconnect loses the result but the request is usually still billed. Set generous timeouts.

FAQ

-2k always outputs 2048×2048 and -4k always outputs 4096×4096. The endpoint, parameters, and reference-image behavior are identical; only the model name changes. The official 1K/1.5K/2K price is the same, so -2k gives the best value in that tier. See the FAQ.
Both models override size: -2k is fixed at 2048×2048 and -4k at 4096×4096. size only works on the legacy image edit path; the recommended images path is also overridden.
The default is response_format: "b64_json" and the image is in data[0].b64_json. Pass response_format: "url" to receive a stable URL on hdcdn.agisuitepro.com. A 4K base64 response can reach 26 MB, so use URL mode for web display.
images is the recommended JSON array and returns fixed 2K/4K. image is the legacy edit path and returns only 1536×1536 without size. Both bill at the model’s flat price; use images for all new integrations.
The model always returns exactly one image. n has no effect and you are billed once. Send concurrent requests for multiple images.
Measured 4K text-to-image latency is 45–58 seconds. The PNG is 12.6–18.9 MB and the base64 response is 17.6–26.4 MB. Use a timeout of at least 240 seconds (360 seconds for base64) and raise response-size limits.
Tencent Hunyuan Hy-Image 3.5 Preview is a preview model; Tencent may change its behavior or retire it at any time. Keep a fallback image model for production. APIYI follows the official channel, and pricing and groups are governed by the Model Pricing tab.