<!--
{
  "availability" : [
    "iOS: 9.0.0 -",
    "iPadOS: 9.0.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.15.0 -",
    "tvOS: 10.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "PhotoKit",
  "identifier" : "/documentation/Photos/PHAssetCreationRequest",
  "metadataVersion" : "0.1.0",
  "role" : "Class",
  "symbol" : {
    "kind" : "Class",
    "modules" : [
      "Photos"
    ],
    "preciseIdentifier" : "c:objc(cs)PHAssetCreationRequest"
  },
  "title" : "PHAssetCreationRequest"
}
-->

# PHAssetCreationRequest

A request to create a new Photos asset from underlying data resources, for use in a photo library change block.

```
class PHAssetCreationRequest
```

## Overview

A [`PHAssetCreationRequest`](/documentation/Photos/PHAssetCreationRequest) object, used within a photo library change block, constructs a new photo or video asset from data resources, and adds it to the Photos library. This class works in terms of the raw data resources that together form an asset, so you can use it together with the [`PHAssetResource`](/documentation/Photos/PHAssetResource) class to perform a complete copy (or backup and restore) of an asset’s underlying resources. To instead simply create a new asset from an image object, image file, or video file, see the superclass [`PHAssetChangeRequest`](/documentation/Photos/PHAssetChangeRequest).

To create a new asset from data resources, first start a change block using the shared [`PHPhotoLibrary`](/documentation/Photos/PHPhotoLibrary) method [`performChanges(_:completionHandler:)`](/documentation/Photos/PHPhotoLibrary/performChanges(_:completionHandler:)) or [`performChangesAndWait(_:)`](/documentation/Photos/PHPhotoLibrary/performChangesAndWait(_:)). Then, within the change block:

1. Within the change block, create a new asset creation request with the [`forAsset()`](/documentation/Photos/PHAssetCreationRequest/forAsset()) method.
2. Add image, video, or data resources using the methods in the Providing Data Resources for the New Asset section below.
3. (Optional.) Set metadata for the new asset using methods and properties of the superclass [`PHAssetChangeRequest`](/documentation/Photos/PHAssetChangeRequest).

After Photos runs the change block and calls your completion handler, the new asset is created in the Photos library.

If you instantiate or use this class outside a photo library change block, Photos throws an exception. For details on change blocks, see [`PHPhotoLibrary`](/documentation/Photos/PHPhotoLibrary).

## Topics

### Requesting Asset Creation

[`forAsset()`](/documentation/Photos/PHAssetCreationRequest/forAsset())

Creates a request for adding a new asset to the Photos library using asset resources.

### Preflighting a Request

[`supportsAssetResourceTypes(_:)`](/documentation/Photos/PHAssetCreationRequest/supportsAssetResourceTypes(_:))

Returns a Boolean value indicating whether Photos supports creating an asset with the specified combination of resource types.

### Providing Data Resources for the New Asset

[`addResource(with:data:options:)`](/documentation/Photos/PHAssetCreationRequest/addResource(with:data:options:))

Adds a data resource to the asset being created, using the specified data.

[`addResource(with:fileURL:options:)`](/documentation/Photos/PHAssetCreationRequest/addResource(with:fileURL:options:))

Adds a data resource to the asset being created, using the file at the specified 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)