Documentation

Everything you need to build versioned JSON APIs with Pionia v3.

The example app: Pionia Shop

Hands-on pages follow one small store so names stay consistent:

  • Pionia Shop — a fictional online store + wallet (named after the framework)
  • pionia-shop — the Composer project name used in commands
  • ada@pionia.shop — sample customer in curl examples

Requires PHP 8.5+. Tutorial services: product, customer, order, wallet.

TableWhat it stores
productsCatalog (name, price, stock)
customersShoppers (email, password_hash)
orders / order_itemsCheckouts and line items
wallets / wallet_transactionsBalance and top-ups / payments

Build it in the Pionia Shop tutorial.

Pick your learning path

Getting started

Install Pionia and meet Pionia Shop.

Pionia Shop tutorial

15 steps — scaffold through deploy.

Browse examples

Copy-paste curl payloads and JSON envelopes.

First steps

OrderGuideDescription
1IntroductionInstall with Composer, first ping, meet Pionia Shop
2PHP basicsMinimum PHP (optional)
3Pionia Shop tutorialCatalog, checkout, and wallet step by step
4Glossaryservice, action, switch, envelope

How the documentation is organized

TypeReader goalExamples
TutorialsHands-on; build Pionia ShopShop tutorial
Topic guidesUnderstand conceptsMoonlight overview, Auth
ReferenceLook up APIs and configHelpers, Porm API
How-to guidesOne task, one recipeRoadRunner, Maintenance

What these docs cover

LayerTopics
Getting startedComposer install, PHP basics, Pionia Shop tutorial, app structure, v3 changelog
Building your APIMoonlight, services, actions, validation, generic CRUD, API docs
Database (Porm)Migrations, configuration, queries, filtering, joins, pagination, connections
HTTPEnvelopes, welcome page, middleware, exceptions, routing, collections
SecurityJWT, authentication backends, authorization in services
FrontendVite SPA scaffold, dev proxy, production build
OperationsCLI, bench, RoadRunner, caching, logging, maintenance, production optimize
ExtendingApp providers, Composer packages, helpers, maintainer notes

The API layer

Services · Actions · Validation · Generic services · Moonlight overview · Documenting your API

The data layer (Porm)

Migrations · Getting started · Making queries · Filtering · Joins · Pagination

The HTTP layer

Requests & responses · Welcome page & branding · Middleware · Exceptions · Routing

Security

JWT authentication · Protecting actions · Authentication · Security utilities

Frontend & operations

Vite integration · RoadRunner · Production performance · CLI · Benchmarking · Caching · Logging

Extending Pionia

App providers · Composer packages · Maintainer notes

Getting help

  • Common mistakes — each guide ends with a troubleshooting section
  • Logsstorage/logs/ with DEBUG=true in .env
  • Examplescurl snippets for Pionia Shop actions
  • Resourcespackages, CLI, and links

Community

Common mistakes

  • Starting with advanced topics — follow IntroductionPionia Shop tutorial before auth or RoadRunner.
  • Skipping the glossary — terms like switch, envelope, and action are defined in Glossary.
  • Using maintainer commandsphp pionia new is for framework contributors only; apps install via composer create-project pionia/pionia-app.
  • Old flat URLs — bookmark /documentation/getting-started/introduction/ not /documentation/introduction/ (redirects exist but paths moved).