Skip to main content

Endpoint

POST https://api.magicfurnish.com/api/v2/ai/process

Request Format

This endpoint expects a multipart/form-data POST request with:
FieldTypeRequiredDescription
imageFileYesJPG, PNG, or single-page PDF floor plan
additionalDatatextNoOptional JSON string echoed back

Headers

X-API-Key: YOUR_API_KEY
X-API-Secret: YOUR_API_SECRET
Optional: X-Request-Id: demo-req-001

Example Request

curl -X POST "https://api.magicfurnish.com/api/v2/ai/process" \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "X-API-Secret: YOUR_API_SECRET" \
  -H "X-Request-Id: demo-req-001" \
  -F "image=@floorplan.png" \
  -F 'additionalData={"project_id":"demo"}'

Successful Response

If the floor plan is valid and processed successfully, the API returns:
{
  "status": "success",
  "data": {
    "uniqueId": "4959055a-5243-4e1f-8554-4091091f6bdf",
    "galleryUrl": "https://app.magicfurnish.com/floor-gallery/69245f96705e17e1e881bf2f",
    "furnishedImageUrl": "https://api.magicfurnish.com/api/v2/g/s3-image/59d98258-5da2-4d73-bcc0-667cd9ded501_layout.jpg"
  },
  "code": 200
}

Field Definitions

FieldDescription
uniqueIdInternal processing identifier for the uploaded plan
galleryUrlURL to the auto-generated MagicFurnish viewer/gallery
furnishedImageUrlDirect link to the furnished layout image

Validation Rules

The Upload endpoint performs automatic validation before processing. Floor plans must:
  • Be JPG, PNG, or single-page PDF
  • Be under 10 MB
  • Contain at least one visible dimension
  • Use consistent scale (if multiple scales appear, request is rejected)
  • Not contain visible furniture (to avoid misinterpretation)

Possible Error Responses

StatusCodeMeaning
400invalid_fileFile is not a supported image/PDF, or cannot be parsed
400multiple_pagesPDF contains more than one page
400furniture_detectedFloor plan contains visible furniture (remove and re-upload)
400dimensions_missingAt least one dimension must be readable
400size_unsupportedDimensions/scale not supported
400file_unreadableLow resolution or corrupted upload
401unauthorizedMissing/invalid API key/secret
403forbiddenKey not allowed for this endpoint
408timeoutProcessing exceeded time limit
413payload_too_largeFile exceeds 10 MB
415unsupported_media_typeUnsupported file type
429rate_limitedToo many requests
500internal_errorUnexpected internal error
503service_unavailableService temporarily unavailable
For detailed error shapes, see Errors.

Processing Time

Typical processing times (approximate):
  • Upload: ~10 seconds
  • Auto-Furnish: ~30–60 seconds
  • Gallery Ready: instantly upon completion

Next Steps

The returned galleryUrl can be:
  • Embedded in your app
  • Opened in a webview
  • Linked as part of a workflow (internal dashboards, listing platforms, etc.)