@venturialstd/kyc 0.0.1

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 (54) hide show
  1. package/README.md +278 -0
  2. package/dist/constants/kyc.constant.d.ts +47 -0
  3. package/dist/constants/kyc.constant.d.ts.map +1 -0
  4. package/dist/constants/kyc.constant.js +55 -0
  5. package/dist/constants/kyc.constant.js.map +1 -0
  6. package/dist/dtos/create-kyc-profile.dto.d.ts +20 -0
  7. package/dist/dtos/create-kyc-profile.dto.d.ts.map +1 -0
  8. package/dist/dtos/create-kyc-profile.dto.js +113 -0
  9. package/dist/dtos/create-kyc-profile.dto.js.map +1 -0
  10. package/dist/dtos/update-kyc-profile.dto.d.ts +6 -0
  11. package/dist/dtos/update-kyc-profile.dto.d.ts.map +1 -0
  12. package/dist/dtos/update-kyc-profile.dto.js +9 -0
  13. package/dist/dtos/update-kyc-profile.dto.js.map +1 -0
  14. package/dist/entities/kyc-document.entity.d.ts +26 -0
  15. package/dist/entities/kyc-document.entity.d.ts.map +1 -0
  16. package/dist/entities/kyc-document.entity.js +177 -0
  17. package/dist/entities/kyc-document.entity.js.map +1 -0
  18. package/dist/entities/kyc-profile.entity.d.ts +31 -0
  19. package/dist/entities/kyc-profile.entity.d.ts.map +1 -0
  20. package/dist/entities/kyc-profile.entity.js +213 -0
  21. package/dist/entities/kyc-profile.entity.js.map +1 -0
  22. package/dist/entities/kyc-verification.entity.d.ts +21 -0
  23. package/dist/entities/kyc-verification.entity.d.ts.map +1 -0
  24. package/dist/entities/kyc-verification.entity.js +135 -0
  25. package/dist/entities/kyc-verification.entity.js.map +1 -0
  26. package/dist/index.d.ts +12 -0
  27. package/dist/index.d.ts.map +1 -0
  28. package/dist/index.js +28 -0
  29. package/dist/index.js.map +1 -0
  30. package/dist/interfaces/kyc-provider.interface.d.ts +98 -0
  31. package/dist/interfaces/kyc-provider.interface.d.ts.map +1 -0
  32. package/dist/interfaces/kyc-provider.interface.js +12 -0
  33. package/dist/interfaces/kyc-provider.interface.js.map +1 -0
  34. package/dist/kyc.module.d.ts +12 -0
  35. package/dist/kyc.module.d.ts.map +1 -0
  36. package/dist/kyc.module.js +65 -0
  37. package/dist/kyc.module.js.map +1 -0
  38. package/dist/providers/aiprise.provider.d.ts +9 -0
  39. package/dist/providers/aiprise.provider.d.ts.map +1 -0
  40. package/dist/providers/aiprise.provider.js +73 -0
  41. package/dist/providers/aiprise.provider.js.map +1 -0
  42. package/dist/providers/index.d.ts +2 -0
  43. package/dist/providers/index.d.ts.map +1 -0
  44. package/dist/providers/index.js +18 -0
  45. package/dist/providers/index.js.map +1 -0
  46. package/dist/services/kyc-provider.service.d.ts +18 -0
  47. package/dist/services/kyc-provider.service.d.ts.map +1 -0
  48. package/dist/services/kyc-provider.service.js +179 -0
  49. package/dist/services/kyc-provider.service.js.map +1 -0
  50. package/dist/services/kyc.service.d.ts +15 -0
  51. package/dist/services/kyc.service.d.ts.map +1 -0
  52. package/dist/services/kyc.service.js +96 -0
  53. package/dist/services/kyc.service.js.map +1 -0
  54. package/package.json +42 -0
@@ -0,0 +1,177 @@
1
+ "use strict";
2
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
3
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
6
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
7
+ };
8
+ var __metadata = (this && this.__metadata) || function (k, v) {
9
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
+ };
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ exports.KYCDocument = void 0;
13
+ const class_validator_1 = require("class-validator");
14
+ const typeorm_1 = require("typeorm");
15
+ const kyc_constant_1 = require("../constants/kyc.constant");
16
+ const kyc_profile_entity_1 = require("./kyc-profile.entity");
17
+ let KYCDocument = class KYCDocument {
18
+ id;
19
+ kycProfileId;
20
+ kycProfile;
21
+ documentType;
22
+ side;
23
+ status;
24
+ documentNumber;
25
+ issuingCountry;
26
+ issueDate;
27
+ expiryDate;
28
+ fileUrl;
29
+ fileName;
30
+ fileType;
31
+ fileSize;
32
+ verifiedAt;
33
+ verificationNotes;
34
+ rejectionReason;
35
+ extractedData;
36
+ metadata;
37
+ createdAt;
38
+ updatedAt;
39
+ };
40
+ exports.KYCDocument = KYCDocument;
41
+ __decorate([
42
+ (0, typeorm_1.PrimaryGeneratedColumn)('uuid'),
43
+ __metadata("design:type", String)
44
+ ], KYCDocument.prototype, "id", void 0);
45
+ __decorate([
46
+ (0, class_validator_1.IsString)(),
47
+ (0, class_validator_1.IsNotEmpty)(),
48
+ (0, typeorm_1.Column)(),
49
+ (0, typeorm_1.Index)(),
50
+ __metadata("design:type", String)
51
+ ], KYCDocument.prototype, "kycProfileId", void 0);
52
+ __decorate([
53
+ (0, typeorm_1.ManyToOne)(() => kyc_profile_entity_1.KYCProfile, { onDelete: 'CASCADE' }),
54
+ (0, typeorm_1.JoinColumn)({ name: 'kycProfileId' }),
55
+ __metadata("design:type", kyc_profile_entity_1.KYCProfile)
56
+ ], KYCDocument.prototype, "kycProfile", void 0);
57
+ __decorate([
58
+ (0, class_validator_1.IsEnum)(kyc_constant_1.KYC_DOCUMENT_TYPE),
59
+ (0, typeorm_1.Column)({
60
+ type: 'enum',
61
+ enum: kyc_constant_1.KYC_DOCUMENT_TYPE,
62
+ }),
63
+ __metadata("design:type", String)
64
+ ], KYCDocument.prototype, "documentType", void 0);
65
+ __decorate([
66
+ (0, class_validator_1.IsEnum)(kyc_constant_1.KYC_DOCUMENT_SIDE),
67
+ (0, typeorm_1.Column)({
68
+ type: 'enum',
69
+ enum: kyc_constant_1.KYC_DOCUMENT_SIDE,
70
+ default: kyc_constant_1.KYC_DOCUMENT_SIDE.FRONT,
71
+ }),
72
+ __metadata("design:type", String)
73
+ ], KYCDocument.prototype, "side", void 0);
74
+ __decorate([
75
+ (0, class_validator_1.IsEnum)(kyc_constant_1.KYC_DOCUMENT_STATUS),
76
+ (0, typeorm_1.Column)({
77
+ type: 'enum',
78
+ enum: kyc_constant_1.KYC_DOCUMENT_STATUS,
79
+ default: kyc_constant_1.KYC_DOCUMENT_STATUS.PENDING,
80
+ }),
81
+ __metadata("design:type", String)
82
+ ], KYCDocument.prototype, "status", void 0);
83
+ __decorate([
84
+ (0, class_validator_1.IsString)(),
85
+ (0, class_validator_1.IsOptional)(),
86
+ (0, typeorm_1.Column)({ nullable: true }),
87
+ __metadata("design:type", String)
88
+ ], KYCDocument.prototype, "documentNumber", void 0);
89
+ __decorate([
90
+ (0, class_validator_1.IsString)(),
91
+ (0, class_validator_1.IsOptional)(),
92
+ (0, typeorm_1.Column)({ nullable: true }),
93
+ __metadata("design:type", String)
94
+ ], KYCDocument.prototype, "issuingCountry", void 0);
95
+ __decorate([
96
+ (0, class_validator_1.IsString)(),
97
+ (0, class_validator_1.IsOptional)(),
98
+ (0, typeorm_1.Column)({ type: 'date', nullable: true }),
99
+ __metadata("design:type", String)
100
+ ], KYCDocument.prototype, "issueDate", void 0);
101
+ __decorate([
102
+ (0, class_validator_1.IsString)(),
103
+ (0, class_validator_1.IsOptional)(),
104
+ (0, typeorm_1.Column)({ type: 'date', nullable: true }),
105
+ __metadata("design:type", String)
106
+ ], KYCDocument.prototype, "expiryDate", void 0);
107
+ __decorate([
108
+ (0, class_validator_1.IsString)(),
109
+ (0, class_validator_1.IsOptional)(),
110
+ (0, typeorm_1.Column)({ nullable: true }),
111
+ __metadata("design:type", String)
112
+ ], KYCDocument.prototype, "fileUrl", void 0);
113
+ __decorate([
114
+ (0, class_validator_1.IsString)(),
115
+ (0, class_validator_1.IsOptional)(),
116
+ (0, typeorm_1.Column)({ nullable: true }),
117
+ __metadata("design:type", String)
118
+ ], KYCDocument.prototype, "fileName", void 0);
119
+ __decorate([
120
+ (0, class_validator_1.IsString)(),
121
+ (0, class_validator_1.IsOptional)(),
122
+ (0, typeorm_1.Column)({ nullable: true }),
123
+ __metadata("design:type", String)
124
+ ], KYCDocument.prototype, "fileType", void 0);
125
+ __decorate([
126
+ (0, class_validator_1.IsString)(),
127
+ (0, class_validator_1.IsOptional)(),
128
+ (0, typeorm_1.Column)({ type: 'bigint', nullable: true }),
129
+ __metadata("design:type", Number)
130
+ ], KYCDocument.prototype, "fileSize", void 0);
131
+ __decorate([
132
+ (0, typeorm_1.Column)({ type: 'timestamptz', nullable: true }),
133
+ __metadata("design:type", Date)
134
+ ], KYCDocument.prototype, "verifiedAt", void 0);
135
+ __decorate([
136
+ (0, class_validator_1.IsString)(),
137
+ (0, class_validator_1.IsOptional)(),
138
+ (0, typeorm_1.Column)({ type: 'text', nullable: true }),
139
+ __metadata("design:type", String)
140
+ ], KYCDocument.prototype, "verificationNotes", void 0);
141
+ __decorate([
142
+ (0, class_validator_1.IsString)(),
143
+ (0, class_validator_1.IsOptional)(),
144
+ (0, typeorm_1.Column)({ type: 'text', nullable: true }),
145
+ __metadata("design:type", String)
146
+ ], KYCDocument.prototype, "rejectionReason", void 0);
147
+ __decorate([
148
+ (0, typeorm_1.Column)({ type: 'jsonb', nullable: true }),
149
+ __metadata("design:type", Object)
150
+ ], KYCDocument.prototype, "extractedData", void 0);
151
+ __decorate([
152
+ (0, typeorm_1.Column)({ type: 'jsonb', nullable: true }),
153
+ __metadata("design:type", Object)
154
+ ], KYCDocument.prototype, "metadata", void 0);
155
+ __decorate([
156
+ (0, typeorm_1.CreateDateColumn)({
157
+ name: 'createdAt',
158
+ nullable: false,
159
+ type: 'timestamptz',
160
+ default: () => 'CURRENT_TIMESTAMP',
161
+ }),
162
+ __metadata("design:type", Date)
163
+ ], KYCDocument.prototype, "createdAt", void 0);
164
+ __decorate([
165
+ (0, typeorm_1.UpdateDateColumn)({
166
+ name: 'updatedAt',
167
+ nullable: false,
168
+ type: 'timestamptz',
169
+ default: () => 'CURRENT_TIMESTAMP',
170
+ }),
171
+ __metadata("design:type", Date)
172
+ ], KYCDocument.prototype, "updatedAt", void 0);
173
+ exports.KYCDocument = KYCDocument = __decorate([
174
+ (0, typeorm_1.Entity)('kyc_document'),
175
+ (0, typeorm_1.Index)(['kycProfileId', 'documentType', 'side'], { unique: true })
176
+ ], KYCDocument);
177
+ //# sourceMappingURL=kyc-document.entity.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"kyc-document.entity.js","sourceRoot":"","sources":["../../src/entities/kyc-document.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAA2E;AAC3E,qCASiB;AAEjB,4DAAsG;AACtG,6DAAkD;AAQ3C,IAAM,WAAW,GAAjB,MAAM,WAAW;IAEtB,EAAE,CAAS;IAMX,YAAY,CAAS;IAIrB,UAAU,CAAa;IAOvB,YAAY,CAAoB;IAQhC,IAAI,CAAoB;IAQxB,MAAM,CAAsB;IAK5B,cAAc,CAAS;IAKvB,cAAc,CAAS;IAKvB,SAAS,CAAS;IAKlB,UAAU,CAAS;IAMnB,OAAO,CAAS;IAKhB,QAAQ,CAAS;IAKjB,QAAQ,CAAS;IAKjB,QAAQ,CAAS;IAIjB,UAAU,CAAO;IAKjB,iBAAiB,CAAS;IAK1B,eAAe,CAAS;IAIxB,aAAa,CAA0B;IAIvC,QAAQ,CAA0B;IAQlC,SAAS,CAAO;IAQhB,SAAS,CAAO;CACjB,CAAA;AAnHY,kCAAW;AAEtB;IADC,IAAA,gCAAsB,EAAC,MAAM,CAAC;;uCACpB;AAMX;IAJC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;IACZ,IAAA,gBAAM,GAAE;IACR,IAAA,eAAK,GAAE;;iDACa;AAIrB;IAFC,IAAA,mBAAS,EAAC,GAAG,EAAE,CAAC,+BAAU,EAAE,EAAE,QAAQ,EAAE,SAAS,EAAE,CAA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AC;8BACS,IAAI;8CAAC;AAQhB;IANC,IAAA,0BAAgB,EAAC;QAChB,IAAI,EAAE,WAAW;QACjB,QAAQ,EAAE,KAAK;QACf,IAAI,EAAE,aAAa;QACnB,OAAO,EAAE,GAAG,EAAE,CAAC,mBAAmB;KACnC,CAAC;8BACS,IAAI;8CAAC;sBAlHL,WAAW;IAFvB,IAAA,gBAAM,EAAC,cAAc,CAAC;IACtB,IAAA,eAAK,EAAC,CAAC,cAAc,EAAE,cAAc,EAAE,MAAM,CAAC,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC;GACrD,WAAW,CAmHvB"}
@@ -0,0 +1,31 @@
1
+ import { KYC_STATUS, KYC_VERIFICATION_LEVEL } from '../constants/kyc.constant';
2
+ export declare class KYCProfile {
3
+ id: string;
4
+ userId: string;
5
+ status: KYC_STATUS;
6
+ verificationLevel: KYC_VERIFICATION_LEVEL;
7
+ firstName: string;
8
+ lastName: string;
9
+ dateOfBirth: string;
10
+ nationality: string;
11
+ occupation: string;
12
+ sourceOfFunds: string;
13
+ addressLine1: string;
14
+ addressLine2: string;
15
+ city: string;
16
+ state: string;
17
+ postalCode: string;
18
+ country: string;
19
+ residenceType: string;
20
+ submittedAt: Date;
21
+ reviewedAt: Date;
22
+ approvedAt: Date;
23
+ rejectedAt: Date;
24
+ rejectionReason: string;
25
+ reviewNotes: string;
26
+ reviewedBy: string;
27
+ metadata: Record<string, unknown>;
28
+ createdAt: Date;
29
+ updatedAt: Date;
30
+ }
31
+ //# sourceMappingURL=kyc-profile.entity.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"kyc-profile.entity.d.ts","sourceRoot":"","sources":["../../src/entities/kyc-profile.entity.ts"],"names":[],"mappings":"AAUA,OAAO,EAAE,UAAU,EAAE,sBAAsB,EAAE,MAAM,2BAA2B,CAAC;AAM/E,qBAEa,UAAU;IAErB,EAAE,EAAE,MAAM,CAAC;IAMX,MAAM,EAAE,MAAM,CAAC;IAQf,MAAM,EAAE,UAAU,CAAC;IAQnB,iBAAiB,EAAE,sBAAsB,CAAC;IAM1C,SAAS,EAAE,MAAM,CAAC;IAKlB,QAAQ,EAAE,MAAM,CAAC;IAKjB,WAAW,EAAE,MAAM,CAAC;IAKpB,WAAW,EAAE,MAAM,CAAC;IAKpB,UAAU,EAAE,MAAM,CAAC;IAKnB,aAAa,EAAE,MAAM,CAAC;IAMtB,YAAY,EAAE,MAAM,CAAC;IAKrB,YAAY,EAAE,MAAM,CAAC;IAKrB,IAAI,EAAE,MAAM,CAAC;IAKb,KAAK,EAAE,MAAM,CAAC;IAKd,UAAU,EAAE,MAAM,CAAC;IAKnB,OAAO,EAAE,MAAM,CAAC;IAKhB,aAAa,EAAE,MAAM,CAAC;IAItB,WAAW,EAAE,IAAI,CAAC;IAGlB,UAAU,EAAE,IAAI,CAAC;IAGjB,UAAU,EAAE,IAAI,CAAC;IAGjB,UAAU,EAAE,IAAI,CAAC;IAKjB,eAAe,EAAE,MAAM,CAAC;IAKxB,WAAW,EAAE,MAAM,CAAC;IAKpB,UAAU,EAAE,MAAM,CAAC;IAInB,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAQlC,SAAS,EAAE,IAAI,CAAC;IAQhB,SAAS,EAAE,IAAI,CAAC;CACjB"}
@@ -0,0 +1,213 @@
1
+ "use strict";
2
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
3
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
6
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
7
+ };
8
+ var __metadata = (this && this.__metadata) || function (k, v) {
9
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
+ };
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ exports.KYCProfile = void 0;
13
+ const class_validator_1 = require("class-validator");
14
+ const typeorm_1 = require("typeorm");
15
+ const kyc_constant_1 = require("../constants/kyc.constant");
16
+ let KYCProfile = class KYCProfile {
17
+ id;
18
+ userId;
19
+ status;
20
+ verificationLevel;
21
+ firstName;
22
+ lastName;
23
+ dateOfBirth;
24
+ nationality;
25
+ occupation;
26
+ sourceOfFunds;
27
+ addressLine1;
28
+ addressLine2;
29
+ city;
30
+ state;
31
+ postalCode;
32
+ country;
33
+ residenceType;
34
+ submittedAt;
35
+ reviewedAt;
36
+ approvedAt;
37
+ rejectedAt;
38
+ rejectionReason;
39
+ reviewNotes;
40
+ reviewedBy;
41
+ metadata;
42
+ createdAt;
43
+ updatedAt;
44
+ };
45
+ exports.KYCProfile = KYCProfile;
46
+ __decorate([
47
+ (0, typeorm_1.PrimaryGeneratedColumn)('uuid'),
48
+ __metadata("design:type", String)
49
+ ], KYCProfile.prototype, "id", void 0);
50
+ __decorate([
51
+ (0, class_validator_1.IsString)(),
52
+ (0, class_validator_1.IsNotEmpty)(),
53
+ (0, typeorm_1.Column)(),
54
+ (0, typeorm_1.Index)(),
55
+ __metadata("design:type", String)
56
+ ], KYCProfile.prototype, "userId", void 0);
57
+ __decorate([
58
+ (0, class_validator_1.IsEnum)(kyc_constant_1.KYC_STATUS),
59
+ (0, typeorm_1.Column)({
60
+ type: 'enum',
61
+ enum: kyc_constant_1.KYC_STATUS,
62
+ default: kyc_constant_1.KYC_STATUS.PENDING,
63
+ }),
64
+ __metadata("design:type", String)
65
+ ], KYCProfile.prototype, "status", void 0);
66
+ __decorate([
67
+ (0, class_validator_1.IsEnum)(kyc_constant_1.KYC_VERIFICATION_LEVEL),
68
+ (0, typeorm_1.Column)({
69
+ type: 'enum',
70
+ enum: kyc_constant_1.KYC_VERIFICATION_LEVEL,
71
+ default: kyc_constant_1.KYC_VERIFICATION_LEVEL.NONE,
72
+ }),
73
+ __metadata("design:type", String)
74
+ ], KYCProfile.prototype, "verificationLevel", void 0);
75
+ __decorate([
76
+ (0, class_validator_1.IsString)(),
77
+ (0, class_validator_1.IsOptional)(),
78
+ (0, typeorm_1.Column)({ nullable: true }),
79
+ __metadata("design:type", String)
80
+ ], KYCProfile.prototype, "firstName", void 0);
81
+ __decorate([
82
+ (0, class_validator_1.IsString)(),
83
+ (0, class_validator_1.IsOptional)(),
84
+ (0, typeorm_1.Column)({ nullable: true }),
85
+ __metadata("design:type", String)
86
+ ], KYCProfile.prototype, "lastName", void 0);
87
+ __decorate([
88
+ (0, class_validator_1.IsString)(),
89
+ (0, class_validator_1.IsOptional)(),
90
+ (0, typeorm_1.Column)({ type: 'date', nullable: true }),
91
+ __metadata("design:type", String)
92
+ ], KYCProfile.prototype, "dateOfBirth", void 0);
93
+ __decorate([
94
+ (0, class_validator_1.IsString)(),
95
+ (0, class_validator_1.IsOptional)(),
96
+ (0, typeorm_1.Column)({ nullable: true }),
97
+ __metadata("design:type", String)
98
+ ], KYCProfile.prototype, "nationality", void 0);
99
+ __decorate([
100
+ (0, class_validator_1.IsString)(),
101
+ (0, class_validator_1.IsOptional)(),
102
+ (0, typeorm_1.Column)({ nullable: true }),
103
+ __metadata("design:type", String)
104
+ ], KYCProfile.prototype, "occupation", void 0);
105
+ __decorate([
106
+ (0, class_validator_1.IsString)(),
107
+ (0, class_validator_1.IsOptional)(),
108
+ (0, typeorm_1.Column)({ nullable: true }),
109
+ __metadata("design:type", String)
110
+ ], KYCProfile.prototype, "sourceOfFunds", void 0);
111
+ __decorate([
112
+ (0, class_validator_1.IsString)(),
113
+ (0, class_validator_1.IsOptional)(),
114
+ (0, typeorm_1.Column)({ nullable: true }),
115
+ __metadata("design:type", String)
116
+ ], KYCProfile.prototype, "addressLine1", void 0);
117
+ __decorate([
118
+ (0, class_validator_1.IsString)(),
119
+ (0, class_validator_1.IsOptional)(),
120
+ (0, typeorm_1.Column)({ nullable: true }),
121
+ __metadata("design:type", String)
122
+ ], KYCProfile.prototype, "addressLine2", void 0);
123
+ __decorate([
124
+ (0, class_validator_1.IsString)(),
125
+ (0, class_validator_1.IsOptional)(),
126
+ (0, typeorm_1.Column)({ nullable: true }),
127
+ __metadata("design:type", String)
128
+ ], KYCProfile.prototype, "city", void 0);
129
+ __decorate([
130
+ (0, class_validator_1.IsString)(),
131
+ (0, class_validator_1.IsOptional)(),
132
+ (0, typeorm_1.Column)({ nullable: true }),
133
+ __metadata("design:type", String)
134
+ ], KYCProfile.prototype, "state", void 0);
135
+ __decorate([
136
+ (0, class_validator_1.IsString)(),
137
+ (0, class_validator_1.IsOptional)(),
138
+ (0, typeorm_1.Column)({ nullable: true }),
139
+ __metadata("design:type", String)
140
+ ], KYCProfile.prototype, "postalCode", void 0);
141
+ __decorate([
142
+ (0, class_validator_1.IsString)(),
143
+ (0, class_validator_1.IsOptional)(),
144
+ (0, typeorm_1.Column)({ nullable: true }),
145
+ __metadata("design:type", String)
146
+ ], KYCProfile.prototype, "country", void 0);
147
+ __decorate([
148
+ (0, class_validator_1.IsString)(),
149
+ (0, class_validator_1.IsOptional)(),
150
+ (0, typeorm_1.Column)({ nullable: true }),
151
+ __metadata("design:type", String)
152
+ ], KYCProfile.prototype, "residenceType", void 0);
153
+ __decorate([
154
+ (0, typeorm_1.Column)({ type: 'timestamptz', nullable: true }),
155
+ __metadata("design:type", Date)
156
+ ], KYCProfile.prototype, "submittedAt", void 0);
157
+ __decorate([
158
+ (0, typeorm_1.Column)({ type: 'timestamptz', nullable: true }),
159
+ __metadata("design:type", Date)
160
+ ], KYCProfile.prototype, "reviewedAt", void 0);
161
+ __decorate([
162
+ (0, typeorm_1.Column)({ type: 'timestamptz', nullable: true }),
163
+ __metadata("design:type", Date)
164
+ ], KYCProfile.prototype, "approvedAt", void 0);
165
+ __decorate([
166
+ (0, typeorm_1.Column)({ type: 'timestamptz', nullable: true }),
167
+ __metadata("design:type", Date)
168
+ ], KYCProfile.prototype, "rejectedAt", void 0);
169
+ __decorate([
170
+ (0, class_validator_1.IsString)(),
171
+ (0, class_validator_1.IsOptional)(),
172
+ (0, typeorm_1.Column)({ type: 'text', nullable: true }),
173
+ __metadata("design:type", String)
174
+ ], KYCProfile.prototype, "rejectionReason", void 0);
175
+ __decorate([
176
+ (0, class_validator_1.IsString)(),
177
+ (0, class_validator_1.IsOptional)(),
178
+ (0, typeorm_1.Column)({ type: 'text', nullable: true }),
179
+ __metadata("design:type", String)
180
+ ], KYCProfile.prototype, "reviewNotes", void 0);
181
+ __decorate([
182
+ (0, class_validator_1.IsString)(),
183
+ (0, class_validator_1.IsOptional)(),
184
+ (0, typeorm_1.Column)({ nullable: true }),
185
+ __metadata("design:type", String)
186
+ ], KYCProfile.prototype, "reviewedBy", void 0);
187
+ __decorate([
188
+ (0, typeorm_1.Column)({ type: 'jsonb', nullable: true }),
189
+ __metadata("design:type", Object)
190
+ ], KYCProfile.prototype, "metadata", void 0);
191
+ __decorate([
192
+ (0, typeorm_1.CreateDateColumn)({
193
+ name: 'createdAt',
194
+ nullable: false,
195
+ type: 'timestamptz',
196
+ default: () => 'CURRENT_TIMESTAMP',
197
+ }),
198
+ __metadata("design:type", Date)
199
+ ], KYCProfile.prototype, "createdAt", void 0);
200
+ __decorate([
201
+ (0, typeorm_1.UpdateDateColumn)({
202
+ name: 'updatedAt',
203
+ nullable: false,
204
+ type: 'timestamptz',
205
+ default: () => 'CURRENT_TIMESTAMP',
206
+ }),
207
+ __metadata("design:type", Date)
208
+ ], KYCProfile.prototype, "updatedAt", void 0);
209
+ exports.KYCProfile = KYCProfile = __decorate([
210
+ (0, typeorm_1.Entity)('kyc_profile'),
211
+ (0, typeorm_1.Index)(['userId'], { unique: true })
212
+ ], KYCProfile);
213
+ //# sourceMappingURL=kyc-profile.entity.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"kyc-profile.entity.js","sourceRoot":"","sources":["../../src/entities/kyc-profile.entity.ts"],"names":[],"mappings":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,EAAE,IAAI,EAAE,CAAC;;8CACR;AAInB;IADC,IAAA,gBAAM,EAAC,EAAE,IAAI,EAAE,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;4CACR;AAQlC;IANC,IAAA,0BAAgB,EAAC;QAChB,IAAI,EAAE,WAAW;QACjB,QAAQ,EAAE,KAAK;QACf,IAAI,EAAE,aAAa;QACnB,OAAO,EAAE,GAAG,EAAE,CAAC,mBAAmB;KACnC,CAAC;8BACS,IAAI;6CAAC;AAQhB;IANC,IAAA,0BAAgB,EAAC;QAChB,IAAI,EAAE,WAAW;QACjB,QAAQ,EAAE,KAAK;QACf,IAAI,EAAE,aAAa;QACnB,OAAO,EAAE,GAAG,EAAE,CAAC,mBAAmB;KACnC,CAAC;8BACS,IAAI;6CAAC;qBA3IL,UAAU;IAFtB,IAAA,gBAAM,EAAC,aAAa,CAAC;IACrB,IAAA,eAAK,EAAC,CAAC,QAAQ,CAAC,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC;GACvB,UAAU,CA4ItB"}
@@ -0,0 +1,21 @@
1
+ import { KYC_STATUS } from '../constants/kyc.constant';
2
+ import { KYCProfile } from './kyc-profile.entity';
3
+ export declare class KYCVerification {
4
+ id: string;
5
+ kycProfileId: string;
6
+ kycProfile: KYCProfile;
7
+ verificationType: string;
8
+ status: KYC_STATUS;
9
+ provider: string;
10
+ providerVerificationId: string;
11
+ providerResponse: Record<string, unknown>;
12
+ confidenceScore: number;
13
+ notes: string;
14
+ rejectionReason: string;
15
+ verifiedAt: Date;
16
+ verifiedBy: string;
17
+ metadata: Record<string, unknown>;
18
+ createdAt: Date;
19
+ updatedAt: Date;
20
+ }
21
+ //# sourceMappingURL=kyc-verification.entity.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"kyc-verification.entity.d.ts","sourceRoot":"","sources":["../../src/entities/kyc-verification.entity.ts"],"names":[],"mappings":"AAYA,OAAO,EAAE,UAAU,EAAE,MAAM,2BAA2B,CAAC;AACvD,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAMlD,qBAEa,eAAe;IAE1B,EAAE,EAAE,MAAM,CAAC;IAMX,YAAY,EAAE,MAAM,CAAC;IAIrB,UAAU,EAAE,UAAU,CAAC;IAKvB,gBAAgB,EAAE,MAAM,CAAC;IAQzB,MAAM,EAAE,UAAU,CAAC;IAKnB,QAAQ,EAAE,MAAM,CAAC;IAKjB,sBAAsB,EAAE,MAAM,CAAC;IAG/B,gBAAgB,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAG1C,eAAe,EAAE,MAAM,CAAC;IAKxB,KAAK,EAAE,MAAM,CAAC;IAKd,eAAe,EAAE,MAAM,CAAC;IAGxB,UAAU,EAAE,IAAI,CAAC;IAKjB,UAAU,EAAE,MAAM,CAAC;IAInB,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAQlC,SAAS,EAAE,IAAI,CAAC;IAQhB,SAAS,EAAE,IAAI,CAAC;CACjB"}
@@ -0,0 +1,135 @@
1
+ "use strict";
2
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
3
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
6
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
7
+ };
8
+ var __metadata = (this && this.__metadata) || function (k, v) {
9
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
+ };
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ exports.KYCVerification = void 0;
13
+ const class_validator_1 = require("class-validator");
14
+ const typeorm_1 = require("typeorm");
15
+ const kyc_constant_1 = require("../constants/kyc.constant");
16
+ const kyc_profile_entity_1 = require("./kyc-profile.entity");
17
+ let KYCVerification = class KYCVerification {
18
+ id;
19
+ kycProfileId;
20
+ kycProfile;
21
+ verificationType;
22
+ status;
23
+ provider;
24
+ providerVerificationId;
25
+ providerResponse;
26
+ confidenceScore;
27
+ notes;
28
+ rejectionReason;
29
+ verifiedAt;
30
+ verifiedBy;
31
+ metadata;
32
+ createdAt;
33
+ updatedAt;
34
+ };
35
+ exports.KYCVerification = KYCVerification;
36
+ __decorate([
37
+ (0, typeorm_1.PrimaryGeneratedColumn)('uuid'),
38
+ __metadata("design:type", String)
39
+ ], KYCVerification.prototype, "id", void 0);
40
+ __decorate([
41
+ (0, class_validator_1.IsString)(),
42
+ (0, class_validator_1.IsNotEmpty)(),
43
+ (0, typeorm_1.Column)(),
44
+ (0, typeorm_1.Index)(),
45
+ __metadata("design:type", String)
46
+ ], KYCVerification.prototype, "kycProfileId", void 0);
47
+ __decorate([
48
+ (0, typeorm_1.ManyToOne)(() => kyc_profile_entity_1.KYCProfile, { onDelete: 'CASCADE' }),
49
+ (0, typeorm_1.JoinColumn)({ name: 'kycProfileId' }),
50
+ __metadata("design:type", kyc_profile_entity_1.KYCProfile)
51
+ ], KYCVerification.prototype, "kycProfile", void 0);
52
+ __decorate([
53
+ (0, class_validator_1.IsString)(),
54
+ (0, class_validator_1.IsNotEmpty)(),
55
+ (0, typeorm_1.Column)(),
56
+ __metadata("design:type", String)
57
+ ], KYCVerification.prototype, "verificationType", void 0);
58
+ __decorate([
59
+ (0, class_validator_1.IsEnum)(kyc_constant_1.KYC_STATUS),
60
+ (0, typeorm_1.Column)({
61
+ type: 'enum',
62
+ enum: kyc_constant_1.KYC_STATUS,
63
+ default: kyc_constant_1.KYC_STATUS.PENDING,
64
+ }),
65
+ __metadata("design:type", String)
66
+ ], KYCVerification.prototype, "status", void 0);
67
+ __decorate([
68
+ (0, class_validator_1.IsString)(),
69
+ (0, class_validator_1.IsOptional)(),
70
+ (0, typeorm_1.Column)({ nullable: true }),
71
+ __metadata("design:type", String)
72
+ ], KYCVerification.prototype, "provider", void 0);
73
+ __decorate([
74
+ (0, class_validator_1.IsString)(),
75
+ (0, class_validator_1.IsOptional)(),
76
+ (0, typeorm_1.Column)({ nullable: true }),
77
+ __metadata("design:type", String)
78
+ ], KYCVerification.prototype, "providerVerificationId", void 0);
79
+ __decorate([
80
+ (0, typeorm_1.Column)({ type: 'jsonb', nullable: true }),
81
+ __metadata("design:type", Object)
82
+ ], KYCVerification.prototype, "providerResponse", void 0);
83
+ __decorate([
84
+ (0, typeorm_1.Column)({ type: 'decimal', precision: 5, scale: 2, nullable: true }),
85
+ __metadata("design:type", Number)
86
+ ], KYCVerification.prototype, "confidenceScore", void 0);
87
+ __decorate([
88
+ (0, class_validator_1.IsString)(),
89
+ (0, class_validator_1.IsOptional)(),
90
+ (0, typeorm_1.Column)({ type: 'text', nullable: true }),
91
+ __metadata("design:type", String)
92
+ ], KYCVerification.prototype, "notes", void 0);
93
+ __decorate([
94
+ (0, class_validator_1.IsString)(),
95
+ (0, class_validator_1.IsOptional)(),
96
+ (0, typeorm_1.Column)({ type: 'text', nullable: true }),
97
+ __metadata("design:type", String)
98
+ ], KYCVerification.prototype, "rejectionReason", void 0);
99
+ __decorate([
100
+ (0, typeorm_1.Column)({ type: 'timestamptz', nullable: true }),
101
+ __metadata("design:type", Date)
102
+ ], KYCVerification.prototype, "verifiedAt", void 0);
103
+ __decorate([
104
+ (0, class_validator_1.IsString)(),
105
+ (0, class_validator_1.IsOptional)(),
106
+ (0, typeorm_1.Column)({ nullable: true }),
107
+ __metadata("design:type", String)
108
+ ], KYCVerification.prototype, "verifiedBy", void 0);
109
+ __decorate([
110
+ (0, typeorm_1.Column)({ type: 'jsonb', nullable: true }),
111
+ __metadata("design:type", Object)
112
+ ], KYCVerification.prototype, "metadata", void 0);
113
+ __decorate([
114
+ (0, typeorm_1.CreateDateColumn)({
115
+ name: 'createdAt',
116
+ nullable: false,
117
+ type: 'timestamptz',
118
+ default: () => 'CURRENT_TIMESTAMP',
119
+ }),
120
+ __metadata("design:type", Date)
121
+ ], KYCVerification.prototype, "createdAt", void 0);
122
+ __decorate([
123
+ (0, typeorm_1.UpdateDateColumn)({
124
+ name: 'updatedAt',
125
+ nullable: false,
126
+ type: 'timestamptz',
127
+ default: () => 'CURRENT_TIMESTAMP',
128
+ }),
129
+ __metadata("design:type", Date)
130
+ ], KYCVerification.prototype, "updatedAt", void 0);
131
+ exports.KYCVerification = KYCVerification = __decorate([
132
+ (0, typeorm_1.Entity)('kyc_verification'),
133
+ (0, typeorm_1.Index)(['kycProfileId', 'verificationType'], { unique: true })
134
+ ], KYCVerification);
135
+ //# sourceMappingURL=kyc-verification.entity.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"kyc-verification.entity.js","sourceRoot":"","sources":["../../src/entities/kyc-verification.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAA2E;AAC3E,qCASiB;AAEjB,4DAAuD;AACvD,6DAAkD;AAQ3C,IAAM,eAAe,GAArB,MAAM,eAAe;IAE1B,EAAE,CAAS;IAMX,YAAY,CAAS;IAIrB,UAAU,CAAa;IAKvB,gBAAgB,CAAS;IAQzB,MAAM,CAAa;IAKnB,QAAQ,CAAS;IAKjB,sBAAsB,CAAS;IAG/B,gBAAgB,CAA0B;IAG1C,eAAe,CAAS;IAKxB,KAAK,CAAS;IAKd,eAAe,CAAS;IAGxB,UAAU,CAAO;IAKjB,UAAU,CAAS;IAInB,QAAQ,CAA0B;IAQlC,SAAS,CAAO;IAQhB,SAAS,CAAO;CACjB,CAAA;AAhFY,0CAAe;AAE1B;IADC,IAAA,gCAAsB,EAAC,MAAM,CAAC;;2CACpB;AAMX;IAJC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;IACZ,IAAA,gBAAM,GAAE;IACR,IAAA,eAAK,GAAE;;qDACa;AAIrB;IAFC,IAAA,mBAAS,EAAC,GAAG,EAAE,CAAC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gBAAM,EAAC,EAAE,IAAI,EAAE,aAAa,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;8BACpC,IAAI;mDAAC;AAKjB;IAHC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;IACZ,IAAA,gBAAM,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;mDACR;AAInB;IADC,IAAA,gBAAM,EAAC,EAAE,IAAI,EAAE,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;iDACR;AAQlC;IANC,IAAA,0BAAgB,EAAC;QAChB,IAAI,EAAE,WAAW;QACjB,QAAQ,EAAE,KAAK;QACf,IAAI,EAAE,aAAa;QACnB,OAAO,EAAE,GAAG,EAAE,CAAC,mBAAmB;KACnC,CAAC;8BACS,IAAI;kDAAC;AAQhB;IANC,IAAA,0BAAgB,EAAC;QAChB,IAAI,EAAE,WAAW;QACjB,QAAQ,EAAE,KAAK;QACf,IAAI,EAAE,aAAa;QACnB,OAAO,EAAE,GAAG,EAAE,CAAC,mBAAmB;KACnC,CAAC;8BACS,IAAI;kDAAC;0BA/EL,eAAe;IAF3B,IAAA,gBAAM,EAAC,kBAAkB,CAAC;IAC1B,IAAA,eAAK,EAAC,CAAC,cAAc,EAAE,kBAAkB,CAAC,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC;GACjD,eAAe,CAgF3B"}
@@ -0,0 +1,12 @@
1
+ export * from './constants/kyc.constant';
2
+ export * from './dtos/create-kyc-profile.dto';
3
+ export * from './dtos/update-kyc-profile.dto';
4
+ export * from './entities/kyc-document.entity';
5
+ export * from './entities/kyc-profile.entity';
6
+ export * from './entities/kyc-verification.entity';
7
+ export * from './interfaces/kyc-provider.interface';
8
+ export * from './providers';
9
+ export * from './services/kyc-provider.service';
10
+ export * from './services/kyc.service';
11
+ export * from './kyc.module';
12
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,0BAA0B,CAAC;AACzC,cAAc,+BAA+B,CAAC;AAC9C,cAAc,+BAA+B,CAAC;AAC9C,cAAc,gCAAgC,CAAC;AAC/C,cAAc,+BAA+B,CAAC;AAC9C,cAAc,oCAAoC,CAAC;AACnD,cAAc,qCAAqC,CAAC;AACpD,cAAc,aAAa,CAAC;AAC5B,cAAc,iCAAiC,CAAC;AAChD,cAAc,wBAAwB,CAAC;AACvC,cAAc,cAAc,CAAC"}
package/dist/index.js ADDED
@@ -0,0 +1,28 @@
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("./constants/kyc.constant"), exports);
18
+ __exportStar(require("./dtos/create-kyc-profile.dto"), exports);
19
+ __exportStar(require("./dtos/update-kyc-profile.dto"), exports);
20
+ __exportStar(require("./entities/kyc-document.entity"), exports);
21
+ __exportStar(require("./entities/kyc-profile.entity"), exports);
22
+ __exportStar(require("./entities/kyc-verification.entity"), exports);
23
+ __exportStar(require("./interfaces/kyc-provider.interface"), exports);
24
+ __exportStar(require("./providers"), exports);
25
+ __exportStar(require("./services/kyc-provider.service"), exports);
26
+ __exportStar(require("./services/kyc.service"), exports);
27
+ __exportStar(require("./kyc.module"), exports);
28
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,2DAAyC;AACzC,gEAA8C;AAC9C,gEAA8C;AAC9C,iEAA+C;AAC/C,gEAA8C;AAC9C,qEAAmD;AACnD,sEAAoD;AACpD,8CAA4B;AAC5B,kEAAgD;AAChD,yDAAuC;AACvC,+CAA6B"}