PHPackages                             jay-patel/service-repository - 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. jay-patel/service-repository

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

jay-patel/service-repository
============================

A package for implementing the repository pattern in Laravel applications, providing a structured approach to data access and manipulation. It creates service, repository, interfaces and migration and model.

13PHP

Since Mar 4Pushed 2y ago1 watchersCompare

[ Source](https://github.com/novaprime-code/service-repository-pattern)[ Packagist](https://packagist.org/packages/jay-patel/service-repository)[ RSS](/packages/jay-patel-service-repository/feed)WikiDiscussions main Synced today

READMEChangelogDependenciesVersions (1)Used By (0)

Laravel Service Repository Package
==================================

[](#laravel-service-repository-package)

[![License](https://camo.githubusercontent.com/08cef40a9105b6526ca22088bc514fbfdbc9aac1ddbf8d4e6c750e3a88a44dca/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c6963656e73652d4d49542d626c75652e737667)](LICENSE.md)

Introduction
------------

[](#introduction)

Welcome to the Laravel Service Repository Package! This package streamlines the generation of files for implementing the service repository pattern in Laravel projects. By automating the creation of essential elements, it saves you time and ensures consistency in your codebase.

Features
--------

[](#features)

- **Efficient File Generation**: Automatically generates repository interfaces and implementations, service interfaces and implementations, model files, and optionally API controllers.
- **Customizable**: Easily adjust file structure and content using stubs and configuration options.
- **User-Friendly**: Simple command-line interface requiring just the model name to generate the necessary files.
- **Tested**: Unit tests guarantee the package's reliability and functionality.

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

[](#installation)

### 1. Install via Composer

[](#1-install-via-composer)

```
composer require jay-patel/service-repository:^1.0.0
```

### 2. Publish Configuration File

[](#2-publish-configuration-file)

```
php artisan vendor:publish --provider="JayPatel\ServiceRepository\ServiceRepositoryProvider"
```

Usage
-----

[](#usage)

### Generate Service Repository Files

[](#generate-service-repository-files)

To generate the necessary files for a model, run the following command:

```
php artisan make:service-repository ModelName
```

Replace `ModelName` with the name of the model for which you want to generate the files. This command will create the following files:

- Repository interface and implementation
- Service interface and implementation
- Model file and migration
- Optionally, an API controller

###  Health Score

13

—

LowBetter than 1% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity5

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity19

Early-stage or recently created project

 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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/b77a9182be57f499c99cf251de1a0e1e7daf5bdf8a4cb572cab3b179d0143799?d=identicon)[novaprime-code](/maintainers/novaprime-code)

---

Top Contributors

[![novaprime-code](https://avatars.githubusercontent.com/u/71209536?v=4)](https://github.com/novaprime-code "novaprime-code (7 commits)")

### Embed Badge

![Health badge](/badges/jay-patel-service-repository/health.svg)

```
[![Health](https://phpackages.com/badges/jay-patel-service-repository/health.svg)](https://phpackages.com/packages/jay-patel-service-repository)
```

###  Alternatives

[jdorn/sql-formatter

a PHP SQL highlighting library

3.9k117.2M118](/packages/jdorn-sql-formatter)[propel/propel1

Propel is an open-source Object-Relational Mapping (ORM) for PHP5.

8351.6M87](/packages/propel-propel1)[pgvector/pgvector

pgvector support for PHP

198741.5k12](/packages/pgvector-pgvector)[jfelder/oracledb

Oracle DB driver for Laravel

11518.4k](/packages/jfelder-oracledb)

PHPackages © 2026

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