Add WP.com simple site and Jetpack site routing to WpApiClient#22765
Add WP.com simple site and Jetpack site routing to WpApiClient#22765
Conversation
Generated by 🚫 Danger |
|
|
|
|
🤖 Build Failure AnalysisThis build has failures. Claude has analyzed them - check the build annotations for details. |
d538543 to
865899d
Compare
f861ada to
6cfa2a2
Compare
|
@jkmassel There are multiple conflicts and CI failures in this PR. Probably best to address that before I do a review. |
|
@nbradbury – sorry, this was supposed to be a draft still! |
bae20e0 to
bfebb4a
Compare
Add `isWPComSimpleSite()` to SiteModel and use it to route WP.com simple sites through the public-api.wordpress.com proxy with bearer token authentication. This enables the Rust WP API client to make authenticated requests for WPCom sites that don't use application passwords. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Route sites using WP.com REST API (isUsingWpComRestApi) through the WP.com API client, alongside pure WP.com sites. This enables Jetpack- connected sites to use the correct authentication and URL resolution. Add manifest route fetching methods (fetchWpComManifestRoutes, fetchSiteManifestRoutes) that retrieve the API root index to discover available REST routes for a site.
bfebb4a to
e9eba85
Compare
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## trunk #22765 +/- ##
=======================================
Coverage 37.34% 37.34%
=======================================
Files 2327 2327
Lines 124639 124645 +6
Branches 16892 16894 +2
=======================================
+ Hits 46551 46554 +3
- Misses 74351 74354 +3
Partials 3737 3737 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|


Summary
isWPComSimpleSite()toSiteModeland overridegetWpApiRestUrl()to return thepublic-api.wordpress.comproxy URL for simple (non-Atomic) WP.com sitesisUsingWpComRestApi) through the WP.com API client alongside pure WP.com sitesapiUrlResolverconstructor: UpdatecreateSelfHostedClientto useWpOrgSiteApiUrlResolverinstead of the oldwpOrgSiteApiRootUrlparameterTest plan
getWpApiRestUrl()WpOrgSiteApiUrlResolver