get_account
所需權限:account:read組織、方案與訂閱狀態、圖片與 LLM credits、下次補充時間、各圖片模型與成本、比例與 Carousel 成本。
不需要輸入,組織由登入時決定。

載入中...
SMEPost MCP
連接 Codex、Claude Code,或任何支援 Streamable HTTP 與 OAuth 的 MCP 客戶端。查看 credits、生成圖片與 4 頁 Instagram Carousel,之後可在 SMEPost 繼續編輯。
在客戶端加入一個網址,依提示以 SMEPost 帳戶登入即可。
MCP 連線網址
https://smepost.io/api/mcp/content
Codex 會開啟瀏覽器,讓你登入並選擇組織。
codex mcp add smepost --url https://smepost.io/api/mcp/content
codex mcp login smepost加入伺服器後,在 Claude Code 中透過 /mcp 選單完成登入。
claude mcp add --transport http smepost https://smepost.io/api/mcp/content
# Then run /mcp inside Claude Code and choose smepost → Authenticate以 Streamable HTTP transport 連接同一個網址。客戶端會自動找到登入方式,不需要 API key、外掛或 widget。
{
"mcpServers": {
"smepost": {
"type": "http",
"url": "https://smepost.io/api/mcp/content"
}
}
}開啟 Inspector,選擇 Streamable HTTP 並貼上連線網址,即可在串接自己的客戶端前先執行 initialize、tools/list 與 tools/call。
npx @modelcontextprotocol/inspector採用 OAuth 2.1 與 PKCE(S256),客戶端完全不會取得你的 SMEPost 密碼。
| 所需權限 | 說明 |
|---|---|
account:read | 讀取方案、訂閱狀態、credits 餘額、補充日期與成本(get_account)。 |
images:generate | 開始會使用圖片 credits 的圖片與 Carousel 生成(generate_image、generate_ig_carousel)。 |
images:read | 讀取工作進度與結果,並取得下載連結(get_generation)。 |
Access token 有效 60 分鐘。Refresh token 最長有效 90 天,每次使用都會更換;重複使用舊的 refresh token 會撤銷整個連線。
在客戶端撤銷(客戶端會呼叫 revoke endpoint),或移除組織成員資格。新請求會立即失敗;仍在執行的工作會在儲存前停止,並退回 credits。
https://smepost.io/.well-known/oauth-protected-resource/api/mcp/content
https://smepost.io/.well-known/oauth-authorization-server/api/content/oauth
https://smepost.io/api/content/oauth/authorize
https://smepost.io/api/content/oauth/token
https://smepost.io/api/content/oauth/register
https://smepost.io/api/content/oauth/revoke共 4 個工具,伺服器以這裡列出的同一份 schema 驗證;未知欄位會被拒絕。
account:read組織、方案與訂閱狀態、圖片與 LLM credits、下次補充時間、各圖片模型與成本、比例與 Carousel 成本。
不需要輸入,組織由登入時決定。
images:generate排入一張符合品牌的圖片,自動套用組織的品牌資料與知識,並立即回傳 jobId。
| 欄位 | 類型 | 必填 | 說明 |
|---|---|---|---|
prompt | string | 是 | 圖片要呈現的內容。 |
ratio | 1:1 | 4:5 | 9:16 | 是 | 長寬比例。 |
language | en | zh-hk | zh-tw | zh-cn | 是 | 圖片中文字使用的語言。 |
modelId | gemini-3.1-flash-image-preview | gemini-nano-banana-2.1 | gpt-image-2.5-flare | 否 | 從 get_account 取得的圖片模型;未填則使用預設模型。 |
background | opaque | transparent | auto | 否 | auto(預設)、opaque,或在模型支援時使用 transparent。 |
requestId | string | 是 | 你自訂的 idempotency key,只用來重試完全相同的請求。 |
maxCredits | number | 是 | 圖片 credits 的硬性上限;成本更高的工作會被拒絕,也不會扣款。 |
images:generate排入 4 頁 Instagram Carousel:先設計一張拼圖,再以 2×2 切成 4 頁,逐頁 upscale。4 頁全部完成後才依頁序回傳。
| 欄位 | 類型 | 必填 | 說明 |
|---|---|---|---|
brief | string | 是 | Carousel 主題與重點;brief 內的連結不會被讀取。 |
ratio | 1:1 | 4:5 | 是 | 長寬比例。 |
language | en | zh-hk | zh-tw | zh-cn | 是 | 圖片中文字使用的語言。 |
requestId | string | 是 | 你自訂的 idempotency key,只用來重試完全相同的請求。 |
maxCredits | number | 是 | 圖片 credits 的硬性上限;成本更高的工作會被拒絕,也不會扣款。 |
images:read狀態、階段、頁數進度、credits 結算、錯誤;成功後提供短效下載連結與在 SMEPost 繼續編輯的連結。
| 欄位 | 類型 | 必填 | 說明 |
|---|---|---|---|
jobId | string | 是 | 開始工作時回傳的 jobId。 |
參數放在 tools/call。結構化結果也會以文字回傳,方便只讀取文字的客戶端。
{
"method": "tools/call",
"params": {
"name": "generate_image",
"arguments": {
"prompt": "A calm flat-lay of a pour-over coffee set for an autumn menu launch",
"ratio": "4:5",
"language": "en",
"requestId": "autumn-menu-image-001",
"maxCredits": 1
}
}
}{
"method": "tools/call",
"params": {
"name": "generate_ig_carousel",
"arguments": {
"brief": "Four practical tips for brewing better coffee at home, ending with a visit-us call to action",
"ratio": "4:5",
"language": "zh-hk",
"requestId": "brew-tips-carousel-001",
"maxCredits": 3
}
}
}{
"jobId": "cmj_3f9a1c2b7d4e5f60718293a4b5c6d7e8f9012345",
"kind": "ig_carousel",
"status": "queued",
"reservedCredits": 3,
"replayed": false,
"pollAfterMs": 5000
}{
"jobId": "cmj_3f9a1c2b7d4e5f60718293a4b5c6d7e8f9012345",
"kind": "ig_carousel",
"status": "running",
"stage": "upscaling",
"progress": {
"completedPages": 2,
"totalPages": 4
},
"attempts": 1,
"billing": {
"state": "reserved",
"reservedCredits": 3,
"chargedCredits": 0,
"refundedCredits": 0
},
"images": [],
"downloadExpiresAt": null,
"smepostUrl": null,
"error": null,
"pollAfterMs": 8000,
"createdAt": "2026-10-23T08:00:00.000Z",
"completedAt": null
}{
"jobId": "cmj_3f9a1c2b7d4e5f60718293a4b5c6d7e8f9012345",
"kind": "ig_carousel",
"status": "succeeded",
"stage": "completed",
"progress": {
"completedPages": 4,
"totalPages": 4
},
"attempts": 1,
"billing": {
"state": "charged",
"reservedCredits": 3,
"chargedCredits": 3,
"refundedCredits": 0
},
"images": [
{
"page": 1,
"width": 1728,
"height": 2160,
"mimeType": "image/png",
"downloadUrl": "https://smepost.io/api/content/downloads/DOWNLOAD_TOKEN_PAGE_1"
},
{
"page": 2,
"width": 1728,
"height": 2160,
"mimeType": "image/png",
"downloadUrl": "https://smepost.io/api/content/downloads/DOWNLOAD_TOKEN_PAGE_2"
},
{
"page": 3,
"width": 1728,
"height": 2160,
"mimeType": "image/png",
"downloadUrl": "https://smepost.io/api/content/downloads/DOWNLOAD_TOKEN_PAGE_3"
},
{
"page": 4,
"width": 1728,
"height": 2160,
"mimeType": "image/png",
"downloadUrl": "https://smepost.io/api/content/downloads/DOWNLOAD_TOKEN_PAGE_4"
}
],
"downloadExpiresAt": "2026-10-23T08:19:30.000Z",
"smepostUrl": "https://smepost.io/org/ORG_ID/projects/PROJECT_ID/chats/CHAT_ID",
"error": null,
"pollAfterMs": null,
"createdAt": "2026-10-23T08:00:00.000Z",
"completedAt": "2026-10-23T08:04:30.000Z"
}{
"jobId": "cmj_3f9a1c2b7d4e5f60718293a4b5c6d7e8f9012345",
"kind": "ig_carousel",
"status": "failed",
"stage": "failed",
"progress": {
"completedPages": 3,
"totalPages": 4
},
"attempts": 3,
"billing": {
"state": "refunded",
"reservedCredits": 3,
"chargedCredits": 0,
"refundedCredits": 3
},
"images": [],
"downloadExpiresAt": null,
"smepostUrl": null,
"error": {
"code": "GENERATION_TIMEOUT",
"retryable": false
},
"pollAfterMs": null,
"createdAt": "2026-10-23T08:00:00.000Z",
"completedAt": "2026-10-23T08:12:00.000Z"
}{
"error": {
"code": "COST_EXCEEDS_MAX_CREDITS",
"message": "This job costs 3 image credits, above maxCredits 2.",
"retryable": false,
"cost": 3,
"maxCredits": 2
}
}{
"organization": {
"id": "ORG_ID",
"name": "Example Coffee"
},
"plan": {
"planId": "plus",
"effectivePlanId": "plus",
"subscriptionStatus": "active",
"billingPastDue": false
},
"credits": {
"image": {
"remaining": 42.5,
"unlimited": false
},
"llm": {
"remaining": null,
"unlimited": true
},
"nextRefillAt": "2026-11-01T00:00:00.000Z"
},
"imageModels": [
{
"modelId": "gemini-3.1-flash-image-preview",
"label": "Nano Banana 2",
"creditCost": 0.5,
"default": false
},
{
"modelId": "gemini-nano-banana-2.1",
"label": "Nano Banana 2.1",
"creditCost": 1,
"default": true
},
{
"modelId": "gpt-image-2.5-flare",
"label": "GPT Image 2.5 Flare",
"creditCost": 1,
"default": false
}
],
"generation": {
"imageRatios": [
"1:1",
"4:5",
"9:16"
],
"carousel": {
"ratios": [
"1:1",
"4:5"
],
"pageCount": 4,
"creditCost": 3,
"generationModelId": "gpt-image-2.5-flare",
"generationCreditCost": 1,
"upscaleModelId": "gemini-3.1-flash-image-preview",
"upscaleCreditCost": 2
},
"languages": [
"en",
"zh-hk",
"zh-tw",
"zh-cn"
]
},
"scopes": [
"account:read",
"images:generate",
"images:read"
]
}生成在背景執行,連線中斷不會取消工作,也不會重複扣款。
呼叫 get_generation,每次之間等待 pollAfterMs(排隊時約 5 秒,執行中約 8 秒)。狀態變成 succeeded 或 failed 即可停止。
相同的 requestId 搭配相同輸入,會回傳原本的工作(replayed: true),不會再次扣款;相同 requestId 但輸入不同會回傳 IDEMPOTENCY_CONFLICT。每個客戶端、使用者與組織各自獨立。
建立工作時,會在確認餘額的同一步驟預留 credits,因此同時送出多個請求也不會超額扣款。成本高於 maxCredits 的工作會在預留前被拒絕。
服務供應商錯誤與逾時會依 backoff 自動重試,最多 3 次,並重複使用已完成的部分,例如拼圖與已 upscale 的頁面。若最後仍失敗,預留的 credits 只會退回一次。若工作開始後 credits 已補充或方案有變動,餘額已重設,因此不會再退款。
圖片以私人方式儲存。每次呼叫 get_generation 都會回傳新連結,有效 15 分鐘;連結到期後再呼叫一次即可。
每個結果都會儲存為組織內「AI 應用程式創作」專案中的圖片對話,可在網站上檢視、編輯與發佈。smepostUrl 會直接開啟。
價格來自 SMEPost 全站共用的模型目錄;get_account 一律回傳最新數值。
| 模型 | 圖片 credits |
|---|---|
Nano Banana 2 gemini-3.1-flash-image-preview | 0.5 |
Nano Banana 2.1 gemini-nano-banana-2.1預設 | 1 |
GPT Image 2.5 Flare gpt-image-2.5-flare | 1 |
| 4 頁 Carousel | 3 |
拼圖 1 + 4 頁 upscale 2 = 共 3 圖片 credits。
Credits 不足時會回傳 INSUFFICIENT_IMAGE_CREDITS。SMEPost 不會自動改用其他模型或方案。
工具失敗會以 MCP 工具錯誤回傳,附上錯誤碼與是否可重試。
| 錯誤碼 | 說明 | 可重試? |
|---|---|---|
INVALID_INPUT | 參數不符合工具 schema。 | 不可 |
COST_EXCEEDS_MAX_CREDITS | 工作成本高於 maxCredits。請提高 maxCredits 或改用較便宜的模型。 | 不可 |
INSUFFICIENT_IMAGE_CREDITS | 組織的圖片 credits 不足。 | 不可 |
BILLING_PAST_DUE | 有逾期付款,請在 SMEPost 更新付款資料。 | 不可 |
IDEMPOTENCY_CONFLICT | 這個 requestId 已用於不同輸入,請改用新的 requestId。 | 不可 |
TOO_MANY_ACTIVE_JOBS | 組織同時執行的生成過多,請等待其中一項完成。 | 可以 |
RATE_LIMITED | 請求過於頻繁,請等待一分鐘。 | 可以 |
JOB_NOT_FOUND | 此使用者與組織沒有這個 jobId 的工作。 | 不可 |
ORGANIZATION_NOT_FOUND | 組織已不存在。 | 不可 |
ACCESS_REVOKED | 連線或組織存取權已被移除,請重新連接客戶端。 | 不可 |
GENERATION_FAILED | 圖片服務供應商發生錯誤,系統會先自動重試。 | 可以 |
GENERATION_TIMEOUT | 圖片服務供應商處理過久,系統會先自動重試。 | 可以 |
VERSION_LIMIT_REACHED | 已達免費方案的版本上限。 | 不可 |
TEMPORARILY_UNAVAILABLE | SMEPost 暫時無法完成請求,請稍後再試。 | 可以 |
任何支援 Streamable HTTP 與 OAuth 的客戶端都使用同一個網址。下表列出已完成端對端檢查的客戶端。
| 客戶端 | 狀態 |
|---|---|
| Codex | 已提供設定,正式環境檢查待完成 |
| Claude Code | 已提供設定,正式環境檢查待完成 |
| MCP Inspector | 已提供設定,正式環境檢查待完成 |
| 其他 Streamable HTTP + OAuth 客戶端 | 已提供設定,正式環境檢查待完成 |