PHPackages                             divya2407sharma/pepipost - 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. divya2407sharma/pepipost

ActiveLibrary

divya2407sharma/pepipost
========================

This library adds a 'pepipost' mail driver to Laravel.This library is a copy of https://github.com/pepipost/pepipost-laravel-driver

3.0(4y ago)03MITPHPPHP &gt;=5.5.9

Since Oct 4Pushed 4y agoCompare

[ Source](https://github.com/divya2407sharma/pepipost)[ Packagist](https://packagist.org/packages/divya2407sharma/pepipost)[ RSS](/packages/divya2407sharma-pepipost/feed)WikiDiscussions main Synced today

READMEChangelog (3)Dependencies (4)Versions (4)Used By (0)

This project is a copy of [pepipost/pepipost-laravel-driver](https://github.com/pepipost/pepipost-laravel-driver), with some customizations to make it compatible with Laravel 5.2

Laravel Driver for [Pepipost](http://www.pepipost.com/?utm_campaign=GitHubSDK&utm_medium=GithubSDK&utm_source=GithubSDK)
========================================================================================================================

[](#laravel-driver-for-pepipost)

A Mail Driver with support for Pepipost Send Email Web API, using the original Laravel API. This library extends the original Laravel classes, so it uses exactly the same methods.

To use this package required your [Pepipost Api Key](https://app.pepipost.com). Please make it [Here](https://app.pepipost.com).

We are trying to make our libraries Community Driven- which means we need your help in building the right things in proper order we would request you to help us by sharing comments, creating new [issues](https://github.com/pepipost/laravel-pepipost-driver/issues) or [pull requests](https://github.com/pepipost/laravel-pepipost-driver/pulls).

We welcome any sort of contribution to this library.

The latest 1.0.0 version of this library provides is fully compatible with the latest Pepipost v2.0 API.

For any update of this library check [Releases](https://github.com/pepipost/laravel-pepipost-driver/releases).

Table of Content
================

[](#table-of-content)

- [Installation](#installation)
- [Quick Start](#quick-start)
- [Usage of library in Project](#inproject)
- [Sample Example](#eg)
- [Announcements](#announcements)
- [Roadmap](#roadmap)
- [About](#about)
- [License](#license)

Installation
============

[](#installation)

### Prerequisites

[](#prerequisites)

[PHP &gt;= 5.5.9](https://www.php.net/manual/en/install.php)

[Laravel 5.2](https://laravel.com/docs/5.8/installation)

[guzzlehttp/guzzle ~5.3|~6.0](https://docs.guzzlephp.org/)

A free account on Pepipost. If you don't have a one, [click here](https://app.pepipost.com) to signup.

Usage
-----

[](#usage)

### Configuring laravel project

[](#configuring-laravel-project)

#### Step 1 - Create New Laravel project

[](#step-1---create-new-laravel-project)

```
laravel new testproject
```

#### Step 2 - Add the package to your composer.json and run composer update.

[](#step-2---add-the-package-to-your-composerjson-and-run-composer-update)

```
"require": {
    "divya2407sharma/pepipost": "~1.0"
},
```

#### or install with composer

[](#or-install-with-composer)

```
$ composer require divya2407sharma/pepipost
```

#### Step 3 - Configurations

[](#step-3---configurations)

1. Add the pepipost service provider in config/app.php: (Laravel 5.5+ uses Package Auto-Discovery, so doesn't require you to manually add the ServiceProvider.)

    ```
    'providers' => [
        DS\PepiPost\PepipostTransportServiceProvider::class
    ];
    ```
2. Add pepipost api key, endpoint in config/services.php

    ```
        'pepipost' => [
            'api_key' => env('PEPIPOST_API_KEY'),
        ],
    ```

    ```
     endpoint config

     If you need to set custom endpoint, you can set any endpoint by using endpoint key.
     For example,calls to Pepipost Web API through a proxy,configure endpoint in config/services.php.

       'pepipost' => [
               'api_key' => env('PEPIPOST_API_KEY'),
               'endpoint' => 'https://api.pepipost.com/v2/sendEmail',
           ],

    ```
3. Add following in .env file

    ```
    MAIL_DRIVER=pepipost

    PEPIPOST_API_KEY='YOUR_PEPIPOST_API_KEY'
    ```

#### Step 4- Laravel Steps to create controller and view

[](#step-4---laravel-steps-to-create-controller-and-view)

1. Define Controller

    ```
    php artisan make:controller TestController
    ```
2. create file in resources/views/viewname/name.blade.php and include your email content

    include following function sendMail in TestController to send viewname.name as content of email and initialize $data to use it on view page

    ```
    function sendMail(){

    Mail::send('viewname.name',$data, function ($message) {
        $message
            ->to('foo@example.com', 'foo_name')
            ->from('sender@example.com', 'sender_name')
            ->subject('subject')
            ->cc('cc@example.com','recipient_cc_name')
            ->bcc('recipient_bcc@example.com','recipient_bcc_name')
            ->replyTo('reply_to@example.com','recipient_bcc')
            ->attach('/myfilename.pdf');
    });

    return 'Email sent successfully';
    }
    ```
3. Create Route in routes/web.php

    ```
    Route::get('/send/email', 'TestController@sendMail')->name('sendEmail');
    ```

#### Step 5 - Testing

[](#step-5---testing)

Host your laravel project and enter url- http://your\_url.com/send/email in browser

This will send email and display Email sent successfully on browser.

#### Additional Usage

[](#additional-usage)

IF want to pass others parameters of PepiPost SendEmail API use embedData function and include below code as below Add parameters as per your requirement. Do not use multiple to's,cc's,bcc's with this method.

```
function sendMail(){

Mail::send('viewname.name',$data, function ($message) {
    $message
        ->to('foo@example.com', 'foo_name')
        ->from('sender@example.com', 'sender_name')
        ->subject('subject')
        ->cc('cc@example.com','recipient_cc_name')
        ->bcc('recipient_bcc@example.com','recipient_bcc_name')
        ->replyTo('reply_to@example.com','recipient_bcc')
        ->attach('/myfilename.pdf')
        ->embedData([
            'personalizations' => ['attributes'=>['ACCOUNT_BAL'=>'String','NAME'=>'NAME'],'x-apiheader'=>'x-apiheader_value','x-apiheader_cc'=>'x-apiheader_cc_value'],'settings' => ['bcc'=>'bccemail@gmail.com','clicktrack'=>1,'footer'=>1,'opentrack'=>1,'unsubscribe'=>1 ],'tags'=>'tags_value','templateId'=>''
        ],'pepipostapi');

 return 'Email sent successfully';
}
```

For multiple to's,cc's,bcc's pass recipient,recipient\_cc,recipient\_bcc as below, create personalizations as required

```
function sendMail(){

Mail::send('viewname.name',$data, function ($message) {
    $message
        ->from('sender@example.com', 'sender_name')
        ->subject('subject')
        ->replyTo('reply_to'@example.com,'recipient_bcc')
        ->attach('/myfilename.pdf')
        ->embedData([
                    'personalizations' => [['recipient'=>'foo@example.com','attributes'=>['ACCOUNT_BAL'=>'String','NAME'=>'name'],'recipient_cc'=>['cc@example.com','cc2@example.com'],'recipient_bcc'=>['bcc@example.com','bcc2@example.com'],'x-apiheader'=>'x-apiheader_value','x-apiheader_cc'=>'x-apiheader_cc_value'],['recipient'=>'foo@example.com','attributes'=>['ACCOUNT_BAL'=>'String','NAME'=>'name'],'x-apiheader'=>'x-apiheader_value','x-apiheader_cc'=>'x-apiheader_cc_value']],'settings' => ['bcc'=>'bccemail@gmail.com','clicktrack'=>1,'footer'=>1,'opentrack'=>1,'unsubscribe'=>1 ],'tags'=>'tags_value','templateId'=>''
                ],'pepipostapi');
        });

return 'Email sent successfully';
}
```

License
-------

[](#license)

[MIT](https://choosealicense.com/licenses/mit/)

###  Health Score

21

—

LowBetter than 19% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity3

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity47

Maturing project, gaining track record

 Bus Factor1

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

Total

3

Last Release

1665d ago

Major Versions

1.0 → 2.02021-10-18

2.0 → 3.02021-10-18

### Community

Maintainers

![](https://www.gravatar.com/avatar/8f4472097b9983b0c58d38dc5a05c69ff714298483a04c277e5b6ccfa452e496?d=identicon)[divya2407sharma](/maintainers/divya2407sharma)

---

Top Contributors

[![divya2407sharma](https://avatars.githubusercontent.com/u/75476823?v=4)](https://github.com/divya2407sharma "divya2407sharma (4 commits)")[![iYogesharma](https://avatars.githubusercontent.com/u/44565761?v=4)](https://github.com/iYogesharma "iYogesharma (1 commits)")

---

Tags

laravelpepipostlaravel mail driver

### Embed Badge

![Health badge](/badges/divya2407sharma-pepipost/health.svg)

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

###  Alternatives

[s-ichikawa/laravel-sendgrid-driver

This library adds a 'sendgrid' mail driver to Laravel.

4139.3M1](/packages/s-ichikawa-laravel-sendgrid-driver)[tzsk/sms

A robust and unified SMS gateway integration package for Laravel, supporting multiple providers.

320244.3k6](/packages/tzsk-sms)[tpetry/laravel-mysql-explain

Get Visual MySQL EXPLAIN for Laravel.

264154.2k](/packages/tpetry-laravel-mysql-explain)[erag/laravel-disposable-email

A Laravel package to detect and block disposable email addresses.

226102.4k](/packages/erag-laravel-disposable-email)[ralphjsmit/laravel-helpers

A package containing handy helpers for your Laravel-application.

13704.6k2](/packages/ralphjsmit-laravel-helpers)[shaffe/laravel-mail-log-channel

A package to support logging via email in Laravel

1286.2k](/packages/shaffe-laravel-mail-log-channel)

PHPackages © 2026

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