PHPackages                             osirisgate/lemonsqueezy - 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. [Payment Processing](/categories/payments)
4. /
5. osirisgate/lemonsqueezy

ActiveLibrary[Payment Processing](/categories/payments)

osirisgate/lemonsqueezy
=======================

Osirisgate Lemonsqueezy PHP SDK.

1.0.0(1y ago)018MITPHPPHP &gt;=8.2

Since Jun 19Pushed 1y ago1 watchersCompare

[ Source](https://github.com/osirisgate/lemonsqueezy-php)[ Packagist](https://packagist.org/packages/osirisgate/lemonsqueezy)[ RSS](/packages/osirisgate-lemonsqueezy/feed)WikiDiscussions 1.0 Synced today

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

🌐 Osirisgate LemonSqueezy PHP SDK
=================================

[](#-osirisgate-lemonsqueezy-php-sdk)

[![License: MIT](https://camo.githubusercontent.com/08cef40a9105b6526ca22088bc514fbfdbc9aac1ddbf8d4e6c750e3a88a44dca/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c6963656e73652d4d49542d626c75652e737667)](LICENSE)[![PHP Version](https://camo.githubusercontent.com/337c77af623b2c89c0dee0d532c1ca73390e5e9f06f06217a72493ad0cdfab4d/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d2533453d382e322d3838393242462e737667)](https://www.php.net/releases/8.2/)

> Lightweight, developer-first SDK to interact with the LemonSqueezy API. Built with modern PHP and clean architecture principles. Focused on simplicity, readability and full control.

---

📦 Installation
--------------

[](#-installation)

```
composer require osirisgate/lemonsqueezy
```

✅ Requirements
--------------

[](#-requirements)

- PHP 8.2 or higher

🚀 Getting Started
-----------------

[](#-getting-started)

```
use Osirisgate\Component\Lemonsqueezy\LemonsqueezyClient;

$client = LemonsqueezyClient::init('your-api-key');
```

You can now access all LemonSqueezy resources:

For each resource, some methods are available. You can see the full list of methods in the respective resource class.

You can see in `Resources/` directory the list of all available resources and methods for each resource.

```
# User Resource: Manage the authenticated user.
$usersResource = $client->users();
// Example: $user = $usersResource->find();

# Store Resource: Manage your LemonSqueezy stores.
$storesResource = $client->stores();
// Example: $stores = $storesResource->all();

# Customer Resource: Manage your customers.
$customersResource = $client->customers();
// Example: $customer = $customersResource->find(123);

# Product Resource: Manage your products.
$productsResource = $client->products();
// Example: $products = $productsResource->all();

# Variant Resource: Manage product variants.
$variantsResource = $client->variants();
// Example: $variant = $variantsResource->find(456);

# Price Resource: Manage pricing options.
$pricesResource = $client->prices();
// Example: $prices = $pricesResource->all();

# File Resource: Manage digital files associated with products.
$filesResource = $client->files();
// Example: $files = $filesResource->all();

# Order Resource: Manage customer orders.
$ordersResource = $client->orders();
// Example: $order = $ordersResource->find(789);

# Order Item Resource: Access individual items within an order.
$orderItemsResource = $client->orderItems();
// Example: $orderItems = $orderItemsResource->all();

# Subscription Resource: Manage recurring subscriptions.
$subscriptionsResource = $client->subscriptions();
// Example: $subscription = $subscriptionsResource->find(101);

# Subscription Invoice Resource: Access invoices for subscriptions.
$subscriptionInvoicesResource = $client->subscriptionInvoices();
// Example: $invoices = $subscriptionInvoicesResource->all();

# Subscription Item Resource: Access individual items within a subscription.
$subscriptionItemsResource = $client->subscriptionItems();
// Example: $subscriptionItems = $subscriptionItemsResource->all();

# Usage Record Resource: Report usage for metered billing.
$usageRecordsResource = $client->usageRecords();
// Example: $usageRecord = $usageRecordsResource->create(...);

# Discount Resource: Manage discount codes.
$discountsResource = $client->discounts();
// Example: $discounts = $discountsResource->all();

# Discount Redemption Resource: Track how discounts are used.
$discountRedemptionsResource = $client->discountRedemptions();
// Example: $redemptions = $discountRedemptionsResource->all();

# License Key Resource: Manage license keys for software.
$licenseKeysResource = $client->licenseKeys();
// Example: $licenseKey = $licenseKeysResource->find('...');

# License Key Instance Resource: Manage specific instances of license keys.
$licenseKeyInstancesResource = $client->licenseKeyInstances();
// Example: $instances = $licenseKeyInstancesResource->all();

# Checkout Resource: Generate checkout URLs.
$checkoutsResource = $client->checkouts();
// Example: $checkoutUrl = $checkoutsResource->create(...);

# Webhook Resource: Manage webhook configurations.
$webhooksResource = $client->webhooks();
// Example: $webhooks = $webhooksResource->all();

# License API Resource: Verify and manage licenses via the API.
$licenseApiResource = $client->licenseApi();
// Example: $license = $licenseApiResource->verify('...');

# Affiliate Resource: Manage affiliate programs.
$affiliatesResource = $client->affiliates();
// Example: $affiliates = $affiliatesResource->all();
```

🧪 Run Tests
-----------

[](#-run-tests)

```
vendor/bin/phpunit tests
```

🧰 Developer Tools
-----------------

[](#-developer-tools)

### ✅ Code style

[](#-code-style)

```
composer run phpcs-fix
```

### 🧠 Static analysis

[](#-static-analysis)

```
composer run phpstan
```

Or run both checks at once:

```
make check-code-quality
```

📜 License
---------

[](#-license)

This package is licensed under the [MIT License](LICENSE).

👤 Author
--------

[](#-author)

**Ulrich Geraud AHOGLA** Software Engineer — Osirisgate

If you have any questions or suggestions, please contact me via

###  Health Score

30

—

LowBetter than 62% of packages

Maintenance49

Moderate activity, may be stable

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 ~0 days

Total

2

Last Release

379d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/572d40b1645d8f32e42a4f07bfdab165b975c830d9b8608204cb20a90bd04697?d=identicon)[developer\_osirisgate](/maintainers/developer_osirisgate)

---

Top Contributors

[![osirisgate](https://avatars.githubusercontent.com/u/211675927?v=4)](https://github.com/osirisgate "osirisgate (1 commits)")

---

Tags

sdkpaymentsubscriptionlemonsqueezyosirisgate

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/osirisgate-lemonsqueezy/health.svg)

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

###  Alternatives

[yandex-money/yandex-money-sdk-php

Yandex.Money API SDK for PHP

105168.9k2](/packages/yandex-money-yandex-money-sdk-php)[cryptonator/merchant-php-sdk

Cryptonator.com Merchant API SDK for PHP

2714.4k](/packages/cryptonator-merchant-php-sdk)

PHPackages © 2026

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