PHPackages                             kirchevsky/laravel-esignatures - 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. kirchevsky/laravel-esignatures

ActiveLibrary[API Development](/categories/api)

kirchevsky/laravel-esignatures
==============================

A Laravel module for integrating with eSignatures.io

018PHP

Since Jan 12Pushed 1y ago1 watchersCompare

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

READMEChangelogDependenciesVersions (1)Used By (0)

Laravel eSignatures Module
==========================

[](#laravel-esignatures-module)

This package provides an easy-to-use Laravel integration with [eSignatures.io](https://esignatures.io), allowing you to send, manage, and track contracts programmatically.

---

Features
--------

[](#features)

- Send contracts using eSignatures.io templates.
- Use custom PDFs for signing without templates.
- Manage signers (add, update, delete).
- Handle webhooks for real-time contract updates.
- Withdraw contracts.
- List and copy templates.
- Logging support for debugging and monitoring.

---

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

[](#installation)

1. Install the package via Composer:

    ```
    composer require kirchevsky/laravel-esignatures
    ```
2. Publish the configuration (optional):

    ```
    php artisan vendor:publish --tag=esignatures-config
    ```
3. Add your eSignatures.io API token to the `.env` file:

    ```
    ESIGNATURES_TOKEN=your-secret-token
    ```

---

Usage
-----

[](#usage)

### Basic Initialization

[](#basic-initialization)

Create an instance of the module:

```
use YourNamespace\ESignatures\ESignatures;

$eSignatures = new ESignatures(env('ESIGNATURES_TOKEN'));
```

### Sending a Contract with a Template

[](#sending-a-contract-with-a-template)

```
$response = $eSignatures->sendContract([
    'template_id' => 'template-id',
    'signers' => [
        [
            'name' => 'John Doe',
            'email' => 'john@example.com',
            'mobile' => '+1234567890',
        ],
    ],
    'title' => 'Contract Title',
    'metadata' => 'custom-metadata',
]);

if ($response['status'] === 'queued') {
    echo "Contract sent successfully!";
}
```

### Fetching Contract Details

[](#fetching-contract-details)

```
$contract = $eSignatures->getContract('contract-id');
echo "Contract Title: " . $contract['data']['contract']['title'];
```

### Withdrawing a Contract

[](#withdrawing-a-contract)

```
$response = $eSignatures->withdrawContract('contract-id');
if ($response['status'] === 'queued') {
    echo "Contract withdrawn successfully!";
}
```

### Managing Signers

[](#managing-signers)

#### Add a Signer:

[](#add-a-signer)

```
$response = $eSignatures->addSigner('contract-id', [
    'name' => 'New Signer',
    'email' => 'new@example.com',
    'mobile' => '+1234567890',
]);
```

#### Update a Signer:

[](#update-a-signer)

```
$response = $eSignatures->updateSigner('contract-id', 'signer-id', [
    'name' => 'Updated Signer',
    'email' => 'updated@example.com',
]);
```

#### Delete a Signer:

[](#delete-a-signer)

```
$response = $eSignatures->deleteSigner('contract-id', 'signer-id');
```

### Webhook Handling

[](#webhook-handling)

Handle webhook notifications from eSignatures.io:

1. Add a route in your `web.php`:

    ```
    Route::post('/webhook/esignatures', [WebhookController::class, 'handle']);
    ```
2. Create the `WebhookController`:

    ```
    use Illuminate\Http\Request;
    use YourNamespace\ESignatures\ESignatures;

    class WebhookController extends Controller
    {
        public function handle(Request $request)
        {
            $eSignatures = new ESignatures(env('ESIGNATURES_TOKEN'));
            $eSignatures->handleWebhook(function ($payload) {
                // Process the webhook payload
                Log::info('Webhook received', $payload);
            });
        }
    }
    ```

---

Advanced Usage
--------------

[](#advanced-usage)

### List Templates

[](#list-templates)

```
$templates = $eSignatures->listTemplates();
foreach ($templates['data'] as $template) {
    echo "Template ID: {$template['template_id']}, Name: {$template['template_name']}\n";
}
```

### Copy a Template

[](#copy-a-template)

```
$response = $eSignatures->copyTemplate('template-id', [
    'title' => 'New Template',
    'placeholder_fields' => [
        [
            'api_key' => 'field-key',
            'value' => 'Field Value',
        ],
    ],
]);
```

---

Debugging &amp; Logging
-----------------------

[](#debugging--logging)

If you want to log API requests and responses, pass a PSR-3 logger (like Laravel's Log facade) during initialization:

```
use Illuminate\Support\Facades\Log;

$eSignatures = new ESignatures(env('ESIGNATURES_TOKEN'), Log::channel('stack'));
```

---

Contributing
------------

[](#contributing)

1. Fork the repository.
2. Create a new branch (`git checkout -b feature-name`).
3. Make your changes.
4. Commit your changes (`git commit -am 'Add new feature'`).
5. Push to the branch (`git push origin feature-name`).
6. Open a Pull Request.

---

License
-------

[](#license)

This package is open-sourced software licensed under the [MIT license](LICENSE).

---

Support
-------

[](#support)

If you encounter any issues or have questions, feel free to open an issue on [GitHub](https://github.com/kirchevsky/laravel-esignatures).

###  Health Score

16

—

LowBetter than 5% of packages

Maintenance32

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity16

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

---

Top Contributors

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

### Embed Badge

![Health badge](/badges/kirchevsky-laravel-esignatures/health.svg)

```
[![Health](https://phpackages.com/badges/kirchevsky-laravel-esignatures/health.svg)](https://phpackages.com/packages/kirchevsky-laravel-esignatures)
```

###  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)[knplabs/github-api

GitHub API v3 client

2.2k15.8M187](/packages/knplabs-github-api)[facebook/php-business-sdk

PHP SDK for Facebook Business

90121.9M34](/packages/facebook-php-business-sdk)[meilisearch/meilisearch-php

PHP wrapper for the Meilisearch API

73813.7M114](/packages/meilisearch-meilisearch-php)[google/gax

Google API Core for PHP

263103.1M454](/packages/google-gax)

PHPackages © 2026

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