---
title: "localVersion(ofAssetPackWithID:)"
framework: Background Assets
role: symbol
role_heading: Instance Method
platforms: [iOS 27.2+, iPadOS 27.2+, Mac Catalyst 27.2+, macOS 27.2+, tvOS 27.2+, visionOS 27.2+]
path: "backgroundassets/assetpackmanager/localversion(ofassetpackwithid:)"
---

# localVersion(ofAssetPackWithID:)

Returns a locally available asset pack’s version number.

## Declaration

```swift
nonisolated func localVersion(ofAssetPackWithID assetPackID: String) throws -> Int
```

## Parameters

- `assetPackID`: The asset pack’s ID.

## Return Value

Return Value The asset pack’s version number.

## Discussion

Discussion note: ManagedBackgroundAssetsError.assetPackNotFound(withID:) when no asset pack with the specified ID is available locally.
