PHPackages                             sukhvir1313/directproductadd - 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. sukhvir1313/directproductadd

ActiveMagento2-module[Utility &amp; Helpers](/categories/utility)

sukhvir1313/directproductadd
============================

Share link http://{yourdomain}/dpa/add/tocart/sku/{product\_sku}, http://{yourdomain}/dpa/add/tocart/sku/{product\_sku}/coupon/{coupon\_code}, http://{yourdomain}/dpa/add/tocart/sku/{product\_sku}-{quantity}, http://{yourdomain}/dpa/add/tocart/sku/{product\_sku\_1},{product\_sku\_2}, http://{yourdomain}/dpa/add/tocart/id/{product\_sku\_1}-{quantity},{product\_sku\_2}-{quantity}, http://{yourdomain}/dpa/add/tocart/id/{product\_id}, http://{yourdomain}/dpa/add/tocart/id/{product\_id}-{quantity}, http://{yourdomain}/dpa/add/tocart/id/{product\_id\_1},{product\_id\_2} OR http://{yourdomain}/dpa/add/tocart/id/{product\_id\_1}-{quantity},{product\_id\_2}-{quantity} with your users through email, share media, blogs etc. Once user clicks on this link product will be automatically added to cart and user will be redirected to checkout page.

1.1.3(2y ago)38.9k↑27.3%1Apache-2.0PHPPHP ~5.5.0|~5.6.0|~7.0.0|~7.1.0|~7.2.0|~7.3.0|~7.4.0|~8.1.0|~8.2.0|~8.3.0CI passing

Since Jul 18Pushed 10mo ago2 watchersCompare

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

READMEChangelog (5)DependenciesVersions (6)Used By (0)

**Direct Product Add to Cart**
==============================

[](#direct-product-add-to-cart)

Imagine simplifying the shopping experience for your customers by letting them add products to their cart with just one click. Sounds amazing, right? With the **Direct Product Add** extension, you can do exactly that! This powerful tool lets you share unique links that allow customers to instantly add products to their cart and redirect them to the cart or checkout page—no extra steps, no hassle.

Simply share these links through email, social media, or blogs, and watch your conversion rates soar. When users click the link, the product is added to their cart automatically, and they’re taken straight to where they need to be. You can even customize whether they land on the cart or checkout page from your admin settings. This streamlined shopping process not only enhances the user experience but also helps drive more sales for your store.

**Get started today** by downloading Direct Product Add from the [Adobe Commerce Marketplace](https://commercemarketplace.adobe.com/sukhvir-directproductadd.html)!

---

**How It Works: Creating URLs**
-------------------------------

[](#how-it-works-creating-urls)

The Direct Product Add extension supports a variety of URL formats, making it flexible and easy to use. Here are some examples:

1. **Add a Single Product by SKU**

    ```
    http://{yourdomain}/dpa/add/tocart/sku/{product_sku}

    ```
2. **Add a Product with a Specific Quantity**

    ```
    http://{yourdomain}/dpa/add/tocart/sku/{product_sku}-{quantity}

    ```

    *If the SKU itself contains hyphens, append the quantity as an additional `-number` segment (for example `24-MB01-2`). The module checks whether the complete SKU exists before interpreting the trailing number as the quantity.*
3. **Add Multiple Products with Quantities**

    ```
    http://{yourdomain}/dpa/add/tocart/sku/{product_sku_1}-{quantity_1},{product_sku_2}-{quantity_2}

    ```
4. **Add Multiple Products by SKU**

    ```
    http://{yourdomain}/dpa/add/tocart/sku/{product_sku_1},{product_sku_2}

    ```
5. **Add Products with a Coupon Code**

    ```
    http://{yourdomain}/dpa/add/tocart/sku/{product_sku}/coupon/{coupon_code}

    ```
6. **Add a Single Product by Product ID**

    ```
    http://{yourdomain}/dpa/add/tocart/id/{product_id}

    ```
7. **Add a Product by ID with Quantity**

    ```
    http://{yourdomain}/dpa/add/tocart/id/{product_id}-{quantity}

    ```

    *Example:*

    ```
    http://{yourdomain}/dpa/add/tocart/id/123-2

    ```
8. **Add Multiple Products by ID**

    ```
    http://{yourdomain}/dpa/add/tocart/id/{product_id_1},{product_id_2}

    ```

    *Example:*

    ```
    http://{yourdomain}/dpa/add/tocart/id/123,223

    ```
9. **Add Multiple Products by ID with Quantities**

    ```
    http://{yourdomain}/dpa/add/tocart/id/{product_id_1}-{quantity_1},{product_id_2}-{quantity_2}

    ```

    *Example:*

    ```
    http://{yourdomain}/dpa/add/tocart/id/123-3,223-3

    ```
10. **Clear the Cart Before Adding New Items**
    If you want to empty the cart before adding new items, include the `empty` parameter:

    ```
    http://{yourdomain}/dpa/add/tocart/sku/{product_sku}/empty/1

    ```

---

**Why Use Direct Product Add?**
-------------------------------

[](#why-use-direct-product-add)

Here are some key benefits of the Direct Product Add extension:

- **Instant Cart Addition**: Customers can add products to their cart and be redirected to the cart or checkout page with a single click.
- **Time-Saving for Shoppers**: Reduce the steps customers need to take to complete their purchase, resulting in faster checkouts.
- **Coupon Integration**: Apply coupon codes directly through the link, making discounts even easier to redeem.
- **Custom Redirection**: Decide where the customer lands—cart or checkout—directly from the admin panel.

---

**Tips for Creating URLs**
--------------------------

[](#tips-for-creating-urls)

To ensure the best experience for your users, follow these tips when creating URLs:

1. Always use **simple product SKUs/IDs**. If you use configurable product SKUs/IDs, customers will be redirected to the product page instead of the cart.
2. Use product SKUs/IDs from the **correct store view**. If the SKU or ID doesn’t match the store, users will be redirected to the homepage.

---

**See It in Action**
--------------------

[](#see-it-in-action)

Curious to see how it works? Check out our detailed demo video on YouTube:
[Watch the Demo](https://www.youtube.com/watch?v=PxFEiAbDfpM)

---

**Live Demo Link**
------------------

[](#live-demo-link)

Experience the extension yourself with this demo link. It will directly add a product with sku `24-MB01` to the cart and redirect you to the checkout page:
[Try It Now](https://magento-demo-247p3.chlamyssoftware.com/dpa/add/tocart/sku/24-MB01)

###  Health Score

41

—

FairBetter than 89% of packages

Maintenance39

Infrequent updates — may be unmaintained

Popularity29

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity70

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

Total

5

Last Release

937d ago

PHP version history (3 changes)1.0.5PHP ~5.5.0|~5.6.0|~7.0.0|~7.1.0|~7.2.0|~7.3.0|~7.4.0

1.0.7PHP ~5.5.0|~5.6.0|~7.0.0|~7.1.0|~7.2.0|~7.3.0|~7.4.0|~8.1.0

1.1.1PHP ~5.5.0|~5.6.0|~7.0.0|~7.1.0|~7.2.0|~7.3.0|~7.4.0|~8.1.0|~8.2.0|~8.3.0

### Community

Maintainers

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

---

Top Contributors

[![sukhvir1313](https://avatars.githubusercontent.com/u/2969049?v=4)](https://github.com/sukhvir1313 "sukhvir1313 (24 commits)")

### Embed Badge

![Health badge](/badges/sukhvir1313-directproductadd/health.svg)

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

###  Alternatives

[aimeos/aimeos-base

Aimeos base layer for abstracting from host environments

2.1k134.0k1](/packages/aimeos-aimeos-base)[microweber/screen

A PHP Class to interact with PhantomJs and capture screenshot of a webpage

632226.0k1](/packages/microweber-screen)[fuel/docs

FuelPHP 1.x Documenataion

166542.3k4](/packages/fuel-docs)[php-soap/ext-soap-engine

An ext-soap engine implementation

443.2M7](/packages/php-soap-ext-soap-engine)[ec-europa/toolkit

Toolkit packaged for Drupal projects based on Robo.

38244.6k16](/packages/ec-europa-toolkit)[fof/user-directory

The permission based public user directory extension for your Flarum forum.

2789.7k5](/packages/fof-user-directory)

PHPackages © 2026

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