maniyatech / magento2-orderapi
Export orders via REST API and scheduled cron job based on configurable grand total and date range. Automatically generates Excel files and maintains only the latest 5 exports.
Installs: 0
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 0
Forks: 1
Open Issues: 0
Type:magento2-module
Requires
README
The Order API & Scheduled Export module by ManiyaTech allows merchants to access and export order data efficiently using configurable filters. You can retrieve orders via REST API based on a minimum grand total and a selected date range. In addition, a cron job can be scheduled to automatically export orders to Excel format and store them in the var/exportorder/ directory. The module keeps only the latest 5 export files, ensuring disk space optimization.
This is especially useful for admins who need regular exports for reporting, analysis, or integration with third-party systems.
Key Features
- β REST API Support: Fetch filtered order list using custom API endpoint.
- π§ Configurable Filters: Set minimum grand total and number of past days for export.
- π Scheduled Export via Cron: Automatically generate Excel files on a defined schedule.
- π Auto Cleanup: Keeps only the 5 most recent export files; older files are automatically deleted.
- π Formatted Excel Output: Generates well-structured spreadsheets with all key order fields.
- π‘οΈ Magento Standards Compliant: Follows Magento 2.4.X and PHP 8.4 best practices with PSR & PHPCS compatibility.
- βοΈ Admin Configurable: Enable/disable module, define export filters, and cron frequency from the backend.
- π Timezone Aware: Date range filters work according to store timezone settings.
- π© Automated Email Delivery: Sends the order report automatically via a scheduled cron job β no manual intervention required.
- π Order Report Attachment: Attaches the latest order report (Excel) directly to the email.
- βοΈ Magento Email Template Integration: Fully supports dynamic email templates with variables like subject and receiver name.
- π§© Customizable Configuration: Easily configurable via Magento admin (subject line, recipients, etc.).
- π‘οΈ Secure File Handling: Uses Magentoβs filesystem and mail transport classes for secure and reliable file delivery.
- π Supports Magento 2.4.8: Fully tested and compatible with Magento 2.4.8.
How to install ManiyaTech_OrderApi module
Composer Installation
Run the following command in Magento 2 root directory to install ManiyaTech_OrderApi module via composer.
Install
composer require maniyatech/magento2-orderapi
php bin/magento setup:upgrade
php bin/magento setup:static-content:deploy -f
Update
composer update maniyatech/magento2-orderapi
php bin/magento setup:upgrade
php bin/magento setup:static-content:deploy -f
Run below command if your store is in the production mode:
php bin/magento setup:di:compile
Manual Installation
If you prefer to install this module manually, kindly follow the steps described below -
- Download the latest version here
- Create a folder path like this
app/code/ManiyaTech/OrderApi
and extract themain.zip
file into it. - Navigate to Magento root directory and execute the below commands.
php bin/magento setup:upgrade
php bin/magento setup:static-content:deploy -f