Quick Start
In this example, we’ll be generating a 3D model from an image using the image_to_3d
session type.
First, create an API key from your user profile on the Cube Webapp.
Creating an image_to_3d
session
We’ll start by creating an image_to_3d
session. Paste your API key into the x-api-key
header below. You’re welcome to use the
example image
provided, or use your own. Then, click Send API Request.
Getting your session
Because sessions can take varying amounts of time depending on the model and settings you choose, generation happens asynchronously.
To check your session status, you can visit the Cube Webapp, or you can check the status and get your results using the
GET /v3/sessions/{session_id}
endpoint. Copy your session_id
from the response above and paste it into the path parameter below. Then, click Send API Request.
After a couple minutes you will have successfully created a 3D model with the CSM API! To integrate the API into your application, you can copy code in a variety of languages by opening the Request Sample dropdown in the widgets above.
Finding your 3D model URL
When your model is ready (status is complete
), you can access different 3D model formats:
- In the response above, find the
output.meshes[0].data
section - For the GLB format, use the URL at
output.meshes[0].data.glb_url
- Other formats are also available:
obj_url
,fbx_url
, andusdz_url
These URLs provide direct access to your 3D model files for download or integration into your application.