Skip to main content
Version: 0.0.3-alpha

Welcome to Expression Lab

Expression Lab is sandboxed diagnostics and data inspection environment for WordPress. It provides a declarative Domain-Specific Language (DSL) based on the Symfony Expression Language component to query WordPress internals, inspect data structures, and automate administrative workflows without writing raw PHP scripts or modifying code files.

Expression Lab is free software distributed under the GNU General Public License v2 (GPLv2).


Core Principles​

  • Declarative Functional DSL: Powered by an extended Symfony Expression Language engine. Expressions are compiled into an AST with configurable execution limits, closure validation, and stream operations (prog[...], map[...], filter[...]).
  • Client-Side Cryptographic Authentication: Console sessions derive an Ed25519 key pair client-side in browser memory using Argon2id. Requests are verified on the server against public keys configured in wp-config.php, without storing private keys or passwords in the database.
  • Read-Only Exploration by Default: Inspect databases, taxonomy trees, media metadata, and option stores with optional in-memory SQLite mirroring and read-only defaults for database, filesystem, and network operations.
  • Modern Developer Experience: A reactive interface built with Vue 3, featuring syntax highlighting, a snippet library, and deep data tree visualization.

A Quick Glimpse​

Expression Lab combines familiar object-like queries with functional pipeline composition:

/* Get all active cron jobs */
Options.get('cron')
/* Get details for user 'anderson' */
Users.get('anderson')
/* Get the last 5 published posts ordered by date */
Posts.where('post_type', 'post')
.where('post_status', 'publish')
.order_by('post_date','DESC')
.limit(5)
.get()
/* Build a custom list of posts and their comments count */
prog[
set[
'comments',
Database.mirror( 'posts', { 'post_status' : 'publish' }, { 'limit' : 5 } )
.query('SELECT ID post_id, comment_count FROM wp_posts')
],
map[
var['comments'],
fn[
['post'],
'The post ID #' ~ args['post']['post_id']
~ ' has '
~ args['post']['comment_count']
~ ' comment'
~ ( 1 !== intval( args['post']['comment_count'] ) ? 's' : '' )
]
]
]

Where to Go Next​

Explore the documentation based on your workflow:

Getting Started

Install the plugin, complete the onboarding security wizard, and configure your constants.

Installation · Quick Start Guide

Language & Scripting

Master expressions, AST special forms, state bindings, closures, and collection transformations.

Basic Syntax · Scripting Syntax

API Reference

Explore fluent query builders for Posts, Users, Database, Media, HTTP, Options, and Files.

Posts API · Database API · Users API

Security Architecture

Learn how Argon2id key derivation, Ed25519 signing, and sandbox boundaries safeguard your site.

Security Model