通过
您的应用创作。
Prepare server-side integrations for text-to-image and text-to-video generation. API sales are activated separately by the administrator. Customers fund a separate prepaid API wallet through Stripe in MYR; model, resolution and duration determine consumption.
商业用途和 API 许可
使用您的私有后端集成构建您自己的付费 SaaS 或应用程序。您可以对您的应用程序和生成的交付物收费。禁止销售 API 密钥、原始 API 访问或直通 API 网关。阅读并接受 API 条款 创建密钥时。
1. 准备您的账户
Sign in, complete any required password change, fund your API wallet when checkout opens, and create a key in Settings → Developer API keys. Keep keys on your server and send Authorization: Bearer YOUR_STUDIO_API_KEY。切勿将密钥放入前端代码中。
2. 选择并报价
GET /api/v1/models 列出可用的模型 ID、原生格式、分辨率和持续时间。 POST /api/v1/quote returns required credits and their nominal RM equivalent. One API credit is RM0.10 before SST; Studio credits are separate. Use the same settings when submitting.
GET /api/v1/balance returns your available API-only prepaid credits.
3. 提交一次生成
POST /api/v1/generations 接受包含模型、格式、分辨率、提示和视频 duration_seconds 的 JSON 正文。包含一个唯一的 Idempotency-Key 标题,8–100个字母、数字、下划线或连字符。使用相同的密钥和未更改的正文重试不确定的请求,以防止重复提交。
{
"model": "MODEL_ID_FROM_MODELS_ENDPOINT",
"format": "FORMAT_VALUE_FROM_MODELS_ENDPOINT",
"resolution": "RESOLUTION_FROM_MODELS_ENDPOINT",
"prompt": "A premium product photograph with warm studio lighting"
}4. 追踪和下载
投票 GET /api/v1/generations/JOB_ID。完成后,下载 GET /api/v1/generations/JOB_ID/asset 使用相同的 Bearer 密钥。资产 URL 需要身份验证;在将其提供给客户之前,请在您的后端下载它们。
API pricing tiers
Standard API pricing targets 30% gross margin on provider cost. Approved volume accounts receive 20% when verified prepaid funding meets their agreed minimum in the preceding 30 days. Approval and the minimum are set by Admin; funding alone does not grant a discount. Otherwise standard pricing applies. Additional storage, priority support or custom work requires a separate agreement. Studio keeps its existing pricing and wallet.
限制和账单
报价不预留积分。提交会检查当前价格、账户访问权限、预付余额和服务预算。成功提交会预留积分;失败的生成会使用现有的退款规则。未知结果将保留以供审查。HTTP 401 表示无效/已撤销的密钥,402 积分不足,403 账户访问不可用,409 请求冲突或生成门槛,429 每日请求上限,以及 503 API销售暂停。状态轮询和下载也计入每日请求限额;请谨慎轮询。
此首个 API 版本仅支持文本提示。上传参考、头像、音乐、语音和聊天工作流仍保留在工作室中。毛利率目标不包括支付费用、托管和税费。API 密钥与您的账户绑定,并在撤销、禁用访问或更改密码后停止工作。
准备 API 访问 ↗