From bf2aea0ee6b49687bea0f323d7b09251633aa67c Mon Sep 17 00:00:00 2001 From: ucloud-bot Date: Wed, 20 May 2026 06:49:24 +0000 Subject: [PATCH] sdk: rolling update for 0.3.19 --- VERSION | 2 +- src/UWSC/Apis/AddExportLineRulesRequest.php | 92 ++++ src/UWSC/Apis/AddExportLineRulesResponse.php | 26 + src/UWSC/Apis/BindCPERequest.php | 92 ++++ src/UWSC/Apis/BindCPEResponse.php | 26 + src/UWSC/Apis/CreateCPERequest.php | 173 +++++++ src/UWSC/Apis/CreateCPEResponse.php | 44 ++ src/UWSC/Apis/CreateExportLineRequest.php | 314 +++++++++++++ src/UWSC/Apis/CreateExportLineResponse.php | 44 ++ src/UWSC/Apis/DeleteExportLineRequest.php | 71 +++ src/UWSC/Apis/DeleteExportLineResponse.php | 26 + .../Apis/DeleteExportLineRulesRequest.php | 92 ++++ .../Apis/DeleteExportLineRulesResponse.php | 26 + src/UWSC/Apis/DescribeCPERequest.php | 90 ++++ src/UWSC/Apis/DescribeCPEResponse.php | 57 +++ src/UWSC/Apis/DescribeExportLineRequest.php | 89 ++++ src/UWSC/Apis/DescribeExportLineResponse.php | 58 +++ .../Apis/DescribeExportLineRulesRequest.php | 89 ++++ .../Apis/DescribeExportLineRulesResponse.php | 57 +++ src/UWSC/Apis/UpdateExportLineRequest.php | 92 ++++ src/UWSC/Apis/UpdateExportLineResponse.php | 26 + src/UWSC/Apis/UpgradeExportLineRequest.php | 193 ++++++++ src/UWSC/Apis/UpgradeExportLineResponse.php | 26 + src/UWSC/Models/CPEInfo.php | 324 +++++++++++++ src/UWSC/Models/LineInfo.php | 444 ++++++++++++++++++ src/UWSC/Models/SocksInfo.php | 84 ++++ src/UWSC/Models/WhiteListInfo.php | 84 ++++ src/UWSC/UWSCClient.php | 422 +++++++++++++++++ 28 files changed, 3162 insertions(+), 1 deletion(-) create mode 100644 src/UWSC/Apis/AddExportLineRulesRequest.php create mode 100644 src/UWSC/Apis/AddExportLineRulesResponse.php create mode 100644 src/UWSC/Apis/BindCPERequest.php create mode 100644 src/UWSC/Apis/BindCPEResponse.php create mode 100644 src/UWSC/Apis/CreateCPERequest.php create mode 100644 src/UWSC/Apis/CreateCPEResponse.php create mode 100644 src/UWSC/Apis/CreateExportLineRequest.php create mode 100644 src/UWSC/Apis/CreateExportLineResponse.php create mode 100644 src/UWSC/Apis/DeleteExportLineRequest.php create mode 100644 src/UWSC/Apis/DeleteExportLineResponse.php create mode 100644 src/UWSC/Apis/DeleteExportLineRulesRequest.php create mode 100644 src/UWSC/Apis/DeleteExportLineRulesResponse.php create mode 100644 src/UWSC/Apis/DescribeCPERequest.php create mode 100644 src/UWSC/Apis/DescribeCPEResponse.php create mode 100644 src/UWSC/Apis/DescribeExportLineRequest.php create mode 100644 src/UWSC/Apis/DescribeExportLineResponse.php create mode 100644 src/UWSC/Apis/DescribeExportLineRulesRequest.php create mode 100644 src/UWSC/Apis/DescribeExportLineRulesResponse.php create mode 100644 src/UWSC/Apis/UpdateExportLineRequest.php create mode 100644 src/UWSC/Apis/UpdateExportLineResponse.php create mode 100644 src/UWSC/Apis/UpgradeExportLineRequest.php create mode 100644 src/UWSC/Apis/UpgradeExportLineResponse.php create mode 100644 src/UWSC/Models/CPEInfo.php create mode 100644 src/UWSC/Models/LineInfo.php create mode 100644 src/UWSC/Models/SocksInfo.php create mode 100644 src/UWSC/Models/WhiteListInfo.php create mode 100644 src/UWSC/UWSCClient.php diff --git a/VERSION b/VERSION index 8355eaf..9ec8136 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -0.3.18 +0.3.19 diff --git a/src/UWSC/Apis/AddExportLineRulesRequest.php b/src/UWSC/Apis/AddExportLineRulesRequest.php new file mode 100644 index 0000000..e253ba3 --- /dev/null +++ b/src/UWSC/Apis/AddExportLineRulesRequest.php @@ -0,0 +1,92 @@ + "AddExportLineRules"]); + $this->markRequired("ProjectId"); + $this->markRequired("ResourceId"); + $this->markRequired("RuleTypes"); + } + + + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId($projectId) + { + $this->set("ProjectId", $projectId); + } + + /** + * ResourceId: UReach资源ID + * + * @return string|null + */ + public function getResourceId() + { + return $this->get("ResourceId"); + } + + /** + * ResourceId: UReach资源ID + * + * @param string $resourceId + */ + public function setResourceId($resourceId) + { + $this->set("ResourceId", $resourceId); + } + + /** + * RuleTypes: 白名单类型:Developer、CrossBorder + * + * @return string[]|null + */ + public function getRuleTypes() + { + return $this->get("RuleTypes"); + } + + /** + * RuleTypes: 白名单类型:Developer、CrossBorder + * + * @param string[] $ruleTypes + */ + public function setRuleTypes(array $ruleTypes) + { + $this->set("RuleTypes", $ruleTypes); + } +} diff --git a/src/UWSC/Apis/AddExportLineRulesResponse.php b/src/UWSC/Apis/AddExportLineRulesResponse.php new file mode 100644 index 0000000..e358ca9 --- /dev/null +++ b/src/UWSC/Apis/AddExportLineRulesResponse.php @@ -0,0 +1,26 @@ + "BindCPE"]); + $this->markRequired("ProjectId"); + $this->markRequired("CPEId"); + $this->markRequired("Sn"); + } + + + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId($projectId) + { + $this->set("ProjectId", $projectId); + } + + /** + * CPEId: cpe id + * + * @return string|null + */ + public function getCPEId() + { + return $this->get("CPEId"); + } + + /** + * CPEId: cpe id + * + * @param string $cpeId + */ + public function setCPEId($cpeId) + { + $this->set("CPEId", $cpeId); + } + + /** + * Sn: sn id + * + * @return string|null + */ + public function getSn() + { + return $this->get("Sn"); + } + + /** + * Sn: sn id + * + * @param string $sn + */ + public function setSn($sn) + { + $this->set("Sn", $sn); + } +} diff --git a/src/UWSC/Apis/BindCPEResponse.php b/src/UWSC/Apis/BindCPEResponse.php new file mode 100644 index 0000000..bca9b75 --- /dev/null +++ b/src/UWSC/Apis/BindCPEResponse.php @@ -0,0 +1,26 @@ + "CreateCPE"]); + $this->markRequired("ProjectId"); + $this->markRequired("Name"); + $this->markRequired("Remark"); + $this->markRequired("DeviceType"); + } + + + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId($projectId) + { + $this->set("ProjectId", $projectId); + } + + /** + * Name: cpe 名称 + * + * @return string|null + */ + public function getName() + { + return $this->get("Name"); + } + + /** + * Name: cpe 名称 + * + * @param string $name + */ + public function setName($name) + { + $this->set("Name", $name); + } + + /** + * Remark: cpe 备注 + * + * @return string|null + */ + public function getRemark() + { + return $this->get("Remark"); + } + + /** + * Remark: cpe 备注 + * + * @param string $remark + */ + public function setRemark($remark) + { + $this->set("Remark", $remark); + } + + /** + * DeviceType: 设备型号,枚举值: UCPE3600、UCPE3601 + * + * @return string|null + */ + public function getDeviceType() + { + return $this->get("DeviceType"); + } + + /** + * DeviceType: 设备型号,枚举值: UCPE3600、UCPE3601 + * + * @param string $deviceType + */ + public function setDeviceType($deviceType) + { + $this->set("DeviceType", $deviceType); + } + + /** + * Label: 标签:UReach智能网关:Access + * + * @return string|null + */ + public function getLabel() + { + return $this->get("Label"); + } + + /** + * Label: 标签:UReach智能网关:Access + * + * @param string $label + */ + public function setLabel($label) + { + $this->set("Label", $label); + } + + /** + * UserInfo: 结构体,详见UserInfo模型 + * + * @return string|null + */ + public function getUserInfo() + { + return $this->get("UserInfo"); + } + + /** + * UserInfo: 结构体,详见UserInfo模型 + * + * @param string $userInfo + */ + public function setUserInfo($userInfo) + { + $this->set("UserInfo", $userInfo); + } + + /** + * Count: 数量,默认为1 + * + * @return integer|null + */ + public function getCount() + { + return $this->get("Count"); + } + + /** + * Count: 数量,默认为1 + * + * @param int $count + */ + public function setCount($count) + { + $this->set("Count", $count); + } +} diff --git a/src/UWSC/Apis/CreateCPEResponse.php b/src/UWSC/Apis/CreateCPEResponse.php new file mode 100644 index 0000000..a5e2e5f --- /dev/null +++ b/src/UWSC/Apis/CreateCPEResponse.php @@ -0,0 +1,44 @@ +get("CPEId"); + } + + /** + * CPEId: cpe id + * + * @param string $cpeId + */ + public function setCPEId($cpeId) + { + $this->set("CPEId", $cpeId); + } +} diff --git a/src/UWSC/Apis/CreateExportLineRequest.php b/src/UWSC/Apis/CreateExportLineRequest.php new file mode 100644 index 0000000..602f91c --- /dev/null +++ b/src/UWSC/Apis/CreateExportLineRequest.php @@ -0,0 +1,314 @@ + "CreateExportLine"]); + $this->markRequired("ProjectId"); + $this->markRequired("FromRegion"); + $this->markRequired("ToRegion"); + $this->markRequired("IpType"); + $this->markRequired("CPEId"); + } + + + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId($projectId) + { + $this->set("ProjectId", $projectId); + } + + /** + * FromRegion: 本端地域 + * + * @return string|null + */ + public function getFromRegion() + { + return $this->get("FromRegion"); + } + + /** + * FromRegion: 本端地域 + * + * @param string $fromRegion + */ + public function setFromRegion($fromRegion) + { + $this->set("FromRegion", $fromRegion); + } + + /** + * ToRegion: 目标地域 + * + * @return string|null + */ + public function getToRegion() + { + return $this->get("ToRegion"); + } + + /** + * ToRegion: 目标地域 + * + * @param string $toRegion + */ + public function setToRegion($toRegion) + { + $this->set("ToRegion", $toRegion); + } + + /** + * IpType: IP类型:International、BGP、Native、Resident + * + * @return string|null + */ + public function getIpType() + { + return $this->get("IpType"); + } + + /** + * IpType: IP类型:International、BGP、Native、Resident + * + * @param string $ipType + */ + public function setIpType($ipType) + { + $this->set("IpType", $ipType); + } + + /** + * CPEId: CPE Id + * + * @return string|null + */ + public function getCPEId() + { + return $this->get("CPEId"); + } + + /** + * CPEId: CPE Id + * + * @param string $cpeId + */ + public function setCPEId($cpeId) + { + $this->set("CPEId", $cpeId); + } + + /** + * PkgType: 套餐类型:2M-Entry、5M-Basic、10M-Enterprise + * + * @return string|null + */ + public function getPkgType() + { + return $this->get("PkgType"); + } + + /** + * PkgType: 套餐类型:2M-Entry、5M-Basic、10M-Enterprise + * + * @param string $pkgType + */ + public function setPkgType($pkgType) + { + $this->set("PkgType", $pkgType); + } + + /** + * Bandwidth: 带宽大小 + * + * @return integer|null + */ + public function getBandwidth() + { + return $this->get("Bandwidth"); + } + + /** + * Bandwidth: 带宽大小 + * + * @param int $bandwidth + */ + public function setBandwidth($bandwidth) + { + $this->set("Bandwidth", $bandwidth); + } + + /** + * Name: 资源名称 + * + * @return string|null + */ + public function getName() + { + return $this->get("Name"); + } + + /** + * Name: 资源名称 + * + * @param string $name + */ + public function setName($name) + { + $this->set("Name", $name); + } + + /** + * Tag: 业务组名称, 默认为 "Default" + * + * @return string|null + */ + public function getTag() + { + return $this->get("Tag"); + } + + /** + * Tag: 业务组名称, 默认为 "Default" + * + * @param string $tag + */ + public function setTag($tag) + { + $this->set("Tag", $tag); + } + + /** + * ChargeType: 计费模式。枚举值为: Year,按年付费; Month,按月付费; Dynamic,按小时付费(需开启权限)。默认为月付 + * + * @return string|null + */ + public function getChargeType() + { + return $this->get("ChargeType"); + } + + /** + * ChargeType: 计费模式。枚举值为: Year,按年付费; Month,按月付费; Dynamic,按小时付费(需开启权限)。默认为月付 + * + * @param string $chargeType + */ + public function setChargeType($chargeType) + { + $this->set("ChargeType", $chargeType); + } + + /** + * Quantity: 购买时长。默认: 1。按小时购买(Dynamic)时无需此参数。 月付时,此参数传0,代表了购买至月末。 + * + * @return integer|null + */ + public function getQuantity() + { + return $this->get("Quantity"); + } + + /** + * Quantity: 购买时长。默认: 1。按小时购买(Dynamic)时无需此参数。 月付时,此参数传0,代表了购买至月末。 + * + * @param int $quantity + */ + public function setQuantity($quantity) + { + $this->set("Quantity", $quantity); + } + + /** + * Remark: 备注 + * + * @return string|null + */ + public function getRemark() + { + return $this->get("Remark"); + } + + /** + * Remark: 备注 + * + * @param string $remark + */ + public function setRemark($remark) + { + $this->set("Remark", $remark); + } + + /** + * PayMode: 计费类型:fixed-bw,固定带宽;traffic,流量计费 + * + * @return string|null + */ + public function getPayMode() + { + return $this->get("PayMode"); + } + + /** + * PayMode: 计费类型:fixed-bw,固定带宽;traffic,流量计费 + * + * @param string $payMode + */ + public function setPayMode($payMode) + { + $this->set("PayMode", $payMode); + } + + /** + * CouponId: 代金券ID。请登录用户中心查看 + * + * @return integer|null + */ + public function getCouponId() + { + return $this->get("CouponId"); + } + + /** + * CouponId: 代金券ID。请登录用户中心查看 + * + * @param int $couponId + */ + public function setCouponId($couponId) + { + $this->set("CouponId", $couponId); + } +} diff --git a/src/UWSC/Apis/CreateExportLineResponse.php b/src/UWSC/Apis/CreateExportLineResponse.php new file mode 100644 index 0000000..156e6f9 --- /dev/null +++ b/src/UWSC/Apis/CreateExportLineResponse.php @@ -0,0 +1,44 @@ +get("ResourceId"); + } + + /** + * ResourceId: 资源ID + * + * @param string $resourceId + */ + public function setResourceId($resourceId) + { + $this->set("ResourceId", $resourceId); + } +} diff --git a/src/UWSC/Apis/DeleteExportLineRequest.php b/src/UWSC/Apis/DeleteExportLineRequest.php new file mode 100644 index 0000000..ae7ebcd --- /dev/null +++ b/src/UWSC/Apis/DeleteExportLineRequest.php @@ -0,0 +1,71 @@ + "DeleteExportLine"]); + $this->markRequired("ProjectId"); + $this->markRequired("ResourceId"); + } + + + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId($projectId) + { + $this->set("ProjectId", $projectId); + } + + /** + * ResourceId: UReach资源ID + * + * @return string|null + */ + public function getResourceId() + { + return $this->get("ResourceId"); + } + + /** + * ResourceId: UReach资源ID + * + * @param string $resourceId + */ + public function setResourceId($resourceId) + { + $this->set("ResourceId", $resourceId); + } +} diff --git a/src/UWSC/Apis/DeleteExportLineResponse.php b/src/UWSC/Apis/DeleteExportLineResponse.php new file mode 100644 index 0000000..14c5245 --- /dev/null +++ b/src/UWSC/Apis/DeleteExportLineResponse.php @@ -0,0 +1,26 @@ + "DeleteExportLineRules"]); + $this->markRequired("ProjectId"); + $this->markRequired("ResourceId"); + $this->markRequired("RuleTypes"); + } + + + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId($projectId) + { + $this->set("ProjectId", $projectId); + } + + /** + * ResourceId: UReach资源ID + * + * @return string|null + */ + public function getResourceId() + { + return $this->get("ResourceId"); + } + + /** + * ResourceId: UReach资源ID + * + * @param string $resourceId + */ + public function setResourceId($resourceId) + { + $this->set("ResourceId", $resourceId); + } + + /** + * RuleTypes: 白名单类型:Developer、CrossBorder + * + * @return string[]|null + */ + public function getRuleTypes() + { + return $this->get("RuleTypes"); + } + + /** + * RuleTypes: 白名单类型:Developer、CrossBorder + * + * @param string[] $ruleTypes + */ + public function setRuleTypes(array $ruleTypes) + { + $this->set("RuleTypes", $ruleTypes); + } +} diff --git a/src/UWSC/Apis/DeleteExportLineRulesResponse.php b/src/UWSC/Apis/DeleteExportLineRulesResponse.php new file mode 100644 index 0000000..7d91d61 --- /dev/null +++ b/src/UWSC/Apis/DeleteExportLineRulesResponse.php @@ -0,0 +1,26 @@ + "DescribeCPE"]); + $this->markRequired("ProjectId"); + } + + + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId($projectId) + { + $this->set("ProjectId", $projectId); + } + + /** + * CPEId: cpe id + * + * @return string|null + */ + public function getCPEId() + { + return $this->get("CPEId"); + } + + /** + * CPEId: cpe id + * + * @param string $cpeId + */ + public function setCPEId($cpeId) + { + $this->set("CPEId", $cpeId); + } + + /** + * Label: 标签:Access、Network + * + * @return string|null + */ + public function getLabel() + { + return $this->get("Label"); + } + + /** + * Label: 标签:Access、Network + * + * @param string $label + */ + public function setLabel($label) + { + $this->set("Label", $label); + } +} diff --git a/src/UWSC/Apis/DescribeCPEResponse.php b/src/UWSC/Apis/DescribeCPEResponse.php new file mode 100644 index 0000000..f807565 --- /dev/null +++ b/src/UWSC/Apis/DescribeCPEResponse.php @@ -0,0 +1,57 @@ +get("CPEInfos"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new CPEInfo($item)); + } + return $result; + } + + /** + * CPEInfos: cpe 详情 + * + * @param CPEInfo[] $cpeInfos + */ + public function setCPEInfos(array $cpeInfos) + { + $result = []; + foreach ($cpeInfos as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } +} diff --git a/src/UWSC/Apis/DescribeExportLineRequest.php b/src/UWSC/Apis/DescribeExportLineRequest.php new file mode 100644 index 0000000..ca6281e --- /dev/null +++ b/src/UWSC/Apis/DescribeExportLineRequest.php @@ -0,0 +1,89 @@ + "DescribeExportLine"]); + } + + + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId($projectId) + { + $this->set("ProjectId", $projectId); + } + + /** + * CPEId: CPE资源ID + * + * @return string|null + */ + public function getCPEId() + { + return $this->get("CPEId"); + } + + /** + * CPEId: CPE资源ID + * + * @param string $cpeId + */ + public function setCPEId($cpeId) + { + $this->set("CPEId", $cpeId); + } + + /** + * ResourceId: UReach资源ID + * + * @return string|null + */ + public function getResourceId() + { + return $this->get("ResourceId"); + } + + /** + * ResourceId: UReach资源ID + * + * @param string $resourceId + */ + public function setResourceId($resourceId) + { + $this->set("ResourceId", $resourceId); + } +} diff --git a/src/UWSC/Apis/DescribeExportLineResponse.php b/src/UWSC/Apis/DescribeExportLineResponse.php new file mode 100644 index 0000000..e9bd224 --- /dev/null +++ b/src/UWSC/Apis/DescribeExportLineResponse.php @@ -0,0 +1,58 @@ +get("LineInfos"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new LineInfo($item)); + } + return $result; + } + + /** + * LineInfos: 线路信息 + * + * @param LineInfo[] $lineInfos + */ + public function setLineInfos(array $lineInfos) + { + $result = []; + foreach ($lineInfos as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } +} diff --git a/src/UWSC/Apis/DescribeExportLineRulesRequest.php b/src/UWSC/Apis/DescribeExportLineRulesRequest.php new file mode 100644 index 0000000..57af642 --- /dev/null +++ b/src/UWSC/Apis/DescribeExportLineRulesRequest.php @@ -0,0 +1,89 @@ + "DescribeExportLineRules"]); + } + + + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId($projectId) + { + $this->set("ProjectId", $projectId); + } + + /** + * ResourceId: UReach资源ID + * + * @return string|null + */ + public function getResourceId() + { + return $this->get("ResourceId"); + } + + /** + * ResourceId: UReach资源ID + * + * @param string $resourceId + */ + public function setResourceId($resourceId) + { + $this->set("ResourceId", $resourceId); + } + + /** + * RuleType: 白名单类型 + * + * @return string|null + */ + public function getRuleType() + { + return $this->get("RuleType"); + } + + /** + * RuleType: 白名单类型 + * + * @param string $ruleType + */ + public function setRuleType($ruleType) + { + $this->set("RuleType", $ruleType); + } +} diff --git a/src/UWSC/Apis/DescribeExportLineRulesResponse.php b/src/UWSC/Apis/DescribeExportLineRulesResponse.php new file mode 100644 index 0000000..a538900 --- /dev/null +++ b/src/UWSC/Apis/DescribeExportLineRulesResponse.php @@ -0,0 +1,57 @@ +get("WhiteListInfos"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new WhiteListInfo($item)); + } + return $result; + } + + /** + * WhiteListInfos: 白名单信息 + * + * @param WhiteListInfo[] $whiteListInfos + */ + public function setWhiteListInfos(array $whiteListInfos) + { + $result = []; + foreach ($whiteListInfos as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } +} diff --git a/src/UWSC/Apis/UpdateExportLineRequest.php b/src/UWSC/Apis/UpdateExportLineRequest.php new file mode 100644 index 0000000..4253c0c --- /dev/null +++ b/src/UWSC/Apis/UpdateExportLineRequest.php @@ -0,0 +1,92 @@ + "UpdateExportLine"]); + $this->markRequired("ProjectId"); + $this->markRequired("ResourceId"); + $this->markRequired("Bandwidth"); + } + + + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId($projectId) + { + $this->set("ProjectId", $projectId); + } + + /** + * ResourceId: UReach资源ID + * + * @return string|null + */ + public function getResourceId() + { + return $this->get("ResourceId"); + } + + /** + * ResourceId: UReach资源ID + * + * @param string $resourceId + */ + public function setResourceId($resourceId) + { + $this->set("ResourceId", $resourceId); + } + + /** + * Bandwidth: 带宽大小(仅自定义套餐支持修改) + * + * @return string|null + */ + public function getBandwidth() + { + return $this->get("Bandwidth"); + } + + /** + * Bandwidth: 带宽大小(仅自定义套餐支持修改) + * + * @param string $bandwidth + */ + public function setBandwidth($bandwidth) + { + $this->set("Bandwidth", $bandwidth); + } +} diff --git a/src/UWSC/Apis/UpdateExportLineResponse.php b/src/UWSC/Apis/UpdateExportLineResponse.php new file mode 100644 index 0000000..ecb0290 --- /dev/null +++ b/src/UWSC/Apis/UpdateExportLineResponse.php @@ -0,0 +1,26 @@ + "UpgradeExportLine"]); + $this->markRequired("ProjectId"); + $this->markRequired("ResourceId"); + $this->markRequired("PkgType"); + $this->markRequired("IpType"); + } + + + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId($projectId) + { + $this->set("ProjectId", $projectId); + } + + /** + * ResourceId: UReach资源ID + * + * @return string|null + */ + public function getResourceId() + { + return $this->get("ResourceId"); + } + + /** + * ResourceId: UReach资源ID + * + * @param string $resourceId + */ + public function setResourceId($resourceId) + { + $this->set("ResourceId", $resourceId); + } + + /** + * PkgType: 目标套餐类型:2M-Entry、5M-Basic、10M-Enterprise + * + * @return string|null + */ + public function getPkgType() + { + return $this->get("PkgType"); + } + + /** + * PkgType: 目标套餐类型:2M-Entry、5M-Basic、10M-Enterprise + * + * @param string $pkgType + */ + public function setPkgType($pkgType) + { + $this->set("PkgType", $pkgType); + } + + /** + * IpType: 原IP类型:International、BGP、Native、Resident + * + * @return string|null + */ + public function getIpType() + { + return $this->get("IpType"); + } + + /** + * IpType: 原IP类型:International、BGP、Native、Resident + * + * @param string $ipType + */ + public function setIpType($ipType) + { + $this->set("IpType", $ipType); + } + + /** + * Bandwidth: 带宽大小 + * + * @return integer|null + */ + public function getBandwidth() + { + return $this->get("Bandwidth"); + } + + /** + * Bandwidth: 带宽大小 + * + * @param int $bandwidth + */ + public function setBandwidth($bandwidth) + { + $this->set("Bandwidth", $bandwidth); + } + + /** + * ChargeType: 计费模式。枚举值为: Year,按年付费; Month,按月付费; Dynamic,按小时付费(需开启权限)。默认为月付 + * + * @return string|null + */ + public function getChargeType() + { + return $this->get("ChargeType"); + } + + /** + * ChargeType: 计费模式。枚举值为: Year,按年付费; Month,按月付费; Dynamic,按小时付费(需开启权限)。默认为月付 + * + * @param string $chargeType + */ + public function setChargeType($chargeType) + { + $this->set("ChargeType", $chargeType); + } + + /** + * Quantity: 购买时长。默认: 1。按小时购买(Dynamic)时无需此参数。 月付时,此参数传0,代表了购买至月末。 + * + * @return integer|null + */ + public function getQuantity() + { + return $this->get("Quantity"); + } + + /** + * Quantity: 购买时长。默认: 1。按小时购买(Dynamic)时无需此参数。 月付时,此参数传0,代表了购买至月末。 + * + * @param int $quantity + */ + public function setQuantity($quantity) + { + $this->set("Quantity", $quantity); + } + + /** + * CouponId: 代金券ID。请登录用户中心查看 + * + * @return integer|null + */ + public function getCouponId() + { + return $this->get("CouponId"); + } + + /** + * CouponId: 代金券ID。请登录用户中心查看 + * + * @param int $couponId + */ + public function setCouponId($couponId) + { + $this->set("CouponId", $couponId); + } +} diff --git a/src/UWSC/Apis/UpgradeExportLineResponse.php b/src/UWSC/Apis/UpgradeExportLineResponse.php new file mode 100644 index 0000000..b28d4e0 --- /dev/null +++ b/src/UWSC/Apis/UpgradeExportLineResponse.php @@ -0,0 +1,26 @@ +get("CPEId"); + } + + /** + * CPEId: 资源ID + * + * @param string $cpeId + */ + public function setCPEId($cpeId) + { + $this->set("CPEId", $cpeId); + } + + /** + * CPEName: 资源名称 + * + * @return string|null + */ + public function getCPEName() + { + return $this->get("CPEName"); + } + + /** + * CPEName: 资源名称 + * + * @param string $cpeName + */ + public function setCPEName($cpeName) + { + $this->set("CPEName", $cpeName); + } + + /** + * Remark: 备注 + * + * @return string|null + */ + public function getRemark() + { + return $this->get("Remark"); + } + + /** + * Remark: 备注 + * + * @param string $remark + */ + public function setRemark($remark) + { + $this->set("Remark", $remark); + } + + /** + * DeviceTypeName: 设备型号 + * + * @return string|null + */ + public function getDeviceTypeName() + { + return $this->get("DeviceTypeName"); + } + + /** + * DeviceTypeName: 设备型号 + * + * @param string $deviceTypeName + */ + public function setDeviceTypeName($deviceTypeName) + { + $this->set("DeviceTypeName", $deviceTypeName); + } + + /** + * Vendor: 供应商 + * + * @return string|null + */ + public function getVendor() + { + return $this->get("Vendor"); + } + + /** + * Vendor: 供应商 + * + * @param string $vendor + */ + public function setVendor($vendor) + { + $this->set("Vendor", $vendor); + } + + /** + * PopGwId: 绑定的UWAN资源ID + * + * @return string[]|null + */ + public function getPopGwId() + { + return $this->get("PopGwId"); + } + + /** + * PopGwId: 绑定的UWAN资源ID + * + * @param string[] $popGwId + */ + public function setPopGwId(array $popGwId) + { + $this->set("PopGwId", $popGwId); + } + + /** + * Sn: 设备SN + * + * @return string|null + */ + public function getSn() + { + return $this->get("Sn"); + } + + /** + * Sn: 设备SN + * + * @param string $sn + */ + public function setSn($sn) + { + $this->set("Sn", $sn); + } + + /** + * Status: 状态 + * + * @return integer|null + */ + public function getStatus() + { + return $this->get("Status"); + } + + /** + * Status: 状态 + * + * @param int $status + */ + public function setStatus($status) + { + $this->set("Status", $status); + } + + /** + * ConfUpdateTime: 配置更新时间 + * + * @return integer|null + */ + public function getConfUpdateTime() + { + return $this->get("ConfUpdateTime"); + } + + /** + * ConfUpdateTime: 配置更新时间 + * + * @param int $confUpdateTime + */ + public function setConfUpdateTime($confUpdateTime) + { + $this->set("ConfUpdateTime", $confUpdateTime); + } + + /** + * Ports: 端口 + * + * @return string[]|null + */ + public function getPorts() + { + return $this->get("Ports"); + } + + /** + * Ports: 端口 + * + * @param string[] $ports + */ + public function setPorts(array $ports) + { + $this->set("Ports", $ports); + } + + /** + * LinkNum: 链路数量 + * + * @return integer|null + */ + public function getLinkNum() + { + return $this->get("LinkNum"); + } + + /** + * LinkNum: 链路数量 + * + * @param int $linkNum + */ + public function setLinkNum($linkNum) + { + $this->set("LinkNum", $linkNum); + } + + /** + * CreateTime: 创建时间 + * + * @return integer|null + */ + public function getCreateTime() + { + return $this->get("CreateTime"); + } + + /** + * CreateTime: 创建时间 + * + * @param int $createTime + */ + public function setCreateTime($createTime) + { + $this->set("CreateTime", $createTime); + } + + /** + * LineStatus: 是否与线路绑定 + * + * @return string|null + */ + public function getLineStatus() + { + return $this->get("LineStatus"); + } + + /** + * LineStatus: 是否与线路绑定 + * + * @param string $lineStatus + */ + public function setLineStatus($lineStatus) + { + $this->set("LineStatus", $lineStatus); + } + + /** + * ResourceIds: 绑定的UReach线路资源ID + * + * @return string[]|null + */ + public function getResourceIds() + { + return $this->get("ResourceIds"); + } + + /** + * ResourceIds: 绑定的UReach线路资源ID + * + * @param string[] $resourceIds + */ + public function setResourceIds(array $resourceIds) + { + $this->set("ResourceIds", $resourceIds); + } + + /** + * UseTime: 有效使用时间(天) + * + * @return integer|null + */ + public function getUseTime() + { + return $this->get("UseTime"); + } + + /** + * UseTime: 有效使用时间(天) + * + * @param int $useTime + */ + public function setUseTime($useTime) + { + $this->set("UseTime", $useTime); + } +} diff --git a/src/UWSC/Models/LineInfo.php b/src/UWSC/Models/LineInfo.php new file mode 100644 index 0000000..fd03652 --- /dev/null +++ b/src/UWSC/Models/LineInfo.php @@ -0,0 +1,444 @@ +get("Name"); + } + + /** + * Name: 名称 + * + * @param string $name + */ + public function setName($name) + { + $this->set("Name", $name); + } + + /** + * Remark: 备注 + * + * @return string|null + */ + public function getRemark() + { + return $this->get("Remark"); + } + + /** + * Remark: 备注 + * + * @param string $remark + */ + public function setRemark($remark) + { + $this->set("Remark", $remark); + } + + /** + * ResourceId: 线路资源ID + * + * @return string|null + */ + public function getResourceId() + { + return $this->get("ResourceId"); + } + + /** + * ResourceId: 线路资源ID + * + * @param string $resourceId + */ + public function setResourceId($resourceId) + { + $this->set("ResourceId", $resourceId); + } + + /** + * InstanceId: 线路资源ID对应的加速线路ID + * + * @return string|null + */ + public function getInstanceId() + { + return $this->get("InstanceId"); + } + + /** + * InstanceId: 线路资源ID对应的加速线路ID + * + * @param string $instanceId + */ + public function setInstanceId($instanceId) + { + $this->set("InstanceId", $instanceId); + } + + /** + * Bandwidth: 带宽大小(Mbps) + * + * @return integer|null + */ + public function getBandwidth() + { + return $this->get("Bandwidth"); + } + + /** + * Bandwidth: 带宽大小(Mbps) + * + * @param int $bandwidth + */ + public function setBandwidth($bandwidth) + { + $this->set("Bandwidth", $bandwidth); + } + + /** + * ChargeType: 付费方式(按月、按年等) + * + * @return string|null + */ + public function getChargeType() + { + return $this->get("ChargeType"); + } + + /** + * ChargeType: 付费方式(按月、按年等) + * + * @param string $chargeType + */ + public function setChargeType($chargeType) + { + $this->set("ChargeType", $chargeType); + } + + /** + * PayMode: 计费方式(固定带宽: fixed-bw;流量计费:traffic) + * + * @return string|null + */ + public function getPayMode() + { + return $this->get("PayMode"); + } + + /** + * PayMode: 计费方式(固定带宽: fixed-bw;流量计费:traffic) + * + * @param string $payMode + */ + public function setPayMode($payMode) + { + $this->set("PayMode", $payMode); + } + + /** + * FromRegion: 入口地域 + * + * @return string|null + */ + public function getFromRegion() + { + return $this->get("FromRegion"); + } + + /** + * FromRegion: 入口地域 + * + * @param string $fromRegion + */ + public function setFromRegion($fromRegion) + { + $this->set("FromRegion", $fromRegion); + } + + /** + * FromRegionName: 入口地域名称 + * + * @return string|null + */ + public function getFromRegionName() + { + return $this->get("FromRegionName"); + } + + /** + * FromRegionName: 入口地域名称 + * + * @param string $fromRegionName + */ + public function setFromRegionName($fromRegionName) + { + $this->set("FromRegionName", $fromRegionName); + } + + /** + * ToRegion: 出口地域 + * + * @return string|null + */ + public function getToRegion() + { + return $this->get("ToRegion"); + } + + /** + * ToRegion: 出口地域 + * + * @param string $toRegion + */ + public function setToRegion($toRegion) + { + $this->set("ToRegion", $toRegion); + } + + /** + * ToRegionName: 出口地域名称 + * + * @return string|null + */ + public function getToRegionName() + { + return $this->get("ToRegionName"); + } + + /** + * ToRegionName: 出口地域名称 + * + * @param string $toRegionName + */ + public function setToRegionName($toRegionName) + { + $this->set("ToRegionName", $toRegionName); + } + + /** + * IP: + * + * @return string[]|null + */ + public function getIP() + { + return $this->get("IP"); + } + + /** + * IP: + * + * @param string[] $ip + */ + public function setIP(array $ip) + { + $this->set("IP", $ip); + } + + /** + * Status: 线路是否绑定CPE;"1":已绑定;"0"未绑定 + * + * @return string|null + */ + public function getStatus() + { + return $this->get("Status"); + } + + /** + * Status: 线路是否绑定CPE;"1":已绑定;"0"未绑定 + * + * @param string $status + */ + public function setStatus($status) + { + $this->set("Status", $status); + } + + /** + * CreateTime: 创建时间 + * + * @return integer|null + */ + public function getCreateTime() + { + return $this->get("CreateTime"); + } + + /** + * CreateTime: 创建时间 + * + * @param int $createTime + */ + public function setCreateTime($createTime) + { + $this->set("CreateTime", $createTime); + } + + /** + * ExpireTime: 到期时间 + * + * @return integer|null + */ + public function getExpireTime() + { + return $this->get("ExpireTime"); + } + + /** + * ExpireTime: 到期时间 + * + * @param int $expireTime + */ + public function setExpireTime($expireTime) + { + $this->set("ExpireTime", $expireTime); + } + + /** + * CPEIds: 线路绑定的CPE资源ID + * + * @return string[]|null + */ + public function getCPEIds() + { + return $this->get("CPEIds"); + } + + /** + * CPEIds: 线路绑定的CPE资源ID + * + * @param string[] $cpeIds + */ + public function setCPEIds(array $cpeIds) + { + $this->set("CPEIds", $cpeIds); + } + + /** + * PkgType: 套餐类型 + * + * @return string|null + */ + public function getPkgType() + { + return $this->get("PkgType"); + } + + /** + * PkgType: 套餐类型 + * + * @param string $pkgType + */ + public function setPkgType($pkgType) + { + $this->set("PkgType", $pkgType); + } + + /** + * IpType: IP类型 + * + * @return string|null + */ + public function getIpType() + { + return $this->get("IpType"); + } + + /** + * IpType: IP类型 + * + * @param string $ipType + */ + public function setIpType($ipType) + { + $this->set("IpType", $ipType); + } + + /** + * InstanceStatus: 是否过期(normal/expire) + * + * @return string|null + */ + public function getInstanceStatus() + { + return $this->get("InstanceStatus"); + } + + /** + * InstanceStatus: 是否过期(normal/expire) + * + * @param string $instanceStatus + */ + public function setInstanceStatus($instanceStatus) + { + $this->set("InstanceStatus", $instanceStatus); + } + + /** + * Socks: + * + * @return SocksInfo|null + */ + public function getSocks() + { + return new SocksInfo($this->get("Socks")); + } + + /** + * Socks: + * + * @param SocksInfo $socks + */ + public function setSocks(array $socks) + { + $this->set("Socks", $socks->getAll()); + } + + /** + * Source: 源IP地址 + * + * @return string[]|null + */ + public function getSource() + { + return $this->get("Source"); + } + + /** + * Source: 源IP地址 + * + * @param string[] $source + */ + public function setSource(array $source) + { + $this->set("Source", $source); + } +} diff --git a/src/UWSC/Models/SocksInfo.php b/src/UWSC/Models/SocksInfo.php new file mode 100644 index 0000000..f304228 --- /dev/null +++ b/src/UWSC/Models/SocksInfo.php @@ -0,0 +1,84 @@ +get("Addr"); + } + + /** + * Addr: + * + * @param string $addr + */ + public function setAddr($addr) + { + $this->set("Addr", $addr); + } + + /** + * Port: + * + * @return integer|null + */ + public function getPort() + { + return $this->get("Port"); + } + + /** + * Port: + * + * @param int $port + */ + public function setPort($port) + { + $this->set("Port", $port); + } + + /** + * Account: + * + * @return string|null + */ + public function getAccount() + { + return $this->get("Account"); + } + + /** + * Account: + * + * @param string $account + */ + public function setAccount($account) + { + $this->set("Account", $account); + } +} diff --git a/src/UWSC/Models/WhiteListInfo.php b/src/UWSC/Models/WhiteListInfo.php new file mode 100644 index 0000000..ca707d4 --- /dev/null +++ b/src/UWSC/Models/WhiteListInfo.php @@ -0,0 +1,84 @@ +get("RuleType"); + } + + /** + * RuleType: + * + * @param string $ruleType + */ + public function setRuleType($ruleType) + { + $this->set("RuleType", $ruleType); + } + + /** + * Name: + * + * @return string|null + */ + public function getName() + { + return $this->get("Name"); + } + + /** + * Name: + * + * @param string $name + */ + public function setName($name) + { + $this->set("Name", $name); + } + + /** + * Remark: + * + * @return string|null + */ + public function getRemark() + { + return $this->get("Remark"); + } + + /** + * Remark: + * + * @param string $remark + */ + public function setRemark($remark) + { + $this->set("Remark", $remark); + } +} diff --git a/src/UWSC/UWSCClient.php b/src/UWSC/UWSCClient.php new file mode 100644 index 0000000..3ecd33f --- /dev/null +++ b/src/UWSC/UWSCClient.php @@ -0,0 +1,422 @@ + (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * "ResourceId" => (string) UReach资源ID + * "RuleTypes" => (array) 白名单类型:Developer、CrossBorder + * ] + * + * Outputs: + * + * $outputs = [ + * ] + * + * @return AddExportLineRulesResponse + * @throws UCloudException + */ + public function addExportLineRules(AddExportLineRulesRequest $request = null) + { + $resp = $this->invoke($request); + return new AddExportLineRulesResponse($resp->toArray(), $resp->getRequestId()); + } + + /** + * BindCPE - 绑定 CPE + * + * See also: https://docs.ucloud.cn/api/uwsc-api/bind_cpe + * + * Arguments: + * + * $args = [ + * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * "CPEId" => (string) cpe id + * "Sn" => (string) sn id + * ] + * + * Outputs: + * + * $outputs = [ + * ] + * + * @return BindCPEResponse + * @throws UCloudException + */ + public function bindCPE(BindCPERequest $request = null) + { + $resp = $this->invoke($request); + return new BindCPEResponse($resp->toArray(), $resp->getRequestId()); + } + + /** + * CreateCPE - 创建 CPE + * + * See also: https://docs.ucloud.cn/api/uwsc-api/create_cpe + * + * Arguments: + * + * $args = [ + * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * "Name" => (string) cpe 名称 + * "Remark" => (string) cpe 备注 + * "DeviceType" => (string) 设备型号,枚举值: UCPE3600、UCPE3601 + * "Label" => (string) 标签:UReach智能网关:Access + * "UserInfo" => (string) 结构体,详见UserInfo模型 + * "Count" => (integer) 数量,默认为1 + * ] + * + * Outputs: + * + * $outputs = [ + * "CPEId" => (string) cpe id + * ] + * + * @return CreateCPEResponse + * @throws UCloudException + */ + public function createCPE(CreateCPERequest $request = null) + { + $resp = $this->invoke($request); + return new CreateCPEResponse($resp->toArray(), $resp->getRequestId()); + } + + /** + * CreateExportLine - 创建加速线路 + * + * See also: https://docs.ucloud.cn/api/uwsc-api/create_export_line + * + * Arguments: + * + * $args = [ + * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * "FromRegion" => (string) 本端地域 + * "ToRegion" => (string) 目标地域 + * "IpType" => (string) IP类型:International、BGP、Native、Resident + * "CPEId" => (string) CPE Id + * "PkgType" => (string) 套餐类型:2M-Entry、5M-Basic、10M-Enterprise + * "Bandwidth" => (integer) 带宽大小 + * "Name" => (string) 资源名称 + * "Tag" => (string) 业务组名称, 默认为 "Default" + * "ChargeType" => (string) 计费模式。枚举值为: Year,按年付费; Month,按月付费; Dynamic,按小时付费(需开启权限)。默认为月付 + * "Quantity" => (integer) 购买时长。默认: 1。按小时购买(Dynamic)时无需此参数。 月付时,此参数传0,代表了购买至月末。 + * "Remark" => (string) 备注 + * "PayMode" => (string) 计费类型:fixed-bw,固定带宽;traffic,流量计费 + * "CouponId" => (integer) 代金券ID。请登录用户中心查看 + * ] + * + * Outputs: + * + * $outputs = [ + * "ResourceId" => (string) 资源ID + * ] + * + * @return CreateExportLineResponse + * @throws UCloudException + */ + public function createExportLine(CreateExportLineRequest $request = null) + { + $resp = $this->invoke($request); + return new CreateExportLineResponse($resp->toArray(), $resp->getRequestId()); + } + + /** + * DeleteExportLine - 删除加速线路 + * + * See also: https://docs.ucloud.cn/api/uwsc-api/delete_export_line + * + * Arguments: + * + * $args = [ + * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * "ResourceId" => (string) UReach资源ID + * ] + * + * Outputs: + * + * $outputs = [ + * ] + * + * @return DeleteExportLineResponse + * @throws UCloudException + */ + public function deleteExportLine(DeleteExportLineRequest $request = null) + { + $resp = $this->invoke($request); + return new DeleteExportLineResponse($resp->toArray(), $resp->getRequestId()); + } + + /** + * DeleteExportLineRules - 删除加速规则 + * + * See also: https://docs.ucloud.cn/api/uwsc-api/delete_export_line_rules + * + * Arguments: + * + * $args = [ + * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * "ResourceId" => (string) UReach资源ID + * "RuleTypes" => (array) 白名单类型:Developer、CrossBorder + * ] + * + * Outputs: + * + * $outputs = [ + * ] + * + * @return DeleteExportLineRulesResponse + * @throws UCloudException + */ + public function deleteExportLineRules(DeleteExportLineRulesRequest $request = null) + { + $resp = $this->invoke($request); + return new DeleteExportLineRulesResponse($resp->toArray(), $resp->getRequestId()); + } + + /** + * DescribeCPE - 查询 CPE 信息 + * + * See also: https://docs.ucloud.cn/api/uwsc-api/describe_cpe + * + * Arguments: + * + * $args = [ + * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * "CPEId" => (string) cpe id + * "Label" => (string) 标签:Access、Network + * ] + * + * Outputs: + * + * $outputs = [ + * "CPEInfos" => (array) cpe 详情[ + * [ + * "CPEId" => (string) 资源ID + * "CPEName" => (string) 资源名称 + * "Remark" => (string) 备注 + * "DeviceTypeName" => (string) 设备型号 + * "Vendor" => (string) 供应商 + * "PopGwId" => (array) 绑定的UWAN资源ID + * "Sn" => (string) 设备SN + * "Status" => (integer) 状态 + * "ConfUpdateTime" => (integer) 配置更新时间 + * "Ports" => (array) 端口 + * "LinkNum" => (integer) 链路数量 + * "CreateTime" => (integer) 创建时间 + * "LineStatus" => (string) 是否与线路绑定 + * "ResourceIds" => (array) 绑定的UReach线路资源ID + * "UseTime" => (integer) 有效使用时间(天) + * ] + * ] + * ] + * + * @return DescribeCPEResponse + * @throws UCloudException + */ + public function describeCPE(DescribeCPERequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeCPEResponse($resp->toArray(), $resp->getRequestId()); + } + + /** + * DescribeExportLine - 查询CPE绑定的加速线路信息 + * + * See also: https://docs.ucloud.cn/api/uwsc-api/describe_export_line + * + * Arguments: + * + * $args = [ + * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * "CPEId" => (string) CPE资源ID + * "ResourceId" => (string) UReach资源ID + * ] + * + * Outputs: + * + * $outputs = [ + * "LineInfos" => (array) 线路信息[ + * [ + * "Name" => (string) 名称 + * "Remark" => (string) 备注 + * "ResourceId" => (string) 线路资源ID + * "InstanceId" => (string) 线路资源ID对应的加速线路ID + * "Bandwidth" => (integer) 带宽大小(Mbps) + * "ChargeType" => (string) 付费方式(按月、按年等) + * "PayMode" => (string) 计费方式(固定带宽: fixed-bw;流量计费:traffic) + * "FromRegion" => (string) 入口地域 + * "FromRegionName" => (string) 入口地域名称 + * "ToRegion" => (string) 出口地域 + * "ToRegionName" => (string) 出口地域名称 + * "IP" => (array) + * "Status" => (string) 线路是否绑定CPE;"1":已绑定;"0"未绑定 + * "CreateTime" => (integer) 创建时间 + * "ExpireTime" => (integer) 到期时间 + * "CPEIds" => (array) 线路绑定的CPE资源ID + * "PkgType" => (string) 套餐类型 + * "IpType" => (string) IP类型 + * "InstanceStatus" => (string) 是否过期(normal/expire) + * "Socks" => (object) [ + * "Addr" => (string) + * "Port" => (integer) + * "Account" => (string) + * ] + * "Source" => (array) 源IP地址 + * ] + * ] + * ] + * + * @return DescribeExportLineResponse + * @throws UCloudException + */ + public function describeExportLine(DescribeExportLineRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeExportLineResponse($resp->toArray(), $resp->getRequestId()); + } + + /** + * DescribeExportLineRules - 查询白名单 + * + * See also: https://docs.ucloud.cn/api/uwsc-api/describe_export_line_rules + * + * Arguments: + * + * $args = [ + * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * "ResourceId" => (string) UReach资源ID + * "RuleType" => (string) 白名单类型 + * ] + * + * Outputs: + * + * $outputs = [ + * "WhiteListInfos" => (array) 白名单信息[ + * [ + * "RuleType" => (string) + * "Name" => (string) + * "Remark" => (string) + * ] + * ] + * ] + * + * @return DescribeExportLineRulesResponse + * @throws UCloudException + */ + public function describeExportLineRules(DescribeExportLineRulesRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeExportLineRulesResponse($resp->toArray(), $resp->getRequestId()); + } + + /** + * UpdateExportLine - 修改加速线路 + * + * See also: https://docs.ucloud.cn/api/uwsc-api/update_export_line + * + * Arguments: + * + * $args = [ + * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * "ResourceId" => (string) UReach资源ID + * "Bandwidth" => (string) 带宽大小(仅自定义套餐支持修改) + * ] + * + * Outputs: + * + * $outputs = [ + * ] + * + * @return UpdateExportLineResponse + * @throws UCloudException + */ + public function updateExportLine(UpdateExportLineRequest $request = null) + { + $resp = $this->invoke($request); + return new UpdateExportLineResponse($resp->toArray(), $resp->getRequestId()); + } + + /** + * UpgradeExportLine - 升级加速线路 + * + * See also: https://docs.ucloud.cn/api/uwsc-api/upgrade_export_line + * + * Arguments: + * + * $args = [ + * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * "ResourceId" => (string) UReach资源ID + * "PkgType" => (string) 目标套餐类型:2M-Entry、5M-Basic、10M-Enterprise + * "IpType" => (string) 原IP类型:International、BGP、Native、Resident + * "Bandwidth" => (integer) 带宽大小 + * "ChargeType" => (string) 计费模式。枚举值为: Year,按年付费; Month,按月付费; Dynamic,按小时付费(需开启权限)。默认为月付 + * "Quantity" => (integer) 购买时长。默认: 1。按小时购买(Dynamic)时无需此参数。 月付时,此参数传0,代表了购买至月末。 + * "CouponId" => (integer) 代金券ID。请登录用户中心查看 + * ] + * + * Outputs: + * + * $outputs = [ + * ] + * + * @return UpgradeExportLineResponse + * @throws UCloudException + */ + public function upgradeExportLine(UpgradeExportLineRequest $request = null) + { + $resp = $this->invoke($request); + return new UpgradeExportLineResponse($resp->toArray(), $resp->getRequestId()); + } +}