PHPackages                             ebsp/resting - 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. ebsp/resting

ActiveLibrary

ebsp/resting
============

Simple REST library for Laravel

v6.2.0(1mo ago)38.6k↑400%2[4 issues](https://github.com/ebsp/resting/issues)[3 PRs](https://github.com/ebsp/resting/pulls)PHPPHP ^8.2|^8.3|^8.4

Since Mar 11Pushed 1mo ago2 watchersCompare

[ Source](https://github.com/ebsp/resting)[ Packagist](https://packagist.org/packages/ebsp/resting)[ RSS](/packages/ebsp-resting/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (10)Dependencies (5)Versions (79)Used By (0)

Resting
=======

[](#resting)

Simple REST library for Laravel

This is a pendant to Laravel’s built in resources. It’s aimed to be more type aware, strict and to enforce a layer between models and API interfaces.

Please note
-----------

[](#please-note)

This project is developed for use in personal projects. It's currently not advised to use in production projects, as breaking changes will happen.

Resources
---------

[](#resources)

Resources are classes representing the data you want to send and receive in your API. Resources are made to separate your data layer from your API interface, making it more flexible. A resource is made up of fields (properties), each having a type. The field type is aware of the fields data type and validation criteria.

Resources should extend `Seier\Resting\Resource`.

### Fields

[](#fields)

The Resting package comes with a number of predefined field types. The following field types are included:

- `ArrayField`
- `BoolField`
- `CarbonField`
- `DateField`
- `EnumField`
- `Field`
- `IntField`
- `NumberField`
- `PasswordField`
- `ResourceField`
- `ResourceArrayField`
- `StringField`

You may define your own depending on your needs. Each field type implements `public function set($value)` which is responsible for casting and/or validating the field input when being set.

An instance of a field type is defined on each of the resource’s properties through the resource’s constructor. For instance if the resource expose an attribute `id` the corresponding field type could be `IntField`

### An example

[](#an-example)

An example resource could look like:

```
class UserResource extends \Seier\Resting\Resource
{
	public $id;
	public $name;

	public function __construct()
	{
		$this->id = new IntField;
		$this->name = new StringField;
	}
}

```

###  Health Score

56

—

FairBetter than 97% of packages

Maintenance76

Regular maintenance activity

Popularity27

Limited adoption so far

Community14

Small or concentrated contributor base

Maturity89

Battle-tested with a long release history

 Bus Factor1

Top contributor holds 84.7% 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 ~35 days

Recently: every ~2 days

Total

63

Last Release

52d ago

Major Versions

v1.1.0 → v2.0.02020-03-24

v2.6.0 → v3.0.02020-12-18

v3.0.0 → v4.0.02021-02-01

v4.9.0 → v5.0.02021-12-29

v5.20.0 → v6.0.02026-03-11

PHP version history (4 changes)v4.0.0PHP ^7.0 || ^8.0

v5.2.0PHP ^8.0

v5.4.0PHP ^8.2

v6.0.0PHP ^8.2|^8.3|^8.4

### Community

Maintainers

![](https://www.gravatar.com/avatar/94b0a2b01d629673d5ecb75671a3097d225b695c58a17ac11954aff49ebc6fa1?d=identicon)[ebsp](/maintainers/ebsp)

---

Top Contributors

[![ebsp](https://avatars.githubusercontent.com/u/1406975?v=4)](https://github.com/ebsp "ebsp (61 commits)")[![Thomas-Rosenkrans-Vestergaard](https://avatars.githubusercontent.com/u/15520300?v=4)](https://github.com/Thomas-Rosenkrans-Vestergaard "Thomas-Rosenkrans-Vestergaard (9 commits)")[![aawnu](https://avatars.githubusercontent.com/u/2266126?v=4)](https://github.com/aawnu "aawnu (1 commits)")[![KLIM8D](https://avatars.githubusercontent.com/u/786271?v=4)](https://github.com/KLIM8D "KLIM8D (1 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/ebsp-resting/health.svg)

```
[![Health](https://phpackages.com/badges/ebsp-resting/health.svg)](https://phpackages.com/packages/ebsp-resting)
```

###  Alternatives

[anourvalar/eloquent-serialize

Laravel Query Builder (Eloquent) serialization

11320.2M21](/packages/anourvalar-eloquent-serialize)[namu/wirechat

A Laravel Livewire messaging app for teams with private chats and group conversations.

54324.5k](/packages/namu-wirechat)[statamic-rad-pack/runway

Eloquently manage your database models in Statamic.

135192.6k5](/packages/statamic-rad-pack-runway)

PHPackages © 2026

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