PHPackages                             maxcarter/restup - 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. maxcarter/restup

ActiveLibrary[API Development](/categories/api)

maxcarter/restup
================

A customizable Representational State Transfer (REST) Application Program Interface (API) designed to provide a quick set of tools for developers to quickly build their own API.

v0.1.1(10y ago)115PHPPHP &gt;=5.3.0

Since Oct 3Pushed 10y ago1 watchersCompare

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

READMEChangelog (3)DependenciesVersions (3)Used By (0)

REST-UP
=======

[](#rest-up)

A customizable Representational State Transfer (REST) Application Program Interface (API) designed to provide a quick set of tools for developers to quickly build their own API.

**Note**: this repository is currently under construction.

Features
--------

[](#features)

- Supports basic CRUD (Create Read Update Delete) operations
- Supports HTTP requests GET POST PUT and DELETE
- Can interact with anything that can send an HTTP request
- Data is returned in JSON (JavaScript Object Notation) format
- MySQL database preset
- Protection against MySQL injection
- Interfacing with new tables is as simple as adding new models
- Customizable controllers to interface with other databases

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

[](#installation)

REST-UP can be installed using [composer](https://getcomposer.org/):

```
composer require maxcarter/restup

```

OR by simply extracting all files to the desired location in your website directory:

```
git clone https://github.com/maxcarter/REST-UP.git
rsync -r REST-UP/* Path/To/Destination

```

### Test

[](#test)

Once installed you should be able to see the welcome text at: `http://YourDomain.com/PathToAPI`

Another way to test the API is to install the Chrome Extension [Postman](https://chrome.google.com/webstore/detail/postman/fhbjgbiflinjbdggehcddcbncdddomop) then open the app and send http requests to `http://YourDomain.com/PathToAPI`.

### Server Requirements

[](#server-requirements)

- PHP v5.6+
- MySQL v5.6+

### MySQL Schema

[](#mysql-schema)

The sample code is based on the following MySQL table:

```
CREATE TABLE `person` (
  `id` int NOT NULL AUTO_INCREMENT,
  `Name` varchar(255) DEFAULT NULL,
  `City` varchar(255) DEFAULT NULL,
  `Email` varchar(255) DEFAULT NULL
);

```

To insert sample data into this database:

```
INSERT INTO `person` (`Name`, `City`, `Email`) VALUES
('Clark Kent', 'Smallville', 'superman@justiceleague.com');

```

Configuration
-------------

[](#configuration)

To configure this REST-API to work with your database follow these steps:

1. Modify `config.php` with the appropriate credentials.
2. Create your own DTO (Data Transfer Object) and place it in the `models` directory. (see [models/person.php](https://github.com/maxcarter/REST-API/blob/master/models/person.php) for a sample DTO)

Customize
---------

[](#customize)

This REST API can be customized to work with different databases. The default preset is MySQL, however, you can create your own database controller to interface with different databases and implement custom functionality.

To create a custom controller follow these steps:

1. Create a new PHP file to implement the *Controller* class (see [controllers/mysql.php](https://github.com/maxcarter/REST-API/blob/master/controllers/mysql.php) for an example)
2. Ensure your class implements the required CRUD functions.
3. Modify [config.php](https://github.com/maxcarter/REST-API/blob/master/config/config.php) to include your controller's file name and database credentials.

### Required Functions

[](#required-functions)

```
/**
 * Create a new entry
 * @param [object] - The entry to be inserted
 * @return [object] - JSON result of insertion
 */
postValue($data);

/**
 * Read all entries
 * @return [array] - An array of objects
 */
getValues();

/**
 * Read a single entry
 * @param [int] - The unique id of the entry
 * @return [object] - The requested entry
 */
getValue($value);

/**
 * Update an entry
 * @param [object] - The entry to be updated
 * @return [object] - JSON result of update
 */
putValue($data);

/**
 * Delete a single entry
 * @param [int] - The unique id of the entry
 * @return [object] - JSON result of deletion
 */
deleteValue($value);

```

Future Updates
--------------

[](#future-updates)

- Live Demo
- HTTP request documentation
- More database presets

###  Health Score

23

—

LowBetter than 27% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity49

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% 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 ~1 days

Total

2

Last Release

3880d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/8ec405739a92d37297d4789417c0b2a69f637234240db273ee173169a225afe4?d=identicon)[maxcarter](/maintainers/maxcarter)

---

Top Contributors

[![maxcarter](https://avatars.githubusercontent.com/u/6405242?v=4)](https://github.com/maxcarter "maxcarter (59 commits)")

---

Tags

microframeworkphprest-apirest-router

### Embed Badge

![Health badge](/badges/maxcarter-restup/health.svg)

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

###  Alternatives

[stripe/stripe-php

Stripe PHP Library

4.0k143.3M480](/packages/stripe-stripe-php)[twilio/sdk

A PHP wrapper for Twilio's API

1.6k92.9M272](/packages/twilio-sdk)[facebook/php-business-sdk

PHP SDK for Facebook Business

90821.9M34](/packages/facebook-php-business-sdk)[meilisearch/meilisearch-php

PHP wrapper for the Meilisearch API

74513.7M114](/packages/meilisearch-meilisearch-php)[google/gax

Google API Core for PHP

265103.1M454](/packages/google-gax)[google/common-protos

Google API Common Protos for PHP

173103.7M50](/packages/google-common-protos)

PHPackages © 2026

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