UNPKG

@woocommerce/data

Version:
27 lines (26 loc) 1.26 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.QUERY_DEFAULTS = exports.DEFAULT_ACTIONABLE_STATUSES = exports.DEFAULT_REQUIREMENT = exports.MONTH = exports.WEEK = exports.DAY = exports.HOUR = exports.MINUTE = exports.SECOND = exports.MAX_PER_PAGE = exports.WCS_NAMESPACE = exports.WC_ADMIN_NAMESPACE = exports.NAMESPACE = exports.JETPACK_NAMESPACE = void 0; exports.JETPACK_NAMESPACE = '/jetpack/v4'; exports.NAMESPACE = '/wc-analytics'; exports.WC_ADMIN_NAMESPACE = '/wc-admin'; exports.WCS_NAMESPACE = '/wc/v1'; // WCS endpoints like Stripe are not avaiable on later /wc versions // WordPress & WooCommerce both set a hard limit of 100 for the per_page parameter exports.MAX_PER_PAGE = 100; exports.SECOND = 1000; exports.MINUTE = 60 * exports.SECOND; exports.HOUR = 60 * exports.MINUTE; exports.DAY = 24 * exports.HOUR; exports.WEEK = 7 * exports.DAY; exports.MONTH = (365 * exports.DAY) / 12; exports.DEFAULT_REQUIREMENT = { timeout: 1 * exports.MINUTE, freshness: 30 * exports.MINUTE, }; exports.DEFAULT_ACTIONABLE_STATUSES = ['processing', 'on-hold']; exports.QUERY_DEFAULTS = { pageSize: 25, period: 'month', compare: 'previous_year', noteTypes: ['info', 'marketing', 'survey', 'warning'], };