ข้ามไปยังเนื้อหา

FLUX.2 [dev]

ผสานการทำงาน

ID โมเดล flux-2
# Run the model; wait up to 20 s for the finished result in the same call
curl -X POST "https://api.doitong.com/v1/run/flux-2?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "prompt": "Ultra-stylized high-fashion editorial poster of a confident young Asian female model standing in the center frame, elegant pose, glossy radiant skin, soft dewy makeup, long silky black hair with wispy bangs, wearing modern trendy K-fashion streetwear with premium styling details. Clean studio lighting with high-contrast fashion flash photography, sharp focus, ultra-detailed textures, cinematic composition. Background filled with vibrant retro pop-art magazine aesthetics, layered graphic typography, dynamic UI-inspired design elements, holographic chrome effects, stickers (stars, hearts, sparkles), barcode strips, speech bubbles, and futuristic collage layering. Japanese and Korean-inspired typographic accents integrated as visual design elements. Overall mood combines nostalgic 2000s teen fashion magazine energy with modern luxury editorial campaign style. Bold color harmony, premium print aesthetic, ultra crisp details, fashion advertising quality, 8K resolution, highly polished commercial poster look, surreal yet stylish, trend-forward global fashion branding vibe."
  }'

# Still "queued" or "running"? Poll with the id from the response:
curl "https://api.doitong.com/v1/requests/REQUEST_ID?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY"

คำขอนี้: $0.012 12 เครดิต API เรียกใช้ในหน้านี้

รับคีย์ API
Black Forest Labs ข้อความเป็นภาพ #open-weights#budget#versatile

โมเดล FLUX แบบโอเพนรุ่นที่สอง ซึ่งทำตามพรอมต์ได้ดีขึ้นในราคาต่อเมกะพิกเซลต่ำ

ตัวอย่าง

เอาต์พุต · ~12 s
Ultra-stylized high-fashion editorial poster of a confident young Asian female model standing in the center frame, el...

พรอมต์Ultra-stylized high-fashion editorial poster of a confident young Asian female model standing in the center frame, elegant pose, glossy radiant skin, soft dewy makeup, long silky black hair with wispy bangs, wearing modern trendy K-fashion streetwear with premium styling details. Clean studio lighting with high-contrast fashion flash photography, sharp focus, ultra-detailed textures, cinematic composition. Background filled with vibrant retro pop-art magazine aesthetics, layered graphic typography, dynamic UI-inspired design elements, holographic chrome effects, stickers (stars, hearts, sparkles), barcode strips, speech bubbles, and futuristic collage layering. Japanese and Korean-inspired typographic accents integrated as visual design elements. Overall mood combines nostalgic 2000s teen fashion magazine energy with modern luxury editorial campaign style. Bold color harmony, premium print aesthetic, ultra crisp details, fashion advertising quality, 8K resolution, highly polished commercial poster look, surreal yet stylish, trend-forward global fashion branding vibe.

$0.012 · 12 เครดิต API

พรอมต์จาก @SadiaMalik182 บน X

สร้างคำขอ

ตัวควบคุมสร้างจากสคีมาของโมเดล โค้ดและราคาจะอัปเดตเมื่อคุณเปลี่ยนค่า

•จำเป็น

พรอมต์ที่กำกับการสร้างรูปภาพ

image_size ค่าเริ่มต้น landscape_4_3

ขนาดรูปภาพเอาต์พุต จำกัดขั้นต่ำที่ 512 และสูงสุดที่ 2048 พิกเซลในแต่ละแกน

num_images ค่าเริ่มต้น 1

จำนวนรูปภาพที่ขอให้สร้าง

ขั้นสูง acceleration · output_format · guidance_scale · num_inference_steps · seed · enable_prompt_expansion
acceleration ค่าเริ่มต้น regular

การตั้งค่าการเร่งความเร็วสำหรับการสร้างรูปภาพ

output_format ค่าเริ่มต้น png

รูปแบบไฟล์ของรูปภาพผลลัพธ์

ค่าเริ่มต้น 2.5

การตั้งค่าการทำตามพรอมต์สำหรับการค้นหารูปภาพที่เกี่ยวข้องเพื่อแสดง โดยแสดงเป็นสเกลการแนะนำ

ค่าเริ่มต้น 28

จำนวนขั้นตอน inference ที่ต้องดำเนินการ

การแทนที่ค่าเริ่มต้นการสร้าง หากไม่ระบุ การสร้างจะเลือกค่าเริ่มต้นแบบสุ่ม

POST /run/flux-2?wait=20 ใบเสนอราคา → $0.012
# Run the model; wait up to 20 s for the finished result in the same call
curl -X POST "https://api.doitong.com/v1/run/flux-2?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "prompt": "Ultra-stylized high-fashion editorial poster of a confident young Asian female model standing in the center frame, elegant pose, glossy radiant skin, soft dewy makeup, long silky black hair with wispy bangs, wearing modern trendy K-fashion streetwear with premium styling details. Clean studio lighting with high-contrast fashion flash photography, sharp focus, ultra-detailed textures, cinematic composition. Background filled with vibrant retro pop-art magazine aesthetics, layered graphic typography, dynamic UI-inspired design elements, holographic chrome effects, stickers (stars, hearts, sparkles), barcode strips, speech bubbles, and futuristic collage layering. Japanese and Korean-inspired typographic accents integrated as visual design elements. Overall mood combines nostalgic 2000s teen fashion magazine energy with modern luxury editorial campaign style. Bold color harmony, premium print aesthetic, ultra crisp details, fashion advertising quality, 8K resolution, highly polished commercial poster look, surreal yet stylish, trend-forward global fashion branding vibe."
  }'

# Still "queued" or "running"? Poll with the id from the response:
curl "https://api.doitong.com/v1/requests/REQUEST_ID?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY"

เรียกใช้คำขอนี้

คีย์ของคุณจะอยู่ในเบราว์เซอร์นี้ โดยส่งไปยัง Doitong API เท่านั้น และจะบันทึกใน localStorage ก็ต่อเมื่อคุณเลือกจดจำ รับคีย์ API

สร้างบน Doitong

ผลงานสาธารณะที่สร้างด้วย Flux 2 โดยชุมชน Doitong นำพรอมต์กลับมาใช้ได้ในคลิกเดียว

ผลงานสาธารณะที่แสดง: 9
Close-up portrait seorang wanita berkulit pucat berdiri setengah tubuh di dalam air berwarna lemb...

Close-up portrait seorang wanita berkulit pucat berdiri setengah tubuh di dalam air berwarna lembut kebiruan, dikelilingi bunga teratai berkelopak penuh yang bermekaran indah di permukaan air. Rambutnya pirang pucat tersanggul longgar dengan beberapa helaian tipis jatuh alami membingkai sisi...

Close-up portrait seorang wanita berkulit pucat berdiri setengah tubuh di dalam air berwarna lemb...

Close-up portrait seorang wanita berkulit pucat berdiri setengah tubuh di dalam air berwarna lembut kebiruan, dikelilingi bunga teratai berkelopak penuh yang bermekaran indah di permukaan air. Rambutnya pirang pucat tersanggul longgar dengan beberapa helaian tipis jatuh alami membingkai sisi...

Prompt Details Seorang wanita berkulit pucat berdiri setengah tubuh di dalam air berwarna lembut ...

Prompt Details Seorang wanita berkulit pucat berdiri setengah tubuh di dalam air berwarna lembut kebiruan, dikelilingi bunga teratai berkelopak penuh yang bermekaran indah di permukaan air. Rambutnya pirang pucat tersanggul longgar dengan beberapa helaian tipis jatuh alami membingkai sisi...

Seorang wanita berkulit pucat berdiri setengah tubuh di dalam air berwarna lembut kebiruan, dikel...

Seorang wanita berkulit pucat berdiri setengah tubuh di dalam air berwarna lembut kebiruan, dikelilingi bunga teratai berkelopak penuh yang bermekaran indah di permukaan air. Rambutnya pirang pucat tersanggul longgar dengan beberapa helaian tipis jatuh alami membingkai sisi wajahnya. Ia memeluk...

​"Potret sinematik ultra-realistis close-up seorang anak laki-laki kecil (balita) yang sangat men...

​"Potret sinematik ultra-realistis close-up seorang anak laki-laki kecil (balita) yang sangat menggemaskan dengan mata cokelat besar yang ekspresif, rambut hitam berantakan yang tebal, mengenakan kaus putih kerah henley. Dia berpose dengan kedua tangan terkatup di depan dada, menunjukkan senyum...

​"Potret sinematik ultra-realistis close-up seorang anak laki-laki kecil (balita) yang sangat men...

​"Potret sinematik ultra-realistis close-up seorang anak laki-laki kecil (balita) yang sangat menggemaskan dengan mata cokelat besar yang ekspresif, rambut hitam berantakan yang tebal, mengenakan kaus putih kerah henley. Dia berpose dengan kedua tangan terkatup di depan dada, menunjukkan senyum...

​"Potret sinematik ultra-realistis close-up seorang anak laki-laki kecil (balita) yang sangat men...

​"Potret sinematik ultra-realistis close-up seorang anak laki-laki kecil (balita) yang sangat menggemaskan dengan mata cokelat besar yang ekspresif, rambut hitam berantakan yang tebal, mengenakan kaus putih kerah henley. Dia berpose dengan kedua tangan terkatup di depan dada, menunjukkan senyum...

Foto sinematik hiper-realistis resolusi tinggi menampilkan seorang pria muda Indonesia dengan tub...

Foto sinematik hiper-realistis resolusi tinggi menampilkan seorang pria muda Indonesia dengan tubuh ramping dan proporsional, rambut hitam pendek agak acak, mengenakan jaket kulit hitam, celana riding fit, dan sepatu motor. Ia sedang melakukan aksi freestyle ekstrem dengan motor sport 500cc...

เกี่ยวกับ FLUX.2 [dev]

สมาชิกแบบโอเพนเวตของตระกูล FLUX.2 เมื่อเทียบกับ FLUX.1 โมเดลนี้รักษาองค์ประกอบ วัสดุ และคำสั่งด้านแสงได้แม่นยำยิ่งขึ้น และสามารถขยายพรอมต์สั้น ๆ ก่อนสร้างภาพได้ตามต้องการ เลือกขนาดจากพรีเซ็ตหรือกำหนดเอง ใช้ขั้นตอนการสุ่มตัวอย่าง 4 ถึง 50 ขั้นตอน และสร้างภาพได้สูงสุดสี่ภาพต่อคำขอ เอาต์พุตเป็น PNG, JPEG หรือ WebP

พารามิเตอร์

ส่งชื่อมาตรฐานหรือชื่อดั้งเดิมอย่างใดอย่างหนึ่งเท่านั้น ห้ามส่งทั้งสองชื่อ ชื่อมาตรฐาน

ชื่อประเภท ค่าเริ่มต้นค่าที่อนุญาต คำอธิบาย
promptจำเป็น
ประเภทstring
พรอมต์ที่กำกับการสร้างรูปภาพ
guidance_scaleไม่บังคับ
ประเภทnumber
ค่าเริ่มต้น2.5
0 – 20
การตั้งค่าการทำตามพรอมต์สำหรับการค้นหารูปภาพที่เกี่ยวข้องเพื่อแสดง โดยแสดงเป็นสเกลการแนะนำ
seedไม่บังคับ
ประเภทinteger | null
การแทนที่ค่าเริ่มต้นการสร้าง หากไม่ระบุ การสร้างจะเลือกค่าเริ่มต้นแบบสุ่ม
num_inference_stepsไม่บังคับ
ประเภทinteger
ค่าเริ่มต้น28
4 – 50
จำนวนขั้นตอน inference ที่ต้องดำเนินการ
image_sizeไม่บังคับ
ประเภทobject
ค่าเริ่มต้นlandscape_4_3
square_hdsquareportrait_4_3portrait_16_9landscape_4_3landscape_16_9
ขนาดรูปภาพเอาต์พุต จำกัดขั้นต่ำที่ 512 และสูงสุดที่ 2048 พิกเซลในแต่ละแกน
num_imagesไม่บังคับ num_outputs
ประเภทinteger
ค่าเริ่มต้น1
1 – 4
จำนวนรูปภาพที่ขอให้สร้าง
accelerationไม่บังคับ
ประเภทenum
ค่าเริ่มต้นregular
noneregularhigh
การตั้งค่าการเร่งความเร็วสำหรับการสร้างรูปภาพ
enable_prompt_expansionไม่บังคับ
ประเภทboolean
ค่าเริ่มต้นfalse
การปรับปรุงพรอมต์อัตโนมัติ: true จะเปิดใช้การขยายพรอมต์เพื่อปรับปรุงผลลัพธ์
output_formatไม่บังคับ
ประเภทenum
ค่าเริ่มต้นpng
jpegpngwebp
รูปแบบไฟล์ของรูปภาพผลลัพธ์
จำเป็น ชื่อมาตรฐาน ซึ่งรองรับเช่นกัน

เอาต์พุต

GET /requests/req_8k2m4q7x1z9c3v5b6n0p2r4t
{
  "id": "req_8k2m4q7x1z9c3v5b6n0p2r4t",
  "object": "request",
  "model": "flux-2",
  "status": "succeeded",
  "created_at": "2026-10-20T12:00:00Z",
  "started_at": "2026-10-20T12:00:02Z",
  "completed_at": "2026-10-20T12:00:09Z",
  "queue_position": null,
  "cost": {
    "credits": 12,
    "usd": "0.012",
    "charged": 12,
    "refunded": 0
  },
  "input": {
    "prompt": "Dutch angle close-up of a mountain climber at dawn, frost on the beard, dramatic rim light, gritty realism",
    "image_size": "landscape_16_9"
  },
  "output": {
    "images": [
      {
        "url": "https://content.doitong.com/dev-api/2026/10/20/req_8k2m4q7x1z9c3v5b6n0p2r4t/0-output.jpeg",
        "content_type": "image/jpeg",
        "file_name": "0-output.jpeg",
        "file_size": 1843200,
        "width": 1024,
        "height": 768
      }
    ],
    "timings": {},
    "seed": 42,
    "has_nsfw_concepts": [
      false
    ],
    "prompt": "string"
  },
  "outputs": [
    {
      "type": "image",
      "url": "https://content.doitong.com/dev-api/2026/10/20/req_8k2m4q7x1z9c3v5b6n0p2r4t/0-output.jpeg",
      "content_type": "image/jpeg",
      "file_size": 1843200,
      "width": 1024,
      "height": 768,
      "stored": true
    }
  ],
  "error": null,
  "metrics": {
    "inference_seconds": 6.8
  },
  "urls": {
    "self": "https://api.doitong.com/v1/requests/req_8k2m4q7x1z9c3v5b6n0p2r4t",
    "cancel": "https://api.doitong.com/v1/requests/req_8k2m4q7x1z9c3v5b6n0p2r4t/cancel"
  }
}
ไฟล์ของคุณ คุณเลือกเองทุก outputs[].url คือสำเนาบนพื้นที่จัดเก็บของเรา: เก็บไว้ตลอดไป (คิดค่าบริการต่อ GB-เดือน) หรือฟรี 7 วัน โดยกำหนดได้ในการตั้งค่าบัญชีหรือ ?storage=
รูปแบบเดียวกันในทุกโมเดลtype, url, content_type, width, height และ duration สำหรับภาพ วิดีโอ และเสียงเหมือนกันทั้งหมด ส่วน output คือออบเจ็กต์ผลลัพธ์ของโมเดลเอง
ฟิลด์ของเอาต์พุต
images
array of object {url, content_type, file_name, file_size, width, height}รูปภาพที่โมเดลสร้าง
timings
object
seed
integerseed สำหรับการสร้างรูปภาพ รวมถึงค่าที่สุ่มเลือกหากอินพุตไม่ได้ระบุ seed มิฉะนั้นจะใช้ค่าที่ระบุซ้ำ
has_nsfw_concepts
array of booleanระบุว่ามีแนวคิด NSFW ปรากฏในรูปภาพที่สร้างหรือไม่
prompt
stringพรอมต์ที่ใช้ระหว่างการสร้างรูปภาพ

โมเดลเพิ่มเติม: ข้อความเป็นภาพ

สำหรับเอเจนต์ AI: หน้า Markdown นี้อยู่ที่ https://doitong.com/th/developers/models/flux-2.md. โมเดลและคู่มือทั้งหมด: https://doitong.com/developers/llms.txt