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.

1.0.3 2025-08-01 10:56 UTC

This package is auto-updated.

Last update: 2025-08-01 11:01:36 UTC


README

The Order API & Scheduled Export module by ManiyaTech empowers Magento 2 store admins to efficiently retrieve and export sales orders using flexible filters. Orders can be pulled via a custom REST API or automatically exported via cron in either CSV or XLSX format. Files are saved in the var/exportorder/ directory, and only the latest 5 files are retained to optimize disk usage.

Key Features

  • โœ… REST API Support : Retrieve a filtered list of orders using a custom REST endpoint.
  • ๐Ÿ”ง Dynamic Filters : Admin-configurable filters for grand total and date range (past N days).
  • ๐Ÿ“… Automated Cron Export : Scheduled order export jobs that generate Excel/CSV files and email them.
  • ๐Ÿ“Ž Email Attachment Support : Exported files are automatically attached to emails based on schedule.
  • ๐Ÿ“ง Email Template Integration : Magento-compatible templates with dynamic fields (subject, receiver name, etc.).
  • โš™๏ธ Admin Field Configuration : Define which order fields to export - includes custom attribute mapping.
  • ๐Ÿงน Auto File Cleanup : Keeps only the 5 latest exports to save disk space.
  • ๐Ÿ“‚ Multiple File Format Support : Choose between XLSX or CSV formats.
  • ๐Ÿ“ˆ Formatted Excel Output : Professionally formatted spreadsheets for reporting/analysis.
  • ๐ŸŒ Timezone Aware Filtering : Date range filters work according to your Magento store's timezone.
  • ๐Ÿ” Secure File Delivery : Uses Magento's built-in filesystem and email transport layers.
  • ๐Ÿ”„ Magento 2.4.8 Compatible : Fully tested with Magento 2.4.8 and PHP 8.4.

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 the main.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