PHPackages                             misantron/letsencrypt-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. [Utility &amp; Helpers](/categories/utility)
4. /
5. misantron/letsencrypt-client

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

misantron/letsencrypt-client
============================

LetsEncrypt client library for ACME v2

1.0.0-beta2(6y ago)033MITPHPPHP ^7.2CI failing

Since Mar 26Pushed 6y ago1 watchersCompare

[ Source](https://github.com/misantron/letsencrypt-client)[ Packagist](https://packagist.org/packages/misantron/letsencrypt-client)[ RSS](/packages/misantron-letsencrypt-client/feed)WikiDiscussions master Synced 4d ago

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

LetsEncrypt ACME v2 client
==========================

[](#letsencrypt-acme-v2-client)

[![Build Status](https://camo.githubusercontent.com/325e39039731241df1a89eb8dd3fb5a25cb549bed62db47e0b798f984fd99b49/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f636f6d2f6d6973616e74726f6e2f6c657473656e63727970742d636c69656e742e7376673f7374796c653d666c61742d737175617265266d61784167653d32353932303030)](https://travis-ci.com/misantron/letsencrypt-client)[![Code Coverage](https://camo.githubusercontent.com/ee60f5d63195e5046df6f5fa4339fd4467e116c8685939f47810f137311194ea/68747470733a2f2f696d672e736869656c64732e696f2f636f766572616c6c732f6769746875622f6d6973616e74726f6e2f6c657473656e63727970742d636c69656e742e7376673f7374796c653d666c61742d737175617265)](https://coveralls.io/github/misantron/letsencrypt-client)[![Code Quality](https://camo.githubusercontent.com/e8af0e12b23a8c0c9509509a064b004851d705e3539894730adbc8af79665a17/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f672f6d6973616e74726f6e2f6c657473656e63727970742d636c69656e742e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/misantron/letsencrypt-client/)[![Packagist Version](https://camo.githubusercontent.com/fa06170437b32a7f58e5bfaace2174113b4df79d04d97e079098e8e4ff27bf4e/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6d6973616e74726f6e2f6c657473656e63727970742d636c69656e742e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/misantron/letsencrypt-client)

[ACME v2 draft](https://github.com/ietf-wg-acme/acme/blob/master/draft-ietf-acme-acme.md)

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

[](#installation)

Use Composer to install the package:

```
composer require misantron/letsencrypt-client
```

Basic usage
-----------

[](#basic-usage)

Create client instance with defaults:

```
use LetsEncrypt\Client;

$client = new Client($accountKeysPath, $certificatesPath);
```

By default client uses api staging environment.
To switch to production mode you can pass third argument to client constructor with `false` value:

```
use LetsEncrypt\Client;

$client = new Client($accountKeysPath, $certificatesPath, false);
```

### Account methods

[](#account-methods)

- `$client->account()->create(array $emails)`
- `$client->account()->get()`
- `$client->account()->getOrCreate(array $emails)`
- `$client->account()->update(array $emails)`
- `$client->account()->keyRollover()`
- `$client->account()->deactive()`

### Order methods

[](#order-methods)

- `$client->order()->create(Account $account, string $basename, array $subjects, Certificate $certificate)`
- `$client->order()->get(Account $account, string $basename, array $subjects, KeyType $keyType)`
- `$client->order()->getOrCreate(Account $account, string $basename, array $subjects, Certificate $certificate)`
- `$client->order()->getPendingHttpAuthorizations(Account $account, Order $order)`
- `$client->order()->getPendingDnsAuthorizations(Account $account, Order $order)`
- `$client->order()->verifyPendingHttpAuthorizations(Account $account, Order $order, string $identifier)`
- `$client->order()->verifyPendingDnsAuthorizations(Account $account, Order $order, string $identifier)`
- `$client->order()->getCertificate(Account $account, Order $order, string $basename, KeyType $keyType)`
- `$client->order()->getCertificateContent(string $basename, KeyType $keyType)`
- `$client->order()->getCertificateExpirationDate(string $basename, KeyType $keyType)`
- `$client->order()->revokeCertificate(Account $account, string $basename, KeyType $keyType, RevocationReason $reason)`

Advanced usage
--------------

[](#advanced-usage)

### Logging

[](#logging)

If you need to get some debug information or analyze server interaction

```
use LetsEncrypt\Client;
use LetsEncrypt\Logger\Logger;
use LetsEncrypt\Logger\LogStrategy;

$strategy = LogStrategy::errorsOnly();
// $logger is an instance of PSR-3 logger (\Psr\Log\LoggerInterface)
$clientLogger = new Logger($logger, $strategy);
$client = new Client($accountKeysPath, $certificatesPath, true, $clientLogger);
```

### Logger strategy

[](#logger-strategy)

- `LogStrategy::requestsOnly()` log only requests data
- `LogStrategy::errorsOnly()` log only failed (400/500) requests (request/response data)
- `LogStrategy::debugMode()` log all requests (request/response data)

###  Health Score

20

—

LowBetter than 14% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity38

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.

###  Release Activity

Cadence

Every ~0 days

Total

2

Last Release

2241d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/9839955?v=4)[Aleksandr Ivanov](/maintainers/misantron)[@misantron](https://github.com/misantron)

---

Top Contributors

[![misantron](https://avatars.githubusercontent.com/u/9839955?v=4)](https://github.com/misantron "misantron (68 commits)")

---

Tags

acmeclient-libraryletsencryptphp-libraryssl-certificatesphpACMEclient libraryssl-certificatesletsencypt

###  Code Quality

TestsPHPUnit

Code StylePHP CS Fixer

### Embed Badge

![Health badge](/badges/misantron-letsencrypt-client/health.svg)

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

###  Alternatives

[gehrisandro/tailwind-merge-laravel

TailwindMerge for Laravel merges multiple Tailwind CSS classes by automatically resolving conflicts between them

341682.2k18](/packages/gehrisandro-tailwind-merge-laravel)[aedart/athenaeum

Athenaeum is a mono repository; a collection of various PHP packages

245.2k](/packages/aedart-athenaeum)

PHPackages © 2026

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