@yolo-croket-dev/entity-v2 0.3.33 → 0.3.34
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/customs/customs.entity.d.ts +70 -0
- package/customs/customs.entity.js +24 -0
- package/customs/index.d.ts +1 -0
- package/customs/index.js +17 -0
- package/index.d.ts +2 -0
- package/index.js +2 -0
- package/package.json +1 -1
- package/user-sensitive-identity/index.d.ts +1 -0
- package/user-sensitive-identity/index.js +17 -0
- package/user-sensitive-identity/user-sensitive-identity.entity.d.ts +29 -0
- package/user-sensitive-identity/user-sensitive-identity.entity.js +2 -0
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import { Types } from 'mongoose';
|
|
2
|
+
/** @description 관세청 개인통관고유부호 검증 처리 상태 */
|
|
3
|
+
export declare enum CustomsPcccVerificationStatusEnum {
|
|
4
|
+
REQUESTING = "REQUESTING",
|
|
5
|
+
USER_INPUT_REQUIRED = "USER_INPUT_REQUIRED",
|
|
6
|
+
VERIFIED = "VERIFIED",
|
|
7
|
+
FAILED = "FAILED",
|
|
8
|
+
UNKNOWN_RESULT = "UNKNOWN_RESULT"
|
|
9
|
+
}
|
|
10
|
+
/** @description 관세청 거래정보 제출 처리 상태 */
|
|
11
|
+
export declare enum CustomsTradeSubmissionStatusEnum {
|
|
12
|
+
SUBMITTING = "SUBMITTING",
|
|
13
|
+
SUBMITTED_ACK = "SUBMITTED_ACK",
|
|
14
|
+
VALIDATING = "VALIDATING",
|
|
15
|
+
REGISTERED = "REGISTERED",
|
|
16
|
+
PARTIAL_REJECTED = "PARTIAL_REJECTED",
|
|
17
|
+
FULL_REJECTED = "FULL_REJECTED",
|
|
18
|
+
UNKNOWN_RESULT = "UNKNOWN_RESULT",
|
|
19
|
+
FAILED = "FAILED"
|
|
20
|
+
}
|
|
21
|
+
export interface CustomsPcccVerificationEntity {
|
|
22
|
+
_id: Types.ObjectId | string;
|
|
23
|
+
reqtNo: string;
|
|
24
|
+
orderNo?: string;
|
|
25
|
+
status: CustomsPcccVerificationStatusEnum;
|
|
26
|
+
requestType: '01' | '02';
|
|
27
|
+
phoneLastFour: string;
|
|
28
|
+
otpPrefix?: string;
|
|
29
|
+
responseType?: '01' | '02' | '03';
|
|
30
|
+
validationPeriod?: string;
|
|
31
|
+
issuedAt?: string;
|
|
32
|
+
externalResponseCode?: string;
|
|
33
|
+
externalResponseUuid?: string;
|
|
34
|
+
maskedEmail?: string;
|
|
35
|
+
failureCode?: string;
|
|
36
|
+
requestedAt: Date;
|
|
37
|
+
verifiedAt?: Date;
|
|
38
|
+
}
|
|
39
|
+
export interface CustomsTradeSubmissionEntity {
|
|
40
|
+
_id: Types.ObjectId | string;
|
|
41
|
+
txifSbmtNo: string;
|
|
42
|
+
status: CustomsTradeSubmissionStatusEnum;
|
|
43
|
+
payloadHash: string;
|
|
44
|
+
orderNumbers: string[];
|
|
45
|
+
submittedAt?: Date;
|
|
46
|
+
lastResultQueriedAt?: Date;
|
|
47
|
+
nextResultQueryAt?: Date;
|
|
48
|
+
externalResponseCode?: string;
|
|
49
|
+
externalResponseUuid?: string;
|
|
50
|
+
result?: Record<string, unknown>;
|
|
51
|
+
failureCode?: string;
|
|
52
|
+
failureMessage?: string;
|
|
53
|
+
attemptCount: number;
|
|
54
|
+
createdAt: Date;
|
|
55
|
+
updatedAt: Date;
|
|
56
|
+
}
|
|
57
|
+
export interface CustomsAccessTokenEntity {
|
|
58
|
+
_id: Types.ObjectId | string;
|
|
59
|
+
credentialKey: string;
|
|
60
|
+
accessToken?: string;
|
|
61
|
+
expiresAt?: Date;
|
|
62
|
+
refreshLockUntil?: Date;
|
|
63
|
+
updatedAt: Date;
|
|
64
|
+
}
|
|
65
|
+
export interface CustomsSequenceEntity {
|
|
66
|
+
_id: Types.ObjectId | string;
|
|
67
|
+
key: string;
|
|
68
|
+
value: number;
|
|
69
|
+
updatedAt: Date;
|
|
70
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.CustomsTradeSubmissionStatusEnum = exports.CustomsPcccVerificationStatusEnum = void 0;
|
|
4
|
+
/** @description 관세청 개인통관고유부호 검증 처리 상태 */
|
|
5
|
+
var CustomsPcccVerificationStatusEnum;
|
|
6
|
+
(function (CustomsPcccVerificationStatusEnum) {
|
|
7
|
+
CustomsPcccVerificationStatusEnum["REQUESTING"] = "REQUESTING";
|
|
8
|
+
CustomsPcccVerificationStatusEnum["USER_INPUT_REQUIRED"] = "USER_INPUT_REQUIRED";
|
|
9
|
+
CustomsPcccVerificationStatusEnum["VERIFIED"] = "VERIFIED";
|
|
10
|
+
CustomsPcccVerificationStatusEnum["FAILED"] = "FAILED";
|
|
11
|
+
CustomsPcccVerificationStatusEnum["UNKNOWN_RESULT"] = "UNKNOWN_RESULT";
|
|
12
|
+
})(CustomsPcccVerificationStatusEnum || (exports.CustomsPcccVerificationStatusEnum = CustomsPcccVerificationStatusEnum = {}));
|
|
13
|
+
/** @description 관세청 거래정보 제출 처리 상태 */
|
|
14
|
+
var CustomsTradeSubmissionStatusEnum;
|
|
15
|
+
(function (CustomsTradeSubmissionStatusEnum) {
|
|
16
|
+
CustomsTradeSubmissionStatusEnum["SUBMITTING"] = "SUBMITTING";
|
|
17
|
+
CustomsTradeSubmissionStatusEnum["SUBMITTED_ACK"] = "SUBMITTED_ACK";
|
|
18
|
+
CustomsTradeSubmissionStatusEnum["VALIDATING"] = "VALIDATING";
|
|
19
|
+
CustomsTradeSubmissionStatusEnum["REGISTERED"] = "REGISTERED";
|
|
20
|
+
CustomsTradeSubmissionStatusEnum["PARTIAL_REJECTED"] = "PARTIAL_REJECTED";
|
|
21
|
+
CustomsTradeSubmissionStatusEnum["FULL_REJECTED"] = "FULL_REJECTED";
|
|
22
|
+
CustomsTradeSubmissionStatusEnum["UNKNOWN_RESULT"] = "UNKNOWN_RESULT";
|
|
23
|
+
CustomsTradeSubmissionStatusEnum["FAILED"] = "FAILED";
|
|
24
|
+
})(CustomsTradeSubmissionStatusEnum || (exports.CustomsTradeSubmissionStatusEnum = CustomsTradeSubmissionStatusEnum = {}));
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './customs.entity';
|
package/customs/index.js
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./customs.entity"), exports);
|
package/index.d.ts
CHANGED
|
@@ -10,6 +10,7 @@ export * from './selection-frame-data';
|
|
|
10
10
|
export * from './selection-frame-guide';
|
|
11
11
|
export * from './selection-item-connect';
|
|
12
12
|
export * from './user';
|
|
13
|
+
export * from './user-sensitive-identity';
|
|
13
14
|
export * from './img';
|
|
14
15
|
export * from './selection-frame-first-enterance-guide';
|
|
15
16
|
export * from './app-push-subscribe';
|
|
@@ -78,3 +79,4 @@ export * from './seller-image-asset';
|
|
|
78
79
|
export * from './crawler-proxy-order-slack-event';
|
|
79
80
|
export * from './crawler-proxy-order-payment-request-slack-event';
|
|
80
81
|
export * from './chat.modules/message-template.entity';
|
|
82
|
+
export * from './customs';
|
package/index.js
CHANGED
|
@@ -26,6 +26,7 @@ __exportStar(require("./selection-frame-data"), exports);
|
|
|
26
26
|
__exportStar(require("./selection-frame-guide"), exports);
|
|
27
27
|
__exportStar(require("./selection-item-connect"), exports);
|
|
28
28
|
__exportStar(require("./user"), exports);
|
|
29
|
+
__exportStar(require("./user-sensitive-identity"), exports);
|
|
29
30
|
__exportStar(require("./img"), exports);
|
|
30
31
|
__exportStar(require("./selection-frame-first-enterance-guide"), exports);
|
|
31
32
|
__exportStar(require("./app-push-subscribe"), exports);
|
|
@@ -92,3 +93,4 @@ __exportStar(require("./seller-image-asset"), exports);
|
|
|
92
93
|
__exportStar(require("./crawler-proxy-order-slack-event"), exports);
|
|
93
94
|
__exportStar(require("./crawler-proxy-order-payment-request-slack-event"), exports);
|
|
94
95
|
__exportStar(require("./chat.modules/message-template.entity"), exports);
|
|
96
|
+
__exportStar(require("./customs"), exports);
|
package/package.json
CHANGED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './user-sensitive-identity.entity';
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./user-sensitive-identity.entity"), exports);
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { Types } from 'mongoose';
|
|
2
|
+
export type CiProvider = 'INICIS' | 'PORTONE';
|
|
3
|
+
/**
|
|
4
|
+
* @author 홍준
|
|
5
|
+
* @description 사용자와 분리된 컬렉션에 저장되는 AES-256-GCM CI 정보
|
|
6
|
+
* @process CI 평문과 암호화 키는 이 엔티티·일반 사용자 엔티티에 포함하지 않는다.
|
|
7
|
+
*/
|
|
8
|
+
export interface UserSensitiveIdentityCi {
|
|
9
|
+
algorithm: 'AES-256-GCM';
|
|
10
|
+
authTag: string;
|
|
11
|
+
ciphertext: string;
|
|
12
|
+
iv: string;
|
|
13
|
+
keyVersion: string;
|
|
14
|
+
lookupHmac: string;
|
|
15
|
+
provider: CiProvider;
|
|
16
|
+
verifiedAt: Date;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* @author 홍준
|
|
20
|
+
* @description 사용자 민감 식별정보 전용 엔티티
|
|
21
|
+
* @process userId를 유일 키로 사용해 일반 users 컬렉션과 저장·접근 경로를 분리한다.
|
|
22
|
+
*/
|
|
23
|
+
export default interface UserSensitiveIdentityEntity {
|
|
24
|
+
_id: Types.ObjectId;
|
|
25
|
+
userId: Types.ObjectId;
|
|
26
|
+
ci: UserSensitiveIdentityCi;
|
|
27
|
+
createdAt?: Date;
|
|
28
|
+
updatedAt?: Date;
|
|
29
|
+
}
|