# Magento

Easiest way to integrate is to install Firework Magento Extension. This way you can automatically sync products, add widgets into your templates or pages.

Detailed guide for installation can be found [here](https://marketplace.magento.com/media/catalog/product/firework-firework-1-0-2-ce/user_guides.pdf).

### Extension Installation guide

#### **Step 1: First download the Firework Extension for Magento 2**

<https://commercemarketplace.adobe.com/firework-firework.html>

Navigate to the Magento Marketplace [(My Profile - Access Keys)](https://marketplace.magento.com/customer/accessKeys/) Paste the access keys in your auth.json file inside magento project.

Use the "composer require firework/firework" command to add the extension to your project.

Please run the following commands to install code base and database schemas.

```
 php bin/magento setup:di:compile
 php bin/magento setup:upgrade
 php bin/magento setup:static-content:deploy -f
 php bin/magento indexer:reindex
 php bin/magento cache:clean
 php bin/magento cache:flush 
```

Once you’ve executed all the commands you can exit the command line interface and open your Administrator console for Magento 2. Navigate to the Store, and then its Configuration. If there is a new tab in the menu with the Firework Logo, it means you’ve installed the Firework extension correctly, and it’s ready to use.

<figure><img src="https://lh4.googleusercontent.com/8VySA1LSg-HrkabG_xeE-h39z87jOA2-CPwA_LLDjizIm1NcYAbApClizdm9V94LYH1gOM2HjpSfup308IHAv6iJmbKiSY4X9xlDLoxVKk4c3-q0NrfkbhK-O7zJP3QHjW6W73k3vAjMTzQ1-eNH7qE" alt=""><figcaption></figcaption></figure>

**NOTE:** Do not modify the **Endpoint URL** in **Webhook Configuration**, it will be prefilled and modifying it will break the integration.

If the above steps seem confusing or daunting to you, feel free to reach out to your Firework Account Manager. They are more than willing to assist you in this configuration.

**NOTE:** To implement all changes on the magento storefront, the store admin needs to flush the cache each time settings and configurations are done.

#### Step 2: Configure the Firework Extension

Once the Firework Extension is installed, we need to ensure it is configured correctly to integrate with your stores. These steps need to be performed by a Magento store administrator.

Navigate to **System** and then to **Integrations**, and select **Add New Integration**. Fill out the general information on the Integration and **Save** your changes.

<figure><img src="https://lh3.googleusercontent.com/Iak7v8P7T1MDSiA06PkW3H0lYTpVMIn2WgJYUUtuwPWx4jU9Ozks5nTchwaHbJtfrmYvDFA0zVpc1sqqFYhXWyR-tltZoXQ2z7hNkB4E9tZcNrWZZg1eennZnnCcztCQ4KGs5irsVpFA5Snpf_4CRDg" alt=""><figcaption></figcaption></figure>

Select **API** from the left-hand navigation menu and allow access to the below features:

* Cart
* Catalog
* Customers
* Marketing
* My Account

<figure><img src="https://lh4.googleusercontent.com/Gxzm_68uF9drNi-sQ9FYlN_e8UguEwHT7pKWeKDFDx7VwMg0V7oI2mSe3R91YbRjUQV87pO8XHp7A_Gn6U6h2KRivb5IJOTNqICfOJrwjSDRbrok7FeFW2hjYqXdiwvHNBu4ZvR0pXYcvDRqRKuv9UM" alt=""><figcaption></figcaption></figure>

#### Step 3: Add Widgets

Navigate to the page upon which you want to display a Firework widget. Go to the page editor, and select **Insert Widget**, and then select **Firework Videos** as your **Widget Type**.

From the **Widget Options** you can select the layout you wish to add to the page, and use the dropdown menus to select the appropriate Channel and Playlist.

<figure><img src="https://lh3.googleusercontent.com/5YPTi0KHKvv51MRBpxYmr4W1Tzj08dYhXysqWYNB7MOgFORvSXj5IdNwSsODXKm-GlMlpj0aHMns_oxEXgc2zGm5ZnDlBHVQ3dgZ6V83wxr02qwC3i_Gs22KtdYp-sNh0aISnAvvWDM1zBNE1FzWnAg" alt=""><figcaption></figcaption></figure>

#### Step 4: Import Products

Once you connect to the Firework Dashboard you will be directed to your store. The **Products** tab will include any imported products already. But the **Import Products** tab will list all the products that you have in your magento store.

<figure><img src="https://lh3.googleusercontent.com/d1iubPuJv5LNifV7hao32wO8mGipBfEemzLjThXIk1SvxEDW7jF0mXb6W1kNP5ffWctkt7Hy9GjEkLvIWzFtYI5ygDi9OvYTXl_x2rRErY7kAs7tHe2qh6IaBnHA7NNLRxibC37j_S9nDnvsRS29gA" alt=""><figcaption></figcaption></figure>

You can click the **Import** button on the right to add the product from your Magento Store to your Firework Store. This will enable you to apply this product on product cards on your Firework Videos and Livestreams.

<figure><img src="https://lh6.googleusercontent.com/y83w9z_xIqLUp9CMc4pRUys25gecijA7Bbd5uWw_Z6Tp6dekyQNeREDXqSyghnLSd_l-4ZmKkYZiOuAPlh4_Y1RvtlIhhhQq3dFNIjYlPbSrogYn4SZj4pYsI18vbh6EDi37Dnp7iCXciWpYQPdJNQ" alt=""><figcaption></figcaption></figure>

If products are already imported you will see Sync button to update the products data in your firework account

<figure><img src="https://lh4.googleusercontent.com/0Rgd8yMt6H_7DfF_ReDgaciu_V8cNLP0PjkkbVz_Ke6G8bVS7rRXrwGfpIWEF9quJEBKrZBgW8OFk8RsVuQ7zZ1s5m3MqQRChHKkyaLKI_ccRE6K0ZFunYlDtL2qwRCJ29p46xxXmzNqP5dRVvR1IA" alt=""><figcaption></figcaption></figure>

#### Step 5: Enable Purchase Tracking

Please Navigate to the\
Store -> Settings -> Configuration -> Firework -> Purchase Tracking -> Enable

<div align="left" data-full-width="false"><figure><img src="https://688917408-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MLoGG8m6bokS9YTmS7m%2Fuploads%2Fgit-blob-e6b7de934634a2d9c4b7a6571d52533147b16eb6%2Funnamed.png?alt=media" alt=""><figcaption></figcaption></figure></div>

#### Step 6: Activate Cart Integration

Select a video in your library, and use the options menu … to select **Edit**.

<figure><img src="https://lh5.googleusercontent.com/mlGbYpvmQ8DHg-fgJLraAu2Js3-J4-Bia2nhF9sG0iksBv_pjv2rR8OYS_XD0TEje_C_PYiASuxzuZM1XUJkdOeIRrqbZzTYtNTLStfzCh0JV-cWhlTeSJZl-NXyLAzLGO5u86PE7M79jjqUlQWUhg" alt=""><figcaption></figcaption></figure>

In the video options use the Video Overlays button to add a Product Card to the video.

<figure><img src="https://lh5.googleusercontent.com/y-Hy0PE7B4YSPenXB6ERvYPJqlUAM4-WaJSuyVXiJJPRyeJ4LooO4dDMQsr-RRsHLW5J1EFkj3vjjPnHq8QAv6Q3f5MXpsOoVhNgwSxh8AwL0xuY0CLBNlm9CoNNi2Lv6iANCIgLvuT5zQ_8kqwoFg" alt=""><figcaption></figcaption></figure>

<figure><img src="https://lh5.googleusercontent.com/BTE708zIDrdmC2ToEgDDcNYjxyRds5f192OHW9TYQONKJPBCCUHf-dSSeAaiYlnhuSpD3c1Ox1alzdXJwhaJQ-Ut-m4-VlGXq69gLRHrS8R-It_dBGWKlBHTSfBouxBNdU1N1kWBEHqhB4JInPbuVA" alt=""><figcaption></figcaption></figure>

Use the dropdown menu to select the store that you have integrated to your Magento Store.

<figure><img src="https://lh6.googleusercontent.com/c99Dbs_37uFnwmiF3Nd5kCr2LCLxBoxRtCBVjAOU6DAHxvm4hAv3gBaXrDMP1mKM20Uv4AisdU1NTRBpTKszqs2rnvM_UneMe4aQ0ppOXRwmEzdSi_XFOw_KeBeayegknICXoXPImSyH4sQUzUWEGg" alt=""><figcaption></figcaption></figure>

Then select the product you want to overlay atop the video you are editing and click **Add**.

<figure><img src="https://lh3.googleusercontent.com/XhsvxuB1aN36K2_Bs77B3hlCmd_0E5U_GPZwzouXmSrcuDeR8hs2Q2PKNepuhzD9QWZz64s7m6gPI2i-liJ55Xd_oLkJ2d4HS95BK2EtBQDWpxbiLwIxNt3MbGbYL8yTzvPCOsEo5Wmpn8HlqcbFQQ" alt=""><figcaption></figcaption></figure>

Once your video is edited to include the product you can return to the page on which you embedded your Firework widget.

<figure><img src="https://lh6.googleusercontent.com/N4nlfBwUzNugiYThxWLizwlWrlasgH6myInQoDxaIslqZgrv0anA0k2cLVjecMSGGXnnjZG1e7HrwVf7F8Qeih0v8JZ_VxUjFqqS6Qmkv1G_uxJdlGeIFmNsDbu6GORtdHnKvRhWba3o2gdmwusSFA" alt=""><figcaption></figcaption></figure>

If you select your video you will see the Product Card on the playing video.

<figure><img src="https://lh6.googleusercontent.com/uM-nFq3Y0fEQFw1uHj94PgZi7o0_8QrVs7auIGN7ajb4RHCDX8izcytgaHrAte9ABqWK9XZKGmItYLfaE5melKTYDVnvpcudvqncC0hCKvG_3QwGYabdfWWY4ZZAh4TsGFlzNWdoiYwGOD_1ex2tWw" alt=""><figcaption></figcaption></figure>

Selecting the product and **Shop Now** will put the product in the shopping cart for this session on your site.

<figure><img src="https://lh3.googleusercontent.com/x-cTeyBvNioDqZJR0UY3NjEfOeJb0pXeTglkevmYPmDU46GXMr0L2pdfzLroWdixoMGZLnTUPpX_XWiMl1Mr60HDKEiF4R0m0kNeasNqXCiS6EJdkSEDdyDQU0fJN8qesM68KSkmK7h0EWMvfuIQAw" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.firework.com/firework-for-developers/web/tutorials/magento.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
