Hermes Agent で Recraft を使う。
Recraft は、アーティファクトなしで細部を復元する鮮明なニューラル画像高画質化と、髪の毛や透明なエッジを保持する精密な背景除去を提供します。Hermes Agent は、チャットで使うのと同じ RunAPI custom プロバイダーで両方のエンドポイントを呼び出します——ソース画像 URL を送信し、高画質化または背景除去を選び、処理結果をポーリングします。
RunAPI を使って Recraft crisp upscale で画像を高画質化します。
要件:
- 認証には RUNAPI_API_KEY 環境変数を使用します。
- base_url https://runapi.ai/v1 の custom:runapi プロバイダーを使用します。
- https://runapi.ai/api/v1/recraft/upscale_image の RunAPI upscale_image エンドポイントを呼び出します。
- model を "recraft-crisp-upscale" に設定します。
- source_image_url にソース画像 URL を渡します。
- レスポンスは task_id を返します。タスクが完了するまでタスクステータスエンドポイントをポーリングし、結果から高画質化された画像 URL を取得します。
- 背景除去の場合は、代わりに /api/v1/recraft/remove_background を model "recraft-remove-background" で呼び出します。
curl -X POST https://runapi.ai/api/v1/recraft/upscale_image \
-H "Authorization: Bearer $RUNAPI_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "recraft-crisp-upscale",
"source_image_url": "https://example.com/product-photo.jpg"
}'
{
"task_id": "tsk_abc123",
"status": "pending",
"model": "recraft-crisp-upscale"
}
Hermes Agent で Recraft を使う3ステップ
Configure RunAPI
If you have not set up RunAPI in Hermes Agent yet, follow the Hermes Agent setup guide. Add a custom provider named runapi with base_url https://runapi.ai/v1, key_env RUNAPI_API_KEY, and api_mode chat_completions.
export RUNAPI_API_KEY=runapi_xxx
Call Recraft upscale or remove background
Send a POST request to the upscale_image endpoint with model set to recraft-crisp-upscale and provide the source_image_url. For background removal, POST to the remove_background endpoint with model recraft-remove-background instead. Both require only source_image_url.
POST /api/v1/recraft/upscale_image
Poll for the result
Both endpoints return a task_id with status pending. Poll the task status endpoint until the status changes to completed, then retrieve the processed image URL from the response. RunAPI SDKs and the CLI handle polling automatically.
GET /api/v1/recraft/upscale_image/tsk_abc123
Recraft API パラメータ
| パラメータ | 型 | 説明 |
|---|---|---|
model |
string |
Required. recraft-crisp-upscale for upscaling, recraft-remove-background for background removal. |
source_image_url |
string |
Required. URL of the source image to process. |
callback_url |
string |
Optional. Webhook URL for async completion notification. |
Hermes AgentのRecraftとは?
RunAPI上のRecraftはクリアなニューラルアップスケーリングと精密な背景除去を提供します——生のAI生成画像を本番対応アセットに変換する2つの後処理ステップです。Hermes Agentは生成モデルと同じcustom:runapi provider経由で両方のエンドポイントを呼び出し、単一ワークフローで生成と後処理を連結しやすくします。
Recraftの活用例
生成から本番対応アセットへのパイプライン
Flux 2またはImagen 4で画像を生成してからRecraftで高解像度にアップスケールして背景を除去し、Hermes Agentの単一ワークフローでデスクトップツールなしに完結します。
ECカタログのバッチ処理
カタログ全体に自動的に背景除去とニューラルアップスケーリングを適用し、Hermes Agentが各タスクを並行ディスパッチして全結果を収集します。
デザイン納品物向けロゴアップスケーリング
低解像度ロゴを大判印刷・展示バナー・動画オーバーレイ向けにアップスケールし、Recraftのニューラルアップスケーリングでエッジの鮮明さを維持します。
Recraft + Hermes Agent のよくある質問
Yes. Both endpoints are stateless and accept standard image URLs. Instruct the Hermes Agent to first call remove_background with the original image, then pass the output URL to upscale_image. The same custom:runapi provider handles both calls.
Recraft accepts JPEG, PNG, and WebP inputs. Background removal outputs PNG with alpha transparency. Upscale output matches the input format.
Change the endpoint path and model field. Use /api/v1/recraft/upscale_image with model recraft-crisp-upscale for upscaling, or /api/v1/recraft/remove_background with model recraft-remove-background for background removal. Both use the same API key and custom:runapi provider.
Specify the endpoint action in your request — use the upscale endpoint for resolution enhancement or the background_removal endpoint for subject extraction. Hermes Agent routes each request to the correct Recraft action through the custom:runapi provider.
Yes. Hermes Agent can loop over a list of image URLs and call Recraft's background removal or upscale endpoint for each one, collecting all processed images when the batch completes.
今すぐ Hermes Agent で Recraft を試す。
無料の RunAPI キーを取得し、custom プロバイダーを設定して、Recraft で画像の高画質化と背景除去を始めましょう。