<!--
{
  "availability" : [
    "iOS: 15.5.0 -",
    "iPadOS: 15.5.0 -",
    "macOS: 12.5.0 -",
    "watchOS: 8.5.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "SwiftUI",
  "identifier" : "/documentation/SwiftUI/View/onApplePayShippingMethodChange(perform:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "SwiftUI",
      "SwiftUI"
    ],
    "preciseIdentifier" : "s:7SwiftUI4ViewP09_PassKit_aB0E30onApplePayShippingMethodChange7performQrSo016PKPaymentRequestiJ6UpdateCSo010PKShippingJ0CYac_tF"
  },
  "title" : "onApplePayShippingMethodChange(perform:)"
}
-->

# onApplePayShippingMethodChange(perform:)

Called when a user selected a shipping method.
This is required if the user is being asked to provide a shipping method.

```
nonisolated func onApplePayShippingMethodChange(perform action: @escaping (PKShippingMethod) async -> PKPaymentRequestShippingMethodUpdate) -> some View
```

## Return Value

An update to the payment request shipping method.

---

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)