Branch #13 docs/api/13-image-templates.md

15. Image Templates & Editor Assets

Branch #13 — Thư viện template ảnh, sample và tài nguyên editor cho content studio.

Endpoints

GET
https://bizgpt.vn/wp-json/bizcity/v1/image-templates

Danh sách template ảnh

Auth: Public

GET
https://bizgpt.vn/wp-json/bizcity/v1/image-templates/{id}

Chi tiết template

Auth: Public

GET
https://bizgpt.vn/wp-json/bizcity/v1/image-samples/{type}

Sample theo loại

Auth: Public

GET
https://bizgpt.vn/wp-json/bizcity/v1/image-editor-assets/{type}

Asset editor

Auth: Public

GET
https://bizgpt.vn/wp-json/bizcity/v1/image-library/manifest

Manifest đồng bộ

Auth: Public

Method Path Auth Mô tả
GET https://bizgpt.vn/wp-json/bizcity/v1/image-templates Public Danh sách template ảnh
GET https://bizgpt.vn/wp-json/bizcity/v1/image-templates/{id} Public Chi tiết template
GET https://bizgpt.vn/wp-json/bizcity/v1/image-samples/{type} Public Sample theo loại
GET https://bizgpt.vn/wp-json/bizcity/v1/image-editor-assets/{type} Public Asset editor
GET https://bizgpt.vn/wp-json/bizcity/v1/image-library/manifest Public Manifest đồng bộ

Query Examples

GET Danh sách template ảnh
curl -X GET "https://bizgpt.vn/wp-json/bizcity/v1/image-templates"
const res = await fetch('https://bizgpt.vn/wp-json/bizcity/v1/image-templates', {
  method: 'GET',
});
const data = await res.json();
console.log(data);
import requests
url = "https://bizgpt.vn/wp-json/bizcity/v1/image-templates"
headers = {}
res = requests.get(url, headers=headers)
print(res.json())
GET Chi tiết template
curl -X GET "https://bizgpt.vn/wp-json/bizcity/v1/image-templates/{id}"
const res = await fetch('https://bizgpt.vn/wp-json/bizcity/v1/image-templates/{id}', {
  method: 'GET',
});
const data = await res.json();
console.log(data);
import requests
url = "https://bizgpt.vn/wp-json/bizcity/v1/image-templates/{id}"
headers = {}
res = requests.get(url, headers=headers)
print(res.json())
GET Sample theo loại
curl -X GET "https://bizgpt.vn/wp-json/bizcity/v1/image-samples/{type}"
const res = await fetch('https://bizgpt.vn/wp-json/bizcity/v1/image-samples/{type}', {
  method: 'GET',
});
const data = await res.json();
console.log(data);
import requests
url = "https://bizgpt.vn/wp-json/bizcity/v1/image-samples/{type}"
headers = {}
res = requests.get(url, headers=headers)
print(res.json())
GET Asset editor
curl -X GET "https://bizgpt.vn/wp-json/bizcity/v1/image-editor-assets/{type}"
const res = await fetch('https://bizgpt.vn/wp-json/bizcity/v1/image-editor-assets/{type}', {
  method: 'GET',
});
const data = await res.json();
console.log(data);
import requests
url = "https://bizgpt.vn/wp-json/bizcity/v1/image-editor-assets/{type}"
headers = {}
res = requests.get(url, headers=headers)
print(res.json())
GET Manifest đồng bộ
curl -X GET "https://bizgpt.vn/wp-json/bizcity/v1/image-library/manifest"
const res = await fetch('https://bizgpt.vn/wp-json/bizcity/v1/image-library/manifest', {
  method: 'GET',
});
const data = await res.json();
console.log(data);
import requests
url = "https://bizgpt.vn/wp-json/bizcity/v1/image-library/manifest"
headers = {}
res = requests.get(url, headers=headers)
print(res.json())

Use Cases

  • Dựng dây chuyền sản xuất content ảnh theo template.
  • Đồng bộ asset cho nhiều editor/client site.
  • Tăng tốc workflow design marketing nội bộ.

Implementation Steps

  1. Đọc manifest để biết phiên bản thư viện hiện tại.
  2. Sync local cache theo version/hash.
  3. Gọi image generation để render output cuối.

Quick Start cURL

bash
curl -X GET "https://bizgpt.vn/wp-json/bizcity/v1/image-templates?category=campaign&per_page=12"
Canonical Spec

docs/api/13-image-templates.md