This project is not covered by Drupal’s security advisory policy.
Adds a read-only "Inspect" tab to any content entity, displaying its complete data as syntax-highlighted JSON. A developer tool for debugging and understanding entity data.
Features
- Adds an "Inspect" local task tab to entity pages showing all entity data as read-only, syntax-highlighted JSON
- Works with any content entity type — nodes, taxonomy terms, media, users, custom entities
- Entities must explicitly opt in via a marker interface, preventing accidental data exposure
- Dual permission model: requires both a module-level permission and the entity type's admin permission
- Entities can exclude specific fields from the output by implementing an optional interface
- Automatically decodes JSON fields to prevent double-encoded display
- Supports custom route providers for advanced control over breadcrumbs and titles
Post-Installation
- Enable the module and its dependency (JSON Field Widget)
- Grant the "View entity inspector" permission to trusted roles (typically administrator) at /admin/people/permissions
- Entity types must opt in with code changes — add an entity_inspector link template and implement EntityInspectorAccessControlInterface on the entity's access handler. See the README for step-by-step instructions with code examples.
- Once configured, an "Inspect" tab appears on opted-in entity pages for users with the correct permissions
Additional Requirements
None.
Recommended modules/libraries
JSON Field — the json_field_widget submodule provides the syntax-highlighted JSON editor used for display
Similar projects
- Entity Debug — logs entity save/delete callers to watchdog. Different purpose: Entity Debug traces operations, Entity Inspector displays data.
- Devel — provides a "Render" tab showing the render array. Entity Inspector shows the raw stored field data as JSON instead, which is useful for understanding what's actually persisted vs. how it renders.
Supporting this Module
Community Documentation
Project information
- Project categories: Developer tools
- Created by foxtrotcharlie on , updated
This project is not covered by the security advisory policy.
Use at your own risk! It may have publicly disclosed vulnerabilities.
