Part of the Views ecosystem · 280 projects
Views Better REST is a Drupal module that enhances the REST export display for views, enabling more flexible JSON output. It allows custom JSON structures, supports exposed filters, pagers, and sorts, and adds URL serializer support.
This module provides a new REST export display for Views, allowing you to return JSON from a View in a more flexible way.
Features
- Define a custom JSON structure for a View by adding fields to the display and overriding their names.
- Use exposed filters and provide available options for them.
- Use an exposed pager and change the number of items per page.
- Use exposed sorts.
- URL serializer support.
Post-Installation
Create a View, add a display called “Better REST Export,” and select Fields as the display style.
Set a path, such as api/v1/my-view.
Add fields to the display and override their names to define a custom JSON structure.
If needed, add exposed filters, sorts, and a pager to the display.
Recommended modules/libraries
Works well with React Table.
Similar projects
REST Views - adds useful features to the standard REST export and can be used alongside this module.
JSON:API Views - works through JSON:API, but its path and exposed parameters are not configurable.
Ask your assistant about Views Better REST export
Check compatibility with your Drupal and PHP version, maintenance and security coverage, from current release data. How it works
Depends on
Dependencies of the latest stable release
- rest Drupal core
- views Drupal core
Required by
Tracked projects that depend on this one
No tracked projects depend on this one yet.
More in the Views ecosystem
Most installed first