Skip to content

Commit d03b49a

Browse files
dmallory42claude
andcommitted
Add promotions route to Request validation list
Adds the PROMOTIONS_API constant to the route_list array in the Request class to allow promotions API calls to pass validation. This enables the GET /promotions, POST /promotions/{id}/activate, and POST /promotions/{id}/dismiss endpoints to function correctly. Without this fix, all promotions API calls would fail with an "Invalid request api route" exception. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
1 parent cdc9e41 commit d03b49a

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

includes/core/server/class-request.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,6 +154,7 @@ abstract class Request {
154154
WC_Payments_API_Client::TERMINAL_READERS_API => 'terminal/readers',
155155
WC_Payments_API_Client::MINIMUM_RECURRING_AMOUNT_API => 'subscriptions/minimum_amount',
156156
WC_Payments_API_Client::CAPITAL_API => 'capital',
157+
WC_Payments_API_Client::PROMOTIONS_API => 'promotions',
157158
WC_Payments_API_Client::WEBHOOK_FETCH_API => 'webhook/failed_events',
158159
WC_Payments_API_Client::DOCUMENTS_API => 'documents',
159160
WC_Payments_API_Client::VAT_API => 'vat',

0 commit comments

Comments
 (0)