tencentcloud-sdk-python-tokenhub 3.1.205__py2.py3-none-any.whl → 3.1.214__py2.py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- tencentcloud/__init__.py +1 -1
- tencentcloud/tokenhub/v20260322/models.py +567 -96
- tencentcloud/tokenhub/v20260322/tokenhub_client.py +26 -3
- tencentcloud/tokenhub/v20260322/tokenhub_client_async.py +21 -3
- {tencentcloud_sdk_python_tokenhub-3.1.205.dist-info → tencentcloud_sdk_python_tokenhub-3.1.214.dist-info}/METADATA +2 -2
- tencentcloud_sdk_python_tokenhub-3.1.214.dist-info/RECORD +11 -0
- tencentcloud_sdk_python_tokenhub-3.1.205.dist-info/RECORD +0 -11
- {tencentcloud_sdk_python_tokenhub-3.1.205.dist-info → tencentcloud_sdk_python_tokenhub-3.1.214.dist-info}/WHEEL +0 -0
- {tencentcloud_sdk_python_tokenhub-3.1.205.dist-info → tencentcloud_sdk_python_tokenhub-3.1.214.dist-info}/top_level.txt +0 -0
tencentcloud/__init__.py
CHANGED
|
@@ -1147,24 +1147,24 @@ class CreateTokenPlanApiKeysRequest(AbstractModel):
|
|
|
1147
1147
|
|
|
1148
1148
|
def __init__(self):
|
|
1149
1149
|
r"""
|
|
1150
|
-
:param _TeamId:
|
|
1150
|
+
:param _TeamId: <p>套餐 ID。可通过DescribeTokenPlanList接口获取。</p>
|
|
1151
1151
|
:type TeamId: str
|
|
1152
|
-
:param _ApiKeyName: API Key 名称,最大 128 字符。如果创建 API Key 的数量超过1个,实际名称格式为 {ApiKeyName}-{序号}(如 mykey-1, mykey-2
|
|
1152
|
+
:param _ApiKeyName: <p>API Key 名称,最大 128 字符。如果创建 API Key 的数量超过1个,实际名称格式为 {ApiKeyName}-{序号}(如 mykey-1, mykey-2)。</p>
|
|
1153
1153
|
:type ApiKeyName: str
|
|
1154
|
-
:param _Count:
|
|
1154
|
+
:param _Count: <p>创建数量。取值范围:1 ~ 10。</p>
|
|
1155
1155
|
:type Count: int
|
|
1156
|
-
:param _AllowedModels:
|
|
1156
|
+
:param _AllowedModels: <p>可用模型列表。如果套餐类型为企业版专业套餐,该字段必传!可以指定模型,也可以传入“all”,传入 “all“表示可以使用套餐支持的所有模型,如果要指定具体模型,传入 Model ID,“all“和具体的 Model ID 不能同时传入。如果套餐类型为企业版轻享套餐,则无论是否传入该字段,以及该字段传入什么值,都会被强制覆盖为["auto"]。</p>
|
|
1157
1157
|
:type AllowedModels: list of str
|
|
1158
|
-
:param _ExclusiveQuota:
|
|
1159
|
-
- 套餐类型为专业,单位取值为积分;
|
|
1160
|
-
- 套餐类型为轻享套餐,单位取值为 token。
|
|
1158
|
+
:param _ExclusiveQuota: <p>独占额度。不传则为0,代表该 API Key 不被分配任何独占配额。单位说明如下:</p><ul><li>套餐类型为专业,单位取值为积分;</li><li>套餐类型为轻享套餐,单位取值为 token。</li></ul>
|
|
1161
1159
|
:type ExclusiveQuota: int
|
|
1162
|
-
:param _TotalQuota:
|
|
1163
|
-
- 套餐类型为专业,单位取值为积分;
|
|
1164
|
-
- 套餐类型为轻享套餐,单位取值为 token。
|
|
1160
|
+
:param _TotalQuota: <p>总额度上限。-1 表示不限,必须为 -1 或 >= API Key 当前的 ExclusiveQuota(独占额度)。不传表示不设置上限。单位说明如下:</p><ul><li>套餐类型为专业,单位取值为积分;</li><li>套餐类型为轻享套餐,单位取值为 token。</li></ul>
|
|
1165
1161
|
:type TotalQuota: int
|
|
1166
|
-
:param _TPM: TPM(Tokens Per Minute)限制。不传使用套餐级别 TPM。必须
|
|
1162
|
+
:param _TPM: <p>TPM(Tokens Per Minute)限制。不传使用套餐级别 TPM。必须 >= 0 且 <= 套餐 TPM。</p>
|
|
1167
1163
|
:type TPM: int
|
|
1164
|
+
:param _IpWhitelist: <p>IP 白名单列表。支持 IPv4 单地址(如 1.2.3.4)和 IPv4 CIDR(如 10.0.0.0/24)格式。最多 50 个条目,不允许重复;不支持 IPv6 与 IP 范围。不传或传空数组表示不限制。批量创建时所有 APIKey 共用同一份白名单。</p>
|
|
1165
|
+
:type IpWhitelist: list of str
|
|
1166
|
+
:param _OverageEnabled: <p>是否开启超额按量计费。默认值为 false。开启后,若 APIKey 用量达到总额度上限,并且使用的模型已开启按量计费,将自动切换至按量计费模式,该部分将按所用模型的按量计费定价额外计费;未开启时用量达上限后调用报错。</p>
|
|
1167
|
+
:type OverageEnabled: bool
|
|
1168
1168
|
"""
|
|
1169
1169
|
self._TeamId = None
|
|
1170
1170
|
self._ApiKeyName = None
|
|
@@ -1173,10 +1173,12 @@ class CreateTokenPlanApiKeysRequest(AbstractModel):
|
|
|
1173
1173
|
self._ExclusiveQuota = None
|
|
1174
1174
|
self._TotalQuota = None
|
|
1175
1175
|
self._TPM = None
|
|
1176
|
+
self._IpWhitelist = None
|
|
1177
|
+
self._OverageEnabled = None
|
|
1176
1178
|
|
|
1177
1179
|
@property
|
|
1178
1180
|
def TeamId(self):
|
|
1179
|
-
r"""
|
|
1181
|
+
r"""<p>套餐 ID。可通过DescribeTokenPlanList接口获取。</p>
|
|
1180
1182
|
:rtype: str
|
|
1181
1183
|
"""
|
|
1182
1184
|
return self._TeamId
|
|
@@ -1187,7 +1189,7 @@ class CreateTokenPlanApiKeysRequest(AbstractModel):
|
|
|
1187
1189
|
|
|
1188
1190
|
@property
|
|
1189
1191
|
def ApiKeyName(self):
|
|
1190
|
-
r"""API Key 名称,最大 128 字符。如果创建 API Key 的数量超过1个,实际名称格式为 {ApiKeyName}-{序号}(如 mykey-1, mykey-2
|
|
1192
|
+
r"""<p>API Key 名称,最大 128 字符。如果创建 API Key 的数量超过1个,实际名称格式为 {ApiKeyName}-{序号}(如 mykey-1, mykey-2)。</p>
|
|
1191
1193
|
:rtype: str
|
|
1192
1194
|
"""
|
|
1193
1195
|
return self._ApiKeyName
|
|
@@ -1198,7 +1200,7 @@ class CreateTokenPlanApiKeysRequest(AbstractModel):
|
|
|
1198
1200
|
|
|
1199
1201
|
@property
|
|
1200
1202
|
def Count(self):
|
|
1201
|
-
r"""
|
|
1203
|
+
r"""<p>创建数量。取值范围:1 ~ 10。</p>
|
|
1202
1204
|
:rtype: int
|
|
1203
1205
|
"""
|
|
1204
1206
|
return self._Count
|
|
@@ -1209,7 +1211,7 @@ class CreateTokenPlanApiKeysRequest(AbstractModel):
|
|
|
1209
1211
|
|
|
1210
1212
|
@property
|
|
1211
1213
|
def AllowedModels(self):
|
|
1212
|
-
r"""
|
|
1214
|
+
r"""<p>可用模型列表。如果套餐类型为企业版专业套餐,该字段必传!可以指定模型,也可以传入“all”,传入 “all“表示可以使用套餐支持的所有模型,如果要指定具体模型,传入 Model ID,“all“和具体的 Model ID 不能同时传入。如果套餐类型为企业版轻享套餐,则无论是否传入该字段,以及该字段传入什么值,都会被强制覆盖为["auto"]。</p>
|
|
1213
1215
|
:rtype: list of str
|
|
1214
1216
|
"""
|
|
1215
1217
|
return self._AllowedModels
|
|
@@ -1220,9 +1222,7 @@ class CreateTokenPlanApiKeysRequest(AbstractModel):
|
|
|
1220
1222
|
|
|
1221
1223
|
@property
|
|
1222
1224
|
def ExclusiveQuota(self):
|
|
1223
|
-
r"""
|
|
1224
|
-
- 套餐类型为专业,单位取值为积分;
|
|
1225
|
-
- 套餐类型为轻享套餐,单位取值为 token。
|
|
1225
|
+
r"""<p>独占额度。不传则为0,代表该 API Key 不被分配任何独占配额。单位说明如下:</p><ul><li>套餐类型为专业,单位取值为积分;</li><li>套餐类型为轻享套餐,单位取值为 token。</li></ul>
|
|
1226
1226
|
:rtype: int
|
|
1227
1227
|
"""
|
|
1228
1228
|
return self._ExclusiveQuota
|
|
@@ -1233,9 +1233,7 @@ class CreateTokenPlanApiKeysRequest(AbstractModel):
|
|
|
1233
1233
|
|
|
1234
1234
|
@property
|
|
1235
1235
|
def TotalQuota(self):
|
|
1236
|
-
r"""
|
|
1237
|
-
- 套餐类型为专业,单位取值为积分;
|
|
1238
|
-
- 套餐类型为轻享套餐,单位取值为 token。
|
|
1236
|
+
r"""<p>总额度上限。-1 表示不限,必须为 -1 或 >= API Key 当前的 ExclusiveQuota(独占额度)。不传表示不设置上限。单位说明如下:</p><ul><li>套餐类型为专业,单位取值为积分;</li><li>套餐类型为轻享套餐,单位取值为 token。</li></ul>
|
|
1239
1237
|
:rtype: int
|
|
1240
1238
|
"""
|
|
1241
1239
|
return self._TotalQuota
|
|
@@ -1246,7 +1244,7 @@ class CreateTokenPlanApiKeysRequest(AbstractModel):
|
|
|
1246
1244
|
|
|
1247
1245
|
@property
|
|
1248
1246
|
def TPM(self):
|
|
1249
|
-
r"""TPM(Tokens Per Minute)限制。不传使用套餐级别 TPM。必须
|
|
1247
|
+
r"""<p>TPM(Tokens Per Minute)限制。不传使用套餐级别 TPM。必须 >= 0 且 <= 套餐 TPM。</p>
|
|
1250
1248
|
:rtype: int
|
|
1251
1249
|
"""
|
|
1252
1250
|
return self._TPM
|
|
@@ -1255,6 +1253,28 @@ class CreateTokenPlanApiKeysRequest(AbstractModel):
|
|
|
1255
1253
|
def TPM(self, TPM):
|
|
1256
1254
|
self._TPM = TPM
|
|
1257
1255
|
|
|
1256
|
+
@property
|
|
1257
|
+
def IpWhitelist(self):
|
|
1258
|
+
r"""<p>IP 白名单列表。支持 IPv4 单地址(如 1.2.3.4)和 IPv4 CIDR(如 10.0.0.0/24)格式。最多 50 个条目,不允许重复;不支持 IPv6 与 IP 范围。不传或传空数组表示不限制。批量创建时所有 APIKey 共用同一份白名单。</p>
|
|
1259
|
+
:rtype: list of str
|
|
1260
|
+
"""
|
|
1261
|
+
return self._IpWhitelist
|
|
1262
|
+
|
|
1263
|
+
@IpWhitelist.setter
|
|
1264
|
+
def IpWhitelist(self, IpWhitelist):
|
|
1265
|
+
self._IpWhitelist = IpWhitelist
|
|
1266
|
+
|
|
1267
|
+
@property
|
|
1268
|
+
def OverageEnabled(self):
|
|
1269
|
+
r"""<p>是否开启超额按量计费。默认值为 false。开启后,若 APIKey 用量达到总额度上限,并且使用的模型已开启按量计费,将自动切换至按量计费模式,该部分将按所用模型的按量计费定价额外计费;未开启时用量达上限后调用报错。</p>
|
|
1270
|
+
:rtype: bool
|
|
1271
|
+
"""
|
|
1272
|
+
return self._OverageEnabled
|
|
1273
|
+
|
|
1274
|
+
@OverageEnabled.setter
|
|
1275
|
+
def OverageEnabled(self, OverageEnabled):
|
|
1276
|
+
self._OverageEnabled = OverageEnabled
|
|
1277
|
+
|
|
1258
1278
|
|
|
1259
1279
|
def _deserialize(self, params):
|
|
1260
1280
|
self._TeamId = params.get("TeamId")
|
|
@@ -1264,6 +1284,8 @@ class CreateTokenPlanApiKeysRequest(AbstractModel):
|
|
|
1264
1284
|
self._ExclusiveQuota = params.get("ExclusiveQuota")
|
|
1265
1285
|
self._TotalQuota = params.get("TotalQuota")
|
|
1266
1286
|
self._TPM = params.get("TPM")
|
|
1287
|
+
self._IpWhitelist = params.get("IpWhitelist")
|
|
1288
|
+
self._OverageEnabled = params.get("OverageEnabled")
|
|
1267
1289
|
memeber_set = set(params.keys())
|
|
1268
1290
|
for name, value in vars(self).items():
|
|
1269
1291
|
property_name = name[1:]
|
|
@@ -1281,9 +1303,9 @@ class CreateTokenPlanApiKeysResponse(AbstractModel):
|
|
|
1281
1303
|
|
|
1282
1304
|
def __init__(self):
|
|
1283
1305
|
r"""
|
|
1284
|
-
:param _Items:
|
|
1306
|
+
:param _Items: <p>成功创建的项列表。</p>
|
|
1285
1307
|
:type Items: list of CreateApiKeysResultItem
|
|
1286
|
-
:param _FailedItems:
|
|
1308
|
+
:param _FailedItems: <p>创建失败的项列表。</p>
|
|
1287
1309
|
:type FailedItems: list of BatchCreateFailedItem
|
|
1288
1310
|
:param _RequestId: 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
|
|
1289
1311
|
:type RequestId: str
|
|
@@ -1294,7 +1316,7 @@ class CreateTokenPlanApiKeysResponse(AbstractModel):
|
|
|
1294
1316
|
|
|
1295
1317
|
@property
|
|
1296
1318
|
def Items(self):
|
|
1297
|
-
r"""
|
|
1319
|
+
r"""<p>成功创建的项列表。</p>
|
|
1298
1320
|
:rtype: list of CreateApiKeysResultItem
|
|
1299
1321
|
"""
|
|
1300
1322
|
return self._Items
|
|
@@ -1305,7 +1327,7 @@ class CreateTokenPlanApiKeysResponse(AbstractModel):
|
|
|
1305
1327
|
|
|
1306
1328
|
@property
|
|
1307
1329
|
def FailedItems(self):
|
|
1308
|
-
r"""
|
|
1330
|
+
r"""<p>创建失败的项列表。</p>
|
|
1309
1331
|
:rtype: list of BatchCreateFailedItem
|
|
1310
1332
|
"""
|
|
1311
1333
|
return self._FailedItems
|
|
@@ -4115,6 +4137,310 @@ class DescribeTokenPlanListResponse(AbstractModel):
|
|
|
4115
4137
|
self._RequestId = params.get("RequestId")
|
|
4116
4138
|
|
|
4117
4139
|
|
|
4140
|
+
class DescribeTokenPlanPersonalPackageRequest(AbstractModel):
|
|
4141
|
+
r"""DescribeTokenPlanPersonalPackage请求参数结构体
|
|
4142
|
+
|
|
4143
|
+
"""
|
|
4144
|
+
|
|
4145
|
+
def __init__(self):
|
|
4146
|
+
r"""
|
|
4147
|
+
:param _ProductType: <p>产品类型。取值:personal(个人版)、personal-hunyuan(个人版混元)。</p>
|
|
4148
|
+
:type ProductType: str
|
|
4149
|
+
"""
|
|
4150
|
+
self._ProductType = None
|
|
4151
|
+
|
|
4152
|
+
@property
|
|
4153
|
+
def ProductType(self):
|
|
4154
|
+
r"""<p>产品类型。取值:personal(个人版)、personal-hunyuan(个人版混元)。</p>
|
|
4155
|
+
:rtype: str
|
|
4156
|
+
"""
|
|
4157
|
+
return self._ProductType
|
|
4158
|
+
|
|
4159
|
+
@ProductType.setter
|
|
4160
|
+
def ProductType(self, ProductType):
|
|
4161
|
+
self._ProductType = ProductType
|
|
4162
|
+
|
|
4163
|
+
|
|
4164
|
+
def _deserialize(self, params):
|
|
4165
|
+
self._ProductType = params.get("ProductType")
|
|
4166
|
+
memeber_set = set(params.keys())
|
|
4167
|
+
for name, value in vars(self).items():
|
|
4168
|
+
property_name = name[1:]
|
|
4169
|
+
if property_name in memeber_set:
|
|
4170
|
+
memeber_set.remove(property_name)
|
|
4171
|
+
if len(memeber_set) > 0:
|
|
4172
|
+
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
|
4173
|
+
|
|
4174
|
+
|
|
4175
|
+
|
|
4176
|
+
class DescribeTokenPlanPersonalPackageResponse(AbstractModel):
|
|
4177
|
+
r"""DescribeTokenPlanPersonalPackage返回参数结构体
|
|
4178
|
+
|
|
4179
|
+
"""
|
|
4180
|
+
|
|
4181
|
+
def __init__(self):
|
|
4182
|
+
r"""
|
|
4183
|
+
:param _ProductType: <p>产品类型。</p>
|
|
4184
|
+
:type ProductType: str
|
|
4185
|
+
:param _PackageStatus: <p>套餐状态。取值:active(生效中)、processing(处理中)、failed(创建失败)、isolated(隔离/欠费)、destroyed(已销毁)、used_up(额度用尽)、stopped(已停止)、unpurchased(未购买)。</p>
|
|
4186
|
+
:type PackageStatus: str
|
|
4187
|
+
:param _ResourceId: <p>计费资源ID</p>
|
|
4188
|
+
:type ResourceId: str
|
|
4189
|
+
:param _TotalCredits: <p>总额度。</p>
|
|
4190
|
+
:type TotalCredits: str
|
|
4191
|
+
:param _TotalUsed: <p>已使用额度。</p>
|
|
4192
|
+
:type TotalUsed: str
|
|
4193
|
+
:param _CycleCredits: <p>单周期额度。</p>
|
|
4194
|
+
:type CycleCredits: str
|
|
4195
|
+
:param _TotalCycles: <p>总周期数。</p>
|
|
4196
|
+
:type TotalCycles: int
|
|
4197
|
+
:param _CurrentCycle: <p>当前周期序号。</p>
|
|
4198
|
+
:type CurrentCycle: int
|
|
4199
|
+
:param _RemainCycles: <p>剩余周期数。</p>
|
|
4200
|
+
:type RemainCycles: int
|
|
4201
|
+
:param _StartTime: <p>套餐生效时间,ISO 8601 格式。</p>
|
|
4202
|
+
:type StartTime: str
|
|
4203
|
+
:param _ExpireTime: <p>套餐过期时间,ISO 8601 格式。</p>
|
|
4204
|
+
:type ExpireTime: str
|
|
4205
|
+
:param _PeriodEndDate: <p>当前周期到期日,ISO 8601 格式。</p>
|
|
4206
|
+
:type PeriodEndDate: str
|
|
4207
|
+
:param _AutoRenewFlag: <p>自动续费标识。取值:0(未开启)、1(已开启)。</p>
|
|
4208
|
+
:type AutoRenewFlag: int
|
|
4209
|
+
:param _OutputToken: <p>输出token数</p><p>单位:tokens</p>
|
|
4210
|
+
:type OutputToken: int
|
|
4211
|
+
:param _InputToken: <p>输入token数</p><p>单位:token</p>
|
|
4212
|
+
:type InputToken: int
|
|
4213
|
+
:param _CacheToken: <p>缓存命中token数</p><p>单位:token</p>
|
|
4214
|
+
:type CacheToken: int
|
|
4215
|
+
:param _RequestId: 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
|
|
4216
|
+
:type RequestId: str
|
|
4217
|
+
"""
|
|
4218
|
+
self._ProductType = None
|
|
4219
|
+
self._PackageStatus = None
|
|
4220
|
+
self._ResourceId = None
|
|
4221
|
+
self._TotalCredits = None
|
|
4222
|
+
self._TotalUsed = None
|
|
4223
|
+
self._CycleCredits = None
|
|
4224
|
+
self._TotalCycles = None
|
|
4225
|
+
self._CurrentCycle = None
|
|
4226
|
+
self._RemainCycles = None
|
|
4227
|
+
self._StartTime = None
|
|
4228
|
+
self._ExpireTime = None
|
|
4229
|
+
self._PeriodEndDate = None
|
|
4230
|
+
self._AutoRenewFlag = None
|
|
4231
|
+
self._OutputToken = None
|
|
4232
|
+
self._InputToken = None
|
|
4233
|
+
self._CacheToken = None
|
|
4234
|
+
self._RequestId = None
|
|
4235
|
+
|
|
4236
|
+
@property
|
|
4237
|
+
def ProductType(self):
|
|
4238
|
+
r"""<p>产品类型。</p>
|
|
4239
|
+
:rtype: str
|
|
4240
|
+
"""
|
|
4241
|
+
return self._ProductType
|
|
4242
|
+
|
|
4243
|
+
@ProductType.setter
|
|
4244
|
+
def ProductType(self, ProductType):
|
|
4245
|
+
self._ProductType = ProductType
|
|
4246
|
+
|
|
4247
|
+
@property
|
|
4248
|
+
def PackageStatus(self):
|
|
4249
|
+
r"""<p>套餐状态。取值:active(生效中)、processing(处理中)、failed(创建失败)、isolated(隔离/欠费)、destroyed(已销毁)、used_up(额度用尽)、stopped(已停止)、unpurchased(未购买)。</p>
|
|
4250
|
+
:rtype: str
|
|
4251
|
+
"""
|
|
4252
|
+
return self._PackageStatus
|
|
4253
|
+
|
|
4254
|
+
@PackageStatus.setter
|
|
4255
|
+
def PackageStatus(self, PackageStatus):
|
|
4256
|
+
self._PackageStatus = PackageStatus
|
|
4257
|
+
|
|
4258
|
+
@property
|
|
4259
|
+
def ResourceId(self):
|
|
4260
|
+
r"""<p>计费资源ID</p>
|
|
4261
|
+
:rtype: str
|
|
4262
|
+
"""
|
|
4263
|
+
return self._ResourceId
|
|
4264
|
+
|
|
4265
|
+
@ResourceId.setter
|
|
4266
|
+
def ResourceId(self, ResourceId):
|
|
4267
|
+
self._ResourceId = ResourceId
|
|
4268
|
+
|
|
4269
|
+
@property
|
|
4270
|
+
def TotalCredits(self):
|
|
4271
|
+
r"""<p>总额度。</p>
|
|
4272
|
+
:rtype: str
|
|
4273
|
+
"""
|
|
4274
|
+
return self._TotalCredits
|
|
4275
|
+
|
|
4276
|
+
@TotalCredits.setter
|
|
4277
|
+
def TotalCredits(self, TotalCredits):
|
|
4278
|
+
self._TotalCredits = TotalCredits
|
|
4279
|
+
|
|
4280
|
+
@property
|
|
4281
|
+
def TotalUsed(self):
|
|
4282
|
+
r"""<p>已使用额度。</p>
|
|
4283
|
+
:rtype: str
|
|
4284
|
+
"""
|
|
4285
|
+
return self._TotalUsed
|
|
4286
|
+
|
|
4287
|
+
@TotalUsed.setter
|
|
4288
|
+
def TotalUsed(self, TotalUsed):
|
|
4289
|
+
self._TotalUsed = TotalUsed
|
|
4290
|
+
|
|
4291
|
+
@property
|
|
4292
|
+
def CycleCredits(self):
|
|
4293
|
+
r"""<p>单周期额度。</p>
|
|
4294
|
+
:rtype: str
|
|
4295
|
+
"""
|
|
4296
|
+
return self._CycleCredits
|
|
4297
|
+
|
|
4298
|
+
@CycleCredits.setter
|
|
4299
|
+
def CycleCredits(self, CycleCredits):
|
|
4300
|
+
self._CycleCredits = CycleCredits
|
|
4301
|
+
|
|
4302
|
+
@property
|
|
4303
|
+
def TotalCycles(self):
|
|
4304
|
+
r"""<p>总周期数。</p>
|
|
4305
|
+
:rtype: int
|
|
4306
|
+
"""
|
|
4307
|
+
return self._TotalCycles
|
|
4308
|
+
|
|
4309
|
+
@TotalCycles.setter
|
|
4310
|
+
def TotalCycles(self, TotalCycles):
|
|
4311
|
+
self._TotalCycles = TotalCycles
|
|
4312
|
+
|
|
4313
|
+
@property
|
|
4314
|
+
def CurrentCycle(self):
|
|
4315
|
+
r"""<p>当前周期序号。</p>
|
|
4316
|
+
:rtype: int
|
|
4317
|
+
"""
|
|
4318
|
+
return self._CurrentCycle
|
|
4319
|
+
|
|
4320
|
+
@CurrentCycle.setter
|
|
4321
|
+
def CurrentCycle(self, CurrentCycle):
|
|
4322
|
+
self._CurrentCycle = CurrentCycle
|
|
4323
|
+
|
|
4324
|
+
@property
|
|
4325
|
+
def RemainCycles(self):
|
|
4326
|
+
r"""<p>剩余周期数。</p>
|
|
4327
|
+
:rtype: int
|
|
4328
|
+
"""
|
|
4329
|
+
return self._RemainCycles
|
|
4330
|
+
|
|
4331
|
+
@RemainCycles.setter
|
|
4332
|
+
def RemainCycles(self, RemainCycles):
|
|
4333
|
+
self._RemainCycles = RemainCycles
|
|
4334
|
+
|
|
4335
|
+
@property
|
|
4336
|
+
def StartTime(self):
|
|
4337
|
+
r"""<p>套餐生效时间,ISO 8601 格式。</p>
|
|
4338
|
+
:rtype: str
|
|
4339
|
+
"""
|
|
4340
|
+
return self._StartTime
|
|
4341
|
+
|
|
4342
|
+
@StartTime.setter
|
|
4343
|
+
def StartTime(self, StartTime):
|
|
4344
|
+
self._StartTime = StartTime
|
|
4345
|
+
|
|
4346
|
+
@property
|
|
4347
|
+
def ExpireTime(self):
|
|
4348
|
+
r"""<p>套餐过期时间,ISO 8601 格式。</p>
|
|
4349
|
+
:rtype: str
|
|
4350
|
+
"""
|
|
4351
|
+
return self._ExpireTime
|
|
4352
|
+
|
|
4353
|
+
@ExpireTime.setter
|
|
4354
|
+
def ExpireTime(self, ExpireTime):
|
|
4355
|
+
self._ExpireTime = ExpireTime
|
|
4356
|
+
|
|
4357
|
+
@property
|
|
4358
|
+
def PeriodEndDate(self):
|
|
4359
|
+
r"""<p>当前周期到期日,ISO 8601 格式。</p>
|
|
4360
|
+
:rtype: str
|
|
4361
|
+
"""
|
|
4362
|
+
return self._PeriodEndDate
|
|
4363
|
+
|
|
4364
|
+
@PeriodEndDate.setter
|
|
4365
|
+
def PeriodEndDate(self, PeriodEndDate):
|
|
4366
|
+
self._PeriodEndDate = PeriodEndDate
|
|
4367
|
+
|
|
4368
|
+
@property
|
|
4369
|
+
def AutoRenewFlag(self):
|
|
4370
|
+
r"""<p>自动续费标识。取值:0(未开启)、1(已开启)。</p>
|
|
4371
|
+
:rtype: int
|
|
4372
|
+
"""
|
|
4373
|
+
return self._AutoRenewFlag
|
|
4374
|
+
|
|
4375
|
+
@AutoRenewFlag.setter
|
|
4376
|
+
def AutoRenewFlag(self, AutoRenewFlag):
|
|
4377
|
+
self._AutoRenewFlag = AutoRenewFlag
|
|
4378
|
+
|
|
4379
|
+
@property
|
|
4380
|
+
def OutputToken(self):
|
|
4381
|
+
r"""<p>输出token数</p><p>单位:tokens</p>
|
|
4382
|
+
:rtype: int
|
|
4383
|
+
"""
|
|
4384
|
+
return self._OutputToken
|
|
4385
|
+
|
|
4386
|
+
@OutputToken.setter
|
|
4387
|
+
def OutputToken(self, OutputToken):
|
|
4388
|
+
self._OutputToken = OutputToken
|
|
4389
|
+
|
|
4390
|
+
@property
|
|
4391
|
+
def InputToken(self):
|
|
4392
|
+
r"""<p>输入token数</p><p>单位:token</p>
|
|
4393
|
+
:rtype: int
|
|
4394
|
+
"""
|
|
4395
|
+
return self._InputToken
|
|
4396
|
+
|
|
4397
|
+
@InputToken.setter
|
|
4398
|
+
def InputToken(self, InputToken):
|
|
4399
|
+
self._InputToken = InputToken
|
|
4400
|
+
|
|
4401
|
+
@property
|
|
4402
|
+
def CacheToken(self):
|
|
4403
|
+
r"""<p>缓存命中token数</p><p>单位:token</p>
|
|
4404
|
+
:rtype: int
|
|
4405
|
+
"""
|
|
4406
|
+
return self._CacheToken
|
|
4407
|
+
|
|
4408
|
+
@CacheToken.setter
|
|
4409
|
+
def CacheToken(self, CacheToken):
|
|
4410
|
+
self._CacheToken = CacheToken
|
|
4411
|
+
|
|
4412
|
+
@property
|
|
4413
|
+
def RequestId(self):
|
|
4414
|
+
r"""唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
|
|
4415
|
+
:rtype: str
|
|
4416
|
+
"""
|
|
4417
|
+
return self._RequestId
|
|
4418
|
+
|
|
4419
|
+
@RequestId.setter
|
|
4420
|
+
def RequestId(self, RequestId):
|
|
4421
|
+
self._RequestId = RequestId
|
|
4422
|
+
|
|
4423
|
+
|
|
4424
|
+
def _deserialize(self, params):
|
|
4425
|
+
self._ProductType = params.get("ProductType")
|
|
4426
|
+
self._PackageStatus = params.get("PackageStatus")
|
|
4427
|
+
self._ResourceId = params.get("ResourceId")
|
|
4428
|
+
self._TotalCredits = params.get("TotalCredits")
|
|
4429
|
+
self._TotalUsed = params.get("TotalUsed")
|
|
4430
|
+
self._CycleCredits = params.get("CycleCredits")
|
|
4431
|
+
self._TotalCycles = params.get("TotalCycles")
|
|
4432
|
+
self._CurrentCycle = params.get("CurrentCycle")
|
|
4433
|
+
self._RemainCycles = params.get("RemainCycles")
|
|
4434
|
+
self._StartTime = params.get("StartTime")
|
|
4435
|
+
self._ExpireTime = params.get("ExpireTime")
|
|
4436
|
+
self._PeriodEndDate = params.get("PeriodEndDate")
|
|
4437
|
+
self._AutoRenewFlag = params.get("AutoRenewFlag")
|
|
4438
|
+
self._OutputToken = params.get("OutputToken")
|
|
4439
|
+
self._InputToken = params.get("InputToken")
|
|
4440
|
+
self._CacheToken = params.get("CacheToken")
|
|
4441
|
+
self._RequestId = params.get("RequestId")
|
|
4442
|
+
|
|
4443
|
+
|
|
4118
4444
|
class DescribeTokenPlanRequest(AbstractModel):
|
|
4119
4445
|
r"""DescribeTokenPlan请求参数结构体
|
|
4120
4446
|
|
|
@@ -4863,14 +5189,14 @@ class EndpointCreateDetail(AbstractModel):
|
|
|
4863
5189
|
|
|
4864
5190
|
def __init__(self):
|
|
4865
5191
|
r"""
|
|
4866
|
-
:param _PreResourceId:
|
|
5192
|
+
:param _PreResourceId: <p>预付费包 id</p>
|
|
4867
5193
|
:type PreResourceId: str
|
|
4868
5194
|
"""
|
|
4869
5195
|
self._PreResourceId = None
|
|
4870
5196
|
|
|
4871
5197
|
@property
|
|
4872
5198
|
def PreResourceId(self):
|
|
4873
|
-
r"""
|
|
5199
|
+
r"""<p>预付费包 id</p>
|
|
4874
5200
|
:rtype: str
|
|
4875
5201
|
"""
|
|
4876
5202
|
return self._PreResourceId
|
|
@@ -4901,6 +5227,10 @@ class EndpointDetail(AbstractModel):
|
|
|
4901
5227
|
r"""
|
|
4902
5228
|
:param _EndpointId: <p>推理服务 ID。</p>
|
|
4903
5229
|
:type EndpointId: str
|
|
5230
|
+
:param _WorkspaceId: <p>所属企业空间 ID。</p>
|
|
5231
|
+
:type WorkspaceId: str
|
|
5232
|
+
:param _OriginEndpointId: <p>跨空间展开时的原始推理服务 ID;未展开时与 EndpointId 相同。</p>
|
|
5233
|
+
:type OriginEndpointId: str
|
|
4904
5234
|
:param _EndpointName: <p>服务名称。</p>
|
|
4905
5235
|
:type EndpointName: str
|
|
4906
5236
|
:param _ModelName: <p>模型名称。</p>
|
|
@@ -4927,8 +5257,12 @@ class EndpointDetail(AbstractModel):
|
|
|
4927
5257
|
:type RPM: int
|
|
4928
5258
|
:param _ModelStatus: <p>模型状态</p><p>枚举值:</p><ul><li>online: 在线</li><li>pre-offline: 预下线</li><li>discontinued: 停止新购</li><li>maintenance: 维护</li><li>offline: 下线</li></ul>
|
|
4929
5259
|
:type ModelStatus: str
|
|
5260
|
+
:param _NightDiscountEnabled: <p>是否参与夜间折扣。true 表示该接入点参与夜间时段折扣计费,false 表示不参与。</p>
|
|
5261
|
+
:type NightDiscountEnabled: bool
|
|
4930
5262
|
"""
|
|
4931
5263
|
self._EndpointId = None
|
|
5264
|
+
self._WorkspaceId = None
|
|
5265
|
+
self._OriginEndpointId = None
|
|
4932
5266
|
self._EndpointName = None
|
|
4933
5267
|
self._ModelName = None
|
|
4934
5268
|
self._ModelId = None
|
|
@@ -4942,6 +5276,7 @@ class EndpointDetail(AbstractModel):
|
|
|
4942
5276
|
self._AutoAdjustQuota = None
|
|
4943
5277
|
self._RPM = None
|
|
4944
5278
|
self._ModelStatus = None
|
|
5279
|
+
self._NightDiscountEnabled = None
|
|
4945
5280
|
|
|
4946
5281
|
@property
|
|
4947
5282
|
def EndpointId(self):
|
|
@@ -4954,6 +5289,28 @@ class EndpointDetail(AbstractModel):
|
|
|
4954
5289
|
def EndpointId(self, EndpointId):
|
|
4955
5290
|
self._EndpointId = EndpointId
|
|
4956
5291
|
|
|
5292
|
+
@property
|
|
5293
|
+
def WorkspaceId(self):
|
|
5294
|
+
r"""<p>所属企业空间 ID。</p>
|
|
5295
|
+
:rtype: str
|
|
5296
|
+
"""
|
|
5297
|
+
return self._WorkspaceId
|
|
5298
|
+
|
|
5299
|
+
@WorkspaceId.setter
|
|
5300
|
+
def WorkspaceId(self, WorkspaceId):
|
|
5301
|
+
self._WorkspaceId = WorkspaceId
|
|
5302
|
+
|
|
5303
|
+
@property
|
|
5304
|
+
def OriginEndpointId(self):
|
|
5305
|
+
r"""<p>跨空间展开时的原始推理服务 ID;未展开时与 EndpointId 相同。</p>
|
|
5306
|
+
:rtype: str
|
|
5307
|
+
"""
|
|
5308
|
+
return self._OriginEndpointId
|
|
5309
|
+
|
|
5310
|
+
@OriginEndpointId.setter
|
|
5311
|
+
def OriginEndpointId(self, OriginEndpointId):
|
|
5312
|
+
self._OriginEndpointId = OriginEndpointId
|
|
5313
|
+
|
|
4957
5314
|
@property
|
|
4958
5315
|
def EndpointName(self):
|
|
4959
5316
|
r"""<p>服务名称。</p>
|
|
@@ -5097,9 +5454,22 @@ class EndpointDetail(AbstractModel):
|
|
|
5097
5454
|
def ModelStatus(self, ModelStatus):
|
|
5098
5455
|
self._ModelStatus = ModelStatus
|
|
5099
5456
|
|
|
5457
|
+
@property
|
|
5458
|
+
def NightDiscountEnabled(self):
|
|
5459
|
+
r"""<p>是否参与夜间折扣。true 表示该接入点参与夜间时段折扣计费,false 表示不参与。</p>
|
|
5460
|
+
:rtype: bool
|
|
5461
|
+
"""
|
|
5462
|
+
return self._NightDiscountEnabled
|
|
5463
|
+
|
|
5464
|
+
@NightDiscountEnabled.setter
|
|
5465
|
+
def NightDiscountEnabled(self, NightDiscountEnabled):
|
|
5466
|
+
self._NightDiscountEnabled = NightDiscountEnabled
|
|
5467
|
+
|
|
5100
5468
|
|
|
5101
5469
|
def _deserialize(self, params):
|
|
5102
5470
|
self._EndpointId = params.get("EndpointId")
|
|
5471
|
+
self._WorkspaceId = params.get("WorkspaceId")
|
|
5472
|
+
self._OriginEndpointId = params.get("OriginEndpointId")
|
|
5103
5473
|
self._EndpointName = params.get("EndpointName")
|
|
5104
5474
|
self._ModelName = params.get("ModelName")
|
|
5105
5475
|
self._ModelId = params.get("ModelId")
|
|
@@ -5113,6 +5483,7 @@ class EndpointDetail(AbstractModel):
|
|
|
5113
5483
|
self._AutoAdjustQuota = params.get("AutoAdjustQuota")
|
|
5114
5484
|
self._RPM = params.get("RPM")
|
|
5115
5485
|
self._ModelStatus = params.get("ModelStatus")
|
|
5486
|
+
self._NightDiscountEnabled = params.get("NightDiscountEnabled")
|
|
5116
5487
|
memeber_set = set(params.keys())
|
|
5117
5488
|
for name, value in vars(self).items():
|
|
5118
5489
|
property_name = name[1:]
|
|
@@ -6049,6 +6420,8 @@ class ModelEndpointView(AbstractModel):
|
|
|
6049
6420
|
:type Status: str
|
|
6050
6421
|
:param _ModelStatus: <p>模型状态</p><p>枚举值:</p><ul><li>online: 在线</li><li>pre-offline: 预下线</li><li>discontinued: 停止新购</li><li>maintenance: 维护中</li><li>offline: 下线</li></ul>
|
|
6051
6422
|
:type ModelStatus: str
|
|
6423
|
+
:param _ModelChargeUnit: <p>模型计费单位(模型维度属性,区别于计费方式 ChargeType)。取值:TOKEN(词元)、COUNT(次)、CREDIT(积分)、PICTURE(张)。未激活时为空。</p>
|
|
6424
|
+
:type ModelChargeUnit: str
|
|
6052
6425
|
:param _ServiceType: <p>服务类型。固定为 TEXT_GENERATION(文本生成)。</p>
|
|
6053
6426
|
:type ServiceType: str
|
|
6054
6427
|
:param _ChargeType: <p>计费方式。取值:FREE(免费体验)、TOKEN(按 Token 计费)。未激活时为空。</p>
|
|
@@ -6063,6 +6436,14 @@ class ModelEndpointView(AbstractModel):
|
|
|
6063
6436
|
:type RPM: int
|
|
6064
6437
|
:param _TPM: <p>推理服务的tpm 限制,没设置就按模型维度 tpm 限制展示</p>
|
|
6065
6438
|
:type TPM: int
|
|
6439
|
+
:param _ModelImage: <p>模型图标。</p>
|
|
6440
|
+
:type ModelImage: :class:`tencentcloud.tokenhub.v20260322.models.ModelImage`
|
|
6441
|
+
:param _OfflineAt: <p>模型下线时间,Status=pre-offline 时,会配置模型下线时间</p>
|
|
6442
|
+
:type OfflineAt: str
|
|
6443
|
+
:param _DiscontinuedAt: <p>停止新购时间</p>
|
|
6444
|
+
:type DiscontinuedAt: str
|
|
6445
|
+
:param _NightDiscountEnabled: <p>是否参与夜间折扣。true 表示该接入点参与夜间时段折扣计费,false 表示不参与。</p>
|
|
6446
|
+
:type NightDiscountEnabled: bool
|
|
6066
6447
|
"""
|
|
6067
6448
|
self._EndpointId = None
|
|
6068
6449
|
self._EndpointName = None
|
|
@@ -6071,6 +6452,7 @@ class ModelEndpointView(AbstractModel):
|
|
|
6071
6452
|
self._ModelName = None
|
|
6072
6453
|
self._Status = None
|
|
6073
6454
|
self._ModelStatus = None
|
|
6455
|
+
self._ModelChargeUnit = None
|
|
6074
6456
|
self._ServiceType = None
|
|
6075
6457
|
self._ChargeType = None
|
|
6076
6458
|
self._PaymentEnabled = None
|
|
@@ -6078,6 +6460,10 @@ class ModelEndpointView(AbstractModel):
|
|
|
6078
6460
|
self._StopReason = None
|
|
6079
6461
|
self._RPM = None
|
|
6080
6462
|
self._TPM = None
|
|
6463
|
+
self._ModelImage = None
|
|
6464
|
+
self._OfflineAt = None
|
|
6465
|
+
self._DiscontinuedAt = None
|
|
6466
|
+
self._NightDiscountEnabled = None
|
|
6081
6467
|
|
|
6082
6468
|
@property
|
|
6083
6469
|
def EndpointId(self):
|
|
@@ -6156,6 +6542,17 @@ class ModelEndpointView(AbstractModel):
|
|
|
6156
6542
|
def ModelStatus(self, ModelStatus):
|
|
6157
6543
|
self._ModelStatus = ModelStatus
|
|
6158
6544
|
|
|
6545
|
+
@property
|
|
6546
|
+
def ModelChargeUnit(self):
|
|
6547
|
+
r"""<p>模型计费单位(模型维度属性,区别于计费方式 ChargeType)。取值:TOKEN(词元)、COUNT(次)、CREDIT(积分)、PICTURE(张)。未激活时为空。</p>
|
|
6548
|
+
:rtype: str
|
|
6549
|
+
"""
|
|
6550
|
+
return self._ModelChargeUnit
|
|
6551
|
+
|
|
6552
|
+
@ModelChargeUnit.setter
|
|
6553
|
+
def ModelChargeUnit(self, ModelChargeUnit):
|
|
6554
|
+
self._ModelChargeUnit = ModelChargeUnit
|
|
6555
|
+
|
|
6159
6556
|
@property
|
|
6160
6557
|
def ServiceType(self):
|
|
6161
6558
|
r"""<p>服务类型。固定为 TEXT_GENERATION(文本生成)。</p>
|
|
@@ -6233,6 +6630,50 @@ class ModelEndpointView(AbstractModel):
|
|
|
6233
6630
|
def TPM(self, TPM):
|
|
6234
6631
|
self._TPM = TPM
|
|
6235
6632
|
|
|
6633
|
+
@property
|
|
6634
|
+
def ModelImage(self):
|
|
6635
|
+
r"""<p>模型图标。</p>
|
|
6636
|
+
:rtype: :class:`tencentcloud.tokenhub.v20260322.models.ModelImage`
|
|
6637
|
+
"""
|
|
6638
|
+
return self._ModelImage
|
|
6639
|
+
|
|
6640
|
+
@ModelImage.setter
|
|
6641
|
+
def ModelImage(self, ModelImage):
|
|
6642
|
+
self._ModelImage = ModelImage
|
|
6643
|
+
|
|
6644
|
+
@property
|
|
6645
|
+
def OfflineAt(self):
|
|
6646
|
+
r"""<p>模型下线时间,Status=pre-offline 时,会配置模型下线时间</p>
|
|
6647
|
+
:rtype: str
|
|
6648
|
+
"""
|
|
6649
|
+
return self._OfflineAt
|
|
6650
|
+
|
|
6651
|
+
@OfflineAt.setter
|
|
6652
|
+
def OfflineAt(self, OfflineAt):
|
|
6653
|
+
self._OfflineAt = OfflineAt
|
|
6654
|
+
|
|
6655
|
+
@property
|
|
6656
|
+
def DiscontinuedAt(self):
|
|
6657
|
+
r"""<p>停止新购时间</p>
|
|
6658
|
+
:rtype: str
|
|
6659
|
+
"""
|
|
6660
|
+
return self._DiscontinuedAt
|
|
6661
|
+
|
|
6662
|
+
@DiscontinuedAt.setter
|
|
6663
|
+
def DiscontinuedAt(self, DiscontinuedAt):
|
|
6664
|
+
self._DiscontinuedAt = DiscontinuedAt
|
|
6665
|
+
|
|
6666
|
+
@property
|
|
6667
|
+
def NightDiscountEnabled(self):
|
|
6668
|
+
r"""<p>是否参与夜间折扣。true 表示该接入点参与夜间时段折扣计费,false 表示不参与。</p>
|
|
6669
|
+
:rtype: bool
|
|
6670
|
+
"""
|
|
6671
|
+
return self._NightDiscountEnabled
|
|
6672
|
+
|
|
6673
|
+
@NightDiscountEnabled.setter
|
|
6674
|
+
def NightDiscountEnabled(self, NightDiscountEnabled):
|
|
6675
|
+
self._NightDiscountEnabled = NightDiscountEnabled
|
|
6676
|
+
|
|
6236
6677
|
|
|
6237
6678
|
def _deserialize(self, params):
|
|
6238
6679
|
self._EndpointId = params.get("EndpointId")
|
|
@@ -6242,6 +6683,7 @@ class ModelEndpointView(AbstractModel):
|
|
|
6242
6683
|
self._ModelName = params.get("ModelName")
|
|
6243
6684
|
self._Status = params.get("Status")
|
|
6244
6685
|
self._ModelStatus = params.get("ModelStatus")
|
|
6686
|
+
self._ModelChargeUnit = params.get("ModelChargeUnit")
|
|
6245
6687
|
self._ServiceType = params.get("ServiceType")
|
|
6246
6688
|
self._ChargeType = params.get("ChargeType")
|
|
6247
6689
|
self._PaymentEnabled = params.get("PaymentEnabled")
|
|
@@ -6249,6 +6691,12 @@ class ModelEndpointView(AbstractModel):
|
|
|
6249
6691
|
self._StopReason = params.get("StopReason")
|
|
6250
6692
|
self._RPM = params.get("RPM")
|
|
6251
6693
|
self._TPM = params.get("TPM")
|
|
6694
|
+
if params.get("ModelImage") is not None:
|
|
6695
|
+
self._ModelImage = ModelImage()
|
|
6696
|
+
self._ModelImage._deserialize(params.get("ModelImage"))
|
|
6697
|
+
self._OfflineAt = params.get("OfflineAt")
|
|
6698
|
+
self._DiscontinuedAt = params.get("DiscontinuedAt")
|
|
6699
|
+
self._NightDiscountEnabled = params.get("NightDiscountEnabled")
|
|
6252
6700
|
memeber_set = set(params.keys())
|
|
6253
6701
|
for name, value in vars(self).items():
|
|
6254
6702
|
property_name = name[1:]
|
|
@@ -7146,29 +7594,20 @@ class ModifyTokenPlanApiKeyRequest(AbstractModel):
|
|
|
7146
7594
|
|
|
7147
7595
|
def __init__(self):
|
|
7148
7596
|
r"""
|
|
7149
|
-
:param _ApiKeyId: API Key ID
|
|
7597
|
+
:param _ApiKeyId: <p>API Key ID。</p>
|
|
7150
7598
|
:type ApiKeyId: str
|
|
7151
|
-
:param _AllowedModels:
|
|
7152
|
-
|
|
7153
|
-
- 如果套餐类型为企业版专业套餐:
|
|
7154
|
-
1)传入“all“ :使用套餐支持的所有模型
|
|
7155
|
-
2)传入 Model ID:指定具体模型。“all“和具体的 Model ID 不能同时传入。
|
|
7156
|
-
|
|
7157
|
-
- 如果套餐类型为企业版轻享套餐,不允许传该参数。
|
|
7599
|
+
:param _AllowedModels: <p>可用模型列表。不传则不修改。</p><ul><li><p>如果套餐类型为企业版专业套餐:<br>1)传入“all“ :使用套餐支持的所有模型<br>2)传入 Model ID:指定具体模型。“all“和具体的 Model ID 不能同时传入。</p></li><li><p>如果套餐类型为企业版轻享套餐,不允许传该参数。</p></li></ul>
|
|
7158
7600
|
:type AllowedModels: list of str
|
|
7159
|
-
:param _ExclusiveQuota:
|
|
7160
|
-
|
|
7161
|
-
- 套餐类型为专业套餐,单位取值为积分;
|
|
7162
|
-
- 套餐类型为轻享套餐,单位取值为 token。
|
|
7601
|
+
:param _ExclusiveQuota: <p>独占额度,不传则不修改。单位说明:</p><ul><li>套餐类型为专业套餐,单位取值为积分;</li><li>套餐类型为轻享套餐,单位取值为 token。</li></ul>
|
|
7163
7602
|
:type ExclusiveQuota: int
|
|
7164
|
-
:param _TotalQuota:
|
|
7165
|
-
- 套餐类型为专业套餐,单位取值为积分;
|
|
7166
|
-
- 套餐类型为轻享套餐,单位取值为 token。
|
|
7603
|
+
:param _TotalQuota: <p>总额度上限。-1 表示不限,必须为 -1 或 >= API Key 当前的 ExclusiveQuota(独占额度),不传则不修改。单位说明如下:</p><ul><li>套餐类型为专业套餐,单位取值为积分;</li><li>套餐类型为轻享套餐,单位取值为 token。</li></ul>
|
|
7167
7604
|
:type TotalQuota: int
|
|
7168
|
-
:param _UseStatus:
|
|
7605
|
+
:param _UseStatus: <p>是否启用该 API Key。取值:enable(启用)、disable(停用),不传则不修改。</p>
|
|
7169
7606
|
:type UseStatus: str
|
|
7170
|
-
:param _TPM: TPM(Tokens Per Minute)限制。不传则不修改。必须
|
|
7607
|
+
:param _TPM: <p>TPM(Tokens Per Minute)限制。不传则不修改。必须 >= 0 且 <= 套餐 TPM。</p>
|
|
7171
7608
|
:type TPM: int
|
|
7609
|
+
:param _IpWhitelist: <p>IP 白名单列表。不传则不修改;传空数组表示清空(不限制 IP);传非空数组表示覆盖。支持 IPv4 单地址(如 1.2.3.4)和 IPv4 CIDR(如 10.0.0.0/24)格式,最多 50 个条目,不允许重复;不支持 IPv6 与 IP 范围。</p>
|
|
7610
|
+
:type IpWhitelist: list of str
|
|
7172
7611
|
"""
|
|
7173
7612
|
self._ApiKeyId = None
|
|
7174
7613
|
self._AllowedModels = None
|
|
@@ -7176,10 +7615,11 @@ class ModifyTokenPlanApiKeyRequest(AbstractModel):
|
|
|
7176
7615
|
self._TotalQuota = None
|
|
7177
7616
|
self._UseStatus = None
|
|
7178
7617
|
self._TPM = None
|
|
7618
|
+
self._IpWhitelist = None
|
|
7179
7619
|
|
|
7180
7620
|
@property
|
|
7181
7621
|
def ApiKeyId(self):
|
|
7182
|
-
r"""API Key ID
|
|
7622
|
+
r"""<p>API Key ID。</p>
|
|
7183
7623
|
:rtype: str
|
|
7184
7624
|
"""
|
|
7185
7625
|
return self._ApiKeyId
|
|
@@ -7190,13 +7630,7 @@ class ModifyTokenPlanApiKeyRequest(AbstractModel):
|
|
|
7190
7630
|
|
|
7191
7631
|
@property
|
|
7192
7632
|
def AllowedModels(self):
|
|
7193
|
-
r"""
|
|
7194
|
-
|
|
7195
|
-
- 如果套餐类型为企业版专业套餐:
|
|
7196
|
-
1)传入“all“ :使用套餐支持的所有模型
|
|
7197
|
-
2)传入 Model ID:指定具体模型。“all“和具体的 Model ID 不能同时传入。
|
|
7198
|
-
|
|
7199
|
-
- 如果套餐类型为企业版轻享套餐,不允许传该参数。
|
|
7633
|
+
r"""<p>可用模型列表。不传则不修改。</p><ul><li><p>如果套餐类型为企业版专业套餐:<br>1)传入“all“ :使用套餐支持的所有模型<br>2)传入 Model ID:指定具体模型。“all“和具体的 Model ID 不能同时传入。</p></li><li><p>如果套餐类型为企业版轻享套餐,不允许传该参数。</p></li></ul>
|
|
7200
7634
|
:rtype: list of str
|
|
7201
7635
|
"""
|
|
7202
7636
|
return self._AllowedModels
|
|
@@ -7207,10 +7641,7 @@ class ModifyTokenPlanApiKeyRequest(AbstractModel):
|
|
|
7207
7641
|
|
|
7208
7642
|
@property
|
|
7209
7643
|
def ExclusiveQuota(self):
|
|
7210
|
-
r"""
|
|
7211
|
-
|
|
7212
|
-
- 套餐类型为专业套餐,单位取值为积分;
|
|
7213
|
-
- 套餐类型为轻享套餐,单位取值为 token。
|
|
7644
|
+
r"""<p>独占额度,不传则不修改。单位说明:</p><ul><li>套餐类型为专业套餐,单位取值为积分;</li><li>套餐类型为轻享套餐,单位取值为 token。</li></ul>
|
|
7214
7645
|
:rtype: int
|
|
7215
7646
|
"""
|
|
7216
7647
|
return self._ExclusiveQuota
|
|
@@ -7221,9 +7652,7 @@ class ModifyTokenPlanApiKeyRequest(AbstractModel):
|
|
|
7221
7652
|
|
|
7222
7653
|
@property
|
|
7223
7654
|
def TotalQuota(self):
|
|
7224
|
-
r"""
|
|
7225
|
-
- 套餐类型为专业套餐,单位取值为积分;
|
|
7226
|
-
- 套餐类型为轻享套餐,单位取值为 token。
|
|
7655
|
+
r"""<p>总额度上限。-1 表示不限,必须为 -1 或 >= API Key 当前的 ExclusiveQuota(独占额度),不传则不修改。单位说明如下:</p><ul><li>套餐类型为专业套餐,单位取值为积分;</li><li>套餐类型为轻享套餐,单位取值为 token。</li></ul>
|
|
7227
7656
|
:rtype: int
|
|
7228
7657
|
"""
|
|
7229
7658
|
return self._TotalQuota
|
|
@@ -7234,7 +7663,7 @@ class ModifyTokenPlanApiKeyRequest(AbstractModel):
|
|
|
7234
7663
|
|
|
7235
7664
|
@property
|
|
7236
7665
|
def UseStatus(self):
|
|
7237
|
-
r"""
|
|
7666
|
+
r"""<p>是否启用该 API Key。取值:enable(启用)、disable(停用),不传则不修改。</p>
|
|
7238
7667
|
:rtype: str
|
|
7239
7668
|
"""
|
|
7240
7669
|
return self._UseStatus
|
|
@@ -7245,7 +7674,7 @@ class ModifyTokenPlanApiKeyRequest(AbstractModel):
|
|
|
7245
7674
|
|
|
7246
7675
|
@property
|
|
7247
7676
|
def TPM(self):
|
|
7248
|
-
r"""TPM(Tokens Per Minute)限制。不传则不修改。必须
|
|
7677
|
+
r"""<p>TPM(Tokens Per Minute)限制。不传则不修改。必须 >= 0 且 <= 套餐 TPM。</p>
|
|
7249
7678
|
:rtype: int
|
|
7250
7679
|
"""
|
|
7251
7680
|
return self._TPM
|
|
@@ -7254,6 +7683,17 @@ class ModifyTokenPlanApiKeyRequest(AbstractModel):
|
|
|
7254
7683
|
def TPM(self, TPM):
|
|
7255
7684
|
self._TPM = TPM
|
|
7256
7685
|
|
|
7686
|
+
@property
|
|
7687
|
+
def IpWhitelist(self):
|
|
7688
|
+
r"""<p>IP 白名单列表。不传则不修改;传空数组表示清空(不限制 IP);传非空数组表示覆盖。支持 IPv4 单地址(如 1.2.3.4)和 IPv4 CIDR(如 10.0.0.0/24)格式,最多 50 个条目,不允许重复;不支持 IPv6 与 IP 范围。</p>
|
|
7689
|
+
:rtype: list of str
|
|
7690
|
+
"""
|
|
7691
|
+
return self._IpWhitelist
|
|
7692
|
+
|
|
7693
|
+
@IpWhitelist.setter
|
|
7694
|
+
def IpWhitelist(self, IpWhitelist):
|
|
7695
|
+
self._IpWhitelist = IpWhitelist
|
|
7696
|
+
|
|
7257
7697
|
|
|
7258
7698
|
def _deserialize(self, params):
|
|
7259
7699
|
self._ApiKeyId = params.get("ApiKeyId")
|
|
@@ -7262,6 +7702,7 @@ class ModifyTokenPlanApiKeyRequest(AbstractModel):
|
|
|
7262
7702
|
self._TotalQuota = params.get("TotalQuota")
|
|
7263
7703
|
self._UseStatus = params.get("UseStatus")
|
|
7264
7704
|
self._TPM = params.get("TPM")
|
|
7705
|
+
self._IpWhitelist = params.get("IpWhitelist")
|
|
7265
7706
|
memeber_set = set(params.keys())
|
|
7266
7707
|
for name, value in vars(self).items():
|
|
7267
7708
|
property_name = name[1:]
|
|
@@ -8287,40 +8728,44 @@ class TokenPlanApiKeyListItem(AbstractModel):
|
|
|
8287
8728
|
|
|
8288
8729
|
def __init__(self):
|
|
8289
8730
|
r"""
|
|
8290
|
-
:param _ApiKeyId: API Key ID
|
|
8731
|
+
:param _ApiKeyId: <p>API Key ID。</p>
|
|
8291
8732
|
:type ApiKeyId: str
|
|
8292
|
-
:param _ApiKey: API Key
|
|
8733
|
+
:param _ApiKey: <p>API Key 密钥值(脱敏)。</p>
|
|
8293
8734
|
:type ApiKey: str
|
|
8294
|
-
:param _Name: API Key
|
|
8735
|
+
:param _Name: <p>API Key 名称。</p>
|
|
8295
8736
|
:type Name: str
|
|
8296
|
-
:param _TeamId:
|
|
8737
|
+
:param _TeamId: <p>所属套餐 ID。</p>
|
|
8297
8738
|
:type TeamId: str
|
|
8298
|
-
:param _AppId:
|
|
8739
|
+
:param _AppId: <p>账号APP ID。</p>
|
|
8299
8740
|
:type AppId: str
|
|
8300
|
-
:param _Uin:
|
|
8741
|
+
:param _Uin: <p>主账号 UIN。最大 128 字符。</p>
|
|
8301
8742
|
:type Uin: str
|
|
8302
|
-
:param _AllowedModels: API Key 可用模型列表(JSON
|
|
8743
|
+
:param _AllowedModels: <p>API Key 可用模型列表(JSON 数组字符串)。</p>
|
|
8303
8744
|
:type AllowedModels: str
|
|
8304
|
-
:param _Status: API Key 是否可用。取值:enable(启用)、disable
|
|
8745
|
+
:param _Status: <p>API Key 是否可用。取值:enable(启用)、disable(停用)。</p>
|
|
8305
8746
|
:type Status: str
|
|
8306
|
-
:param _StopReason: API Key 停用原因。取值:NORMAL(正常,默认值),QUOTA_EXHAUSTED(API Key额度包耗尽),ABNORMAL
|
|
8747
|
+
:param _StopReason: <p>API Key 停用原因。取值:NORMAL(正常,默认值),QUOTA_EXHAUSTED(API Key额度包耗尽),ABNORMAL(异常,需人工介入)</p>
|
|
8307
8748
|
:type StopReason: str
|
|
8308
|
-
:param _UseStatus:
|
|
8749
|
+
:param _UseStatus: <p>用户侧开关。取值:enable(启用)、disable(停用)。</p>
|
|
8309
8750
|
:type UseStatus: str
|
|
8310
|
-
:param _KeyVersion:
|
|
8751
|
+
:param _KeyVersion: <p>密钥版本号。</p>
|
|
8311
8752
|
:type KeyVersion: int
|
|
8312
|
-
:param _LastRotatedAt:
|
|
8753
|
+
:param _LastRotatedAt: <p>最近一次重置时间。(ISO 8601)</p>
|
|
8313
8754
|
:type LastRotatedAt: str
|
|
8314
|
-
:param _Creator:
|
|
8755
|
+
:param _Creator: <p>创建人,如果是子账号创建,则该值为子账号UIN。</p>
|
|
8315
8756
|
:type Creator: str
|
|
8316
|
-
:param _CreatedAt:
|
|
8757
|
+
:param _CreatedAt: <p>创建时间。</p>
|
|
8317
8758
|
:type CreatedAt: str
|
|
8318
|
-
:param _UpdatedAt:
|
|
8759
|
+
:param _UpdatedAt: <p>更新时间。</p>
|
|
8319
8760
|
:type UpdatedAt: str
|
|
8320
|
-
:param _Balance: API Key
|
|
8761
|
+
:param _Balance: <p>API Key 额度用量信息</p>
|
|
8321
8762
|
:type Balance: :class:`tencentcloud.tokenhub.v20260322.models.SubPackageBalance`
|
|
8322
|
-
:param _ProductType:
|
|
8763
|
+
:param _ProductType: <p>套餐类型。取值:enterprise(企业版专业套餐)、enterprise-auto(企业版轻享套餐)。</p>
|
|
8323
8764
|
:type ProductType: str
|
|
8765
|
+
:param _IpWhitelist: <p>IP 白名单列表。支持 IPv4 单地址与 IPv4 CIDR 格式,空数组表示不限制。</p>
|
|
8766
|
+
:type IpWhitelist: list of str
|
|
8767
|
+
:param _OverageEnabled: <p>是否开启超额按量计费。开启后,若 APIKey 用量达到总额度上限,并且使用的模型已开启按量计费,将自动切换至按量计费模式;未开启时用量达上限后调用报错。</p>
|
|
8768
|
+
:type OverageEnabled: bool
|
|
8324
8769
|
"""
|
|
8325
8770
|
self._ApiKeyId = None
|
|
8326
8771
|
self._ApiKey = None
|
|
@@ -8339,10 +8784,12 @@ class TokenPlanApiKeyListItem(AbstractModel):
|
|
|
8339
8784
|
self._UpdatedAt = None
|
|
8340
8785
|
self._Balance = None
|
|
8341
8786
|
self._ProductType = None
|
|
8787
|
+
self._IpWhitelist = None
|
|
8788
|
+
self._OverageEnabled = None
|
|
8342
8789
|
|
|
8343
8790
|
@property
|
|
8344
8791
|
def ApiKeyId(self):
|
|
8345
|
-
r"""API Key ID
|
|
8792
|
+
r"""<p>API Key ID。</p>
|
|
8346
8793
|
:rtype: str
|
|
8347
8794
|
"""
|
|
8348
8795
|
return self._ApiKeyId
|
|
@@ -8353,7 +8800,7 @@ class TokenPlanApiKeyListItem(AbstractModel):
|
|
|
8353
8800
|
|
|
8354
8801
|
@property
|
|
8355
8802
|
def ApiKey(self):
|
|
8356
|
-
r"""API Key
|
|
8803
|
+
r"""<p>API Key 密钥值(脱敏)。</p>
|
|
8357
8804
|
:rtype: str
|
|
8358
8805
|
"""
|
|
8359
8806
|
return self._ApiKey
|
|
@@ -8364,7 +8811,7 @@ class TokenPlanApiKeyListItem(AbstractModel):
|
|
|
8364
8811
|
|
|
8365
8812
|
@property
|
|
8366
8813
|
def Name(self):
|
|
8367
|
-
r"""API Key
|
|
8814
|
+
r"""<p>API Key 名称。</p>
|
|
8368
8815
|
:rtype: str
|
|
8369
8816
|
"""
|
|
8370
8817
|
return self._Name
|
|
@@ -8375,7 +8822,7 @@ class TokenPlanApiKeyListItem(AbstractModel):
|
|
|
8375
8822
|
|
|
8376
8823
|
@property
|
|
8377
8824
|
def TeamId(self):
|
|
8378
|
-
r"""
|
|
8825
|
+
r"""<p>所属套餐 ID。</p>
|
|
8379
8826
|
:rtype: str
|
|
8380
8827
|
"""
|
|
8381
8828
|
return self._TeamId
|
|
@@ -8386,7 +8833,7 @@ class TokenPlanApiKeyListItem(AbstractModel):
|
|
|
8386
8833
|
|
|
8387
8834
|
@property
|
|
8388
8835
|
def AppId(self):
|
|
8389
|
-
r"""
|
|
8836
|
+
r"""<p>账号APP ID。</p>
|
|
8390
8837
|
:rtype: str
|
|
8391
8838
|
"""
|
|
8392
8839
|
return self._AppId
|
|
@@ -8397,7 +8844,7 @@ class TokenPlanApiKeyListItem(AbstractModel):
|
|
|
8397
8844
|
|
|
8398
8845
|
@property
|
|
8399
8846
|
def Uin(self):
|
|
8400
|
-
r"""
|
|
8847
|
+
r"""<p>主账号 UIN。最大 128 字符。</p>
|
|
8401
8848
|
:rtype: str
|
|
8402
8849
|
"""
|
|
8403
8850
|
return self._Uin
|
|
@@ -8408,7 +8855,7 @@ class TokenPlanApiKeyListItem(AbstractModel):
|
|
|
8408
8855
|
|
|
8409
8856
|
@property
|
|
8410
8857
|
def AllowedModels(self):
|
|
8411
|
-
r"""API Key 可用模型列表(JSON
|
|
8858
|
+
r"""<p>API Key 可用模型列表(JSON 数组字符串)。</p>
|
|
8412
8859
|
:rtype: str
|
|
8413
8860
|
"""
|
|
8414
8861
|
return self._AllowedModels
|
|
@@ -8419,7 +8866,7 @@ class TokenPlanApiKeyListItem(AbstractModel):
|
|
|
8419
8866
|
|
|
8420
8867
|
@property
|
|
8421
8868
|
def Status(self):
|
|
8422
|
-
r"""API Key 是否可用。取值:enable(启用)、disable
|
|
8869
|
+
r"""<p>API Key 是否可用。取值:enable(启用)、disable(停用)。</p>
|
|
8423
8870
|
:rtype: str
|
|
8424
8871
|
"""
|
|
8425
8872
|
return self._Status
|
|
@@ -8430,7 +8877,7 @@ class TokenPlanApiKeyListItem(AbstractModel):
|
|
|
8430
8877
|
|
|
8431
8878
|
@property
|
|
8432
8879
|
def StopReason(self):
|
|
8433
|
-
r"""API Key 停用原因。取值:NORMAL(正常,默认值),QUOTA_EXHAUSTED(API Key额度包耗尽),ABNORMAL
|
|
8880
|
+
r"""<p>API Key 停用原因。取值:NORMAL(正常,默认值),QUOTA_EXHAUSTED(API Key额度包耗尽),ABNORMAL(异常,需人工介入)</p>
|
|
8434
8881
|
:rtype: str
|
|
8435
8882
|
"""
|
|
8436
8883
|
return self._StopReason
|
|
@@ -8441,7 +8888,7 @@ class TokenPlanApiKeyListItem(AbstractModel):
|
|
|
8441
8888
|
|
|
8442
8889
|
@property
|
|
8443
8890
|
def UseStatus(self):
|
|
8444
|
-
r"""
|
|
8891
|
+
r"""<p>用户侧开关。取值:enable(启用)、disable(停用)。</p>
|
|
8445
8892
|
:rtype: str
|
|
8446
8893
|
"""
|
|
8447
8894
|
return self._UseStatus
|
|
@@ -8452,7 +8899,7 @@ class TokenPlanApiKeyListItem(AbstractModel):
|
|
|
8452
8899
|
|
|
8453
8900
|
@property
|
|
8454
8901
|
def KeyVersion(self):
|
|
8455
|
-
r"""
|
|
8902
|
+
r"""<p>密钥版本号。</p>
|
|
8456
8903
|
:rtype: int
|
|
8457
8904
|
"""
|
|
8458
8905
|
return self._KeyVersion
|
|
@@ -8463,7 +8910,7 @@ class TokenPlanApiKeyListItem(AbstractModel):
|
|
|
8463
8910
|
|
|
8464
8911
|
@property
|
|
8465
8912
|
def LastRotatedAt(self):
|
|
8466
|
-
r"""
|
|
8913
|
+
r"""<p>最近一次重置时间。(ISO 8601)</p>
|
|
8467
8914
|
:rtype: str
|
|
8468
8915
|
"""
|
|
8469
8916
|
return self._LastRotatedAt
|
|
@@ -8474,7 +8921,7 @@ class TokenPlanApiKeyListItem(AbstractModel):
|
|
|
8474
8921
|
|
|
8475
8922
|
@property
|
|
8476
8923
|
def Creator(self):
|
|
8477
|
-
r"""
|
|
8924
|
+
r"""<p>创建人,如果是子账号创建,则该值为子账号UIN。</p>
|
|
8478
8925
|
:rtype: str
|
|
8479
8926
|
"""
|
|
8480
8927
|
return self._Creator
|
|
@@ -8485,7 +8932,7 @@ class TokenPlanApiKeyListItem(AbstractModel):
|
|
|
8485
8932
|
|
|
8486
8933
|
@property
|
|
8487
8934
|
def CreatedAt(self):
|
|
8488
|
-
r"""
|
|
8935
|
+
r"""<p>创建时间。</p>
|
|
8489
8936
|
:rtype: str
|
|
8490
8937
|
"""
|
|
8491
8938
|
return self._CreatedAt
|
|
@@ -8496,7 +8943,7 @@ class TokenPlanApiKeyListItem(AbstractModel):
|
|
|
8496
8943
|
|
|
8497
8944
|
@property
|
|
8498
8945
|
def UpdatedAt(self):
|
|
8499
|
-
r"""
|
|
8946
|
+
r"""<p>更新时间。</p>
|
|
8500
8947
|
:rtype: str
|
|
8501
8948
|
"""
|
|
8502
8949
|
return self._UpdatedAt
|
|
@@ -8507,7 +8954,7 @@ class TokenPlanApiKeyListItem(AbstractModel):
|
|
|
8507
8954
|
|
|
8508
8955
|
@property
|
|
8509
8956
|
def Balance(self):
|
|
8510
|
-
r"""API Key
|
|
8957
|
+
r"""<p>API Key 额度用量信息</p>
|
|
8511
8958
|
:rtype: :class:`tencentcloud.tokenhub.v20260322.models.SubPackageBalance`
|
|
8512
8959
|
"""
|
|
8513
8960
|
return self._Balance
|
|
@@ -8518,7 +8965,7 @@ class TokenPlanApiKeyListItem(AbstractModel):
|
|
|
8518
8965
|
|
|
8519
8966
|
@property
|
|
8520
8967
|
def ProductType(self):
|
|
8521
|
-
r"""
|
|
8968
|
+
r"""<p>套餐类型。取值:enterprise(企业版专业套餐)、enterprise-auto(企业版轻享套餐)。</p>
|
|
8522
8969
|
:rtype: str
|
|
8523
8970
|
"""
|
|
8524
8971
|
return self._ProductType
|
|
@@ -8527,6 +8974,28 @@ class TokenPlanApiKeyListItem(AbstractModel):
|
|
|
8527
8974
|
def ProductType(self, ProductType):
|
|
8528
8975
|
self._ProductType = ProductType
|
|
8529
8976
|
|
|
8977
|
+
@property
|
|
8978
|
+
def IpWhitelist(self):
|
|
8979
|
+
r"""<p>IP 白名单列表。支持 IPv4 单地址与 IPv4 CIDR 格式,空数组表示不限制。</p>
|
|
8980
|
+
:rtype: list of str
|
|
8981
|
+
"""
|
|
8982
|
+
return self._IpWhitelist
|
|
8983
|
+
|
|
8984
|
+
@IpWhitelist.setter
|
|
8985
|
+
def IpWhitelist(self, IpWhitelist):
|
|
8986
|
+
self._IpWhitelist = IpWhitelist
|
|
8987
|
+
|
|
8988
|
+
@property
|
|
8989
|
+
def OverageEnabled(self):
|
|
8990
|
+
r"""<p>是否开启超额按量计费。开启后,若 APIKey 用量达到总额度上限,并且使用的模型已开启按量计费,将自动切换至按量计费模式;未开启时用量达上限后调用报错。</p>
|
|
8991
|
+
:rtype: bool
|
|
8992
|
+
"""
|
|
8993
|
+
return self._OverageEnabled
|
|
8994
|
+
|
|
8995
|
+
@OverageEnabled.setter
|
|
8996
|
+
def OverageEnabled(self, OverageEnabled):
|
|
8997
|
+
self._OverageEnabled = OverageEnabled
|
|
8998
|
+
|
|
8530
8999
|
|
|
8531
9000
|
def _deserialize(self, params):
|
|
8532
9001
|
self._ApiKeyId = params.get("ApiKeyId")
|
|
@@ -8548,6 +9017,8 @@ class TokenPlanApiKeyListItem(AbstractModel):
|
|
|
8548
9017
|
self._Balance = SubPackageBalance()
|
|
8549
9018
|
self._Balance._deserialize(params.get("Balance"))
|
|
8550
9019
|
self._ProductType = params.get("ProductType")
|
|
9020
|
+
self._IpWhitelist = params.get("IpWhitelist")
|
|
9021
|
+
self._OverageEnabled = params.get("OverageEnabled")
|
|
8551
9022
|
memeber_set = set(params.keys())
|
|
8552
9023
|
for name, value in vars(self).items():
|
|
8553
9024
|
property_name = name[1:]
|
|
@@ -52,9 +52,7 @@ class TokenhubClient(AbstractClient):
|
|
|
52
52
|
|
|
53
53
|
|
|
54
54
|
def CreateEndpoint(self, request):
|
|
55
|
-
r"""
|
|
56
|
-
|
|
57
|
-
创建一个在线推理服务,创建成功后返回推理服务 ID。
|
|
55
|
+
r"""创建推理服务,并可指定所属企业空间。不传 WorkspaceId 时,推理服务会创建在账号默认空间。
|
|
58
56
|
|
|
59
57
|
:param request: Request instance for CreateEndpoint.
|
|
60
58
|
:type request: :class:`tencentcloud.tokenhub.v20260322.models.CreateEndpointRequest`
|
|
@@ -646,6 +644,31 @@ class TokenhubClient(AbstractClient):
|
|
|
646
644
|
raise TencentCloudSDKException(type(e).__name__, str(e))
|
|
647
645
|
|
|
648
646
|
|
|
647
|
+
def DescribeTokenPlanPersonalPackage(self, request):
|
|
648
|
+
r"""查询个人版套餐详情。
|
|
649
|
+
|
|
650
|
+
查询指定产品类型的个人版 Token Plan 套餐状态、额度及续费信息。
|
|
651
|
+
|
|
652
|
+
:param request: Request instance for DescribeTokenPlanPersonalPackage.
|
|
653
|
+
:type request: :class:`tencentcloud.tokenhub.v20260322.models.DescribeTokenPlanPersonalPackageRequest`
|
|
654
|
+
:rtype: :class:`tencentcloud.tokenhub.v20260322.models.DescribeTokenPlanPersonalPackageResponse`
|
|
655
|
+
|
|
656
|
+
"""
|
|
657
|
+
try:
|
|
658
|
+
params = request._serialize()
|
|
659
|
+
headers = request.headers
|
|
660
|
+
body = self.call("DescribeTokenPlanPersonalPackage", params, headers=headers)
|
|
661
|
+
response = json.loads(body)
|
|
662
|
+
model = models.DescribeTokenPlanPersonalPackageResponse()
|
|
663
|
+
model._deserialize(response["Response"])
|
|
664
|
+
return model
|
|
665
|
+
except Exception as e:
|
|
666
|
+
if isinstance(e, TencentCloudSDKException):
|
|
667
|
+
raise
|
|
668
|
+
else:
|
|
669
|
+
raise TencentCloudSDKException(type(e).__name__, str(e))
|
|
670
|
+
|
|
671
|
+
|
|
649
672
|
def DescribeUsageRankList(self, request):
|
|
650
673
|
r"""查询用量排行列表。
|
|
651
674
|
|
|
@@ -51,9 +51,7 @@ class TokenhubClient(AbstractClient):
|
|
|
51
51
|
opts: Dict = None,
|
|
52
52
|
) -> models.CreateEndpointResponse:
|
|
53
53
|
"""
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
创建一个在线推理服务,创建成功后返回推理服务 ID。
|
|
54
|
+
创建推理服务,并可指定所属企业空间。不传 WorkspaceId 时,推理服务会创建在账号默认空间。
|
|
57
55
|
"""
|
|
58
56
|
|
|
59
57
|
kwargs = {}
|
|
@@ -520,6 +518,26 @@ class TokenhubClient(AbstractClient):
|
|
|
520
518
|
|
|
521
519
|
return await self.call_and_deserialize(**kwargs)
|
|
522
520
|
|
|
521
|
+
async def DescribeTokenPlanPersonalPackage(
|
|
522
|
+
self,
|
|
523
|
+
request: models.DescribeTokenPlanPersonalPackageRequest,
|
|
524
|
+
opts: Dict = None,
|
|
525
|
+
) -> models.DescribeTokenPlanPersonalPackageResponse:
|
|
526
|
+
"""
|
|
527
|
+
查询个人版套餐详情。
|
|
528
|
+
|
|
529
|
+
查询指定产品类型的个人版 Token Plan 套餐状态、额度及续费信息。
|
|
530
|
+
"""
|
|
531
|
+
|
|
532
|
+
kwargs = {}
|
|
533
|
+
kwargs["action"] = "DescribeTokenPlanPersonalPackage"
|
|
534
|
+
kwargs["params"] = request._serialize()
|
|
535
|
+
kwargs["resp_cls"] = models.DescribeTokenPlanPersonalPackageResponse
|
|
536
|
+
kwargs["headers"] = request.headers
|
|
537
|
+
kwargs["opts"] = opts or {}
|
|
538
|
+
|
|
539
|
+
return await self.call_and_deserialize(**kwargs)
|
|
540
|
+
|
|
523
541
|
async def DescribeUsageRankList(
|
|
524
542
|
self,
|
|
525
543
|
request: models.DescribeUsageRankListRequest,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: tencentcloud-sdk-python-tokenhub
|
|
3
|
-
Version: 3.1.
|
|
3
|
+
Version: 3.1.214
|
|
4
4
|
Summary: Tencent Cloud Tokenhub SDK for Python
|
|
5
5
|
Home-page: https://github.com/TencentCloud/tencentcloud-sdk-python
|
|
6
6
|
Author: Tencent Cloud
|
|
@@ -15,7 +15,7 @@ Classifier: Programming Language :: Python :: 2.7
|
|
|
15
15
|
Classifier: Programming Language :: Python :: 3
|
|
16
16
|
Classifier: Programming Language :: Python :: 3.6
|
|
17
17
|
Classifier: Programming Language :: Python :: 3.7
|
|
18
|
-
Requires-Dist: tencentcloud-sdk-python-common <4.0.0,>=3.1.
|
|
18
|
+
Requires-Dist: tencentcloud-sdk-python-common <4.0.0,>=3.1.214
|
|
19
19
|
|
|
20
20
|
============================
|
|
21
21
|
Tencent Cloud SDK for Python
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
tencentcloud/__init__.py,sha256=rBlZ2ZU5lghyUPB6pRsndOEDAD_nmlsTl0qSIYozpG0,630
|
|
2
|
+
tencentcloud/tokenhub/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
3
|
+
tencentcloud/tokenhub/v20260322/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
4
|
+
tencentcloud/tokenhub/v20260322/errorcodes.py,sha256=PbXuAwOFyrrqNktUv8iAHg_58Cr07sMxORM3XD1ubIA,5205
|
|
5
|
+
tencentcloud/tokenhub/v20260322/models.py,sha256=kNKNqSMZ5SfYITKZFvUWVX7BJqHQN2KsPNvK_khsIqo,342547
|
|
6
|
+
tencentcloud/tokenhub/v20260322/tokenhub_client.py,sha256=Yw-MXi3JPt2nzhSxZH8BmdAl-aEFNdOLROpjthjs45w,40031
|
|
7
|
+
tencentcloud/tokenhub/v20260322/tokenhub_client_async.py,sha256=eRXMP8Ps9sp4D2z6WHFhYYINADXORDiscRnjUzEHoqM,28702
|
|
8
|
+
tencentcloud_sdk_python_tokenhub-3.1.214.dist-info/METADATA,sha256=G27iBeSGegfpy5wkKAS2yLUZm8C4r3mSbzDn9yyDBgk,1522
|
|
9
|
+
tencentcloud_sdk_python_tokenhub-3.1.214.dist-info/WHEEL,sha256=a5ogxI61vGGBHYbAAwISCXsfU7mxKr76gTpCEmSNOI8,109
|
|
10
|
+
tencentcloud_sdk_python_tokenhub-3.1.214.dist-info/top_level.txt,sha256=g-8OyzoqI6O6LiS85zkeNzhB-osEnRIPZMdyRd_0eL0,13
|
|
11
|
+
tencentcloud_sdk_python_tokenhub-3.1.214.dist-info/RECORD,,
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
tencentcloud/__init__.py,sha256=aisXuvVz8-xZ1rwMQjGx8uh3qhHgjdp1v9KtQxSFpH0,630
|
|
2
|
-
tencentcloud/tokenhub/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
3
|
-
tencentcloud/tokenhub/v20260322/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
4
|
-
tencentcloud/tokenhub/v20260322/errorcodes.py,sha256=PbXuAwOFyrrqNktUv8iAHg_58Cr07sMxORM3XD1ubIA,5205
|
|
5
|
-
tencentcloud/tokenhub/v20260322/models.py,sha256=z1ocFON91Jn7C0eRwyQEs7j9rdHnuD-2gXpuQynix2k,323034
|
|
6
|
-
tencentcloud/tokenhub/v20260322/tokenhub_client.py,sha256=0KPbo6zIRxoVRzFsHJOAMLsk-YarIdgfE0Y-MO-XjPk,38931
|
|
7
|
-
tencentcloud/tokenhub/v20260322/tokenhub_client_async.py,sha256=lTQg0izdRrv4Rsq8NhD3Ana2LTIpfno-10sW1eKsWCc,27926
|
|
8
|
-
tencentcloud_sdk_python_tokenhub-3.1.205.dist-info/METADATA,sha256=AS5IbSbN0av0PXhwI71s6WUcI7lSZt6bOeraaZkQ0fY,1522
|
|
9
|
-
tencentcloud_sdk_python_tokenhub-3.1.205.dist-info/WHEEL,sha256=a5ogxI61vGGBHYbAAwISCXsfU7mxKr76gTpCEmSNOI8,109
|
|
10
|
-
tencentcloud_sdk_python_tokenhub-3.1.205.dist-info/top_level.txt,sha256=g-8OyzoqI6O6LiS85zkeNzhB-osEnRIPZMdyRd_0eL0,13
|
|
11
|
-
tencentcloud_sdk_python_tokenhub-3.1.205.dist-info/RECORD,,
|
|
File without changes
|