You need to enable JavaScript to run this app.
veImageX

veImageX

复制全文
统计与监控
数据监控
复制全文
数据监控

阅读本文,您可以快速了解数据监控 PHP SDK 的使用方法。

说明

以下 SDK 示例中仅展示了部分参数,您可以在 veImageX 的接口文档中查看该接口支持的全部参数及取值。

初始化

调用接口前请先完成初始化,具体操作请参考初始化

查询边缘请求次数

查询当前账号下对应域名的边缘请求次数。

具体接口参数和返回字段请参考 DescribeImageXEdgeRequest。我们同时在 GitHub 上提供了参考示例

具体示例如下所示:

<?php
include_once(__DIR__ . '/../../../vendor/autoload.php');

use Volc\Service\ImageX;

$client = ImageX::getInstance();

// call below method if you dont set ak and sk in ~/.volc/config
$client->setAccessKey("ak");
$client->setSecretKey("sk");

$body = [
    'DataTypes' => '2xx,3xx,4xx,5xx',
    'GroupBy' => 'DomainName,DataType',
    'StartTime' => "2023-01-21T00:00:00+08:00",
    'EndTime' => "2023-01-28T00:00:00+08:00",
    'Interval' => "300",
];

$response = $client->describeImageXEdgeRequest($body);
print_r($response);

查询镜像回源带宽

本接口支持查询当前账号下镜像回源带宽用量数据。

具体接口参数和返回字段请参考 DescribeImageXMirrorRequestBandwidth。我们同时在 GitHub 上提供了参考示例

具体示例如下所示:

<?php
include_once(__DIR__ . '/../../../vendor/autoload.php');

use Volc\Service\ImageX;

$client = ImageX::getInstance();

// call below method if you dont set ak and sk in ~/.volc/config
$client->setAccessKey("ak");
$client->setSecretKey("sk");

$body = [
    'StartTime' => "2023-01-21T00:00:00+08:00",
    'EndTime' => "2023-01-28T00:00:00+08:00",
    'Interval' => "5m",
];

$response = $client->describeImageXMirrorRequestBandwidth($body);
print_r($response);

查询镜像回源流量

本接口支持查询当前账号下镜像回源流量用量数据。

具体接口参数和返回字段请参考 DescribeImageXMirrorRequestTraffic。我们同时在 GitHub 上提供了参考示例

具体示例如下所示:

<?php
include_once(__DIR__ . '/../../../vendor/autoload.php');

use Volc\Service\ImageX;

$client = ImageX::getInstance();

// call below method if you dont set ak and sk in ~/.volc/config
$client->setAccessKey("ak");
$client->setSecretKey("sk");

$query = [
    'StartTime' => "2023-01-21T00:00:00+08:00",
    'EndTime' => "2023-01-28T00:00:00+08:00",
    'Interval' => "5m",
];

$response = $client->describeImageXMirrorRequestTraffic($query);
print_r($response);

查询镜像回源请求次时序数据

本接口支持查询当前账号下的镜像回源请求次时序数据。

具体接口参数和返回字段请参考 DescribeImageXMirrorRequestHttpCodeByTime。我们同时在 GitHub 上提供了参考示例

具体示例如下所示:

<?php
include_once(__DIR__ . '/../../../vendor/autoload.php');

use Volc\Service\ImageX;

$client = ImageX::getInstance();

// call below method if you dont set ak and sk in ~/.volc/config
$client->setAccessKey("ak");
$client->setSecretKey("sk");

$body = [
    'StartTime' => "2023-01-21T00:00:00+08:00",
    'EndTime' => "2023-01-28T00:00:00+08:00",
    'Interval' => "5m",
];

$response = $client->describeImageXMirrorRequestHttpCodeByTime($body);
print_r($response);

查询镜像回源请求次域名明细数据

本接口支持查询当前账号下镜像回源请求次的域名明细数据用量数据。

具体接口参数和返回字段请参考 DescribeImageXMirrorRequestHttpCodeOverview。我们同时在 GitHub 上提供了参考示例

具体示例如下所示:

<?php
include_once(__DIR__ . '/../../../vendor/autoload.php');

use Volc\Service\ImageX;

$client = ImageX::getInstance();

// call below method if you dont set ak and sk in ~/.volc/config
$client->setAccessKey("ak");
$client->setSecretKey("sk");

$body = [
    'StartTime' => "2023-01-21T00:00:00+08:00",
    'EndTime' => "2023-01-28T00:00:00+08:00",
    'AggregateCode' => "false",
];

$response = $client->describeImageXMirrorRequestHttpCodeOverview($body);
print_r($response);

查询边缘分发带宽用量

本接口支持查询账号下对应域名的边缘分发带宽用量。

具体接口参数和返回字段请参考 DescribeImageXEdgeRequestBandwidth。我们同时在 GitHub 上提供了参考示例

具体示例如下所示:

<?php
include_once(__DIR__ . '/../../../vendor/autoload.php');

use Volc\Service\ImageX;

$client = ImageX::getInstance();

// call below method if you dont set ak and sk in ~/.volc/config
$client->setAccessKey("ak");
$client->setSecretKey("sk");

$body = [
    'StartTime' => "2023-01-21T00:00:00+08:00",
    'EndTime' => "2023-01-28T00:00:00+08:00",
    'Interval' => "300",
];

$response = $client->describeImageXEdgeRequestBandwidth($body);
print_r($response);

查询边缘分发流量用量

本接口支持查询账号下对应域名的边缘分发流量用量。
具体接口参数和返回字段请参考 DescribeImageXEdgeRequestTraffic。我们同时在 GitHub 上提供了参考示例

具体示例如下所示:

<?php
include_once(__DIR__ . '/../../../vendor/autoload.php');

use Volc\Service\ImageX;

$client = ImageX::getInstance();

// call below method if you dont set ak and sk in ~/.volc/config
$client->setAccessKey("ak");
$client->setSecretKey("sk");

$body = [
    'StartTime' => "2023-01-21T00:00:00+08:00",
    'EndTime' => "2023-01-28T00:00:00+08:00",
    'Interval' => "300",
];

$response = $client->describeImageXEdgeRequestTraffic($body);
print_r($response);

获取边缘分发地区列表

本接口支持查询账号下边缘分发数据的地区列表。

具体接口参数和返回字段请参考 DescribeImageXEdgeRequestRegions。我们同时在 GitHub 上提供了参考示例

具体示例如下所示:

<?php
include_once(__DIR__ . '/../../../vendor/autoload.php');

use Volc\Service\ImageX;

$client = ImageX::getInstance();

// call below method if you dont set ak and sk in ~/.volc/config
$client->setAccessKey("ak");
$client->setSecretKey("sk");

$body = [
    'StartTime' => "2023-01-21T00:00:00+08:00",
    'EndTime' => "2023-01-28T00:00:00+08:00",
];

$response = $client->describeImageXEdgeRequestRegions($body);
print_r($response);
最近更新时间:2024.12.05 18:30:55
这个页面对您有帮助吗?
有用
有用
无用
无用