Commit b15290ea5f9 for woocommerce

commit b15290ea5f97f6988a07b7f59616be9d0b80411e
Author: iris-woocommerce[bot] <282076412+iris-woocommerce[bot]@users.noreply.github.com>
Date:   Tue Dec 1 17:07:18 2026 +0100

    [Abilities] Mark payment gateway update as destructive so agents confirm before changing it (#71659)

    Mark payment-gateway-update ability as destructive

    Co-authored-by: aaronfc <aaron.fas@automattic.com>
    Co-authored-by: matticbot <matticbot@users.noreply.github.com>

diff --git a/plugins/woocommerce/changelog/payment-gateway-update-destructive b/plugins/woocommerce/changelog/payment-gateway-update-destructive
new file mode 100644
index 00000000000..255924abbba
--- /dev/null
+++ b/plugins/woocommerce/changelog/payment-gateway-update-destructive
@@ -0,0 +1,4 @@
+Significance: patch
+Type: tweak
+
+Ask for confirmation in AI agents before they change payment method settings through the payment gateway update ability.
diff --git a/plugins/woocommerce/src/Internal/Abilities/Domain/PaymentGatewayUpdate.php b/plugins/woocommerce/src/Internal/Abilities/Domain/PaymentGatewayUpdate.php
index 21616f41997..c4864d91a2b 100644
--- a/plugins/woocommerce/src/Internal/Abilities/Domain/PaymentGatewayUpdate.php
+++ b/plugins/woocommerce/src/Internal/Abilities/Domain/PaymentGatewayUpdate.php
@@ -61,7 +61,7 @@ class PaymentGatewayUpdate extends AbstractDomainAbility implements AbilityDefin
 				'annotations'  => array(
 					'readonly'    => false,
 					'idempotent'  => true,
-					'destructive' => false,
+					'destructive' => true,
 				),
 			),
 		);
diff --git a/plugins/woocommerce/tests/php/src/Internal/Abilities/AbilitiesLoaderTest.php b/plugins/woocommerce/tests/php/src/Internal/Abilities/AbilitiesLoaderTest.php
index 847fc3fc22a..5f7267eeb95 100644
--- a/plugins/woocommerce/tests/php/src/Internal/Abilities/AbilitiesLoaderTest.php
+++ b/plugins/woocommerce/tests/php/src/Internal/Abilities/AbilitiesLoaderTest.php
@@ -435,7 +435,7 @@ class AbilitiesLoaderTest extends \WC_Unit_Test_Case {
 			'woocommerce/payment-gateway-update'      => array(
 				'readonly'    => false,
 				'idempotent'  => true,
-				'destructive' => false,
+				'destructive' => true,
 			),
 			'woocommerce/shipping-zone-create'        => array(
 				'readonly'    => false,