Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions docs/services.rst
Original file line number Diff line number Diff line change
Expand Up @@ -296,3 +296,10 @@ VPC
.. autoclass:: ucloud.services.vpc.client.VPCClient
:members:


ipv6gw
------

.. autoclass:: ucloud.services.ipv6gw.client.ipv6gwClient
:members:

10 changes: 10 additions & 0 deletions ucloud/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -432,6 +432,16 @@ def uvms(self):
self.logger,
)

def ipv6gw(self):
from ucloud.services.ipv6gw.client import ipv6gwClient

return ipv6gwClient(
self._auto_config("ipv6gw"),
self.transport,
self.middleware,
self.logger,
)

def vpc(self):
from ucloud.services.vpc.client import VPCClient

Expand Down
Empty file.
44 changes: 44 additions & 0 deletions ucloud/services/ipv6gw/client.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
""" Code is generated by ucloud-model, DO NOT EDIT IT. """

import typing


from ucloud.core.client import Client
from ucloud.services.ipv6gw.schemas import apis


class ipv6gwClient(Client):

Check warning on line 10 in ucloud/services/ipv6gw/client.py

View check run for this annotation

SonarQubeCloud / SonarCloud Code Analysis

Rename class "ipv6gwClient" to match the regular expression ^_?([A-Z_][a-zA-Z0-9]*|[a-z_][a-z0-9_]*)$.

See more on https://sonarcloud.io/project/issues?id=ucloud_ucloud-sdk-python3&issues=AZsRf9byBXTnw1nu6oM2&open=AZsRf9byBXTnw1nu6oM2&pullRequest=292
def __init__(
self, config: dict, transport=None, middleware=None, logger=None
):
super(ipv6gwClient, self).__init__(
config, transport, middleware, logger
)

def modify_ipv_6internet_bandwidth(
self, req: typing.Optional[dict] = None, **kwargs
) -> dict:
"""ModifyIpv6InternetBandwidth - 修改ipv6公网带宽值

**Request**

- **ProjectId** (str) - (Config) 项目ID。不填写为默认项目,子帐号必须填写。 请参考 `GetProjectList接口 <https://docs.ucloud.cn/api/summary/get_project_list>`_
- **Region** (str) - (Config) 地域。 参见 `地域和可用区列表 <https://docs.ucloud.cn/api/summary/regionlist>`_
- **Bandwidth** (int) - 要修改为的出向带宽峰值。带宽值范围[1, 2000]
- **InternetBandwidthId** (str) - ipv6公网带宽Id;与Ipv6AddressId二选一必填
- **Ipv6AddressId** (str) - Ipv6地址 id;与InternetBandwidthId二选一必填

**Response**


"""
# build request
d = {
"ProjectId": self.config.project_id,
"Region": self.config.region,
}
req and d.update(req)
d = apis.ModifyIpv6InternetBandwidthRequestSchema().dumps(d)

resp = self.invoke("ModifyIpv6InternetBandwidth", d, **kwargs)
return apis.ModifyIpv6InternetBandwidthResponseSchema().loads(resp)
Empty file.
34 changes: 34 additions & 0 deletions ucloud/services/ipv6gw/schemas/apis.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
""" Code is generated by ucloud-model, DO NOT EDIT IT. """

from ucloud.core.typesystem import schema, fields
from ucloud.services.ipv6gw.schemas import models

""" ipv6gw API Schema
"""


"""
API: ModifyIpv6InternetBandwidth

修改ipv6公网带宽值
"""

Check warning on line 14 in ucloud/services/ipv6gw/schemas/apis.py

View check run for this annotation

SonarQubeCloud / SonarCloud Code Analysis

Remove this commented out code.

See more on https://sonarcloud.io/project/issues?id=ucloud_ucloud-sdk-python3&issues=AZsRf9dnBXTnw1nu6oM3&open=AZsRf9dnBXTnw1nu6oM3&pullRequest=292


class ModifyIpv6InternetBandwidthRequestSchema(schema.RequestSchema):
"""ModifyIpv6InternetBandwidth - 修改ipv6公网带宽值"""

fields = {
"Bandwidth": fields.Int(required=False, dump_to="Bandwidth"),
"InternetBandwidthId": fields.Str(
required=False, dump_to="InternetBandwidthId"
),
"Ipv6AddressId": fields.Str(required=False, dump_to="Ipv6AddressId"),
"ProjectId": fields.Str(required=True, dump_to="ProjectId"),
"Region": fields.Str(required=True, dump_to="Region"),
}


class ModifyIpv6InternetBandwidthResponseSchema(schema.ResponseSchema):
"""ModifyIpv6InternetBandwidth - 修改ipv6公网带宽值"""

fields = {}
3 changes: 3 additions & 0 deletions ucloud/services/ipv6gw/schemas/models.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
""" Code is generated by ucloud-model, DO NOT EDIT IT. """

from ucloud.core.typesystem import schema, fields
2 changes: 1 addition & 1 deletion ucloud/version.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
version = "0.11.79"
version = "0.11.80"