Download the PHP package dogukantokgoz/route-to-postman without Composer
On this page you can find all versions of the php package dogukantokgoz/route-to-postman. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download dogukantokgoz/route-to-postman
More information about dogukantokgoz/route-to-postman
Files in dogukantokgoz/route-to-postman
Package route-to-postman
Short Description Generate Postman collections directly from Laravel routes with structured grouping and documentation.
License MIT
Informations about the package route-to-postman
Route to Postman for Laravel
Generate organized Postman collections directly from your Laravel routes with intelligent automation.

Features
📂 Smart File Structure
The package automatically organizes your Postman collection based on your route prefixes.
- Folders: Created based on the route prefix (e.g.,
api/users->usersfolder). - Requests: Named using the controller method in PascalCase (e.g.,
UserController@store->Store). - Filtering: Routes defined in
routes/api.phpthat do not have a valid controller method are automatically skipped to keep your collection clean.
📝 Intelligent Body Generation
The package analyzes your code to generate sample request bodies for POST, PUT, and PATCH requests.
- FormRequest: If a method uses a
FormRequest, validation rules are used to generate the body. - Model Inference: If no
FormRequestis used, the package infers the Model from the Controller name (e.g.,ProductController->Productmodel). It then uses the model'sfillableattributes to generate the request body.
🔐 Automated Authentication
Forget about manually copying and pasting tokens!
- Login Detection: The package automatically finds routes ending in
loginor containingauth/login. - Auto-Script Injection: A Postman test script is injected into the login request to capture the token.
- Smart Bearer Token Assignment: Bearer token is automatically added to routes that have middleware assigned. Public routes (without middleware) and excluded routes will not receive bearer token authentication.
Expected Login Response:
The script expects the token to be in data.token. Example:
Once you run the Login request in Postman, the token is automatically saved and used for all other requests.
Bearer Token Rules:
- ✅ Added to: Routes with any middleware (except
apimiddleware which is automatically added by Laravel) - ❌ Not added to:
- Routes without middleware (public routes)
- Routes matching patterns in
excluded_routesconfig (login, register, password reset, email verification, etc.)
Excluded Routes Configuration:
You can configure which routes should not receive bearer token in config/postman.php:
⚙️ Configuration
- Collection Name: The Postman collection name is taken from your
APP_NAMEenvironment variable (defaults to 'Laravel Routes').
Installation
Publish the configuration file:
Usage
Run the command to generate your collection:
The collection will be saved to storage/postman/route_collection.json. Import this file into Postman.
License
MIT
All versions of route-to-postman with dependencies
illuminate/support Version ^10.0|^11.0|^12.0
symfony/console Version ^6.0|^7.0