@payfit/audit-log 1.0.0-alpha8 → 1.0.0-rc.100

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.
Files changed (51) hide show
  1. package/README.md +92 -0
  2. package/dist/index.d.ts +27 -8
  3. package/dist/index.js +1 -30
  4. package/dist/index.mjs +149 -0
  5. package/dist/playground.d.ts +1 -0
  6. package/dist/transport/generated/api/default-api.d.ts +7 -7
  7. package/dist/transport/generated/base.d.ts +2 -2
  8. package/dist/transport/generated/common.d.ts +65 -0
  9. package/dist/transport/generated/configuration.d.ts +24 -4
  10. package/dist/transport/generated/index.d.ts +1 -0
  11. package/dist/transport/generated/model/inline-object.d.ts +36 -18
  12. package/dist/transport/implementation.d.ts +4 -4
  13. package/dist/transport/interface.d.ts +18 -3
  14. package/package.json +46 -18
  15. package/.prettierrc +0 -5
  16. package/dist/index.js.map +0 -1
  17. package/dist/transport/generated/api/default-api.js +0 -131
  18. package/dist/transport/generated/api/default-api.js.map +0 -1
  19. package/dist/transport/generated/api.js +0 -19
  20. package/dist/transport/generated/api.js.map +0 -1
  21. package/dist/transport/generated/base.js +0 -63
  22. package/dist/transport/generated/base.js.map +0 -1
  23. package/dist/transport/generated/configuration.js +0 -26
  24. package/dist/transport/generated/configuration.js.map +0 -1
  25. package/dist/transport/generated/index.js +0 -20
  26. package/dist/transport/generated/index.js.map +0 -1
  27. package/dist/transport/generated/model/index.js +0 -3
  28. package/dist/transport/generated/model/index.js.map +0 -1
  29. package/dist/transport/generated/model/inline-object.js +0 -15
  30. package/dist/transport/generated/model/inline-object.js.map +0 -1
  31. package/dist/transport/implementation.js +0 -39
  32. package/dist/transport/implementation.js.map +0 -1
  33. package/dist/transport/interface.js +0 -3
  34. package/dist/transport/interface.js.map +0 -1
  35. package/openapi-codegen-config.yml +0 -6
  36. package/playground/index.ts +0 -26
  37. package/src/index.ts +0 -120
  38. package/src/transport/generated/.openapi-generator/VERSION +0 -1
  39. package/src/transport/generated/.openapi-generator-ignore +0 -23
  40. package/src/transport/generated/api/default-api.ts +0 -131
  41. package/src/transport/generated/api.ts +0 -17
  42. package/src/transport/generated/base.ts +0 -70
  43. package/src/transport/generated/configuration.ts +0 -75
  44. package/src/transport/generated/git_push.sh +0 -58
  45. package/src/transport/generated/index.ts +0 -16
  46. package/src/transport/generated/model/index.ts +0 -1
  47. package/src/transport/generated/model/inline-object.ts +0 -126
  48. package/src/transport/implementation.ts +0 -23
  49. package/src/transport/interface.ts +0 -12
  50. package/tsconfig.json +0 -25
  51. package/tslint.json +0 -12
@@ -20,101 +20,119 @@ export interface InlineObject {
20
20
  * @type {string}
21
21
  * @memberof InlineObject
22
22
  */
23
- id: string;
23
+ 'id': string;
24
24
  /**
25
25
  * Audit log event country code
26
26
  * @type {string}
27
27
  * @memberof InlineObject
28
28
  */
29
- countryCode?: string;
29
+ 'countryCode'?: string;
30
30
  /**
31
31
  * Audit log event payload
32
32
  * @type {object}
33
33
  * @memberof InlineObject
34
34
  */
35
- payload?: object;
35
+ 'payload'?: object;
36
36
  /**
37
37
  * id of the payfiter who performed the audit log action, if signed as.
38
38
  * @type {string}
39
39
  * @memberof InlineObject
40
40
  */
41
- internalId?: string;
41
+ 'internalId'?: string;
42
42
  /**
43
43
  * Tells whether the logged action has been made by the system
44
44
  * @type {boolean}
45
45
  * @memberof InlineObject
46
46
  */
47
- isSystem?: boolean;
47
+ 'isSystem'?: boolean;
48
48
  /**
49
49
  * Audit log event namespace (business related)
50
50
  * @type {string}
51
51
  * @memberof InlineObject
52
52
  */
53
- namespace: string;
53
+ 'namespace': string;
54
54
  /**
55
55
  * Audit log event namespace (technical related)
56
56
  * @type {string}
57
57
  * @memberof InlineObject
58
58
  */
59
- service: string;
59
+ 'service': string;
60
60
  /**
61
61
  * Audit log event type
62
62
  * @type {string}
63
63
  * @memberof InlineObject
64
64
  */
65
- event?: string;
65
+ 'event': string;
66
66
  /**
67
- * Audit log event environment
67
+ * Audit log target
68
68
  * @type {string}
69
69
  * @memberof InlineObject
70
70
  */
71
- environment?: string;
71
+ 'target': string;
72
+ /**
73
+ * Audit log event environment, only required when in todd context
74
+ * @type {string}
75
+ * @memberof InlineObject
76
+ */
77
+ 'environment'?: string;
72
78
  /**
73
79
  * holdingId of the account performing the event
74
80
  * @type {string}
75
81
  * @memberof InlineObject
76
82
  */
77
- holdingId?: string;
83
+ 'holdingId'?: string;
78
84
  /**
79
85
  * companyId of the account performing the event
80
86
  * @type {string}
81
87
  * @memberof InlineObject
82
88
  */
83
- companyId?: string;
89
+ 'companyId'?: string;
84
90
  /**
85
91
  * employeeId of the account performing the event
86
92
  * @type {string}
87
93
  * @memberof InlineObject
88
94
  */
89
- employeeId?: string;
95
+ 'employeeId'?: string;
90
96
  /**
91
97
  * individualId of the account performing the event
92
98
  * @type {string}
93
99
  * @memberof InlineObject
94
100
  */
95
- individualId?: string;
101
+ 'individualId'?: string;
96
102
  /**
97
103
  * roleId of the account performing the event
98
104
  * @type {string}
99
105
  * @memberof InlineObject
100
106
  */
101
- roleId?: string;
107
+ 'roleId'?: string;
102
108
  /**
103
109
  * userIp of the account performing the event
104
110
  * @type {string}
105
111
  * @memberof InlineObject
106
112
  */
107
- userIp?: string;
113
+ 'userIp'?: string;
108
114
  /**
109
115
  * specialRole of the account performing the event
110
116
  * @type {string}
111
117
  * @memberof InlineObject
112
118
  */
113
- specialRole?: string;
119
+ 'specialRole'?: string;
114
120
  /**
115
121
  * email of the account performing the event
116
122
  * @type {string}
117
123
  * @memberof InlineObject
118
124
  */
119
- email?: string;
125
+ 'email'?: string;
126
+ /**
127
+ * Audit log event scope
128
+ * @type {object}
129
+ * @memberof InlineObject
130
+ */
131
+ 'scope'?: object;
132
+ /**
133
+ * Audit log event timestamp unix format
134
+ * @type {number}
135
+ * @memberof InlineObject
136
+ */
137
+ 'timestamp': number;
120
138
  }
@@ -1,8 +1,8 @@
1
- import { DefaultApi } from './generated';
2
- import { IAuditLogTransport, IAuditLogCreationData } from './interface';
1
+ import { InlineObject } from './generated/model';
2
+ import { IAuditLogTransport } from './interface';
3
3
  export declare class Transport implements IAuditLogTransport {
4
4
  protected apiUrl: string;
5
- api: DefaultApi;
5
+ private api;
6
6
  constructor(apiUrl: string);
7
- create(auditLogData: IAuditLogCreationData): Promise<void>;
7
+ create(auditLogData: InlineObject): Promise<void>;
8
8
  }
@@ -1,10 +1,25 @@
1
- import { IAuditLogData } from '..';
2
- export declare type IAuditLogCreationData = IAuditLogData & {
1
+ export interface IAuditLogCreationData {
3
2
  id: string;
4
3
  timestamp: number;
5
4
  environment: string;
6
5
  service: string;
7
- };
6
+ scope?: Record<string, unknown>;
7
+ countryCode?: string;
8
+ payload?: Record<string, unknown>;
9
+ internalId?: string;
10
+ isSystem?: boolean;
11
+ namespace: string;
12
+ event: string;
13
+ target: string;
14
+ holdingId?: string;
15
+ companyId?: string;
16
+ employeeId?: string;
17
+ individualId?: string;
18
+ roleId?: string;
19
+ userIp?: string;
20
+ specialRole?: string;
21
+ email?: string;
22
+ }
8
23
  export interface IAuditLogTransport {
9
24
  create: (data: IAuditLogCreationData) => Promise<void>;
10
25
  }
package/package.json CHANGED
@@ -1,30 +1,58 @@
1
1
  {
2
2
  "name": "@payfit/audit-log",
3
- "version": "1.0.0-alpha8",
3
+ "version": "1.0.0-rc.100",
4
+ "repository": {
5
+ "type": "git",
6
+ "url": "https://github.com/PayFit/audit-logs.git",
7
+ "directory": "sdk"
8
+ },
4
9
  "description": "Library to handle audit logs at Payfit",
5
10
  "main": "dist/index.js",
11
+ "module": "dist/index.mjs",
12
+ "types": "dist/index.d.ts",
6
13
  "scripts": {
7
- "test": "echo \"Error: no test specified\" && exit 1",
8
- "type:check": "tsc --noEmit",
9
- "build": "rimraf dist && tsc",
10
- "prepublish": "npm run build"
14
+ "generate": "openapi-generator-cli generate -i ../pkg/broker/v1/swagger/openapi.json -g typescript-axios -o src/transport/generated -c openapi-codegen-config.yml",
15
+ "build": "rimraf dist && vite build",
16
+ "prepack": "npm run build",
17
+ "lint": "eslint .",
18
+ "start:playground": "ts-node src/playground.ts",
19
+ "format:check": "prettier --check .",
20
+ "format:fix": "prettier --write .",
21
+ "release": "semantic-release --noCi"
11
22
  },
12
23
  "author": "",
13
24
  "license": "ISC",
14
25
  "dependencies": {
15
- "axios": "0.19.2",
16
- "lodash": "4.17.15",
17
- "uuid": "7.0.0"
26
+ "axios": "^1.0.0",
27
+ "lodash": "^4.17.20",
28
+ "uuid": "^9.0.0"
18
29
  },
19
30
  "devDependencies": {
20
- "@types/lodash": "4.14.149",
21
- "@types/uuid": "3.4.7",
22
- "prettier": "1.18.2",
23
- "rimraf": "2.6.3",
24
- "ts-node": "8.3.0",
25
- "ts-node-dev": "1.0.0-pre.40",
26
- "tslint": "5.18.0",
27
- "tslint-config-prettier": "1.18.0",
28
- "typescript": "3.5.3"
29
- }
31
+ "@openapitools/openapi-generator-cli": "2.7.0",
32
+ "@payfit/browserslist-config": "1.1.1",
33
+ "@payfit/eslint-config-node": "1.1.0",
34
+ "@payfit/semantic-release-package-config": "6.11.0",
35
+ "@rollup/plugin-typescript": "11.1.3",
36
+ "@tsconfig/node18": "18.2.2",
37
+ "@tsconfig/strictest": "2.0.2",
38
+ "@types/lodash": "4.14.198",
39
+ "@types/node": "18.17.16",
40
+ "@types/uuid": "9.0.4",
41
+ "@typescript-eslint/eslint-plugin": "6.7.0",
42
+ "builtin-modules": "3.3.0",
43
+ "eslint": "8.49.0",
44
+ "prettier": "3.0.3",
45
+ "rimraf": "5.0.1",
46
+ "semantic-release": "20.1.3",
47
+ "ts-node": "10.9.1",
48
+ "typescript": "5.2.2",
49
+ "vite": "4.4.9"
50
+ },
51
+ "peerDependencies": {},
52
+ "publishConfig": {
53
+ "registry": "https://registry.npmjs.org/"
54
+ },
55
+ "files": [
56
+ "dist"
57
+ ]
30
58
  }
package/.prettierrc DELETED
@@ -1,5 +0,0 @@
1
- {
2
- "semi": false,
3
- "singleQuote": true,
4
- "trailingComma": "es5"
5
- }
package/dist/index.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;AAAA,+BAAmC;AAEnC,+DAAsD;AA+FtD,MAAa,WAAW;IAGtB,YAAsB,MAAkC;QAAlC,WAAM,GAAN,MAAM,CAA4B;QACtD,IAAI,CAAC,SAAS,GAAG,IAAI,0BAAS,CAAC,MAAM,CAAC,MAAM,CAAC,CAAA;IAC/C,CAAC;IAEK,GAAG,CAAC,IAAmB;;YAC3B,MAAM,IAAI,GAAG,SAAM,EAAE,CAAA;YACrB,MAAM,EAAE,WAAW,EAAE,OAAO,EAAE,GAAG,IAAI,CAAC,MAAM,CAAA;YAC5C,MAAM,SAAS,GAAG,IAAI,IAAI,EAAE,CAAC,OAAO,EAAE,CAAA;YAEtC,MAAM,GAAG,qBACJ,IAAI,IACP,OAAO,EACP,EAAE,EAAE,IAAI,EACR,WAAW;gBACX,SAAS,GACV,CAAA;YAED,MAAM,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC,GAAG,CAAC,CAAA;QAClC,CAAC;KAAA;CACF;AAtBD,kCAsBC"}
@@ -1,131 +0,0 @@
1
- "use strict";
2
- // tslint:disable
3
- /**
4
- * Audit Logs
5
- * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
6
- *
7
- * The version of the OpenAPI document: 1.0.0
8
- * Contact: damian.bursztyn@payfit.com
9
- *
10
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
- * https://openapi-generator.tech
12
- * Do not edit the class manually.
13
- */
14
- var __importStar = (this && this.__importStar) || function (mod) {
15
- if (mod && mod.__esModule) return mod;
16
- var result = {};
17
- if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
18
- result["default"] = mod;
19
- return result;
20
- };
21
- var __importDefault = (this && this.__importDefault) || function (mod) {
22
- return (mod && mod.__esModule) ? mod : { "default": mod };
23
- };
24
- Object.defineProperty(exports, "__esModule", { value: true });
25
- const globalImportUrl = __importStar(require("url"));
26
- const axios_1 = __importDefault(require("axios"));
27
- // Some imports not used depending on template conditions
28
- // @ts-ignore
29
- const base_1 = require("../base");
30
- /**
31
- * DefaultApi - axios parameter creator
32
- * @export
33
- */
34
- exports.DefaultApiAxiosParamCreator = function (configuration) {
35
- return {
36
- /**
37
- *
38
- * @summary Creates Audit Log event
39
- * @param {InlineObject} inlineObject
40
- * @param {*} [options] Override http request option.
41
- * @throws {RequiredError}
42
- */
43
- v1LogPost(inlineObject, options = {}) {
44
- // verify required parameter 'inlineObject' is not null or undefined
45
- if (inlineObject === null || inlineObject === undefined) {
46
- throw new base_1.RequiredError('inlineObject', 'Required parameter inlineObject was null or undefined when calling v1LogPost.');
47
- }
48
- const localVarPath = `/v1/log`;
49
- const localVarUrlObj = globalImportUrl.parse(localVarPath, true);
50
- let baseOptions;
51
- if (configuration) {
52
- baseOptions = configuration.baseOptions;
53
- }
54
- const localVarRequestOptions = Object.assign({ method: 'POST' }, baseOptions, options);
55
- const localVarHeaderParameter = {};
56
- const localVarQueryParameter = {};
57
- localVarHeaderParameter['Content-Type'] = 'application/json';
58
- localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query);
59
- // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943
60
- delete localVarUrlObj.search;
61
- localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers);
62
- const needsSerialization = (typeof inlineObject !== "string") || localVarRequestOptions.headers['Content-Type'] === 'application/json';
63
- localVarRequestOptions.data = needsSerialization ? JSON.stringify(inlineObject !== undefined ? inlineObject : {}) : (inlineObject || "");
64
- return {
65
- url: globalImportUrl.format(localVarUrlObj),
66
- options: localVarRequestOptions,
67
- };
68
- },
69
- };
70
- };
71
- /**
72
- * DefaultApi - functional programming interface
73
- * @export
74
- */
75
- exports.DefaultApiFp = function (configuration) {
76
- return {
77
- /**
78
- *
79
- * @summary Creates Audit Log event
80
- * @param {InlineObject} inlineObject
81
- * @param {*} [options] Override http request option.
82
- * @throws {RequiredError}
83
- */
84
- v1LogPost(inlineObject, options) {
85
- const localVarAxiosArgs = exports.DefaultApiAxiosParamCreator(configuration).v1LogPost(inlineObject, options);
86
- return (axios = axios_1.default, basePath = base_1.BASE_PATH) => {
87
- const axiosRequestArgs = Object.assign({}, localVarAxiosArgs.options, { url: basePath + localVarAxiosArgs.url });
88
- return axios.request(axiosRequestArgs);
89
- };
90
- },
91
- };
92
- };
93
- /**
94
- * DefaultApi - factory interface
95
- * @export
96
- */
97
- exports.DefaultApiFactory = function (configuration, basePath, axios) {
98
- return {
99
- /**
100
- *
101
- * @summary Creates Audit Log event
102
- * @param {InlineObject} inlineObject
103
- * @param {*} [options] Override http request option.
104
- * @throws {RequiredError}
105
- */
106
- v1LogPost(inlineObject, options) {
107
- return exports.DefaultApiFp(configuration).v1LogPost(inlineObject, options)(axios, basePath);
108
- },
109
- };
110
- };
111
- /**
112
- * DefaultApi - object-oriented interface
113
- * @export
114
- * @class DefaultApi
115
- * @extends {BaseAPI}
116
- */
117
- class DefaultApi extends base_1.BaseAPI {
118
- /**
119
- *
120
- * @summary Creates Audit Log event
121
- * @param {InlineObject} inlineObject
122
- * @param {*} [options] Override http request option.
123
- * @throws {RequiredError}
124
- * @memberof DefaultApi
125
- */
126
- v1LogPost(inlineObject, options) {
127
- return exports.DefaultApiFp(this.configuration).v1LogPost(inlineObject, options)(this.axios, this.basePath);
128
- }
129
- }
130
- exports.DefaultApi = DefaultApi;
131
- //# sourceMappingURL=default-api.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"default-api.js","sourceRoot":"","sources":["../../../../src/transport/generated/api/default-api.ts"],"names":[],"mappings":";AAAA,iBAAiB;AACjB;;;;;;;;;;GAUG;;;;;;;;;;;;AAGH,qDAAuC;AACvC,kDAAiE;AAEjE,yDAAyD;AACzD,aAAa;AACb,kCAA6F;AAG7F;;;GAGG;AACU,QAAA,2BAA2B,GAAG,UAAU,aAA6B;IAC9E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
@@ -1,19 +0,0 @@
1
- "use strict";
2
- // tslint:disable
3
- /**
4
- * Audit Logs
5
- * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
6
- *
7
- * The version of the OpenAPI document: 1.0.0
8
- * Contact: damian.bursztyn@payfit.com
9
- *
10
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
- * https://openapi-generator.tech
12
- * Do not edit the class manually.
13
- */
14
- function __export(m) {
15
- for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];
16
- }
17
- Object.defineProperty(exports, "__esModule", { value: true });
18
- __export(require("./api/default-api"));
19
- //# sourceMappingURL=api.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"api.js","sourceRoot":"","sources":["../../../src/transport/generated/api.ts"],"names":[],"mappings":";AAAA,iBAAiB;AACjB;;;;;;;;;;GAUG;;;;;AAIH,uCAAkC"}
@@ -1,63 +0,0 @@
1
- "use strict";
2
- // tslint:disable
3
- /**
4
- * Audit Logs
5
- * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
6
- *
7
- * The version of the OpenAPI document: 1.0.0
8
- * Contact: damian.bursztyn@payfit.com
9
- *
10
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
- * https://openapi-generator.tech
12
- * Do not edit the class manually.
13
- */
14
- var __importDefault = (this && this.__importDefault) || function (mod) {
15
- return (mod && mod.__esModule) ? mod : { "default": mod };
16
- };
17
- Object.defineProperty(exports, "__esModule", { value: true });
18
- // Some imports not used depending on template conditions
19
- // @ts-ignore
20
- const axios_1 = __importDefault(require("axios"));
21
- exports.BASE_PATH = "http://localhost:8081/v1".replace(/\/+$/, "");
22
- /**
23
- *
24
- * @export
25
- */
26
- exports.COLLECTION_FORMATS = {
27
- csv: ",",
28
- ssv: " ",
29
- tsv: "\t",
30
- pipes: "|",
31
- };
32
- /**
33
- *
34
- * @export
35
- * @class BaseAPI
36
- */
37
- class BaseAPI {
38
- constructor(configuration, basePath = exports.BASE_PATH, axios = axios_1.default) {
39
- this.basePath = basePath;
40
- this.axios = axios;
41
- if (configuration) {
42
- this.configuration = configuration;
43
- this.basePath = configuration.basePath || this.basePath;
44
- }
45
- }
46
- }
47
- exports.BaseAPI = BaseAPI;
48
- ;
49
- /**
50
- *
51
- * @export
52
- * @class RequiredError
53
- * @extends {Error}
54
- */
55
- class RequiredError extends Error {
56
- constructor(field, msg) {
57
- super(msg);
58
- this.field = field;
59
- this.name = "RequiredError";
60
- }
61
- }
62
- exports.RequiredError = RequiredError;
63
- //# sourceMappingURL=base.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"base.js","sourceRoot":"","sources":["../../../src/transport/generated/base.ts"],"names":[],"mappings":";AAAA,iBAAiB;AACjB;;;;;;;;;;GAUG;;;;;AAIH,yDAAyD;AACzD,aAAa;AACb,kDAAiE;AAEpD,QAAA,SAAS,GAAG,0BAA0B,CAAC,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC;AAExE;;;GAGG;AACU,QAAA,kBAAkB,GAAG;IAC9B,GAAG,EAAE,GAAG;IACR,GAAG,EAAE,GAAG;IACR,GAAG,EAAE,IAAI;IACT,KAAK,EAAE,GAAG;CACb,CAAC;AAYF;;;;GAIG;AACH,MAAa,OAAO;IAGhB,YAAY,aAA6B,EAAY,WAAmB,iBAAS,EAAY,QAAuB,eAAW;QAA1E,aAAQ,GAAR,QAAQ,CAAoB;QAAY,UAAK,GAAL,KAAK,CAA6B;QAC3H,IAAI,aAAa,EAAE;YACf,IAAI,CAAC,aAAa,GAAG,aAAa,CAAC;YACnC,IAAI,CAAC,QAAQ,GAAG,aAAa,CAAC,QAAQ,IAAI,IAAI,CAAC,QAAQ,CAAC;SAC3D;IACL,CAAC;CACJ;AATD,0BASC;AAAA,CAAC;AAEF;;;;;GAKG;AACH,MAAa,aAAc,SAAQ,KAAK;IAEpC,YAAmB,KAAa,EAAE,GAAY;QAC1C,KAAK,CAAC,GAAG,CAAC,CAAC;QADI,UAAK,GAAL,KAAK,CAAQ;QADhC,SAAI,GAAoB,eAAe,CAAC;IAGxC,CAAC;CACJ;AALD,sCAKC"}
@@ -1,26 +0,0 @@
1
- "use strict";
2
- // tslint:disable
3
- /**
4
- * Audit Logs
5
- * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
6
- *
7
- * The version of the OpenAPI document: 1.0.0
8
- * Contact: damian.bursztyn@payfit.com
9
- *
10
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
- * https://openapi-generator.tech
12
- * Do not edit the class manually.
13
- */
14
- Object.defineProperty(exports, "__esModule", { value: true });
15
- class Configuration {
16
- constructor(param = {}) {
17
- this.apiKey = param.apiKey;
18
- this.username = param.username;
19
- this.password = param.password;
20
- this.accessToken = param.accessToken;
21
- this.basePath = param.basePath;
22
- this.baseOptions = param.baseOptions;
23
- }
24
- }
25
- exports.Configuration = Configuration;
26
- //# sourceMappingURL=configuration.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"configuration.js","sourceRoot":"","sources":["../../../src/transport/generated/configuration.ts"],"names":[],"mappings":";AAAA,iBAAiB;AACjB;;;;;;;;;;GAUG;;AAYH,MAAa,aAAa;IA2CtB,YAAY,QAAiC,EAAE;QAC3C,IAAI,CAAC,MAAM,GAAG,KAAK,CAAC,MAAM,CAAC;QAC3B,IAAI,CAAC,QAAQ,GAAG,KAAK,CAAC,QAAQ,CAAC;QAC/B,IAAI,CAAC,QAAQ,GAAG,KAAK,CAAC,QAAQ,CAAC;QAC/B,IAAI,CAAC,WAAW,GAAG,KAAK,CAAC,WAAW,CAAC;QACrC,IAAI,CAAC,QAAQ,GAAG,KAAK,CAAC,QAAQ,CAAC;QAC/B,IAAI,CAAC,WAAW,GAAG,KAAK,CAAC,WAAW,CAAC;IACzC,CAAC;CACJ;AAnDD,sCAmDC"}
@@ -1,20 +0,0 @@
1
- "use strict";
2
- // tslint:disable
3
- /**
4
- * Audit Logs
5
- * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
6
- *
7
- * The version of the OpenAPI document: 1.0.0
8
- * Contact: damian.bursztyn@payfit.com
9
- *
10
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
- * https://openapi-generator.tech
12
- * Do not edit the class manually.
13
- */
14
- function __export(m) {
15
- for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];
16
- }
17
- Object.defineProperty(exports, "__esModule", { value: true });
18
- __export(require("./api"));
19
- __export(require("./configuration"));
20
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/transport/generated/index.ts"],"names":[],"mappings":";AAAA,iBAAiB;AACjB;;;;;;;;;;GAUG;;;;;AAGH,2BAAsB;AACtB,qCAAgC"}
@@ -1,3 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/transport/generated/model/index.ts"],"names":[],"mappings":""}
@@ -1,15 +0,0 @@
1
- "use strict";
2
- // tslint:disable
3
- /**
4
- * Audit Logs
5
- * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
6
- *
7
- * The version of the OpenAPI document: 1.0.0
8
- * Contact: damian.bursztyn@payfit.com
9
- *
10
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
- * https://openapi-generator.tech
12
- * Do not edit the class manually.
13
- */
14
- Object.defineProperty(exports, "__esModule", { value: true });
15
- //# sourceMappingURL=inline-object.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"inline-object.js","sourceRoot":"","sources":["../../../../src/transport/generated/model/inline-object.ts"],"names":[],"mappings":";AAAA,iBAAiB;AACjB;;;;;;;;;;GAUG"}
@@ -1,39 +0,0 @@
1
- "use strict";
2
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
- return new (P || (P = Promise))(function (resolve, reject) {
4
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
5
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
6
- function step(result) { result.done ? resolve(result.value) : new P(function (resolve) { resolve(result.value); }).then(fulfilled, rejected); }
7
- step((generator = generator.apply(thisArg, _arguments || [])).next());
8
- });
9
- };
10
- var __rest = (this && this.__rest) || function (s, e) {
11
- var t = {};
12
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
13
- t[p] = s[p];
14
- if (s != null && typeof Object.getOwnPropertySymbols === "function")
15
- for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
16
- if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
17
- t[p[i]] = s[p[i]];
18
- }
19
- return t;
20
- };
21
- Object.defineProperty(exports, "__esModule", { value: true });
22
- const generated_1 = require("./generated");
23
- class Transport {
24
- constructor(apiUrl) {
25
- this.apiUrl = apiUrl;
26
- this.api = new generated_1.DefaultApi({
27
- basePath: this.apiUrl,
28
- });
29
- }
30
- create(auditLogData) {
31
- return __awaiter(this, void 0, void 0, function* () {
32
- const { account } = auditLogData, logDataWithoutAccount = __rest(auditLogData, ["account"]);
33
- const dataToSend = Object.assign({}, logDataWithoutAccount, account);
34
- yield this.api.v1LogPost(dataToSend);
35
- });
36
- }
37
- }
38
- exports.Transport = Transport;
39
- //# sourceMappingURL=implementation.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"implementation.js","sourceRoot":"","sources":["../../src/transport/implementation.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;AAAA,2CAAwC;AAGxC,MAAa,SAAS;IAGpB,YAAsB,MAAc;QAAd,WAAM,GAAN,MAAM,CAAQ;QAClC,IAAI,CAAC,GAAG,GAAG,IAAI,sBAAU,CAAC;YACxB,QAAQ,EAAE,IAAI,CAAC,MAAM;SACtB,CAAC,CAAA;IACJ,CAAC;IAEK,MAAM,CAAC,YAAmC;;YAC9C,MAAM,EAAE,OAAO,KAA+B,YAAY,EAAzC,yDAAyC,CAAA;YAE1D,MAAM,UAAU,qBACX,qBAAqB,EACrB,OAAO,CACX,CAAA;YAED,MAAM,IAAI,CAAC,GAAG,CAAC,SAAS,CAAC,UAAU,CAAC,CAAA;QACtC,CAAC;KAAA;CACF;AAnBD,8BAmBC"}
@@ -1,3 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- //# sourceMappingURL=interface.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"interface.js","sourceRoot":"","sources":["../../src/transport/interface.ts"],"names":[],"mappings":""}
@@ -1,6 +0,0 @@
1
- withSeparateModelsAndApi: true
2
- apiPackage: 'api'
3
- modelPackage: 'model'
4
- enumPropertyNaming: UPPERCASE
5
- modelPropertyNaming: camelCase
6
- withoutPrefixEnums: true