Image to 3D mesh
$0.24
- Mesh-only GLB output
Meshy 3D API / 画像から3D・テキストから3Dを生成
使用するモデル: をPiAPI経由で利用し、非同期の3D生成タスクを送信して、完成したGLBアセットを取得します。
PiAPI経由で成功した生成ごとにお支払いください。
$0.24
from $0.36
from $0.24
画像URLを送信し、メッシュのみの出力か、テクスチャ解像度が2K、4K、8Kのテクスチャ付き出力を選択します。
プロンプトでテキストから3Dのプレビュータスクを開始し、完了後にそのPiAPI task_idをリファインに使用します。
リファインリクエストはpreview_task_idを受け取り、同じタスクのポーリング手順で完成したGLBモデルを返します。
PiAPIにタスクを送信し、ステータスをポーリングするかwebhookを利用して、完成したモデルをoutput.model_fileから取得します。
Sign up and grab an API key from the PiAPI workspace — free credits are included on sign-up.
Add credits on the billing page when you are ready to scale beyond the free tier.
POST your first task following the API docs, then poll the task until the result is ready.
Prototype prompts and settings in the the playground above before wiring them into your product.
curl -X POST 'https://api.piapi.ai/api/v1/task' \
-H 'X-API-Key: YOUR_API_KEY' \
-H 'Content-Type: application/json' \
-d '{
"model": "meshy",
"task_type": "image-to-3d",
"input": {
"image_url": "YOUR_IMAGE_URL",
"should_texture": true,
"texture_resolution": "2k"
}
}'curl 'https://api.piapi.ai/api/v1/task/{task_id}' \
-H 'X-API-Key: YOUR_API_KEY'model_file
curl -X POST 'https://api.piapi.ai/api/v1/task' \
-H 'X-API-Key: YOUR_API_KEY' \
-H 'Content-Type: application/json' \
-d '{
"model": "meshy",
"task_type": "text-to-3d",
"input": {
"mode": "preview",
"prompt": "A ceramic teapot",
"texture_resolution": "2k"
}
}'curl 'https://api.piapi.ai/api/v1/task/{task_id}' \
-H 'X-API-Key: YOUR_API_KEY'model_file
mode=previewでプレビューを作成し、完了を待ちます。そのPiAPI task_idをpreview_task_idとして、mode=refineで送信します。
見積もりはshould_textureとtexture_resolutionによって変わります。ワークスペースでは送信前に、選択した設定の見積もりが表示されます。
このページからリンクされているMeshyのタスク作成・タスク取得APIドキュメントをご覧ください。
More questions? See the API docs.