Skip to content

Đọc catalog ​

Mọi field job media (ratio, mode, resolution, duration, model id) phải lấy từ POST https://v2.api.gommo.net/ai/models?type=…. Trang này giải thích JSON trước create + poll.

BướcDoc
List + chọn fieldTrang này
Tham sốParameters
HTTP create/pollMedia & jobs · Hướng dẫn tích hợp
Xem liveModels catalog

Không đoán enum

Copy từ docs, model khác, hoặc screenshot sẽ fail upstream. Luôn dùng response list của model đó.

Gọi catalog ​

http
POST https://v2.api.gommo.net/ai/models?type=image
Authorization: Bearer {access_token}
Content-Type: application/x-www-form-urlencoded

type=image&domain=%REGISTRATION_DOMAIN%

type theo job types. domain đăng ký user — Authentication.

Shape response (điển hình) ​

json
{
  "success": true,
  "data": [
    {
      "model": "example_slug",
      "name": "Tên hiển thị",
      "ratios": [{ "value": "1:1", "label": "Square" }],
      "modes": [{ "value": "low", "label": "Low" }],
      "resolutions": [{ "value": "2k", "label": "2K" }]
    }
  ]
}

Không phải model nào cũng có mọi mảng — bỏ field không có trong row.

Chọn model id (URL create) ​

POST …/ai/jobs/{type}/{model_id} — JSON có thể là model, slug, model_id, id_base.

Đọc ratios, modes, resolutions, duration ​

CatalogForm jobCách đọc
ratios[]ratioThường { value, label } — gửi value
modes[]modeGiống ratios
resolutions[]resolutionGiống ratios
durationsdurationVideo/nhạc — chỉ giây trong list
—promptApp của bạn

TypeScript: SDK lộ trình 5 phút.

Model tool / đặc biệt ​

Upscale, remove-bg… có thể dùng url, image thay prompt. Xem row model và Playground.

Mô tả tiếng Anh (?lang=en) ​

Cache mô tả EN không thay thế validation enum — ratio/mode vẫn từ POST /ai/models. Maintainer: doc/CATALOG-TEST.md.

Sau khi có slug + field ​

  1. Create — Media reference
  2. Poll — Vòng đời request
  3. Lỗi — Lỗi thường gặp

Tiếp theo ​

→ Parameters · Job types · Quickstart