PHPackages                             parziphal/parse - 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. [Database &amp; ORM](/categories/database)
4. /
5. parziphal/parse

ActiveLibrary[Database &amp; ORM](/categories/database)

parziphal/parse
===============

An Eloquent-like interface for Parse

v0.0.8(6y ago)172.1k14[7 issues](https://github.com/Parziphal/parse/issues)[5 PRs](https://github.com/Parziphal/parse/pulls)MITPHPPHP &gt;=5.6CI failing

Since May 12Pushed 6y ago3 watchersCompare

[ Source](https://github.com/Parziphal/parse)[ Packagist](https://packagist.org/packages/parziphal/parse)[ RSS](/packages/parziphal-parse/feed)WikiDiscussions master Synced 2mo ago

READMEChangelog (1)Dependencies (3)Versions (14)Used By (0)

Laravel Parse
=============

[](#laravel-parse)

This library pretends to make Parse usable in a Eloquent-like manner. For Laravel 5.2+.

Features
--------

[](#features)

- Initialize Parse automatically.
- Use facade classes that wraps Parse's classes, exposing an Eloquent-like interface.
- Enabled to work with Parse's relations.
- User authentication with username/password combinations and/or with Facebook.
- Command to create ObjectModels (`artisan parse:model SomeModel`).

Setup
-----

[](#setup)

Install the library with Composer:

```
composer require parziphal/parse

```

Add the service provider in your `config/app.php` file:

```
'providers' => [
    // etc...
    Parziphal\Parse\ParseServiceProvider::class,
],
```

Publish the configuration file by running:

```
php artisan vendor:publish --tag=parse

```

The command creates a file at `config/parse.php`, where you can set your Parse server configuration, but instead of editing that file, you can set your configuration in your `.env` file by setting the following variables:

```
PARSE_APP_ID=Your_App_ID
PARSE_REST_KEY=REST_API_key
PARSE_MASTER_KEY=Master_key
PARSE_SERVER_URL=http://127.0.0.1:1337
PARSE_MOUNT_PATH=/parse

```

The `REST_API_key` variable is optional as Parse doesn't require that key anymore.

ObjectModels
------------

[](#objectmodels)

Create models extending the `Parziphal\Parse\ObjectModel` class:

```
namespace App;

use Parziphal\Parse\ObjectModel;

class Post extends ObjectModel
{
}
```

And that's it. However, remember that you can use the Artisan command `php artisan parse:model SomeModel` to easily create a model.

ObjectModels behave just as an Eloquent model, so you can do stuff like:

```
// Instantiate with data
$post = new Post(['title' => 'Some Title']);

// Create
$post = Post::create(['title' => 'Some Title', 'acl' => $acl]);

// Get objectId
echo $post->id;   // EWFppWR4qf
echo $post->id(); // EWFppWR4qf

// Update
$post->title = 'New Title';
$post->save();
// or
$post->update(['foo' => true]);

// Find or fail
$post = Post::findOrFail($id);

// Delete is like Eloquent's delete: it will delete the object
$post->delete();
// To remove a key (ParseObject's `delete` method), use `removeKey`
$post->removeKey($someKey);

// Create a pointer object
$pointer = Post::pointer($postId);
```

Relations
---------

[](#relations)

Supported relations are:

- `belongsTo` and its complement `hasMany`
- `belongsToMany`, which stores parents ids in an array, and its complement `hasManyArray`

You use them like this:

```
use Parziphal\Parse\ObjectModel;

class Post extends ObjectModel
{
    public function categories()
    {
        return $this->belongsToMany(Category::class);
    }

    public function user()
    {
        return $this->belongsTo(User::class);
    }
}

// Having the above class where categories() is a `belongsToMany` relation,
// the class Category would have a posts() relation of type `hasManyArray`:
class Category extends ObjectModel
{
    public function posts()
    {
        return $this->hasManyArray(Post::class);
    }
}

// This would be the User class:
class User extends ObjectModel
{
    public function posts()
    {
        return $this->hasMany(Post::class);
    }
}

// Relate a post with a category (belongsToMany):
$post->categories()->save($someCategory);

// Relate a category with posts (inverse of above, hasManyArray):
$category->posts()->save($post);
$category->posts()->create($arrayWithPostData);

// Relate a post with a user (belongsTo):
$post->user = $user;
$post->save();

// Relate a use with a post (inverse of above, hasMany):
$user->posts()->create($arrayWithPostData);
```

Queries
-------

[](#queries)

`Parziphal\Parse\Query` is a wrapper for `Parse\ParseQuery`, which also behaves like Eloquent Builder:

```
// Note that `get` is like Eloquent Builder's `get`, which executes the query,
// and not like ParseQuery's `get` which finds an object by id.
$posts = Post::where('createdAt', 'name = $data['name'];
    $user->username = $data['email'];
    $user->password = $data['password'];
    $user->signUp();

    return $user;
}
```

Notice that the email is stored as the username, this is because on Parse, the `username` field is the login name of the user, so if you require users to login using their email, you'll have to store their email under the `username` key.

Inspiration from
----------------

[](#inspiration-from)

- GrahamCampbell's [Laravel-Parse](https://github.com/GrahamCampbell/Laravel-Parse/)
- HipsterJazzbo's [LaraParse](https://github.com/HipsterJazzbo/LaraParse)

License
-------

[](#license)

MIT

###  Health Score

30

—

LowBetter than 64% of packages

Maintenance12

Infrequent updates — may be unmaintained

Popularity27

Limited adoption so far

Community18

Small or concentrated contributor base

Maturity55

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 96% 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 ~121 days

Recently: every ~269 days

Total

13

Last Release

2199d ago

PHP version history (3 changes)v0.0.0-alpha1PHP &gt;=5.5

v0.0.0-beta1PHP &gt;=5.5.9

v0.0.5PHP &gt;=5.6

### Community

Maintainers

![](https://www.gravatar.com/avatar/e2e1688729f739d2cf314e7b23784c5563b1eb4e0bece7763b038b8d6013ea4a?d=identicon)[Pop](/maintainers/Pop)

---

Top Contributors

[![Parziphal](https://avatars.githubusercontent.com/u/5176023?v=4)](https://github.com/Parziphal "Parziphal (96 commits)")[![abronin](https://avatars.githubusercontent.com/u/1532185?v=4)](https://github.com/abronin "abronin (1 commits)")[![evaldas-leliuga](https://avatars.githubusercontent.com/u/1867113?v=4)](https://github.com/evaldas-leliuga "evaldas-leliuga (1 commits)")[![nafplann](https://avatars.githubusercontent.com/u/7114259?v=4)](https://github.com/nafplann "nafplann (1 commits)")[![warrenca](https://avatars.githubusercontent.com/u/771478?v=4)](https://github.com/warrenca "warrenca (1 commits)")

---

Tags

laravelparselaravelsdkeloquentparseparse-sdk

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/parziphal-parse/health.svg)

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

###  Alternatives

[anourvalar/eloquent-serialize

Laravel Query Builder (Eloquent) serialization

11320.2M21](/packages/anourvalar-eloquent-serialize)[bavix/laravel-clickhouse

Eloquent model for ClickHouse

72214.1k2](/packages/bavix-laravel-clickhouse)[stayallive/laravel-eloquent-observable

Register Eloquent model event listeners just-in-time directly from the model.

2928.9k7](/packages/stayallive-laravel-eloquent-observable)[waad/laravel-model-metadata

A robust Laravel package for handling metadata with JSON casting, custom relation names, and advanced querying capabilities.

823.1k](/packages/waad-laravel-model-metadata)[mozex/laravel-scout-bulk-actions

A Laravel Scout extension for bulk importing and flushing of all models.

1033.4k](/packages/mozex-laravel-scout-bulk-actions)

PHPackages © 2026

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