API Explorer Plugin: Interactive REST API Sandbox
Blog Post: API Explorer Plugin
SEO Meta
Meta Title: API Explorer Plugin: Interactive REST API Sandbox for PolyCMS Meta Description: Discover the built-in API Explorer plugin for testing all PolyCMS REST API endpoints with live data, auto-generated code samples, and real-time response inspection including Media operations. Focus Keyphrase: PolyCMS API Explorer
Title
API Explorer Plugin: Interactive REST API Sandbox
Description
The API Explorer is a built-in developer tool that provides an interactive sandbox for testing all PolyCMS REST API endpoints directly from your admin panel. No need for external tools like Postman - you can test GET, POST, PUT, and DELETE operations with live data right inside your CRM.
Key Features
- Live CRUD Testing: Execute real API calls against your data with one click. The Explorer auto-generates request bodies with timestamped test data for easy identification.
- Multi-Language Code Samples: Switch between cURL, PHP, JavaScript (Fetch API), and Python (requests) with tab-based navigation. Copy the generated code directly into your project.
- Visual Data Table: Results are rendered in a clean, sortable table with status badges, clickable frontend links, and detail inspection modals.
- Smart PUT Testing: When testing updates, the Explorer reads the current record title and appends a timestamp - preventing title duplication while making changes clearly visible.
- Auto-Reload: After any successful POST, PUT, or DELETE operation, the data list automatically refreshes to show the latest state.
- Media Resource Support: Full support for Media operations - list files from the
blog_mediadatabase with pagination, upload new files with security validation, and delete files with cascade cleanup.
Supported Resources
| Resource | GET | POST | PUT | DELETE | Notes |
|---|---|---|---|---|---|
| Posts | Yes | Yes | Yes | Yes | Full CRUD |
| Pages | Yes | Yes | Yes | Yes | Full CRUD |
| Categories | Yes | Yes | Yes | Yes | Full CRUD |
| Tags | Yes | Yes | Yes | Yes | Full CRUD |
| Media | Yes | Yes | -- | Yes | Database-backed, paginated |
Media Testing in API Explorer
The Media tab in API Explorer allows you to:
- List Media - View all uploaded files from the
blog_mediadatabase with pagination, search, and MIME filtering. - Upload Media - Test file uploads with the built-in multipart/form-data form. The response includes the new
media_idfor immediate use. - Delete Media - Remove files with full cascade cleanup (physical file + DB record + post/page references).
All media operations go through the same 6-layer security pipeline as external API calls, ensuring consistent behavior during testing.
How to Access
- Navigate to Blog > API Explorer in the admin menu.
- Make sure the REST API is enabled in Blog > Settings > REST API.
- Select a resource (Posts, Pages, Categories, Tags, Media) from the tabs.
- Choose your HTTP method (GET, POST, PUT, DELETE).
- Click Send to execute the request.
Security Note
The API Explorer uses your site's configured API key internally. All requests go through the same authentication and rate-limiting pipeline as external API calls, ensuring consistent behavior during testing.
Who Is This For?
This tool is designed for developers building plugins, custom themes, headless frontends (React, Vue, Next.js), or integrating CMS data with external platforms like mobile apps, SPA frontends, and third-party services.