Download the PHP package simsoft/slim without Composer
On this page you can find all versions of the php package simsoft/slim. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Package slim
Short Description A fluent routing wrapper for Slim Framework 4 with simplified request/response helpers, middleware, error handling, API resources, and DataTable support
License MIT
Homepage https://github.com/sim-soft/slim
Informations about the package slim
Simsoft Slim Route
A fluent routing wrapper for Slim Framework 4 that simplifies route setup, request/response handling, middleware, and error handling through a chainable builder API.
Requirements
- PHP >= 8.2
- Composer
Install
Quick Start
Create an index.php entry file:
Visit http://localhost/ to see "Hello World!" or http://localhost/john to
see "Hello John!"
Route Builder API
Everything is configured through a fluent (chainable) builder:
Controllers
Instead of closures, point routes to controller classes for cleaner code:
Register controller routes:
ContainerAwareTrait
Access container services (database, logger, etc.) as magic properties in your controllers:
Request & Response
Global helper functions for reading requests and sending responses:
Full reference: docs/REQUEST_RESPONSE.md
URL Helper
Generate URLs from named routes — no hardcoded paths:
Middleware
Middleware runs on every request (or specific routes) to handle cross-cutting concerns like authentication, CORS, and rate limiting:
| Middleware | Purpose |
|---|---|
Auth |
Authentication + role/permission authorization |
CORS |
Cross-origin resource sharing headers |
CacheOff |
Disable browser caching |
Benchmark |
Response time and memory usage headers |
Logging |
Request/response logging with custom recorder |
RateLimit |
IP-based rate limiting with configurable window |
Quota |
API usage quota per user/key (daily/monthly) |
Csrf |
CSRF token validation for forms and AJAX |
SecurityHeaders |
XSS, clickjacking, MIME sniffing protection |
MaintenanceMode |
503 response with IP bypass |
IpFilter |
Whitelist or blacklist client IPs |
TrailingSlash |
Normalize trailing slashes in URLs |
ContentNegotiation |
Detect preferred format from Accept header |
ContentLength |
Add Content-Length header to responses |
MethodOverride |
Allow forms to simulate PUT/PATCH/DELETE |
Full reference: docs/builtin-middleware.md
Error Handling
Configure how errors are displayed and logged. Hide details in production, show them in development:
Full reference: docs/ERROR_HANDLING.md
Plugins
- DataTable Plugin — Server-side response builder for jQuery DataTables
- API Resources — Data transformation layer for structured API responses
Documentation
📖 https://sim-soft.github.io/slim/
| Topic | Link |
|---|---|
| Route Builder | docs/route-builder.md |
| Defining Routes | docs/defining-routes.md |
| Controllers | docs/controllers.md |
| Middleware | docs/builtin-middleware.md |
| Request & Response | docs/REQUEST_RESPONSE.md |
| API Resources | docs/RESOURCE.md |
| Error Handling | docs/ERROR_HANDLING.md |
| DataTable Plugin | docs/PLUGIN_DATATABLE.md |
Changelog
See CHANGELOG.md. Behaviour changes are called out separately from fixes, so check it before upgrading.
Security
Found a vulnerability? Please report it privately rather than opening a public issue — see SECURITY.md.
License
MIT License. See LICENSE for details.