elgentos / magento2-apicacheindexmanagement
Extension to invalidate caches and reindex indexers through the REST API.
Installs: 28
Dependents: 0
Suggesters: 0
Security: 0
Stars: 7
Watchers: 3
Forks: 1
Open Issues: 1
Type:magento2-module
This package is auto-updated.
Last update: 2024-11-29 03:36:50 UTC
README
Extension to invalidate caches and reindex indexers through the REST API. All routes are POST routes.
Both {ids}
and {skus}
can be passed as comma-separated strings or arrays.
Cache routes
/V1/cache/flushAll
/V1/cache/flushAllInvalidated
/V1/cache/flush/{cacheType}
/V1/cache/flush/products (parameters; ids / skus)
/V1/cache/flush/categories (parameters; ids / skus)
Possible cacheTypes
;
config
layout
block_html
collections
reflection
db_ddl
compiled_config
eav
customer_notification
full_page
config_integration
config_integration_api
config_webservice
translate
There could be more or less cache types, depending on your installation. See bin/magento cache:status
for your full list.
Index routes
/V1/index/reindexAll
/V1/index/reindexAllInvalidated
/V1/index/reindex/{indexName} (optional parameters; ids / skus)
Possible indexNames
:
design_config_grid Design Config Grid
customer_grid Customer Grid
catalog_category_product Category Products
catalog_product_category Product Categories
catalogrule_rule Catalog Rule Product
catalog_product_attribute Product EAV
cataloginventory_stock Stock
catalog_product_price Product Price
catalogrule_product Catalog Product Rule
catalogsearch_fulltext Catalog Search
There could be more or less indexes, depending on your installation. See bin/magento indexer:info
for your full list.
Note about re-indexing using the {skus}
parameter: it is possible to use parameter this in combination with a non-product indexer, such as customer_grid
. Doing this will fetch the product IDs belonging to the passed SKUs, and will then reindex the customers with that specific entity ID. This shouldn't introduce any problems, but it's fairly useless.