@arrowsphere/api-client 3.17.0-rc.4 → 3.17.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/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,13 @@
|
|
|
3
3
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
4
4
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
5
5
|
|
|
6
|
+
## [3.17.0] - 2022-12-05
|
|
7
|
+
|
|
8
|
+
### Changed
|
|
9
|
+
|
|
10
|
+
- Add endpoint security score
|
|
11
|
+
- Add and improve logs
|
|
12
|
+
|
|
6
13
|
## [3.16.0] - 2022-11-09
|
|
7
14
|
|
|
8
15
|
### Changed
|
package/build/axiosSingleton.js
CHANGED
|
@@ -5,6 +5,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.AxiosSingleton = void 0;
|
|
7
7
|
const axios_1 = __importDefault(require("axios"));
|
|
8
|
+
const lodash_1 = require("lodash");
|
|
8
9
|
class AxiosSingleton {
|
|
9
10
|
static getInstance() {
|
|
10
11
|
if (!AxiosSingleton._axiosInstance) {
|
|
@@ -40,18 +41,22 @@ class AxiosSingleton {
|
|
|
40
41
|
*/
|
|
41
42
|
static cleanRequestLog(request) {
|
|
42
43
|
var _a;
|
|
43
|
-
const tempRequest = request;
|
|
44
|
-
|
|
44
|
+
const tempRequest = lodash_1.cloneDeep(request);
|
|
45
|
+
// coverage bug delete undefined element
|
|
46
|
+
/* istanbul ignore next */
|
|
47
|
+
(_a = tempRequest.headers) === null || _a === void 0 ? true : delete _a.apiKey;
|
|
45
48
|
return tempRequest;
|
|
46
49
|
}
|
|
47
50
|
/**
|
|
48
51
|
* @param response - Axios Response
|
|
49
52
|
*/
|
|
50
53
|
static cleanResponseLog(response) {
|
|
51
|
-
var _a
|
|
52
|
-
const tempResponse = response;
|
|
53
|
-
|
|
54
|
-
|
|
54
|
+
var _a;
|
|
55
|
+
const tempResponse = lodash_1.cloneDeep(response);
|
|
56
|
+
// coverage bug delete undefined element
|
|
57
|
+
/* istanbul ignore next */
|
|
58
|
+
(_a = tempResponse.config.headers) === null || _a === void 0 ? true : delete _a.apiKey;
|
|
59
|
+
delete tempResponse.request;
|
|
55
60
|
return tempResponse;
|
|
56
61
|
}
|
|
57
62
|
}
|
|
@@ -16,4 +16,5 @@ __exportStar(require("./entities/checks/securityChecks"), exports);
|
|
|
16
16
|
__exportStar(require("./entities/checks/checks"), exports);
|
|
17
17
|
__exportStar(require("./entities/resources/securityResources"), exports);
|
|
18
18
|
__exportStar(require("./entities/resources/resources"), exports);
|
|
19
|
+
__exportStar(require("./standardsClient"), exports);
|
|
19
20
|
//# sourceMappingURL=index.js.map
|
package/package.json
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"type": "git",
|
|
5
5
|
"url": "https://github.com/ArrowSphere/nodejs-api-client.git"
|
|
6
6
|
},
|
|
7
|
-
"version": "3.17.0
|
|
7
|
+
"version": "3.17.0",
|
|
8
8
|
"description": "Node.js client for ArrowSphere's public API",
|
|
9
9
|
"main": "build/index.js",
|
|
10
10
|
"types": "build/index.d.ts",
|
|
@@ -32,6 +32,7 @@
|
|
|
32
32
|
"devDependencies": {
|
|
33
33
|
"@types/chai": "4.2.15",
|
|
34
34
|
"@types/chai-as-promised": "7.1.3",
|
|
35
|
+
"@types/lodash": "^4.14.191",
|
|
35
36
|
"@types/mocha": "8.2.0",
|
|
36
37
|
"@types/node": "18.11.10",
|
|
37
38
|
"@types/sinon": "9.0.10",
|
|
@@ -82,6 +83,7 @@
|
|
|
82
83
|
"axios": "1.1.3",
|
|
83
84
|
"graphql": "^16.3.0",
|
|
84
85
|
"graphql-request": "4.2.0",
|
|
86
|
+
"lodash": "^4.17.21",
|
|
85
87
|
"validatorjs": "3.22.1"
|
|
86
88
|
}
|
|
87
89
|
}
|