tencentcloud-sdk-nodejs-tcbr 4.0.1041 → 4.1.20
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.
- package/README.md +27 -5
- package/es/index.js +1 -0
- package/es/services/index.js +1 -0
- package/es/services/tcbr/index.js +4 -0
- package/es/services/tcbr/v20220217/index.js +6 -0
- package/es/services/tcbr/v20220217/tcbr_client.js +36 -0
- package/es/services/tcbr/v20220217/tcbr_models.js +0 -0
- package/package.json +26 -8
- package/tencentcloud/services/tcbr/v20220217/index.js +2 -1
- package/tencentcloud/services/tcbr/v20220217/tcbr_client.js +2 -1
- package/tencentcloud/services/tcbr/v20220217/tcbr_models.d.ts +4 -0
- package/index.d.ts +0 -2
- package/index.js +0 -6
- package/prettier.config.js +0 -38
- package/src/index.ts +0 -1
- package/src/services/index.ts +0 -1
- package/src/services/tcbr/index.ts +0 -5
- package/src/services/tcbr/v20220217/index.ts +0 -6
- package/src/services/tcbr/v20220217/tcbr_client.ts +0 -170
- package/src/services/tcbr/v20220217/tcbr_models.ts +0 -1093
- package/tsconfig.json +0 -33
- package/typings/index.d.ts +0 -2
package/README.md
CHANGED
|
@@ -44,18 +44,40 @@ npm install tencentcloud-sdk-nodejs-vpc --save
|
|
|
44
44
|
|
|
45
45
|
### 安装全产品 SDK
|
|
46
46
|
|
|
47
|
+
如果项目依赖的云产品较多,可以引入全产品 SDK。
|
|
48
|
+
|
|
47
49
|
```
|
|
48
50
|
npm install tencentcloud-sdk-nodejs --save
|
|
49
51
|
```
|
|
50
52
|
|
|
51
|
-
全产品 SDK
|
|
53
|
+
全产品 SDK 包含所有云产品调用代码和 TypeScript 类型文件,体积偏大。对于体积敏感的场景,推荐安装指定产品 SDK。
|
|
54
|
+
|
|
55
|
+
如果既希望全产品调用,又对包体积比较敏感,可以使用 Slim 版本 SDK。Slim SDK 移除类型文件,并进行了代码压缩,适合体积敏感场景使用:
|
|
56
|
+
|
|
57
|
+
```
|
|
58
|
+
npm install tencentcloud-sdk-slim-nodejs --save
|
|
59
|
+
```
|
|
52
60
|
|
|
53
61
|
## 通过源码包安装
|
|
54
62
|
|
|
55
|
-
1.
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
63
|
+
1. clone 代码到本地:
|
|
64
|
+
```
|
|
65
|
+
git clone https://github.com/tencentcloud/tencentcloud-sdk-nodejs
|
|
66
|
+
# 或者
|
|
67
|
+
git clone https://gitee.com/tencentcloud/tencentcloud-sdk-nodejs
|
|
68
|
+
```
|
|
69
|
+
2. 在项目根目录执行以下命令完成构建:
|
|
70
|
+
```
|
|
71
|
+
npm install && npm run build
|
|
72
|
+
```
|
|
73
|
+
3. 打包 NPM 压缩文件,例如 `tencentcloud-sdk-nodejs-4.0.0.tgz`
|
|
74
|
+
```
|
|
75
|
+
npm pack
|
|
76
|
+
```
|
|
77
|
+
4. 安装包到你的项目里:
|
|
78
|
+
```
|
|
79
|
+
npm install /path/to/tencentcloud-sdk-nodejs/tencentcloud-sdk-nodejs-4.0.0.tgz
|
|
80
|
+
```
|
|
59
81
|
|
|
60
82
|
# 示例
|
|
61
83
|
|
package/es/index.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./services";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { tcbr } from "./tcbr";
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import * as TencentCloudCommon from "tencentcloud-sdk-nodejs-common";
|
|
2
|
+
export class Client extends TencentCloudCommon.AbstractClient {
|
|
3
|
+
constructor(clientConfig) {
|
|
4
|
+
super("tcbr.tencentcloudapi.com", "2022-02-17", clientConfig);
|
|
5
|
+
}
|
|
6
|
+
async CreateCloudRunServer(req, cb) {
|
|
7
|
+
return this.request("CreateCloudRunServer", req, cb);
|
|
8
|
+
}
|
|
9
|
+
async DescribeServerManageTask(req, cb) {
|
|
10
|
+
return this.request("DescribeServerManageTask", req, cb);
|
|
11
|
+
}
|
|
12
|
+
async DescribeEnvBaseInfo(req, cb) {
|
|
13
|
+
return this.request("DescribeEnvBaseInfo", req, cb);
|
|
14
|
+
}
|
|
15
|
+
async DescribeCloudRunServers(req, cb) {
|
|
16
|
+
return this.request("DescribeCloudRunServers", req, cb);
|
|
17
|
+
}
|
|
18
|
+
async ReleaseGray(req, cb) {
|
|
19
|
+
return this.request("ReleaseGray", req, cb);
|
|
20
|
+
}
|
|
21
|
+
async UpdateCloudRunServer(req, cb) {
|
|
22
|
+
return this.request("UpdateCloudRunServer", req, cb);
|
|
23
|
+
}
|
|
24
|
+
async CreateCloudRunEnv(req, cb) {
|
|
25
|
+
return this.request("CreateCloudRunEnv", req, cb);
|
|
26
|
+
}
|
|
27
|
+
async DescribeCloudRunEnvs(req, cb) {
|
|
28
|
+
return this.request("DescribeCloudRunEnvs", req, cb);
|
|
29
|
+
}
|
|
30
|
+
async OperateServerManage(req, cb) {
|
|
31
|
+
return this.request("OperateServerManage", req, cb);
|
|
32
|
+
}
|
|
33
|
+
async DescribeCloudRunServerDetail(req, cb) {
|
|
34
|
+
return this.request("DescribeCloudRunServerDetail", req, cb);
|
|
35
|
+
}
|
|
36
|
+
}
|
|
File without changes
|
package/package.json
CHANGED
|
@@ -1,16 +1,26 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "tencentcloud-sdk-nodejs-tcbr",
|
|
3
|
-
"version": "4.
|
|
4
|
-
"description": "
|
|
5
|
-
"main": "tencentcloud/index.js",
|
|
3
|
+
"version": "4.1.20",
|
|
4
|
+
"description": "腾讯云 API NODEJS SDK",
|
|
5
|
+
"main": "./tencentcloud/index.js",
|
|
6
|
+
"module": "./es/index.js",
|
|
7
|
+
"types": "./tencentcloud/index.d.ts",
|
|
6
8
|
"scripts": {
|
|
7
9
|
"test": "mocha -t 10000",
|
|
8
|
-
"build": "
|
|
9
|
-
"
|
|
10
|
+
"build": "concurrently 'npm:build:cjs' 'npm:build:es'",
|
|
11
|
+
"build:cjs": "tsc -p tsconfig.json",
|
|
12
|
+
"build:es": "tsc -p tsconfig.es.json",
|
|
13
|
+
"build:slim": "node ./scripts/build_slim.js",
|
|
14
|
+
"prettier": "prettier --config prettier.config.js --write 'src/**/*.{tsx,ts,jsx,js,css,json,vue}'",
|
|
15
|
+
"clean": "rimraf tencentcloud es"
|
|
10
16
|
},
|
|
11
17
|
"engines": {
|
|
12
18
|
"node": ">=10"
|
|
13
19
|
},
|
|
20
|
+
"files": [
|
|
21
|
+
"tencentcloud",
|
|
22
|
+
"es"
|
|
23
|
+
],
|
|
14
24
|
"keywords": [
|
|
15
25
|
"tencentcloudapi",
|
|
16
26
|
"tencentcloud",
|
|
@@ -22,7 +32,7 @@
|
|
|
22
32
|
"author": "tencentcloudapi",
|
|
23
33
|
"license": "Apache-2.0",
|
|
24
34
|
"dependencies": {
|
|
25
|
-
"tencentcloud-sdk-nodejs-common": "
|
|
35
|
+
"tencentcloud-sdk-nodejs-common": "*",
|
|
26
36
|
"tslib": "1.13.0"
|
|
27
37
|
},
|
|
28
38
|
"directories": {
|
|
@@ -35,14 +45,22 @@
|
|
|
35
45
|
},
|
|
36
46
|
"devDependencies": {
|
|
37
47
|
"@types/form-data": "^2.5.0",
|
|
48
|
+
"@types/json-bigint": "^1.0.1",
|
|
38
49
|
"@types/node": "^14.0.26",
|
|
39
50
|
"@types/node-fetch": "^2.5.7",
|
|
51
|
+
"@types/uuid": "^9.0.8",
|
|
40
52
|
"@typescript-eslint/eslint-plugin": "^2.34.0",
|
|
41
53
|
"@typescript-eslint/parser": "^2.34.0",
|
|
54
|
+
"babel-eslint": "^10.0.2",
|
|
42
55
|
"chai": "^4.2.0",
|
|
56
|
+
"concurrently": "^6.5.1",
|
|
57
|
+
"esbuild": "^0.25.0",
|
|
43
58
|
"eslint": "^6.8.0",
|
|
44
|
-
"
|
|
59
|
+
"eslint-plugin-react": "^7.17.0",
|
|
60
|
+
"mocha": "^8.4.0",
|
|
61
|
+
"prettier": "^2.3.0",
|
|
62
|
+
"rimraf": "^5.0.10",
|
|
45
63
|
"ts-node": "^8.10.2",
|
|
46
64
|
"typescript": "^3.9.7"
|
|
47
65
|
}
|
|
48
|
-
}
|
|
66
|
+
}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.v20220217 = void 0;
|
|
4
|
-
const
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const Models = tslib_1.__importStar(require("./tcbr_models"));
|
|
5
6
|
const tcbr_client_1 = require("./tcbr_client");
|
|
6
7
|
exports.v20220217 = {
|
|
7
8
|
Client: tcbr_client_1.Client,
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.Client = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
4
5
|
/* eslint-disable @typescript-eslint/no-unused-vars */
|
|
5
6
|
/*
|
|
6
7
|
* Copyright (c) 2018 THL A29 Limited, a Tencent company. All Rights Reserved.
|
|
@@ -18,7 +19,7 @@ exports.Client = void 0;
|
|
|
18
19
|
* specific language governing permissions and limitations
|
|
19
20
|
* under the License.
|
|
20
21
|
*/
|
|
21
|
-
const TencentCloudCommon = require("tencentcloud-sdk-nodejs-common");
|
|
22
|
+
const TencentCloudCommon = tslib_1.__importStar(require("tencentcloud-sdk-nodejs-common"));
|
|
22
23
|
/**
|
|
23
24
|
* tcbr client
|
|
24
25
|
* @class
|
package/index.d.ts
DELETED
package/index.js
DELETED
package/prettier.config.js
DELETED
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
// prettier.config.js
|
|
2
|
-
module.exports = {
|
|
3
|
-
// 一行最多 100 字符
|
|
4
|
-
printWidth: 100,
|
|
5
|
-
// 使用 4 个空格缩进
|
|
6
|
-
tabWidth: 2,
|
|
7
|
-
// 不使用缩进符,而使用空格
|
|
8
|
-
useTabs: false,
|
|
9
|
-
// 行尾需要有分号
|
|
10
|
-
semi: false,
|
|
11
|
-
// 使用单引号
|
|
12
|
-
singleQuote: false,
|
|
13
|
-
// 对象的 key 仅在必要时用引号
|
|
14
|
-
quoteProps: "as-needed",
|
|
15
|
-
// jsx 不使用单引号,而使用双引号
|
|
16
|
-
jsxSingleQuote: false,
|
|
17
|
-
// 末尾不需要逗号
|
|
18
|
-
trailingComma: "es5",
|
|
19
|
-
// 大括号内的首尾需要空格
|
|
20
|
-
bracketSpacing: true,
|
|
21
|
-
// jsx 标签的反尖括号需要换行
|
|
22
|
-
jsxBracketSameLine: false,
|
|
23
|
-
// 箭头函数,只有一个参数的时候,也需要括号
|
|
24
|
-
arrowParens: "always",
|
|
25
|
-
// 每个文件格式化的范围是文件的全部内容
|
|
26
|
-
rangeStart: 0,
|
|
27
|
-
rangeEnd: Infinity,
|
|
28
|
-
// 不需要写文件开头的 @prettier
|
|
29
|
-
requirePragma: false,
|
|
30
|
-
// 不需要自动在文件开头插入 @prettier
|
|
31
|
-
insertPragma: false,
|
|
32
|
-
// 使用默认的折行标准
|
|
33
|
-
proseWrap: "preserve",
|
|
34
|
-
// 根据显示样式决定 html 要不要折行
|
|
35
|
-
htmlWhitespaceSensitivity: "css",
|
|
36
|
-
// 换行符使用 lf
|
|
37
|
-
endOfLine: "lf",
|
|
38
|
-
}
|
package/src/index.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "./services"
|
package/src/services/index.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { tcbr } from "./tcbr"
|
|
@@ -1,170 +0,0 @@
|
|
|
1
|
-
/* eslint-disable @typescript-eslint/no-unused-vars */
|
|
2
|
-
/*
|
|
3
|
-
* Copyright (c) 2018 THL A29 Limited, a Tencent company. All Rights Reserved.
|
|
4
|
-
*
|
|
5
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
-
* you may not use this file except in compliance with the License.
|
|
7
|
-
* You may obtain a copy of the License at
|
|
8
|
-
*
|
|
9
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
-
*
|
|
11
|
-
* Unless required by applicable law or agreed to in writing,
|
|
12
|
-
* software distributed under the License is distributed on an
|
|
13
|
-
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
14
|
-
* KIND, either express or implied. See the License for the
|
|
15
|
-
* specific language governing permissions and limitations
|
|
16
|
-
* under the License.
|
|
17
|
-
*/
|
|
18
|
-
import * as TencentCloudCommon from "tencentcloud-sdk-nodejs-common"
|
|
19
|
-
import {
|
|
20
|
-
DescribeCloudRunServersResponse,
|
|
21
|
-
RepositoryInfo,
|
|
22
|
-
ReleaseGrayRequest,
|
|
23
|
-
StorageInfo,
|
|
24
|
-
DescribeEnvBaseInfoResponse,
|
|
25
|
-
CreateCloudRunServerRequest,
|
|
26
|
-
FunctionInfo,
|
|
27
|
-
DescribeServerManageTaskResponse,
|
|
28
|
-
TaskStepInfo,
|
|
29
|
-
DescribeCloudRunEnvsResponse,
|
|
30
|
-
DescribeCloudRunEnvsRequest,
|
|
31
|
-
ReleaseGrayResponse,
|
|
32
|
-
DeployParam,
|
|
33
|
-
OperateServerManageRequest,
|
|
34
|
-
StaticStorageInfo,
|
|
35
|
-
UpdateCloudRunServerRequest,
|
|
36
|
-
LogServiceInfo,
|
|
37
|
-
OperateServerManageResponse,
|
|
38
|
-
DescribeCloudRunServerDetailRequest,
|
|
39
|
-
DatabasesInfo,
|
|
40
|
-
DescribeCloudRunServersRequest,
|
|
41
|
-
ClsInfo,
|
|
42
|
-
DescribeServerManageTaskRequest,
|
|
43
|
-
HpaPolicy,
|
|
44
|
-
OnlineVersionInfo,
|
|
45
|
-
ServerBaseConfig,
|
|
46
|
-
DescribeCloudRunServerDetailResponse,
|
|
47
|
-
CreateCloudRunEnvResponse,
|
|
48
|
-
EnvBaseInfo,
|
|
49
|
-
ServerBaseInfo,
|
|
50
|
-
EnvInfo,
|
|
51
|
-
Tag,
|
|
52
|
-
DescribeEnvBaseInfoRequest,
|
|
53
|
-
CreateCloudRunServerResponse,
|
|
54
|
-
VersionFlowInfo,
|
|
55
|
-
UpdateCloudRunServerResponse,
|
|
56
|
-
ObjectKV,
|
|
57
|
-
BuildPacksInfo,
|
|
58
|
-
CreateCloudRunEnvRequest,
|
|
59
|
-
ServerManageTaskInfo,
|
|
60
|
-
} from "./tcbr_models"
|
|
61
|
-
|
|
62
|
-
/**
|
|
63
|
-
* tcbr client
|
|
64
|
-
* @class
|
|
65
|
-
*/
|
|
66
|
-
export class Client extends TencentCloudCommon.AbstractClient {
|
|
67
|
-
constructor(clientConfig: TencentCloudCommon.ClientConfig) {
|
|
68
|
-
super("tcbr.tencentcloudapi.com", "2022-02-17", clientConfig)
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
/**
|
|
72
|
-
* 创建云托管服务接口
|
|
73
|
-
*/
|
|
74
|
-
async CreateCloudRunServer(
|
|
75
|
-
req: CreateCloudRunServerRequest,
|
|
76
|
-
cb?: (error: string, rep: CreateCloudRunServerResponse) => void
|
|
77
|
-
): Promise<CreateCloudRunServerResponse> {
|
|
78
|
-
return this.request("CreateCloudRunServer", req, cb)
|
|
79
|
-
}
|
|
80
|
-
|
|
81
|
-
/**
|
|
82
|
-
* 查询服务管理任务信息
|
|
83
|
-
*/
|
|
84
|
-
async DescribeServerManageTask(
|
|
85
|
-
req: DescribeServerManageTaskRequest,
|
|
86
|
-
cb?: (error: string, rep: DescribeServerManageTaskResponse) => void
|
|
87
|
-
): Promise<DescribeServerManageTaskResponse> {
|
|
88
|
-
return this.request("DescribeServerManageTask", req, cb)
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
/**
|
|
92
|
-
* 查询环境基础信息
|
|
93
|
-
*/
|
|
94
|
-
async DescribeEnvBaseInfo(
|
|
95
|
-
req: DescribeEnvBaseInfoRequest,
|
|
96
|
-
cb?: (error: string, rep: DescribeEnvBaseInfoResponse) => void
|
|
97
|
-
): Promise<DescribeEnvBaseInfoResponse> {
|
|
98
|
-
return this.request("DescribeEnvBaseInfo", req, cb)
|
|
99
|
-
}
|
|
100
|
-
|
|
101
|
-
/**
|
|
102
|
-
* 查询云托管服务列表接口
|
|
103
|
-
*/
|
|
104
|
-
async DescribeCloudRunServers(
|
|
105
|
-
req: DescribeCloudRunServersRequest,
|
|
106
|
-
cb?: (error: string, rep: DescribeCloudRunServersResponse) => void
|
|
107
|
-
): Promise<DescribeCloudRunServersResponse> {
|
|
108
|
-
return this.request("DescribeCloudRunServers", req, cb)
|
|
109
|
-
}
|
|
110
|
-
|
|
111
|
-
/**
|
|
112
|
-
* 灰度发布
|
|
113
|
-
*/
|
|
114
|
-
async ReleaseGray(
|
|
115
|
-
req: ReleaseGrayRequest,
|
|
116
|
-
cb?: (error: string, rep: ReleaseGrayResponse) => void
|
|
117
|
-
): Promise<ReleaseGrayResponse> {
|
|
118
|
-
return this.request("ReleaseGray", req, cb)
|
|
119
|
-
}
|
|
120
|
-
|
|
121
|
-
/**
|
|
122
|
-
* 更新云托管服务
|
|
123
|
-
*/
|
|
124
|
-
async UpdateCloudRunServer(
|
|
125
|
-
req: UpdateCloudRunServerRequest,
|
|
126
|
-
cb?: (error: string, rep: UpdateCloudRunServerResponse) => void
|
|
127
|
-
): Promise<UpdateCloudRunServerResponse> {
|
|
128
|
-
return this.request("UpdateCloudRunServer", req, cb)
|
|
129
|
-
}
|
|
130
|
-
|
|
131
|
-
/**
|
|
132
|
-
* 创建云托管环境,并开通资源。
|
|
133
|
-
*/
|
|
134
|
-
async CreateCloudRunEnv(
|
|
135
|
-
req: CreateCloudRunEnvRequest,
|
|
136
|
-
cb?: (error: string, rep: CreateCloudRunEnvResponse) => void
|
|
137
|
-
): Promise<CreateCloudRunEnvResponse> {
|
|
138
|
-
return this.request("CreateCloudRunEnv", req, cb)
|
|
139
|
-
}
|
|
140
|
-
|
|
141
|
-
/**
|
|
142
|
-
* 获取环境列表,含环境下的各个资源信息。尤其是各资源的唯一标识,是请求各资源的关键参数
|
|
143
|
-
*/
|
|
144
|
-
async DescribeCloudRunEnvs(
|
|
145
|
-
req: DescribeCloudRunEnvsRequest,
|
|
146
|
-
cb?: (error: string, rep: DescribeCloudRunEnvsResponse) => void
|
|
147
|
-
): Promise<DescribeCloudRunEnvsResponse> {
|
|
148
|
-
return this.request("DescribeCloudRunEnvs", req, cb)
|
|
149
|
-
}
|
|
150
|
-
|
|
151
|
-
/**
|
|
152
|
-
* 操作发布单
|
|
153
|
-
*/
|
|
154
|
-
async OperateServerManage(
|
|
155
|
-
req: OperateServerManageRequest,
|
|
156
|
-
cb?: (error: string, rep: OperateServerManageResponse) => void
|
|
157
|
-
): Promise<OperateServerManageResponse> {
|
|
158
|
-
return this.request("OperateServerManage", req, cb)
|
|
159
|
-
}
|
|
160
|
-
|
|
161
|
-
/**
|
|
162
|
-
* 查询云托管服务详情
|
|
163
|
-
*/
|
|
164
|
-
async DescribeCloudRunServerDetail(
|
|
165
|
-
req: DescribeCloudRunServerDetailRequest,
|
|
166
|
-
cb?: (error: string, rep: DescribeCloudRunServerDetailResponse) => void
|
|
167
|
-
): Promise<DescribeCloudRunServerDetailResponse> {
|
|
168
|
-
return this.request("DescribeCloudRunServerDetail", req, cb)
|
|
169
|
-
}
|
|
170
|
-
}
|