WordPress plugin
The plugin (Diazoma Wall for WordPress) publishes your posts, and WooCommerce products, as a wall. It needs PHP 8.1 or newer and WordPress 6.0 or newer. It adds:
GET /wp-json/diazoma/v1/feed?type=post&cursor=&q=&limit=, a feed with keyset paging (limitdefaults to 50, at most 100);/.well-known/wall.json, a manifest built from the settings;<link rel="wall-manifest">and<link rel="wall-feed">inwp_head;- an optional
/xrpage that prints the embed<script>tag.
Install
Section titled “Install”- Download diazoma-wall-0.2.1.zip. In WordPress, open Plugins, Add New, Upload Plugin and upload the zip. A listing on WordPress.org comes later.
- If you work from the source instead, clone github.com/escapeboy/diazoma-wordpress into
wp-content/plugins/diazoma-walland runcomposer install --no-devinside it. Withoutvendor/the plugin falls back to a built-in loader and still works. - Activate the plugin. Activation flushes the rewrite rules.
- Open Settings, Diazoma Wall and choose:
- the post types to publish;
- the accent colour (a warning shows when its contrast against the wall background,
#0e0e10, is below 4.5:1); - the policy (
allow,denyorrecipes-only); - whether to serve the
/xrpage; - the script base URL: the directory that holds
diazoma-embed.js,wall.iife.jsandloader.js, pluswall-hls.jsandwall-dash.jsfor HLS and DASH video (without them such videos offer “watch in the browser”; mp4 still plays). It defaults tohttps://diazoma.app/wall/0.1.0, so a fresh install needs no hosting. Change it to host the files yourself.
A post with a featured image becomes a picture card. A post without one becomes a text card: its title, author, publication date, first category (as the kicker) and excerpt. A post with neither a featured image nor a title is left out.
A post whose first block is a Video block becomes a video card: the file or stream goes in as video, with video_type,
media_type and, for a video from the media library, duration. Its picture is the featured image, or the block’s poster
when that is an image in the media library; a video without a picture stays a text card. A post whose first block is an
Embed block with a YouTube or Vimeo link becomes an embed card (unplayable with the provider and embed URL), and a YouTube
post without a featured image gets YouTube’s thumbnail. See Video.
Only public post types can be requested. A non-public type returns 403 and an unknown one returns 400.
To check the install, open https://your-site/.well-known/wall.json (the manifest) and, if you turned on the /xr page,
https://your-site/xr (the wall). With WooCommerce active, products are one of the post types you can pick.
Change how the wall looks
Section titled “Change how the wall looks”The manifest passes through the diazoma_wall_manifest filter just before it is served. Use it to add a view:
action buttons, the info panel, rows, colours and texts. The shape and limits are in View customization.
add_filter( 'diazoma_wall_manifest', function ( array $manifest, array $settings ): array { $manifest['view'] = array( 'wall' => array( 'rows' => 4 ), 'theme' => array( 'colors' => array( 'accent' => '#e0556f' ) ), ); return $manifest;}, 10, 2 );A filter that does not return an array is ignored.
nginx: allow /.well-known
Section titled “nginx: allow /.well-known”Many nginx configurations deny dotfiles with location ~ /\. { deny all; }. That also blocks
/.well-known/wall.json. Add an exception before that rule:
location ^~ /.well-known/ { try_files $uri /index.php?$args;}Apache needs no change with the standard WordPress .htaccess.