Skip to content

Releases: factor1/better-rest-endpoints

Add `orderby` param to custom taxonomy term endpoints

10 Nov 20:53
Compare
Choose a tag to compare

Get Posts Belonging To A Taxonomy Term

better-wp-endpoints/v1/{taxonomy}/{term}
Gets posts from a taxonomy term. Accepts rthe following parameters:

  • per_page (int)
  • page (int)
  • content (boolean - setting to false omits the_content from being returned)
  • orderby (string) - see the codex for options, currently does not support multiple values

Add Response Headers

09 Nov 23:54
Compare
Choose a tag to compare
Add Response Headers Pre-release
Pre-release

Added response headers (X-WP-Total, X-WP-TotalPages) for endpoints that return collections.

Update Validation and Sanitization Callbacks

02 Nov 18:25
Compare
Choose a tag to compare

Fixes validation and sanitization callbacks to check data properly.

Adds Orderby Param to CPT Endpoints

01 Nov 23:10
Compare
Choose a tag to compare
Pre-release

Release 0.1.10 adds the orderby param for custom post type endpoints.

Fix Custom Taxonomy Object

26 Oct 18:18
Compare
Choose a tag to compare
Pre-release

Fixes a bug where the custom taxonomy endpoint would only return one post instead of an array of all posts.

Add Taxonomy Term Endpoints

25 Oct 22:08
Compare
Choose a tag to compare
Pre-release

Get Posts Belonging To A Taxonomy Term

better-wp-endpoints/v1/{taxonomy}/{term}
Gets posts from a taxonomy term. Accepts rthe following parameters:

  • per_page (int)
  • page (int)
  • content (boolean - setting to false omits the_content from being returned)

Returns the following JSON Response:

  • ID
  • slug
  • title
  • date (ISO 8601)
  • post terms
  • excerpt
  • content
  • all possible thumbnail sizes & URLs
  • Author & Author ID
  • ACF Fields, if applicable

Add CPT Endpoint by Slug

11 Oct 22:37
Compare
Choose a tag to compare
Pre-release

Adds endpoint to get CPT by slug.

Fix empty Taxonomies on Posts

09 Oct 22:42
Compare
Choose a tag to compare
Pre-release

Wraps foreach statement in an if statement to check if they are empty to avoid errors.

Fixes Content Rendering

09 Oct 21:35
Compare
Choose a tag to compare
Pre-release

Fixes get_the_content to be passed through the_content filter to assure that HTML elements and shortcodes are rendered correctly.

Add slugs to menu response

09 Oct 20:29
Compare
Choose a tag to compare
Pre-release

Adds slugs to menu responses.