<!--
{
  "availability" : [
    "iOS: 15.4.0 -",
    "iPadOS: 15.4.0 -",
    "macCatalyst: 15.4.0 -",
    "macOS: 12.3.0 -",
    "tvOS: 15.4.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 8.5.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "StoreKitTest",
  "identifier" : "/documentation/StoreKitTest/SKTestSession/declinePriceIncreaseForTransaction(identifier:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "StoreKit Test"
    ],
    "preciseIdentifier" : "c:objc(cs)SKTestSession(im)declinePriceIncreaseForTransactionWithIdentifier:error:"
  },
  "title" : "declinePriceIncreaseForTransaction(identifier:)"
}
-->

# declinePriceIncreaseForTransaction(identifier:)

Simulates a user canceling an auto-renewable subscription by disabling auto-renew.

```
func declinePriceIncreaseForTransaction(identifier: Int) throws
```

## Parameters

`identifier`

The transaction [`identifier`](/documentation/StoreKitTest/SKTestTransaction/identifier) of the auto-renewable subscription that has a pending price increase.

## Discussion

To test how your app handles the price increase consent flow for auto-renewable subscriptions, first call [`requestPriceIncreaseConsentForTransaction(identifier:)`](/documentation/StoreKitTest/SKTestSession/requestPriceIncreaseConsentForTransaction(identifier:)).

Call [`declinePriceIncreaseForTransaction(identifier:)`](/documentation/StoreKitTest/SKTestSession/declinePriceIncreaseForTransaction(identifier:)) to simulate a user canceling the subscription. Specifically, this method disables auto-renew and removes the subscription’s pending price increase status. The subscription expires at the end of the billing period in the testing environment.

---

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)