积分
GET /v1/credits — 余额查询与 API 计价
返回密钥所属账户的当前积分余额。调用免费,也是新密钥最简单的连通性测试。
GET https://patentfig.ai/api/v1/credits请求
curl https://patentfig.ai/api/v1/credits \
-H "Authorization: Bearer pfig_xxx"响应
{ "success": true, "data": { "balance": 480 } }各接口计价
| 接口 | 积分 |
|---|---|
POST /figures | 10 |
POST /vectorize | 20 |
POST /enhance | 20 |
POST /convert | 20 |
GET /credits | 0 |
API 与网页端共用同一积分余额。只有成功的调用才扣费——失败的请求不计费。充值或订阅见定价页。
余额不足时返回 402:
{
"success": false,
"error": {
"code": "INSUFFICIENT_CREDITS",
"message": "Insufficient credits. This request costs 10 credits."
}
}
PatentFig AI 文档