Magento 1 extensions were removed from https://marketplace.magento.com about a month ago. According to Adobe’s recent blog posts, all extensions will be removed early August from their repository, which causes a lot of frustration on developers who are still in the middle of moving towards Magento 2 or simply need the code to translate it into Magento 2 modules.
1 2 |
July 7, 2020 – Removal of all M1 extension listings from marketplace.magento.com. Extension will be available on repo.magento.com until 8/6/2020. August 6, 2020 – Removal of M1 extensions from repo.magento.com |
1 |
We encourage Magento 1 merchants to download the Magento 1 extensions they plan to keep, since Magento 1 extensions will not be available in the Magento Marketplace after July 7, 2020, and will be removed from the Magento repository after August 6, 2020. |
Source: https://magento.com/blog/magento-news/support-magento-1-software-ends-june-30-2020
So, in order to download an M1 package, you simply have to point to a specific URL. Luckily they didn’t turn off https://connect20.magentocommerce.com yet, but I believe Magento will get rid of it very soon.
1 |
https://connect20.magentocommerce.com/community/%extKey%/%version%/%extKey%-%version%.tgz |
I’ve spent a few minutes writing a ” quick and dirty ” PHP script that downloads the most recent version of each extension in https://connect20.magentocommerce.com/community/packages.xml including package details such as name, description, and author. For example https://connect20.magentocommerce.com/community/BankPayment/1.2.0/package.xml
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
<?xml version="1.0"?> <package> <name>BankPayment</name> <version>1.2.0</version> <stability>stable</stability> <license uri="http://opensource.org/licenses/osl-3.0.php">OSL</license> <channel>community</channel> <extends/> <summary>Vorkasse - Bank Prepayment module which notifies the buyer to which bank account he has to transfer the money.</summary> <description>Bank Prepayment module which notifies the buyer to which bank account he has to transfer the money.</description> <notes>IBAN ready
 Allow partial capturing
 Localization improvements</notes> <authors><author><name>Phoenix Media GmbH</name><user>PHOENIX</user><email>bjoern.kraus@phoenix-media.eu</email></author></authors> <date>2017-09-05</date> <time>11:08:47</time> <contents><target name="magecommunity"><dir name="Phoenix"><dir name="BankPayment"><dir name="Block"><dir name="Adminhtml"><file name="BankAccount.php" hash="80df5881081ded22b182ac2bde3b0a3e"/>$ <compatible/> <dependencies><required><php><min>5.2.0</min><max>7.0.22</max></php><extension><name>Core</name><min/><max/></extension></required></dependencies> </package> |
If you download all packages, you will end up with about 1300 extensions.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
├── zoe_myzoe │ ├── Zoe_Myzoe--package.xml │ └── Zoe_Myzoe-.tgz ├── zoe_myzoe-1.0.0 │ ├── Zoe_Myzoe-1.0.0--package.xml │ └── Zoe_Myzoe-1.0.0-.tgz ├── zopim_live_chat │ ├── Zopim_Live_Chat-0.5.4-package.xml │ └── Zopim_Live_Chat-0.5.4.tgz └── zubibu ├── zubibu-1.0.0-package.xml └── zubibu-1.0.0.tgz 1359 directories, 2716 files |
However, it seems the packages.xml file contains a lot of extensions that are actually not available anymore, that leads to a 404.
1 2 3 4 |
PHP Warning: file_get_contents(https://connect20.magentocommerce.com/community/SUMOHeavy_Coupons/1.1.0/SUMOHeavy_Coupons-1.1.0.tgz): failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found in /var/www/extensions/index.php on line 41 PHP Warning: file_get_contents(https://connect20.magentocommerce.com/community/SUMOHeavy_Coupons/1.1.0/package.xml): failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found in /var/www/extensions/index.php on line 50 |
Another good resource is https://packages.firegento.com or http://freegento.com/ddl-magento-extension.php to download M1 extensions.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 |
<?php /** * Connect20 * * @category Connect20 * @author Tobias Forkel (http://tobias.forkel.me) * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) */ $packagesUrl = 'https://connect20.magentocommerce.com/community/packages.xml'; $releasesUrl = 'https://connect20.magentocommerce.com/community/%extKey%/releases.xml'; $packageUrl = 'https://connect20.magentocommerce.com/community/%extKey%/%version%/package.xml'; $downloadUrl = 'https://connect20.magentocommerce.com/community/%extKey%/%version%/%extKey%-%version%.tgz'; $packages = implode('/', [dirname(__FILE__), 'packages.xml']); // Cache packages.xml file if (!file_exists($packages)) { file_put_contents($packages, file_get_contents($packagesUrl)); } $packages = simplexml_load_file($packages); foreach ($packages as $data) { $extKey = (string)$data->n; $stable = (string)$data->r->s; $beta = (string)$data->r->b; $version = (!empty($stable)) ? $stable : $beta; if (empty($version)) { echo sprintf('Skipped ( %s )', $extKey); echo PHP_EOL; continue; } $folder = implode('/', [dirname(__FILE__), 'data', strtolower($extKey)]); // Create extension folder if (!file_exists($folder)) { mkdir($folder, 0777, true); } $download = str_replace(['%extKey%', '%version%'] ,[$extKey, $version], $downloadUrl); $downloadPath = implode('/', [$folder, basename($download)]); // Skip downloaded files if (file_exists($downloadPath)) { continue; } // Download the *.tgz file ( stable or beta ) if (file_put_contents($downloadPath, file_get_contents($download))) { echo $download; echo PHP_EOL; } // Download content ( e.g description, author etc. ) from package.xml $package = str_replace(['%extKey%', '%version%'] ,[$extKey, $version], $packageUrl); if (file_put_contents(implode('/', [$folder, $extKey . '-' . $version . '-' . basename($package)]), file_get_contents($package))) { echo $package; echo PHP_EOL; } } ?> |
Feel free to change or share the code.