<!--
{
  "availability" : [
    "iOS: 18.0.0 -",
    "iPadOS: 18.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "PassKit",
  "identifier" : "/documentation/PassKit/JPKIPassContents/UserIdentity-swift.struct/changePIN(from:to:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "PassKit (Apple Pay and Wallet)"
    ],
    "preciseIdentifier" : "s:7PassKit16JPKIPassContentsV12UserIdentityV9changePIN4from2toySS_SStYaKF"
  },
  "title" : "changePIN(from:to:)"
}
-->

# changePIN(from:to:)

A function that allows for the change of the PIN associated with the user identity.

```
func changePIN(from oldValue: String, to newValue: String) async throws
```

## Parameters

`oldValue`

The user authentication value used to perform the request to change the PIN.

`newValue`

The new user authentication value applied to user identity.

---

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)