@alicloud/aliding20230426 1.0.0

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/LICENSE ADDED
@@ -0,0 +1,13 @@
1
+ Copyright (c) 2009-present, Alibaba Cloud All rights reserved.
2
+
3
+ Licensed under the Apache License, Version 2.0 (the "License");
4
+ you may not use this file except in compliance with the License.
5
+ You may obtain a copy of the License at
6
+
7
+ http://www.apache.org/licenses/LICENSE-2.0
8
+
9
+ Unless required by applicable law or agreed to in writing, software
10
+ distributed under the License is distributed on an "AS IS" BASIS,
11
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
+ See the License for the specific language governing permissions and
13
+ limitations under the License.
package/README.md ADDED
@@ -0,0 +1,25 @@
1
+ English | [简体中文](README-CN.md)
2
+ ![](https://aliyunsdk-pages.alicdn.com/icons/AlibabaCloud.svg)
3
+
4
+ # Alibaba Cloud aliding SDK for NodeJS
5
+
6
+ ## Installation
7
+ If you use `npm` to manage your dependence, you can use the following command:
8
+
9
+ ```sh
10
+ npm install @alicloud/aliding20230426 -S
11
+ ```
12
+
13
+ ## Issues
14
+ [Opening an Issue](https://github.com/aliyun/alibabacloud-typescript-sdk/issues/new), Issues not conforming to the guidelines may be closed immediately.
15
+
16
+ ## Usage
17
+ [Usage Document](https://github.com/aliyun/alibabacloud-typescript-sdk/blob/master/docs/Usage-EN.md#quick-examples)
18
+
19
+ ## References
20
+ * [Latest Release](https://github.com/aliyun/alibabacloud-typescript-sdk/)
21
+
22
+ ## License
23
+ [Apache-2.0](http://www.apache.org/licenses/LICENSE-2.0)
24
+
25
+ Copyright (c) 2009-present, Alibaba Cloud All rights reserved.
@@ -0,0 +1,7 @@
1
+ import OpenApi, * as $OpenApi from '@alicloud/openapi-client';
2
+ export default class Client extends OpenApi {
3
+ constructor(config: $OpenApi.Config);
4
+ getEndpoint(productId: string, regionId: string, endpointRule: string, network: string, suffix: string, endpointMap: {
5
+ [key: string]: string;
6
+ }, endpoint: string): string;
7
+ }
package/dist/client.js ADDED
@@ -0,0 +1,31 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ // This file is auto-generated, don't edit it
7
+ /**
8
+ *
9
+ */
10
+ const tea_util_1 = __importDefault(require("@alicloud/tea-util"));
11
+ const openapi_client_1 = __importDefault(require("@alicloud/openapi-client"));
12
+ const endpoint_util_1 = __importDefault(require("@alicloud/endpoint-util"));
13
+ class Client extends openapi_client_1.default {
14
+ constructor(config) {
15
+ super(config);
16
+ this._endpointRule = "";
17
+ this.checkConfig(config);
18
+ this._endpoint = this.getEndpoint("aliding", this._regionId, this._endpointRule, this._network, this._suffix, this._endpointMap, this._endpoint);
19
+ }
20
+ getEndpoint(productId, regionId, endpointRule, network, suffix, endpointMap, endpoint) {
21
+ if (!tea_util_1.default.empty(endpoint)) {
22
+ return endpoint;
23
+ }
24
+ if (!tea_util_1.default.isUnset(endpointMap) && !tea_util_1.default.empty(endpointMap[regionId])) {
25
+ return endpointMap[regionId];
26
+ }
27
+ return endpoint_util_1.default.getEndpointRules(productId, regionId, endpointRule, network, suffix);
28
+ }
29
+ }
30
+ exports.default = Client;
31
+ //# sourceMappingURL=client.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"client.js","sourceRoot":"","sources":["../src/client.ts"],"names":[],"mappings":";;;;;AAAA,6CAA6C;AAC7C;;GAEG;AACH,kEAAsC;AACtC,8EAA8D;AAC9D,4EAAmD;AAInD,MAAqB,MAAO,SAAQ,wBAAO;IAEzC,YAAY,MAAuB;QACjC,KAAK,CAAC,MAAM,CAAC,CAAC;QACd,IAAI,CAAC,aAAa,GAAG,EAAE,CAAC;QACxB,IAAI,CAAC,WAAW,CAAC,MAAM,CAAC,CAAC;QACzB,IAAI,CAAC,SAAS,GAAG,IAAI,CAAC,WAAW,CAAC,SAAS,EAAE,IAAI,CAAC,SAAS,EAAE,IAAI,CAAC,aAAa,EAAE,IAAI,CAAC,QAAQ,EAAE,IAAI,CAAC,OAAO,EAAE,IAAI,CAAC,YAAY,EAAE,IAAI,CAAC,SAAS,CAAC,CAAC;IACnJ,CAAC;IAGD,WAAW,CAAC,SAAiB,EAAE,QAAgB,EAAE,YAAoB,EAAE,OAAe,EAAE,MAAc,EAAE,WAAqC,EAAE,QAAgB;QAC7J,IAAI,CAAC,kBAAI,CAAC,KAAK,CAAC,QAAQ,CAAC,EAAE;YACzB,OAAO,QAAQ,CAAC;SACjB;QAED,IAAI,CAAC,kBAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,kBAAI,CAAC,KAAK,CAAC,WAAW,CAAC,QAAQ,CAAC,CAAC,EAAE;YACpE,OAAO,WAAW,CAAC,QAAQ,CAAC,CAAC;SAC9B;QAED,OAAO,uBAAY,CAAC,gBAAgB,CAAC,SAAS,EAAE,QAAQ,EAAE,YAAY,EAAE,OAAO,EAAE,MAAM,CAAC,CAAC;IAC3F,CAAC;CAEF;AAtBD,yBAsBC"}
package/package.json ADDED
@@ -0,0 +1,31 @@
1
+ {
2
+ "name": "@alicloud/aliding20230426",
3
+ "version": "1.0.0",
4
+ "description": "",
5
+ "main": "dist/client.js",
6
+ "scripts": {
7
+ "test": "mocha --reporter spec --timeout 3000 test/*.test.js",
8
+ "test-cov": "nyc -e .ts -r=html -r=text -r=lcov npm run test",
9
+ "build": "tsc",
10
+ "prepublishOnly": "tsc"
11
+ },
12
+ "author": "Alibaba Cloud SDK",
13
+ "license": "Apache-2.0",
14
+ "devDependencies": {
15
+ "@types/node": "^12.12.26",
16
+ "nyc": "^15.0.0",
17
+ "source-map-support": "^0.5.16",
18
+ "ts-node": "^8.6.2",
19
+ "typescript": "^3.7.5"
20
+ },
21
+ "dependencies": {
22
+ "@alicloud/tea-typescript": "^1.7.1",
23
+ "@alicloud/tea-util": "^1.4.7",
24
+ "@alicloud/openapi-client": "^0.4.4",
25
+ "@alicloud/endpoint-util": "^0.0.1"
26
+ },
27
+ "files": [
28
+ "dist",
29
+ "src"
30
+ ]
31
+ }
package/src/client.ts ADDED
@@ -0,0 +1,33 @@
1
+ // This file is auto-generated, don't edit it
2
+ /**
3
+ *
4
+ */
5
+ import Util from '@alicloud/tea-util';
6
+ import OpenApi, * as $OpenApi from '@alicloud/openapi-client';
7
+ import EndpointUtil from '@alicloud/endpoint-util';
8
+ import * as $tea from '@alicloud/tea-typescript';
9
+
10
+
11
+ export default class Client extends OpenApi {
12
+
13
+ constructor(config: $OpenApi.Config) {
14
+ super(config);
15
+ this._endpointRule = "";
16
+ this.checkConfig(config);
17
+ this._endpoint = this.getEndpoint("aliding", this._regionId, this._endpointRule, this._network, this._suffix, this._endpointMap, this._endpoint);
18
+ }
19
+
20
+
21
+ getEndpoint(productId: string, regionId: string, endpointRule: string, network: string, suffix: string, endpointMap: {[key: string ]: string}, endpoint: string): string {
22
+ if (!Util.empty(endpoint)) {
23
+ return endpoint;
24
+ }
25
+
26
+ if (!Util.isUnset(endpointMap) && !Util.empty(endpointMap[regionId])) {
27
+ return endpointMap[regionId];
28
+ }
29
+
30
+ return EndpointUtil.getEndpointRules(productId, regionId, endpointRule, network, suffix);
31
+ }
32
+
33
+ }