PHPackages                             elendev/checkout-bundle - 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. elendev/checkout-bundle

ActiveSymfony-bundle[Payment Processing](/categories/payments)

elendev/checkout-bundle
=======================

Provide simple checkout utilities for paypal

1.1.5(11y ago)41752Apache2PHP

Since Sep 18Pushed 11y ago1 watchersCompare

[ Source](https://github.com/Elendev/ElendevCheckoutBundle)[ Packagist](https://packagist.org/packages/elendev/checkout-bundle)[ Docs](http://blog.elendev.com)[ RSS](/packages/elendev-checkout-bundle/feed)WikiDiscussions master Synced 6d ago

READMEChangelog (1)Dependencies (4)Versions (8)Used By (0)

ElendevCheckoutBundle
=====================

[](#elendevcheckoutbundle)

Bundle configuration
--------------------

[](#bundle-configuration)

Symfony 2 configuration config.yml

If you don't want to use paypal checkout service, you can remove the paypal configuration. Other available configurations are visible below :

```
elendev_checkout:
	paypal:
    	username: 'your_paypal_username'
    	password: 'your_paypal_password'
    	signature: 'your_paypal_signature'
    	use_sandbox: 'true/false'
    	currency: 'EUR/USD/..., optionnal, default : EUR'
    	page_style: 'saved pagestyle available on paypal website, optionnal'
    	header_image: 'image visible on top left, optionnal'
    	header_border_color: '6 char length color code (e.g. 888888), optionnal'
    	header_background_color: '6 char length color code (e.g. 777777), optionnal'
    	payment_page_background_color: '6 char length color code (e.g. 666666), optionnal'
    	brand_name: 'name visible on top of payment page, optionnal'

```

Simple example
--------------

[](#simple-example)

This page explain how to use the ElendevCheckoutBundle into a simple controller.

Simple implementation example Here you can see a really simple implementation example :

```
/**
 * @author Jonas Renaudot
 */
class OrderingController extends Controller {

	...

    public function doCheckoutAction($checkoutMethod){

        $command = ...; //instance of Elendev\CheckoutBundle\Command\Command

        $checkoutProvider = $this->get("elendev.checkout.service_provider")->getService($checkoutMethod);

        $result = $checkoutProvider->doCheckout($command);

    	if($result->getStatus() == CheckoutResult::STATUS_IN_PROGRESS){
        	return $result->getHttpResponse();
    	}else if($result->getStatus() == CheckoutResult::STATUS_CANCELED){
        	//Command canceled : return to the info page
        	$this->getRequest()->getSession()->setFlash("info", "Command canceled");
        	return new RedirectResponse($this->generateUrl("ordering.info"));
    	}else if($result->getStatus() == CheckoutResult::STATUS_ERROR){
        	//Error occured : return to the info page allowing user to chose an other payment method
        	$this->get('session')->setFlash("error", "An error occured, retry again please");
        	return new RedirectResponse($this->generateUrl("ordering.info"));
    	}else if($result->getStatus() == CheckoutResult::STATUS_SUCCESS){
        	//save current command and mark it as done
        	...
        	//go to confirmation page
        	return new RedirectResponse($this->generateUrl("ordering.confirmation"));
    	}
	}

    ...
}

```

Create a new service class
--------------------------

[](#create-a-new-service-class)

This part explain how to add a new service to the CheckoutServiceProvider. This service will be available through the CheckoutServiceProvider-&gt;getService('id') method.

- Creating a new service class To create a valid service class you need to extends the Elendev\\CheckoutBundle\\CheckoutService class. The simplest checkout service you can implement is visible below :

    namespace Your\\Service\\Namespace;

    use Elendev\\CheckoutBundle\\CheckoutService; use Elendev\\CheckoutBundle\\Command\\Command; use Elendev\\CheckoutBundle\\CheckoutResult;

    class SimpleCheckoutService extends CheckoutService {

    ```
      /**
       * @param Command $command
      * @return CheckoutResult : result of checkout operations
     */
     public function doCheckout(Command $command){

          $result = new CheckoutResult();

          $result->setStatus(CheckoutResult::STATUS_SUCCESS);

          return $result;
      }

    ```

    } When you return a `CheckoutResult::STATUS\_IN\_PROGRESS status in the returned response object, the doCheckout method will be called again on page reloading (or on redirect on the current page).
- Configure a new service Add your new checkout service as a simple service with the elendev.checkout.service tag. The specified id parameter is the service id that you need to use to get the service with the CheckoutServiceProvider-&gt;getService('id') method.

    your.service.id: class : Your\\Checkout\\Service\\Class tags : - {name : elendev.checkout.service, id: your\_service\_id}

###  Health Score

32

—

LowBetter than 72% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity16

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity68

Established project with proven stability

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

Recently: every ~121 days

Total

7

Last Release

4129d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/2f3d01822621b80f6102d24f68e9a0ff2221d98a272ccd5c78c405d19621f475?d=identicon)[Elendev](/maintainers/Elendev)

---

Top Contributors

[![Elendev](https://avatars.githubusercontent.com/u/1331273?v=4)](https://github.com/Elendev "Elendev (13 commits)")

---

Tags

paypalcheckout

### Embed Badge

![Health badge](/badges/elendev-checkout-bundle/health.svg)

```
[![Health](https://phpackages.com/badges/elendev-checkout-bundle/health.svg)](https://phpackages.com/packages/elendev-checkout-bundle)
```

###  Alternatives

[payum/payum-bundle

One million downloads of Payum already! Payum offers everything you need to work with payments. Check more visiting site.

59510.3M40](/packages/payum-payum-bundle)[phpjuice/paypal-checkout-sdk

PayPal's PHP SDK for Checkout REST APIs

5858.1k](/packages/phpjuice-paypal-checkout-sdk)[amsgames/laravel-shop

Package set to provide shop or e-commerce functionality (such as CART, ORDERS, TRANSACTIONS and ITEMS) to Laravel for customizable builds.

4845.9k](/packages/amsgames-laravel-shop)[metisfw/paypal

PayPal SDK integration for Nette Framework

109.2k](/packages/metisfw-paypal)

PHPackages © 2026

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