Docs
Reference for developers building on Basehim: themes, apps, the REST API and AI agents.
35 articles
-
App permissions
How an app declares what it will touch, how site owners approve it, what happens when a call isn't allowed, the full permission catalogue, logs and the static scanner - and what the model does not protect against.
-
AJAX actions
Register browser actions with $this->ajax() and call them with Basehim.ajax. Core checks the session, CSRF token, capability, input schema and rate limit before your handler runs. Includes the full option and error reference.
-
Admin screens, routes and UI components
Add pages to the admin with adminGet() and adminPost(), control who can open them, handle forms safely with CSRF tokens and flash messages, and use the admin's buttons, cards, dialogs and toasts. Public pages have their own guide.
-
The App API: content, cache, mail, HTTP and scheduling
Everything an app can ask core for through $this->api() - posts, pages, custom types, media, users, comments, terms, menus, settings, cache, mail, outbound HTTP and scheduled tasks - with examples.
-
Hooks and filters
How actions and filters work in Basehim, with the complete list of core hooks - content, users, comments, media, mail, admin, editor, SEO, MCP and routing - and the arguments each one passes.
-
SEO, dates and images in themes
What core's SEO service prints so your theme doesn't have to, how to adjust it per page or site-wide, how to show dates in the site's timezone, and how to print responsive featured images.
-
Customizer options, menus and widgets
Declare Customizer options in theme.json and use them as CSS variables, add menu locations and widget areas, ship your own widgets, style the comment form and author box, and register filters from boot.php.
-
Theme reference: variables and helpers
Every variable a template receives, the fields on a post row, and every helper function a theme can call: menus, widgets, comments, authors, images, dates, settings and assets.
-
Updates, migrations and backups
How one-click updates work, what they never touch, how database migrations run, how to update a git checkout, and how to ship updates for your own apps and themes.
-
Configuration and the .env file
Every setting Basehim reads from .env, what it does, and the ones to change for debugging, proxies, CORS, shared databases and token security.