Download the PHP package diversified-design/php-blueprint without Composer

On this page you can find all versions of the php package diversified-design/php-blueprint. 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 php-blueprint

PHP Blueprint

A reflection-based tool that generates a JSON blueprint of a PHP library's class signatures, optimised for use as LLM context.

Purpose

When providing library context to coding agents (like Claude Code), you want the class signatures (methods, types, docblocks) without the implementation noise. This tool gives you the equivalent of TypeScript .d.ts files or C/C++ headers — the public contract without implementation details.

Installation

Usage

Options

Option Short Description
--output -o Output JSON file path (default: blueprint.json in working directory)
--namespace Filter by namespace prefix (e.g. Vendor\\Package)
--exclude Exclude namespace prefix (repeatable)
--include-private Include private/protected members
--include-internal Include \Internal\ namespace classes
--short-docs Truncate doc summaries to first sentence
--compact-enums Truncate large constant/enum lists (>5 entries)
--format -f Output format: json, toon (experimental), or both (default: json)
--config -c Path to config file
--no-config Ignore config file

Configuration

Create a .blueprint.config.php in your project root:

All keys are optional. When a config file is present, you can run Blueprint with no arguments:

CLI arguments always override config values. Use --no-config to ignore the config file, or --config path/to/config.php to use a different one.

Composer Scripts

Add to your project's composer.json:

Then run with composer blueprint.

CI/CD

Output Format

The extractor generates pretty-printed JSON:

Only non-empty fields are included. The type field is omitted for plain classes (only shown for interfaces, traits, and enums).

Output Modes

Public-Only (Default)

Extracts only public methods and properties — the true public API surface.

Use for: LLM context (most token-efficient), API documentation, public interface contracts.

Full Mode (--include-private)

Includes private and protected members.

Use for: Internal refactoring analysis, understanding implementation details, migration planning.

Writing Code That Blueprints Well

Blueprint extracts what's in your source — it can't invent context that isn't there. The more information your code carries in its signatures and docblocks, the more useful the blueprint is to an LLM agent. Here's what matters most:

Type everything

Blueprint captures parameter types, return types, and property types. When a PHPStan/Psalm @param, @return, or @var docblock type is present, Blueprint uses it instead of the native type hint — giving agents the full picture.

Write summary docblocks

Blueprint extracts the first paragraph of each class and method docblock (everything before the first @tag or blank line). This becomes the — description in the output. One or two sentences that explain what the method does and when you'd use it:

Document parameters with @param

Blueprint extracts @param descriptions and appends them as inline comments next to each parameter. This is especially valuable for parameters whose purpose isn't obvious from the type alone:

In the blueprint, this becomes:

Declare @throws

Blueprint appends @throws types to method signatures. This tells agents which exceptions to handle:

Use meaningful names

Parameter names appear directly in the blueprint. $baseDirectory communicates more than $dir. $overwriteNewerFiles communicates more than $force. Since the blueprint may be the only context an agent has, every name carries weight.

Use constants and enums

Blueprint extracts constant names and values, and enum cases with their backing values. Well-named constants tell an agent what valid states and options exist:

Define clear interfaces

Blueprint captures the full class hierarchy — extends, implements, and uses. Well-defined interfaces and abstract classes give agents the contract to code against without needing to read implementations.

How It Works

Blueprint uses static analysis via BetterReflection (which builds on nikic/php-parser) to extract class signatures. No code is executed — source files are parsed, not loaded. This means:

Token Efficiency

For LLM context, token efficiency matters:

Requirements

Limitations

License

MIT


All versions of php-blueprint with dependencies

PHP Build Version
Package Version
Requires php Version >=8.2
helgesverre/toon Version ^3.1
phpstan/phpdoc-parser Version ^2.3
roave/better-reflection Version ^6.69
symfony/console Version ^8.0
symfony/filesystem Version ^8.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 diversified-design/php-blueprint contains the following files

Loading the files please wait ...