API Reference
/
POST /v1/uploads/splat-file
POST /api/v1/uploads/splat-file
Create a short-lived signed upload URL for one already-compressed single-file
splat. Use this from your backend, then have your native client upload the file
directly to the returned uploadUrl.
POST
https://moshpit.studio/api/v1/uploads/splat-file
Auth
All three headers are required:
Authorization: Bearer msk_YOUR_SECRET_KEY
X-Moshpit-Public-Key: mpk_YOUR_PUBLIC_KEY
X-Moshpit-External-User-Id: YOUR_HOST_USER_IDProvision the external user first with PUT /api/v1/external-user.
REST API access
REST API access is included on Free, Pro, and Enterprise. Storage, Scene counts, and integration limits still apply.
Body
JSON
{
"fileName": "scan.sog",
"contentType": "application/sog",
"fileSize": 17825792
}Supported extensions are .sog, .ksplat, .ply, and .splat. Supported
content types are application/sog, application/ksplat,
application/ply, model/ply, application/splat, and
application/octet-stream.
Success response
JSON
{
"status": "success",
"uploadUrl": "https://...",
"fileUrl": "https://cdn.example.com/splats/embed/...",
"expiresAt": "2026-05-20T12:10:00.000Z"
}Upload the file with:
PUT {uploadUrl}
Content-Type: application/sog
Cache-Control: public, max-age=31536000, immutableSend the Cache-Control header exactly as shown — storage only persists it
when the uploading client provides it, and without it the asset is re-fetched
by viewers' browsers instead of being cached for a year. Every upload key is
unique, so the long cache lifetime can never serve stale content.
Then call POST /api/v1/splats with the
returned fileUrl. For a multi-file LOD Scene, use
POST /api/v1/uploads/lod-folder
instead. You can attach a thumbnail and depth map through
POST /api/v1/uploads/splat-images.
Error responses
| Status | Cause |
|---|---|
| 400 | Missing external user, invalid JSON, unsupported type, unsupported extension, or file too large |
| 401 | Missing or invalid Bearer / public-key combination, including an inactive or unknown external user |