Add dedicated clients for all missing WordPress REST API endpoints#425
Draft
Add dedicated clients for all missing WordPress REST API endpoints#425
Conversation
…Blocks, Templates, TemplateParts, GlobalStyles, Navigation, Sidebars, Widgets, WidgetTypes, UrlDetails; add page revisions and autosaves; update docs and add tests Agent-Logs-Url: https://github.com/wp-net/WordPressPCL/sessions/94dfe725-c14e-470e-942a-fc5ce144e317 Co-authored-by: ThomasPe <4225039+ThomasPe@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Add missing WordPress Rest endpoints
Add dedicated clients for all missing WordPress REST API endpoints
Apr 7, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Implements the standard
wp/v2endpoints listed as gaps indocs/v3/endpoint-coverage.md. Adds 11 new top-level clients, 3 sub-resource helpers, 11 models, and 6 query builders.New top-level clients on
WordPressClientclient.Searchwp/v2/searchSearchQueryBuilderclient.BlockTypeswp/v2/block-typesGetByNameAsync("core","paragraph")client.Blockswp/v2/blocksclient.Templateswp/v2/templatesclient.TemplatePartswp/v2/template-partsclient.GlobalStyleswp/v2/global-styles/{id}GetByIdAsync,GetThemeStylesAsync,UpdateAsyncclient.Navigationwp/v2/navigationclient.Sidebarswp/v2/sidebarsclient.Widgetswp/v2/widgetsGetBySidebarAsync(string IDs)client.WidgetTypeswp/v2/widget-typesclient.UrlDetailswp/v2/url-detailsGetAsync(url)— requires authNew sub-resource helpers
Design notes
Templates,TemplateParts,Sidebars,Widgets,WidgetTypeall use string IDs (e.g."twentytwentyfour//index","sidebar-1"); they have custom CRUD implementations instead ofCRUDOperation<T,Q>which assumes integer IDs.BlocksandNavigationextendBase(integer ID) and reuseCRUDOperation<T,Q>normally.GlobalStylesClientandUrlDetailsClientare named with aClientsuffix to avoid clashing with the identically-named model classes.New models
SearchResult,BlockType,Block,Template,TemplatePart,GlobalStyles,Navigation,Sidebar,Widget,WidgetType,UrlDetails(+OgImage)New query builders
SearchQueryBuilder,BlocksQueryBuilder,TemplatesQueryBuilder,TemplatePartsQueryBuilder,NavigationQueryBuilder,WidgetsQueryBuilderDocs + tests
docs/v3/endpoint-coverage.mdandREADME.mdupdated to reflect the new coverage table and remaining gaps.