Skip to content

Make it configurable#3

Open
Erudition wants to merge 17 commits intogetshifter:masterfrom
Erudition:master
Open

Make it configurable#3
Erudition wants to merge 17 commits intogetshifter:masterfrom
Erudition:master

Conversation

@Erudition
Copy link

No description provided.

- Added get_api_routes() to dynamically fetch all public collection endpoints from /wp-json/.
- Replaced hardcoded routes ('posts', 'pages', 'media') with discovered routes.
- Switched to wp_remote_get() for improved HTTP handling and access checking.
- Updated README.md and bumped version to 0.3.0.
- Replaced synchronous build_db on save_post with a scheduled WP-Cron event.
- Added schedule_build_db() to prevent blocking the post-save UI.
- Use wp_next_scheduled to avoid redundant overlapping builds.
- Restricted dynamic discovery to /wp/v2/ namespace only.
- Simplified JSON keys to use the final endpoint name (e.g., 'posts' instead of 'wp/v2/posts').
- Excluded empty collections from the resulting database output.
- Added an admin settings page under Settings > WP Serverless API.
- Re-implemented discovery cache to limit network queries.
- Discovered paths have checkboxes, unchecking them adds to exclusion list.
- Greyed out checkboxes for endpoints that are inaccessible.
- Paths matching a REST base are checked by default, excluding nav_menu_item and ones starting with wp_, e-, elementor_.
- Extracted and display all available fields, allowing field-level exclusions.
- Excluded 'guid' and '_links/curies' fields by default.
- Added 'Output Path' column with editable text boxes for custom JSON keys.
- Show all API paths, with non-wp/v2 paths unchecked by default.
- Updated Preview column to show item counts (e.g., 'View 10 items').
- Inaccessible paths now still provide a link to preview the error.
- Implemented visual indentation for nested fields in the Discovered Fields section.
- Added 'total_items' and 'base_name' to discovery metadata.
- Restricted endpoints to GET methods with no required arguments.
- Updated preview link text: 'View N items' or 'View' (if 0 items).
- Added 'Public Only' and 'Named Only' list filters (on by default).
- Added 'Index Now' button for manual database builds.
- Ensured inaccessible endpoints still provide a direct link to view API errors.
- Visual indentation for nested fields in the Discovered Fields section.
- Added 'Reset to Defaults' button to settings page.
- Implemented logic to clear saved paths, fields, and custom output names.
- Updated version to 0.4.0 in plugin header.
- Updated README.md with comprehensive feature list and 0.4.0 changelog.
- Split settings into 'Paths' and 'Fields' tabs for better organization.
- Implemented dynamic field discovery: the Fields tab now only displays fields found in the currently selected paths.
- Added 'wp/v2/navigation' and 'wp/v2/blocks' to the default path exclusion list.
- Cleaned up UI hints and improved path filtering logic.
- Bumped version to 0.5.0.
- Implemented friendly name fetching for Taxonomies from /wp/v2/taxonomies.
- Added friendly names for 'types' and 'taxonomies' listing endpoints.
- Fixed 'Reset to Defaults' button to properly clear all settings and force a UI refresh.
- Added 'wp/v2/navigation' and 'wp/v2/blocks' to the default exclusion list.
- Bumped version to 0.5.1.
- Grouped discovered paths and fields by component and version (e.g., 'wp v2', 'pods v1').
- Added 'wp/v2/types' and 'wp/v2/taxonomies' to the default exclusion list.
- Improved 'Fields' tab to show fields per component, filtered by selected paths.
- Enhanced 'Reset to Defaults' functionality to properly clear discovery cache and refresh UI.
- Bumped version to 0.6.0.
- Moved 'Build Database Now' button to the bottom of the settings page.
- Replaced the cache refresh checkbox with a 'Re-discover' button in the filter row.
- Updated preview links for private endpoints to display 'Not public' in grey.
- Expanded default path exclusions to include 'wp/v2/types' and 'wp/v2/taxonomies'.
- Organized paths and fields into sections by component and version.
- Bumped version to 0.6.1.
- Updated 'Input Path' column to strip the namespace prefix already implied by the section header.
- Enhanced preview links to show 'View N fields' for object-based endpoints and 'View N items' for lists.
- Added 'media' to the default exclusion list.
- Bumped version to 0.6.2.
- Bumped version to 1.0.0.
- Added 'View in browser' link to the database build success notice.
- Refined input path display by stripping namespace prefixes.
- Enhanced preview links to distinguish between lists (items) and objects (fields).
- Expanded default exclusions to include 'media', 'wp/v2/types', and 'wp/v2/taxonomies'.
- Finalized UI grouping and tab organization.
- Implemented loop to fetch all pages of REST API collections.
- Use per_page=100 to optimize indexing speed.
- Corrected field filtering for both collections and single-object endpoints.
- Ensures larger datasets (like the 65 courses) are fully indexed in db.json.
- Added wp_sls_api_make_relative() to recursively convert absolute staging URLs to relative paths in the JSON output.
- Enabled relative URL conversion by default (toggleable in settings).
- Added 'media' to default exclusion list.
- Improved 'Input Path' display by stripping namespace prefixes.
- Enhanced preview link logic to show item vs field counts based on data structure.
- Added 'View in browser' link to build success notice.
- Bumped version to 1.1.0.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant