<!--
{
  "availability" : [
    "iOS: 17.0.0 -",
    "iPadOS: 17.0.0 -",
    "macCatalyst: 17.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "RoomPlan",
  "identifier" : "/documentation/RoomPlan/CapturedRoom/ModelProvider/modelFileURL(for:)-9irqx",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "RoomPlan"
    ],
    "preciseIdentifier" : "s:8RoomPlan08CapturedA0V13ModelProviderV12modelFileURL3for10Foundation0H0VSgAC6ObjectV8CategoryO_tKF"
  },
  "title" : "modelFileURL(for:)"
}
-->

# modelFileURL(for:)

Provides a URL to the 3D model for the given category.

```
func modelFileURL(for category: CapturedRoom.Object.Category) throws -> URL?
```

## Parameters

`category`

An object type that represents criteria for the model-URL query.

## Return Value

The 3D model that the app associates to the given object’s category via [`setModelFileURL(_:for:)`](/documentation/RoomPlan/CapturedRoom/ModelProvider/setModelFileURL(_:for:)-4law9); or, `nil` if no 3D model URL associates to the given category.

## Discussion

This function throws [`CapturedRoom.ModelProvider.Error.nonExistingFile(url:)`](/documentation/RoomPlan/CapturedRoom/ModelProvider/Error/nonExistingFile(url:)) if a 3D model doesn’t exist at the given URL.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)