<!--
{
  "availability" : [
    "iOS: 26.1.0 - 26.4.0",
    "iPadOS: 26.1.0 - 26.4.0",
    "macCatalyst: 26.1.0 - 26.4.0",
    "macOS: 27.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "PhotoKit",
  "identifier" : "/documentation/Photos/PHAssetResourceUploadJobChangeRequest/createJob(destination:resource:)",
  "metadataVersion" : "0.1.0",
  "role" : "Type Method",
  "symbol" : {
    "kind" : "Type Method",
    "modules" : [
      "Photos"
    ],
    "preciseIdentifier" : "c:objc(cs)PHAssetResourceUploadJobChangeRequest(cm)createJobWithDestination:resource:"
  },
  "title" : "createJob(destination:resource:)"
}
-->

# createJob(destination:resource:)

Creates an asset resource upload job.

```
class func createJob(destination: URLRequest, resource: PHAssetResource)
```

## Discussion

- Parameter:
  - destination: the destination NSURLRequest to which this asset resource will be sent.
  - resource: the asset resource to be uploaded.

If the number of jobs exceeds [`jobLimit`](/documentation/Photos/PHAssetResourceUploadJob/jobLimit) the photo library [`performChanges(_:completionHandler:)`](/documentation/Photos/PHPhotoLibrary/performChanges(_:completionHandler:)) request will fail with a [`limitExceeded`](/documentation/Photos/PHPhotosError-swift.struct/limitExceeded) error. To generate jobs after this limit is triggered, you must acknowledge succeeded/failed jobs, and wait for the registered/pending ones to finish uploading, which will make those jobs also succeeded/failed.

---

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)