Skip to content
Closed
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
222 changes: 222 additions & 0 deletions changelog.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,222 @@
SDK Auto Release

FEATURE:

- Add `ReleaseEIP`
- Add `CreateUDBSlave`
- Add `PromoteUDBSlave`
- Add `DetachUDisk`
- Add `GetUserInfo`
- Add `CreateUDBParamGroup`
- Add `TerminatePHost`
- Add `GetPHostPrice`
- Add `UploadUDBParamGroup`
- Add `GetUMemSpaceState`
- Add `GetSFWorkflowTemplate`
- Add `CreateProject`
- Add `GrantFirewall`
- Add `DescribeFirewallResource`
- Add `ModifyUMemSpaceName`
- Add `DescribeUDBBinlogBackupURL`
- Add `RestartUMemcacheGroup`
- Add `ModifyEIPBandwidth`
- Add `DeleteUDBParamGroup`
- Add `UpdateEIPAttribute`
- Add `ModifyUDPNBandwidth`
- Add `CreateUSMSTemplate`
- Add `DescribeBandwidthPackage`
- Add `ModifyEIPWeight`
- Add `DescribeUDBLogPackage`
- Add `CreateVServer`
- Add `DeleteUSMSSignature`
- Add `DescribeUDisk`
- Add `TerminateUHostInstance`
- Add `ModifyUDBInstancePassword`
- Add `CreateUMemcacheGroup`
- Add `StartUHostInstance`
- Add `CreateVPC`
- Add `CreateUHostInstance`
- Add `AssociateEIPWithShareBandwidth`
- Add `GetUDPNLineList`
- Add `PoweroffUHostInstance`
- Add `DeleteUDBLogPackage`
- Add `DescribeGlobalSSHInstance`
- Add `DescribePHost`
- Add `ResizeUDredisSpace`
- Add `BackupUDBInstanceBinlog`
- Add `DescribeUDBInstancePrice`
- Add `UnbindSSL`
- Add `AllocateUDPN`
- Add `AllocateBackendBatch`
- Add `DeleteFirewall`
- Add `DescribeVServer`
- Add `ResizeShareBandwidth`
- Add `RebootPHost`
- Add `CloneUDisk`
- Add `BackupUDBInstanceErrorLog`
- Add `DescribeUHostTags`
- Add `DeleteUSMSTemplate`
- Add `DeleteVPC`
- Add `DescribeULB`
- Add `DescribeUMemPrice`
- Add `CreateUSMSSignature`
- Add `DescribeVPC`
- Add `QueryUSMSTemplate`
- Add `SetUDiskUDataArkMode`
- Add `DescribeUDBInstanceBinlogBackupState`
- Add `GetUDPNUpgradePrice`
- Add `DeleteVPCIntercom`
- Add `ModifyGlobalSSHRemark`
- Add `DescribeEIP`
- Add `DeleteUDisk`
- Add `DescribeVPCIntercom`
- Add `UpdateFirewall`
- Add `StopUDBInstance`
- Add `DeleteULB`
- Add `DescribeUDBInstanceBinlog`
- Add `BindSSL`
- Add `DescribeURedisPrice`
- Add `DescribeUMemcachePrice`
- Add `GetUDPNPrice`
- Add `CreateUDiskSnapshot`
- Add `DescribeUDBParamGroup`
- Add `DescribeUDBBackup`
- Add `PoweroffPHost`
- Add `RebootUHostInstance`
- Add `CreateGlobalSSHInstance`
- Add `DescribeUDiskPrice`
- Add `ResizeUMemSpace`
- Add `DescribeUDiskUpgradePrice`
- Add `UpdateFirewallAttribute`
- Add `UpdateVPCNetwork`
- Add `GetUSMSSendReceipt`
- Add `UpdatePolicy`
- Add `DeleteGlobalSSHInstance`
- Add `ReinstallUHostInstance`
- Add `DescribeBandwidthUsage`
- Add `CreateUDBRouteInstance`
- Add `DescribeUDiskSnapshot`
- Add `CreateUDBReplicationInstance`
- Add `CheckUDBInstanceToHAAllowance`
- Add `DescribeUHostInstance`
- Add `DeleteUMemcacheGroup`
- Add `DescribeSubnetResource`
- Add `DescribeUDBInstanceBackupURL`
- Add `DescribeUMemUpgradePrice`
- Add `DeletePolicy`
- Add `UpdateUSMSSignature`
- Add `UpdateUDBParamGroup`
- Add `DescribeUMemcacheGroup`
- Add `CreateUDBInstance`
- Add `PromoteUDBInstanceToHA`
- Add `TerminateProject`
- Add `DeleteSSL`
- Add `CreatePHost`
- Add `UpdateUDBInstanceBackupStrategy`
- Add `SendUSMSMessage`
- Add `DeleteUDBBackup`
- Add `GetUHostUpgradePrice`
- Add `DeleteURedisGroup`
- Add `ResizeURedisGroup`
- Add `BindEIP`
- Add `StopUHostInstance`
- Add `DeleteBandwidthPackage`
- Add `UpdateUDBInstanceSlaveBackupSwitch`
- Add `EditUDBBackupBlacklist`
- Add `ResizeAttachedDisk`
- Add `StartPHost`
- Add `UpgradeToArkUHostInstance`
- Add `DescribeSSL`
- Add `DescribeFirewall`
- Add `AllocateVIP`
- Add `DescribeImage`
- Add `TerminateCustomImage`
- Add `AttachUDisk`
- Add `DisassociateEIPWithShareBandwidth`
- Add `DescribeUDBInstanceBackupState`
- Add `StartUDBInstance`
- Add `CreateURedisGroup`
- Add `CreateUDBInstanceByRecovery`
- Add `ImportCustomImage`
- Add `DescribeURedisBackup`
- Add `AllocateShareBandwidth`
- Add `DescribeUMemSpace`
- Add `SwitchUDBInstanceToHA`
- Add `ResetUHostInstancePassword`
- Add `CreateFirewall`
- Add `DescribeVIP`
- Add `ModifyURedisGroupName`
- Add `BackupUDBInstance`
- Add `DescribeShareBandwidth`
- Add `ModifyUHostInstanceRemark`
- Add `GetEIPUpgradePrice`
- Add `CopyCustomImage`
- Add `ReleaseUDPN`
- Add `DeleteUMemSpace`
- Add `DescribeUMemcacheUpgradePrice`
- Add `CreateUMemSpace`
- Add `UpdateBackendAttribute`
- Add `UpdateUSMSTemplate`
- Add `DeleteUDiskSnapshot`
- Add `CreatePolicy`
- Add `ResizeUDBInstance`
- Add `DeleteVServer`
- Add `RestoreUDisk`
- Add `ModifyUHostInstanceName`
- Add `UpdateVServerAttribute`
- Add `GetProjectList`
- Add `GetEIPPayMode`
- Add `ReinstallPHost`
- Add `DescribePHostTags`
- Add `ClearUDBLog`
- Add `ModifyUDBInstanceName`
- Add `DescribeSubnet`
- Add `CreateVPCIntercom`
- Add `AllocateEIP`
- Add `GetUHostInstancePrice`
- Add `DescribeGlobalSSHArea`
- Add `ResizeUDisk`
- Add `CloneUDiskSnapshot`
- Add `SetEIPPayMode`
- Add `DeleteUDBInstance`
- Add `DescribeUDBBackupBlacklist`
- Add `DescribeUDBInstanceState`
- Add `CreateSubnet`
- Add `CreateSFWorkflowFromTemplate`
- Add `FetchUDBInstanceEarliestRecoverTime`
- Add `CheckRecoverUDBInstance`
- Add `QueryUSMSSignature`
- Add `DescribeURedisBackupURL`
- Add `UnBindEIP`
- Add `CreateULB`
- Add `DescribeUDPN`
- Add `DescribeURedisGroup`
- Add `DeleteSubnet`
- Add `ReleaseShareBandwidth`
- Add `DescribeUDBInstanceUpgradePrice`
- Add `GetEIPPrice`
- Add `ReleaseBackend`
- Add `ModifyPHostInfo`
- Add `ModifyUHostInstanceTag`
- Add `GetUHostInstanceVncInfo`
- Add `ReleaseVIP`
- Add `RenameUDisk`
- Add `CreateBandwidthPackage`
- Add `ResizeUHostInstance`
- Add `CreateCustomImage`
- Add `ModifyGlobalSSHPort`
- Add `DescribeUDBType`
- Add `UpdateULBAttribute`
- Add `DescribeUDBLogBackupURL`
- Add `CreateUDisk`
- Add `UpdateSubnetAttribute`
- Add `DescribeUDBInstance`
- Add `AddVPCNetwork`
- Add `RestartUDBInstance`
- Add `DescribeURedisUpgradePrice`
- Add `AllocateBackend`
- Add `DescribePHostImage`
- Add `CreateSSL`



6 changes: 6 additions & 0 deletions docs/services.rst
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,12 @@ UPHost
.. autoclass:: ucloud.services.uphost.client.UPHostClient
:members:

USMS
----

.. autoclass:: ucloud.services.usms.client.USMSClient
:members:

VPC
---

Expand Down
1 change: 1 addition & 0 deletions model/artifact.json

Large diffs are not rendered by default.

22 changes: 22 additions & 0 deletions model/changelog.tpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
SDK 自动发布

{{- define "name" }}
{{- if (eq .ChangeLevel "api") }}`{{ .Api }}`
{{- else if (eq .ChangeLevel "model") }}model `{{ .Model }}` at `{{ .Api }}`
{{- else if (eq .ChangeLevel "field") }}field `{{ .Field }}` at `{{ .Api }}`
{{- end }}
{{- end }}

FEATURE:
{{ range $changelog := . }}
{{- if and (ne .ChangeLevel "field") }}
- {{ .ChangeType | title }} {{ template "name" . -}}
{{- end -}}
{{ end }}

ENHANCEMENT:
{{ range $changelog := . }}
{{- if (eq .ChangeLevel "field") }}
- {{ if .IsCritical }}(**BREAK CHANGE**) {{ end }}{{ .ChangeType | title }} {{ template "name" . -}}
{{- end -}}
{{ end }}
17 changes: 17 additions & 0 deletions model/gen-apis.tpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#!/usr/bin/env bash

# Code is generated by ucloud-model, DO NOT EDIT IT.

ucloud-model sdk apis --lang python3 --type public --template ${U_MODEL_HOME}/providers/python/templates/clients.tpl --output ./ucloud/client.py
ucloud-model sdk apis --lang python3 --type public --template ${U_MODEL_HOME}/providers/python/templates/docs.tpl --output ./docs/services.rst

{{ range $index, $product := (.GetAll | extractUnique "Product") }}
mkdir -p ./ucloud/services/{{ . | lower }}/schemas
touch ./ucloud/services/{{ . | lower }}/__init__.py
touch ./ucloud/services/{{ . | lower }}/schemas/__init__.py
ucloud-model sdk apis --lang python3 --product {{ . }} --type public --template ${U_MODEL_HOME}/providers/python/templates/schema.tpl --output ./ucloud/services/{{ . | lower }}/schemas/apis.py
ucloud-model sdk apis --lang python3 --product {{ . }} --type public --template ${U_MODEL_HOME}/providers/python/templates/model.tpl --output ./ucloud/services/{{ . | lower }}/schemas/models.py
ucloud-model sdk apis --lang python3 --product {{ . }} --type public --template ${U_MODEL_HOME}/providers/python/templates/client.tpl --output ./ucloud/services/{{ . | lower }}/client.py
black ucloud/services/{{ . | lower }}
python -m ucloud.services.{{ . | lower }}.client
{{ end }}
13 changes: 13 additions & 0 deletions model/gen-tests.tpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#!/usr/bin/env bash

# Code is generated by ucloud-model, DO NOT EDIT IT.

{{ range $index, $test := .GetAll }}
ucloud-model sdk test \
--lang python3 \
--template ${U_MODEL_HOME}/providers/python/templates/testing.tpl \
--output tests/test_services/test_set_{{ $test.ID }}.py \
--name {{ $test.ID }}
{{ end }}

black tests/test_services/*
4 changes: 4 additions & 0 deletions model/regression.tpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/usr/bin/env bash

# Code is generated by ucloud-model, DO NOT EDIT IT.
pytest
99 changes: 99 additions & 0 deletions scripts/gen-apis.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,99 @@
#!/usr/bin/env bash

# Code is generated by ucloud-model, DO NOT EDIT IT.

ucloud-model sdk apis --lang python3 --type public --template ${U_MODEL_HOME}/providers/python/templates/clients.tpl --output ./ucloud/client.py
ucloud-model sdk apis --lang python3 --type public --template ${U_MODEL_HOME}/providers/python/templates/docs.tpl --output ./docs/services.rst


mkdir -p ./ucloud/services/pathx/schemas
touch ./ucloud/services/pathx/__init__.py
touch ./ucloud/services/pathx/schemas/__init__.py
ucloud-model sdk apis --lang python3 --product PathX --type public --template ${U_MODEL_HOME}/providers/python/templates/schema.tpl --output ./ucloud/services/pathx/schemas/apis.py
ucloud-model sdk apis --lang python3 --product PathX --type public --template ${U_MODEL_HOME}/providers/python/templates/model.tpl --output ./ucloud/services/pathx/schemas/models.py
ucloud-model sdk apis --lang python3 --product PathX --type public --template ${U_MODEL_HOME}/providers/python/templates/client.tpl --output ./ucloud/services/pathx/client.py

mkdir -p ./ucloud/services/stepflow/schemas
touch ./ucloud/services/stepflow/__init__.py
touch ./ucloud/services/stepflow/schemas/__init__.py
ucloud-model sdk apis --lang python3 --product StepFlow --type public --template ${U_MODEL_HOME}/providers/python/templates/schema.tpl --output ./ucloud/services/stepflow/schemas/apis.py
ucloud-model sdk apis --lang python3 --product StepFlow --type public --template ${U_MODEL_HOME}/providers/python/templates/model.tpl --output ./ucloud/services/stepflow/schemas/models.py
ucloud-model sdk apis --lang python3 --product StepFlow --type public --template ${U_MODEL_HOME}/providers/python/templates/client.tpl --output ./ucloud/services/stepflow/client.py

mkdir -p ./ucloud/services/uaccount/schemas
touch ./ucloud/services/uaccount/__init__.py
touch ./ucloud/services/uaccount/schemas/__init__.py
ucloud-model sdk apis --lang python3 --product UAccount --type public --template ${U_MODEL_HOME}/providers/python/templates/schema.tpl --output ./ucloud/services/uaccount/schemas/apis.py
ucloud-model sdk apis --lang python3 --product UAccount --type public --template ${U_MODEL_HOME}/providers/python/templates/model.tpl --output ./ucloud/services/uaccount/schemas/models.py
ucloud-model sdk apis --lang python3 --product UAccount --type public --template ${U_MODEL_HOME}/providers/python/templates/client.tpl --output ./ucloud/services/uaccount/client.py

mkdir -p ./ucloud/services/udb/schemas
touch ./ucloud/services/udb/__init__.py
touch ./ucloud/services/udb/schemas/__init__.py
ucloud-model sdk apis --lang python3 --product UDB --type public --template ${U_MODEL_HOME}/providers/python/templates/schema.tpl --output ./ucloud/services/udb/schemas/apis.py
ucloud-model sdk apis --lang python3 --product UDB --type public --template ${U_MODEL_HOME}/providers/python/templates/model.tpl --output ./ucloud/services/udb/schemas/models.py
ucloud-model sdk apis --lang python3 --product UDB --type public --template ${U_MODEL_HOME}/providers/python/templates/client.tpl --output ./ucloud/services/udb/client.py

mkdir -p ./ucloud/services/udpn/schemas
touch ./ucloud/services/udpn/__init__.py
touch ./ucloud/services/udpn/schemas/__init__.py
ucloud-model sdk apis --lang python3 --product UDPN --type public --template ${U_MODEL_HOME}/providers/python/templates/schema.tpl --output ./ucloud/services/udpn/schemas/apis.py
ucloud-model sdk apis --lang python3 --product UDPN --type public --template ${U_MODEL_HOME}/providers/python/templates/model.tpl --output ./ucloud/services/udpn/schemas/models.py
ucloud-model sdk apis --lang python3 --product UDPN --type public --template ${U_MODEL_HOME}/providers/python/templates/client.tpl --output ./ucloud/services/udpn/client.py

mkdir -p ./ucloud/services/udisk/schemas
touch ./ucloud/services/udisk/__init__.py
touch ./ucloud/services/udisk/schemas/__init__.py
ucloud-model sdk apis --lang python3 --product UDisk --type public --template ${U_MODEL_HOME}/providers/python/templates/schema.tpl --output ./ucloud/services/udisk/schemas/apis.py
ucloud-model sdk apis --lang python3 --product UDisk --type public --template ${U_MODEL_HOME}/providers/python/templates/model.tpl --output ./ucloud/services/udisk/schemas/models.py
ucloud-model sdk apis --lang python3 --product UDisk --type public --template ${U_MODEL_HOME}/providers/python/templates/client.tpl --output ./ucloud/services/udisk/client.py

mkdir -p ./ucloud/services/uhost/schemas
touch ./ucloud/services/uhost/__init__.py
touch ./ucloud/services/uhost/schemas/__init__.py
ucloud-model sdk apis --lang python3 --product UHost --type public --template ${U_MODEL_HOME}/providers/python/templates/schema.tpl --output ./ucloud/services/uhost/schemas/apis.py
ucloud-model sdk apis --lang python3 --product UHost --type public --template ${U_MODEL_HOME}/providers/python/templates/model.tpl --output ./ucloud/services/uhost/schemas/models.py
ucloud-model sdk apis --lang python3 --product UHost --type public --template ${U_MODEL_HOME}/providers/python/templates/client.tpl --output ./ucloud/services/uhost/client.py

mkdir -p ./ucloud/services/ulb/schemas
touch ./ucloud/services/ulb/__init__.py
touch ./ucloud/services/ulb/schemas/__init__.py
ucloud-model sdk apis --lang python3 --product ULB --type public --template ${U_MODEL_HOME}/providers/python/templates/schema.tpl --output ./ucloud/services/ulb/schemas/apis.py
ucloud-model sdk apis --lang python3 --product ULB --type public --template ${U_MODEL_HOME}/providers/python/templates/model.tpl --output ./ucloud/services/ulb/schemas/models.py
ucloud-model sdk apis --lang python3 --product ULB --type public --template ${U_MODEL_HOME}/providers/python/templates/client.tpl --output ./ucloud/services/ulb/client.py

mkdir -p ./ucloud/services/umem/schemas
touch ./ucloud/services/umem/__init__.py
touch ./ucloud/services/umem/schemas/__init__.py
ucloud-model sdk apis --lang python3 --product UMem --type public --template ${U_MODEL_HOME}/providers/python/templates/schema.tpl --output ./ucloud/services/umem/schemas/apis.py
ucloud-model sdk apis --lang python3 --product UMem --type public --template ${U_MODEL_HOME}/providers/python/templates/model.tpl --output ./ucloud/services/umem/schemas/models.py
ucloud-model sdk apis --lang python3 --product UMem --type public --template ${U_MODEL_HOME}/providers/python/templates/client.tpl --output ./ucloud/services/umem/client.py

mkdir -p ./ucloud/services/unet/schemas
touch ./ucloud/services/unet/__init__.py
touch ./ucloud/services/unet/schemas/__init__.py
ucloud-model sdk apis --lang python3 --product UNet --type public --template ${U_MODEL_HOME}/providers/python/templates/schema.tpl --output ./ucloud/services/unet/schemas/apis.py
ucloud-model sdk apis --lang python3 --product UNet --type public --template ${U_MODEL_HOME}/providers/python/templates/model.tpl --output ./ucloud/services/unet/schemas/models.py
ucloud-model sdk apis --lang python3 --product UNet --type public --template ${U_MODEL_HOME}/providers/python/templates/client.tpl --output ./ucloud/services/unet/client.py

mkdir -p ./ucloud/services/uphost/schemas
touch ./ucloud/services/uphost/__init__.py
touch ./ucloud/services/uphost/schemas/__init__.py
ucloud-model sdk apis --lang python3 --product UPHost --type public --template ${U_MODEL_HOME}/providers/python/templates/schema.tpl --output ./ucloud/services/uphost/schemas/apis.py
ucloud-model sdk apis --lang python3 --product UPHost --type public --template ${U_MODEL_HOME}/providers/python/templates/model.tpl --output ./ucloud/services/uphost/schemas/models.py
ucloud-model sdk apis --lang python3 --product UPHost --type public --template ${U_MODEL_HOME}/providers/python/templates/client.tpl --output ./ucloud/services/uphost/client.py

mkdir -p ./ucloud/services/usms/schemas
touch ./ucloud/services/usms/__init__.py
touch ./ucloud/services/usms/schemas/__init__.py
ucloud-model sdk apis --lang python3 --product USMS --type public --template ${U_MODEL_HOME}/providers/python/templates/schema.tpl --output ./ucloud/services/usms/schemas/apis.py
ucloud-model sdk apis --lang python3 --product USMS --type public --template ${U_MODEL_HOME}/providers/python/templates/model.tpl --output ./ucloud/services/usms/schemas/models.py
ucloud-model sdk apis --lang python3 --product USMS --type public --template ${U_MODEL_HOME}/providers/python/templates/client.tpl --output ./ucloud/services/usms/client.py

mkdir -p ./ucloud/services/vpc/schemas
touch ./ucloud/services/vpc/__init__.py
touch ./ucloud/services/vpc/schemas/__init__.py
ucloud-model sdk apis --lang python3 --product VPC --type public --template ${U_MODEL_HOME}/providers/python/templates/schema.tpl --output ./ucloud/services/vpc/schemas/apis.py
ucloud-model sdk apis --lang python3 --product VPC --type public --template ${U_MODEL_HOME}/providers/python/templates/model.tpl --output ./ucloud/services/vpc/schemas/models.py
ucloud-model sdk apis --lang python3 --product VPC --type public --template ${U_MODEL_HOME}/providers/python/templates/client.tpl --output ./ucloud/services/vpc/client.py

Loading