Core
6 days ago
Reviews
6 days ago
Config.php
6 days ago
EventRecorder.php
6 days ago
ReporterInterface.php
6 days ago
SmashUsageTracking.php
6 days ago
ReporterInterface.php
47 lines
| 1 | <?php |
| 2 | |
| 3 | /** |
| 4 | * Usage Tracking Reporter Interface for Reviews Feed. |
| 5 | * |
| 6 | * @package SmashBalloon\Reviews\Common\UsageTracking |
| 7 | * @since 1.0 |
| 8 | */ |
| 9 | |
| 10 | namespace SmashBalloon\Reviews\Common\UsageTracking; |
| 11 | |
| 12 | if (! defined('ABSPATH')) { |
| 13 | exit; |
| 14 | } |
| 15 | |
| 16 | interface ReporterInterface { |
| 17 | /** |
| 18 | * Plugin identifier for payload root (e.g. 'reviews'). |
| 19 | * |
| 20 | * @return string |
| 21 | */ |
| 22 | public function get_plugin_slug(); |
| 23 | |
| 24 | /** |
| 25 | * Schema version for the report payload. |
| 26 | * |
| 27 | * @return string |
| 28 | */ |
| 29 | public function get_schema_version(); |
| 30 | |
| 31 | /** |
| 32 | * Configuration snapshot (environment, settings, sources, providers, feeds). |
| 33 | * |
| 34 | * @return array |
| 35 | */ |
| 36 | public function get_configuration_snapshot(); |
| 37 | |
| 38 | /** |
| 39 | * Dynamic metrics for a time period (performance, errors, events). |
| 40 | * |
| 41 | * @param string $period_start Start of period (e.g. ISO 8601 or timestamp). |
| 42 | * @param string $period_end End of period (e.g. ISO 8601 or timestamp). |
| 43 | * @return array |
| 44 | */ |
| 45 | public function get_dynamic_metrics($period_start, $period_end); |
| 46 | } |
| 47 |