REST API
Grav's RESTful API provides headless access to your site's content, media, configuration, users, and system management. Built for AI agents, custom frontends, mobile apps, and the next-generation admin interface.
Getting Started
Getting Started with the Grav API The Grav API Plugin adds a RESTful API to your Grav site, providing full headless access to pages, media, configuration, users, and system management. Requirements Grav CMS 2.0+ PHP 8.3+ Login Plugin 3.8+ Installation Install via GPM: bin/grav...
Authentication
Authentication The API supports three authentication methods, tried in order. Requests to public endpoints (token generation, translations) skip authentication. API Keys The recommended method for server-to-server integrations and CLI tools. Generate a key: bin/plugin api keys:generate --u...
Rest API Reference
Complete REST API endpoint reference with parameters, examples, and response codes. All endpoints are prefixed with the configured route (default: /api/v1).
Events
API Events The API fires events before and after every write operation, and uses events to let plugins extend the Admin2 UI (sidebars, menubars, widgets, context panels, settings panels, custom field components, custom reports). Plugins react to these events to validate, modify data, cancel operat...
Developer Guide
API Developer Guide This guide covers how plugin developers can integrate with the Grav API and Admin2 — the new Svelte 5 SPA admin plugin (powered by the API) that supersedes the deprecated classic Admin plugin in Grav 2.0. Extending the API Any plugin can add custom API endpoints. See the P...