PHPackages                             baraja-core/structured-api-doc - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [API Development](/categories/api)
4. /
5. baraja-core/structured-api-doc

ActiveLibrary[API Development](/categories/api)

baraja-core/structured-api-doc
==============================

Automatically generated documentation by parsing of Structured API endpoints.

v2.3.1(3y ago)24.5k↓100%1[1 issues](https://github.com/baraja-core/structured-api-doc/issues)[1 PRs](https://github.com/baraja-core/structured-api-doc/pulls)PHPPHP ^8.1

Since Apr 29Pushed 1y ago1 watchersCompare

[ Source](https://github.com/baraja-core/structured-api-doc)[ Packagist](https://packagist.org/packages/baraja-core/structured-api-doc)[ Docs](https://github.com/baraja-core/structured-api-doc)[ RSS](/packages/baraja-core-structured-api-doc/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (10)Dependencies (11)Versions (24)Used By (0)

   ![BRJ logo](https://camo.githubusercontent.com/813c67e02a7ab7e4dc900316a4521c3ddf5846fe2cabba7140f3f4b78afda198/68747470733a2f2f63646e2e62726a2e6170702f696d616765732f62726a2d6c6f676f2f6c6f676f2d6461726b2e706e67)
 [BRJ organisation](https://brj.app)

---

Structured API Documentation
============================

[](#structured-api-documentation)

Fully automated tool for documentation.

📦 Installation
--------------

[](#-installation)

It's best to use [Composer](https://getcomposer.org) for installation, and you can also find the package on [Packagist](https://packagist.org/packages/baraja-core/structured-api-doc) and [GitHub](https://github.com/baraja-core/structured-api-doc).

To install, simply use the command:

```
$ composer require baraja-core/structured-api-doc
```

You can use the package manually by creating an instance of the internal classes, or register a DIC extension to link the services directly to the Nette Framework.

[![Rendered documentation about Article](doc/sample-article.png)](doc/sample-article.png)

Idea
----

[](#idea)

When developing any application, developers must maintain both the source code itself and documentation describing the general functionality for others. Writing documentation in a separate system takes more time, leads to human error, and makes the documentation obsolete over time. BRJ solves this problem by allowing developers to write documentation directly into comments in the source code, and then always machine-generate the page consistently.

How to start using BRJ documentation?

1. Use Structured API endpoints (implementing [Baraja Structured API](https://github.com/baraja-core/structured-api)) to your application
2. Install this package
3. Open URL `/api-documentation`

Sample endpoint implementation with native comments:

```
/**
 * Common API endpoint for robust article manipulation.
 *
 * @endpointName Article manager
 */
final class ArticleEndpoint extends BaseEndpoint
{
   #[Inject]
   public ArticleManagerAccessor $articleManager;

   /**
    * @param string $locale in format "cs" or "en"
    * @param int $page real page number for filtering, 1 => first page ... "n" page
    * @param string|null $filterTitle filter by words in title?
    * @param string|null $filterFrom find all articles from this date
    * @param string|null $filterTo find all articles to this date
    */
   public function actionDefault(string $locale, int $page = 1, ?string $filterTitle = null, ?string $filterFrom = null, ?string $filterTo = null): void
   {
      // Here is some body...
```

Designed for developers
-----------------------

[](#designed-for-developers)

We understand that maintaining data structures in PHP and on the frontend can be challenging, so the library includes a native button to export any response structure to TypeScript:

[![Native TypeScript export](doc/typescript.png)](doc/typescript.png)

📄 License
---------

[](#-license)

`baraja-core/structured-api-doc` is licensed under the MIT license. See the [LICENSE](https://github.com/baraja-core/template/blob/master/LICENSE) file for more details.

###  Health Score

35

—

LowBetter than 80% of packages

Maintenance17

Infrequent updates — may be unmaintained

Popularity21

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity74

Established project with proven stability

 Bus Factor1

Top contributor holds 96.2% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~48 days

Recently: every ~123 days

Total

19

Last Release

1336d ago

Major Versions

v1.2.0 → v2.0.02021-02-11

PHP version history (5 changes)v1.0.0PHP &gt;=7.1.0

v1.1.0PHP &gt;=7.4.0

v1.2.0PHP ^7.4 || ^8.0

v2.0.0PHP ^8.0

v2.3.0PHP ^8.1

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/3382204?v=4)[baraja](/maintainers/baraja)[@baraja](https://github.com/baraja)

---

Top Contributors

[![janbarasek](https://avatars.githubusercontent.com/u/4738758?v=4)](https://github.com/janbarasek "janbarasek (76 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (1 commits)")[![dependabot-preview[bot]](https://avatars.githubusercontent.com/in/2141?v=4)](https://github.com/dependabot-preview[bot] "dependabot-preview[bot] (1 commits)")[![ImgBotApp](https://avatars.githubusercontent.com/u/31427850?v=4)](https://github.com/ImgBotApp "ImgBotApp (1 commits)")

---

Tags

apiarticledocumentationfrontendgeneratorjavascriptjsphptypescript

###  Code Quality

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/baraja-core-structured-api-doc/health.svg)

```
[![Health](https://phpackages.com/badges/baraja-core-structured-api-doc/health.svg)](https://phpackages.com/packages/baraja-core-structured-api-doc)
```

###  Alternatives

[worksome/graphlint

A static analysis tool for GraphQL

13189.4k](/packages/worksome-graphlint)[orisai/object-mapper

Raw data mapping to validated objects

1133.5k2](/packages/orisai-object-mapper)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
