PHPackages                             yournextship/wpnextship-client - 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. yournextship/wpnextship-client

ActiveComposer-package[API Development](/categories/api)

yournextship/wpnextship-client
==============================

00PHP

Since Dec 31Pushed 4mo agoCompare

[ Source](https://github.com/yournextship/wpnextship-client)[ Packagist](https://packagist.org/packages/yournextship/wpnextship-client)[ RSS](/packages/yournextship-wpnextship-client/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

WPNextShip SDK Documentation
============================

[](#wpnextship-sdk-documentation)

This SDK allows you to easily plug your WordPress plugins into the WPNextShip licensing and update system.

1. Installation
---------------

[](#1-installation)

Copy the `lib` folder into your plugin's directory.

2. Initialization
-----------------

[](#2-initialization)

Initialize the SDK in your main plugin file according to your desired menu placement.

### Option A: Top-Level Menu

[](#option-a-top-level-menu)

This will create a dedicated menu item for your plugin settings/licensing.

```
// wp-content/plugins/my-plugin/my-plugin.php

require_once plugin_dir_path( __FILE__ ) . 'lib/sdk-template/wp-nextship-loader.php';

add_action( 'plugins_loaded', function() {
    WPNextShip_SDK_Manager::init( array(
        'slug'    => 'my-plugin',
        'version' => '1.0.0', // Current plugin version
        'file'    => plugin_basename( __FILE__ ), // e.g., 'my-plugin/my-plugin.php'
    ) );
} );
```

### Option B: Submenu (e.g., Settings)

[](#option-b-submenu-eg-settings)

This will place the "License" page under an existing parent menu, such as Settings (`options-general.php`) or your own custom menu.

```
// wp-content/plugins/my-plugin/my-plugin.php

require_once plugin_dir_path( __FILE__ ) . 'lib/sdk-template/wp-nextship-loader.php';

add_action( 'plugins_loaded', function() {
    WPNextShip_SDK_Manager::init( array(
        'slug'        => 'my-plugin',
        'version'     => '1.0.0',
        'file'        => plugin_basename( __FILE__ ),
        'parent_slug' => 'options-general.php', // Adds under Settings
    ) );
} );
```

3. How It Works
---------------

[](#3-how-it-works)

### Licensing

[](#licensing)

- The SDK creates a "License" page.
- Users enter their License Key and Email.
- Upon activation, the SDK validates the key against your WPNextShip instance.
- Success stores activation status in `_wpnextship_license_{slug}`.

### Updates

[](#updates)

- The SDK hooks into WordPress update checks.
- It sends the current version and license key to your API.
- If a new version is available, it injects the update package into the WordPress updater.
- Regular WordPress update flows work seamlessly.

4. File Structure
-----------------

[](#4-file-structure)

- `wp-nextship-loader.php`: Main entry point.
- `src/Licensing.php`: Handles menu creation and activation UI.
- `src/Updater.php`: Handles `pre_set_site_transient_update_plugins` filter.

5. Troubleshooting
------------------

[](#5-troubleshooting)

- **Check Logs:** Ensure your API URL is reachable from the site.
- **License Key:** Updates only work with an active license.
- **Slug Match:** Ensure the `slug` passed to `init` matches the product slug in your WPNextShip dashboard.

###  Health Score

17

—

LowBetter than 6% of packages

Maintenance51

Moderate activity, may be stable

Popularity0

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity12

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/a83b27b9dfea0d4638f0d583d7986e8878a138e9e518c3886d86d18abae91778?d=identicon)[xaviranik](/maintainers/xaviranik)

---

Top Contributors

[![xaviranik](https://avatars.githubusercontent.com/u/28107639?v=4)](https://github.com/xaviranik "xaviranik (8 commits)")

### Embed Badge

![Health badge](/badges/yournextship-wpnextship-client/health.svg)

```
[![Health](https://phpackages.com/badges/yournextship-wpnextship-client/health.svg)](https://phpackages.com/packages/yournextship-wpnextship-client)
```

###  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)
