PHPackages                             blancoms/laravel-wp-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. [HTTP &amp; Networking](/categories/http)
4. /
5. blancoms/laravel-wp-api

ActiveLibrary[HTTP &amp; Networking](/categories/http)

blancoms/laravel-wp-api
=======================

Laravel package for the Wordpress JSON REST API forked from swancreative/laravel-wp-api

2.3.1(5y ago)059MITPHPPHP ^8.0

Since May 31Pushed 5y agoCompare

[ Source](https://github.com/blancoms/laravel-wp-api)[ Packagist](https://packagist.org/packages/blancoms/laravel-wp-api)[ RSS](/packages/blancoms-laravel-wp-api/feed)WikiDiscussions master Synced yesterday

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

laravel-wp-api
==============

[](#laravel-wp-api)

[![Build Status](https://camo.githubusercontent.com/fd148c609e63b95f5f58d70e55d8efab727b589d4827b78670e10393c456e9f7/68747470733a2f2f7472617669732d63692e6f72672f7468726565737175617265642f6c61726176656c2d77702d6170692e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/threesquared/laravel-wp-api) [![Latest Stable Version](https://camo.githubusercontent.com/2e047833b7d132b7f43c20f4faaba12b01efb53ca80f1dee5026b28bbf836a15/68747470733a2f2f706f7365722e707567782e6f72672f7468726565737175617265642f6c61726176656c2d77702d6170692f762f737461626c65)](https://packagist.org/packages/threesquared/laravel-wp-api)

Laravel 5 package for the [Wordpress JSON REST API](https://github.com/WP-API/WP-API)

Install
-------

[](#install)

Simply add the following line to your `composer.json` and run install/update:

```
"blancoms/laravel-wp-api": "~2.3"

```

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

[](#configuration)

You will need to add the service provider and optionally the facade alias to your `config/app.php`:

```
'providers' => array(
  Blancoms\LaravelWpApi\LaravelWpApiServiceProvider::class
)

'aliases' => array(
  'WpApi' => Blancoms\LaravelWpApi\Facades\WpApi::class
),
```

And publish the package config files to configure the location of your Wordpress install:

```
php artisan vendor:publish

```

### Usage

[](#usage)

The package provides a simplified interface to some of the existing api methods documented [here](http://wp-api.org/). You can either use the Facade provided or inject the `Mattwilding\LaravelWpApi\WpApi` class.

#### Posts

[](#posts)

```
WpApi::posts($page);
```

#### Pages

[](#pages)

```
WpApi::pages($page);
```

#### Post

[](#post)

```
WpApi::post($slug);
```

```
WpApi::postId($id);
```

#### Categories

[](#categories)

```
WpApi::categories();
```

#### Tags

[](#tags)

```
WpApi::tags();
```

#### Category posts

[](#category-posts)

```
WpApi::categoryPosts($slug, $page);
```

#### Author posts

[](#author-posts)

```
WpApi::authorPosts($slug, $page);
```

#### Tag posts

[](#tag-posts)

```
WpApi::tagPosts($slug, $page);
```

#### Search

[](#search)

```
WpApi::search($query, $page);
```

#### Archive

[](#archive)

```
WpApi::archive($year, $month, $page);
```

###  Health Score

31

—

LowBetter than 68% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity75

Established project with proven stability

 Bus Factor1

Top contributor holds 84.6% 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 ~119 days

Total

13

Last Release

1839d ago

Major Versions

1.4 → 2.02021-03-10

PHP version history (3 changes)1.0.0PHP &gt;=5.5.0

1.4PHP ^7.0

2.3PHP ^8.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/153be4fd218c690c886e90b89d8f6edd8063ff201bbd31bba7e9b2430a6a0140?d=identicon)[blancoms](/maintainers/blancoms)

---

Top Contributors

[![mattwilding](https://avatars.githubusercontent.com/u/4983089?v=4)](https://github.com/mattwilding "mattwilding (11 commits)")[![swancreative](https://avatars.githubusercontent.com/u/33896081?v=4)](https://github.com/swancreative "swancreative (2 commits)")

---

Tags

apilaravelwordpressrestpackage

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/blancoms-laravel-wp-api/health.svg)

```
[![Health](https://phpackages.com/badges/blancoms-laravel-wp-api/health.svg)](https://phpackages.com/packages/blancoms-laravel-wp-api)
```

###  Alternatives

[pixelpeter/laravel5-woocommerce-api-client

Laravel 5 wrapper for the Woocommerce REST API

125103.4k](/packages/pixelpeter-laravel5-woocommerce-api-client)[threesquared/laravel-wp-api

Laravel package for the Wordpress JSON REST API

1310.3k](/packages/threesquared-laravel-wp-api)[cybercog/youtrack-rest-php

YouTrack REST API PHP Client.

37149.2k3](/packages/cybercog-youtrack-rest-php)[dreamfactory/df-core

DreamFactory(tm) Core Components

1651.7k20](/packages/dreamfactory-df-core)[laragear/api-manager

Manage multiple REST servers to make requests in few lines and fluently.

161.8k](/packages/laragear-api-manager)

PHPackages © 2026

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