| Server IP : 3.93.235.159 / Your IP : 216.73.216.140 Web Server : Apache System : Linux ip-172-26-0-169 5.10.0-46-cloud-amd64 #1 SMP Debian 5.10.262-1 (2026-07-31) x86_64 User : bitnami ( 1000) PHP Version : 8.2.9 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /bitnami/wordpress/wp-content/plugins/image-optimization/modules/oauth/rest/ |
Upload File : |
<?php
namespace ImageOptimization\Modules\Oauth\Rest;
use ImageOptimization\Modules\Oauth\{
Classes\Route_Base,
Components\Connect,
};
use Throwable;
use WP_REST_Request;
if ( ! defined( 'ABSPATH' ) ) {
exit; // Exit if accessed directly.
}
class Version extends Route_Base {
const NONCE_NAME = 'image-optimization-version';
protected string $path = 'version';
public function get_name(): string {
return 'version';
}
public function get_methods(): array {
return [ 'GET' ];
}
public function GET( WP_REST_Request $request ) {
return $this->respond_success_json( [
'version' => 1,
] );
}
}