Download the PHP package andrii-hrechyn/auto-documentation without Composer

On this page you can find all versions of the php package andrii-hrechyn/auto-documentation. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package auto-documentation

Auto Documentation

Generate OpenAPI 3.1 documentation for Laravel APIs with fluent PHP builders, rendered with Redoc.

The typical endpoint is one chain:

The URI, HTTP verb, {path} parameters, operationId, tag and the auth hint all come from your named Laravel route — you never describe what the framework already knows.

Requirements

Installation

The install command creates a docs/ folder (autoloaded as Docs\) with working examples:

Describing your API

Documentation files return values — no global state:

Route-first (recommended)

Explicit composition

Every shortcut expands into the same explicit object graph, which is always available:

Schemas

Full JSON Schema 2020-12 core: type unions (->nullable()), oneOf/anyOf/allOf/not with discriminators, additionalProperties, const, pattern, numeric and length constraints:

Or infer a response schema from a real payload — the example is attached automatically and all keys become required:

Reusable schemas, parameters and responses extend the classes in AutoDocumentation\Components and are emitted under components with $ref automatically. Presets ship for common responses: UnauthorizedResponse (401), ForbiddenResponse (403), ValidationErrorResponse (422, Laravel error shape).

For API Resources, the recommended convention is one SchemaComponent per resource, referenced from every endpoint that returns it — the contract test below keeps the component honest against the real output.

Custom validation rules

fromFormRequest() maps standard Laravel rules out of the box. Register mappers for your own rules — by class for Rule objects, by name for string rules (rule arguments arrive in the matched string):

A matched extension owns the field's schema; required and nullable handling still applies on top.

Generating and serving

The Redoc UI is served at /api/doc (spec at /api/doc/spec) in the environments listed in the config. Set AUTO_DOCUMENTATION_GENERATE_ALWAYS=true locally to regenerate on every page load. Publish the config with:

Keeping the documentation honest

Lint the spec structurally (missing responses, parameter/URI mismatches, dangling $refs, unregistered security schemes and more):

Contract-test real responses against the documentation in your feature tests:

A response that drifts from its documented schema — wrong type, missing required field, undocumented status — fails the test with a field-level diff.

Testing

License

This library is licensed under the MIT License. See the LICENSE file for details.

Credits


All versions of auto-documentation with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2
illuminate/support Version ^11.0|^12.0
symfony/process Version ^7.0
symfony/yaml Version ^7.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package andrii-hrechyn/auto-documentation contains the following files

Loading the files please wait ...