PHPackages                             comphp/api - 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. comphp/api

ActiveLibrary[API Development](/categories/api)

comphp/api
==========

API request handling and JSON response support for PHP applications

0.3(2w ago)01MITPHPPHP ^8.5

Since May 20Pushed 2w agoCompare

[ Source](https://github.com/commonphp/api)[ Packagist](https://packagist.org/packages/comphp/api)[ RSS](/packages/comphp-api/feed)WikiDiscussions master Synced 1w ago

READMEChangelog (1)Dependencies (5)Versions (2)Used By (0)

CommonPHP API
=============

[](#commonphp-api)

CommonPHP API provides the JSON/API surface layer for CommonPHP applications. It defines the structure for API-focused request handling, response generation, and integration with runtime, HTTP, routing, and action packages.

The package is intended for application endpoints that return structured data rather than rendered pages, keeping API behavior explicit, predictable, and separate from traditional web page rendering.

Requirements
------------

[](#requirements)

- PHP `^8.5`
- `comphp/runtime:^0.3`
- `comphp/http:^0.3`

Installation
------------

[](#installation)

Once this package is available through your Composer repositories, install it with:

```
composer require comphp/api
```

Usage
-----

[](#usage)

```
