@voyantjs/legal 0.5.0 → 0.6.2
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/dist/contracts/route-runtime.d.ts +9 -0
- package/dist/contracts/route-runtime.d.ts.map +1 -0
- package/dist/contracts/route-runtime.js +7 -0
- package/dist/contracts/routes.d.ts +165 -93
- package/dist/contracts/routes.d.ts.map +1 -1
- package/dist/contracts/routes.js +61 -26
- package/dist/contracts/schema.d.ts +1 -1
- package/dist/contracts/service-contracts.d.ts +37 -25
- package/dist/contracts/service-contracts.d.ts.map +1 -1
- package/dist/contracts/service-contracts.js +8 -0
- package/dist/contracts/service-documents.d.ts +0 -1
- package/dist/contracts/service-documents.d.ts.map +1 -1
- package/dist/contracts/service-documents.js +3 -5
- package/dist/contracts/service-series.d.ts +4 -4
- package/dist/contracts/service-templates.d.ts +5 -5
- package/dist/contracts/service.d.ts +46 -34
- package/dist/contracts/service.d.ts.map +1 -1
- package/dist/contracts/validation.d.ts +15 -15
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +9 -1
- package/dist/policies/routes.d.ts +17 -17
- package/dist/policies/routes.d.ts.map +1 -1
- package/dist/policies/routes.js +16 -15
- package/dist/policies/service-core.d.ts +14 -14
- package/dist/policies/service.d.ts +14 -14
- package/package.json +8 -8
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import type { EventBus } from "@voyantjs/core";
|
|
1
|
+
import type { EventBus, ModuleContainer } from "@voyantjs/core";
|
|
2
2
|
import type { PostgresJsDatabase } from "drizzle-orm/postgres-js";
|
|
3
3
|
import { contractsService } from "./service.js";
|
|
4
4
|
type Env = {
|
|
5
5
|
Bindings: Record<string, unknown>;
|
|
6
6
|
Variables: {
|
|
7
|
+
container: ModuleContainer;
|
|
7
8
|
db: PostgresJsDatabase;
|
|
8
9
|
userId?: string;
|
|
9
10
|
};
|
|
@@ -11,9 +12,10 @@ type Env = {
|
|
|
11
12
|
export type ContractDocumentGenerator = Parameters<typeof contractsService.generateContractDocument>[3]["generator"];
|
|
12
13
|
export interface ContractsRouteOptions {
|
|
13
14
|
documentGenerator?: ContractDocumentGenerator;
|
|
14
|
-
resolveDocumentGenerator?: (bindings:
|
|
15
|
+
resolveDocumentGenerator?: (bindings: unknown) => ContractDocumentGenerator | undefined;
|
|
16
|
+
resolveDocumentDownloadUrl?: (bindings: unknown, storageKey: string) => Promise<string | null> | string | null;
|
|
15
17
|
eventBus?: EventBus;
|
|
16
|
-
resolveEventBus?: (bindings:
|
|
18
|
+
resolveEventBus?: (bindings: unknown) => EventBus | undefined;
|
|
17
19
|
}
|
|
18
20
|
export declare function createContractsAdminRoutes(options?: ContractsRouteOptions): import("hono/hono-base").HonoBase<Env, {
|
|
19
21
|
"/templates": {
|
|
@@ -83,13 +85,13 @@ export declare function createContractsAdminRoutes(options?: ContractsRouteOptio
|
|
|
83
85
|
data: {
|
|
84
86
|
id: string;
|
|
85
87
|
name: string;
|
|
86
|
-
active: boolean;
|
|
87
88
|
createdAt: string;
|
|
88
89
|
updatedAt: string;
|
|
89
|
-
description: string | null;
|
|
90
|
-
slug: string;
|
|
91
90
|
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
91
|
+
slug: string;
|
|
92
|
+
description: string | null;
|
|
92
93
|
language: string;
|
|
94
|
+
active: boolean;
|
|
93
95
|
bodyFormat: "markdown" | "html" | "lexical_json";
|
|
94
96
|
body: string;
|
|
95
97
|
variableSchema: import("hono/utils/types").JSONValue;
|
|
@@ -286,10 +288,10 @@ export declare function createContractsAdminRoutes(options?: ContractsRouteOptio
|
|
|
286
288
|
bodyFormat: "markdown" | "html" | "lexical_json";
|
|
287
289
|
body: string;
|
|
288
290
|
variableSchema: import("hono/utils/types").JSONValue;
|
|
289
|
-
templateId: string;
|
|
290
|
-
version: number;
|
|
291
291
|
changelog: string | null;
|
|
292
292
|
createdBy: string | null;
|
|
293
|
+
templateId: string;
|
|
294
|
+
version: number;
|
|
293
295
|
};
|
|
294
296
|
};
|
|
295
297
|
outputFormat: "json";
|
|
@@ -365,16 +367,16 @@ export declare function createContractsAdminRoutes(options?: ContractsRouteOptio
|
|
|
365
367
|
data: {
|
|
366
368
|
id: string;
|
|
367
369
|
name: string;
|
|
368
|
-
|
|
370
|
+
prefix: string;
|
|
369
371
|
createdAt: string;
|
|
370
372
|
updatedAt: string;
|
|
371
|
-
code: string;
|
|
372
373
|
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
373
|
-
|
|
374
|
+
code: string;
|
|
375
|
+
active: boolean;
|
|
374
376
|
separator: string;
|
|
375
377
|
padLength: number;
|
|
376
|
-
currentSequence: number;
|
|
377
378
|
resetStrategy: "never" | "annual" | "monthly";
|
|
379
|
+
currentSequence: number;
|
|
378
380
|
resetAt: string | null;
|
|
379
381
|
} | null;
|
|
380
382
|
};
|
|
@@ -497,7 +499,7 @@ export declare function createContractsAdminRoutes(options?: ContractsRouteOptio
|
|
|
497
499
|
id: string;
|
|
498
500
|
contractNumber: string | null;
|
|
499
501
|
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
500
|
-
status: "
|
|
502
|
+
status: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
501
503
|
title: string;
|
|
502
504
|
templateVersionId: string | null;
|
|
503
505
|
seriesId: string | null;
|
|
@@ -534,31 +536,31 @@ export declare function createContractsAdminRoutes(options?: ContractsRouteOptio
|
|
|
534
536
|
input: {};
|
|
535
537
|
output: {
|
|
536
538
|
data: {
|
|
539
|
+
metadata: import("hono/utils/types").JSONValue;
|
|
537
540
|
id: string;
|
|
538
|
-
status: "draft" | "sent" | "expired" | "issued" | "signed" | "executed" | "void";
|
|
539
541
|
createdAt: string;
|
|
540
542
|
updatedAt: string;
|
|
543
|
+
expiresAt: string | null;
|
|
544
|
+
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
541
545
|
organizationId: string | null;
|
|
546
|
+
status: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
547
|
+
language: string;
|
|
548
|
+
variables: import("hono/utils/types").JSONValue;
|
|
542
549
|
personId: string | null;
|
|
543
|
-
sentAt: string | null;
|
|
544
|
-
title: string;
|
|
545
|
-
metadata: import("hono/utils/types").JSONValue;
|
|
546
550
|
supplierId: string | null;
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
551
|
+
bookingId: string | null;
|
|
552
|
+
orderId: string | null;
|
|
553
|
+
title: string;
|
|
550
554
|
templateVersionId: string | null;
|
|
551
555
|
seriesId: string | null;
|
|
552
556
|
channelId: string | null;
|
|
553
|
-
|
|
554
|
-
|
|
557
|
+
sentAt: string | null;
|
|
558
|
+
contractNumber: string | null;
|
|
555
559
|
issuedAt: string | null;
|
|
556
560
|
executedAt: string | null;
|
|
557
|
-
expiresAt: string | null;
|
|
558
561
|
voidedAt: string | null;
|
|
559
562
|
renderedBodyFormat: "markdown" | "html" | "lexical_json";
|
|
560
563
|
renderedBody: string | null;
|
|
561
|
-
variables: import("hono/utils/types").JSONValue;
|
|
562
564
|
} | null;
|
|
563
565
|
};
|
|
564
566
|
outputFormat: "json";
|
|
@@ -589,7 +591,7 @@ export declare function createContractsAdminRoutes(options?: ContractsRouteOptio
|
|
|
589
591
|
id: string;
|
|
590
592
|
contractNumber: string | null;
|
|
591
593
|
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
592
|
-
status: "
|
|
594
|
+
status: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
593
595
|
title: string;
|
|
594
596
|
templateVersionId: string | null;
|
|
595
597
|
seriesId: string | null;
|
|
@@ -641,7 +643,7 @@ export declare function createContractsAdminRoutes(options?: ContractsRouteOptio
|
|
|
641
643
|
id: string;
|
|
642
644
|
contractNumber: string | null;
|
|
643
645
|
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
644
|
-
status: "
|
|
646
|
+
status: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
645
647
|
title: string;
|
|
646
648
|
templateVersionId: string | null;
|
|
647
649
|
seriesId: string | null;
|
|
@@ -741,7 +743,7 @@ export declare function createContractsAdminRoutes(options?: ContractsRouteOptio
|
|
|
741
743
|
id: string;
|
|
742
744
|
contractNumber: string | null;
|
|
743
745
|
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
744
|
-
status: "
|
|
746
|
+
status: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
745
747
|
title: string;
|
|
746
748
|
templateVersionId: string | null;
|
|
747
749
|
seriesId: string | null;
|
|
@@ -804,7 +806,7 @@ export declare function createContractsAdminRoutes(options?: ContractsRouteOptio
|
|
|
804
806
|
id: string;
|
|
805
807
|
contractNumber: string | null;
|
|
806
808
|
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
807
|
-
status: "
|
|
809
|
+
status: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
808
810
|
title: string;
|
|
809
811
|
templateVersionId: string | null;
|
|
810
812
|
seriesId: string | null;
|
|
@@ -868,7 +870,7 @@ export declare function createContractsAdminRoutes(options?: ContractsRouteOptio
|
|
|
868
870
|
id: string;
|
|
869
871
|
contractNumber: string | null;
|
|
870
872
|
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
871
|
-
status: "
|
|
873
|
+
status: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
872
874
|
title: string;
|
|
873
875
|
templateVersionId: string | null;
|
|
874
876
|
seriesId: string | null;
|
|
@@ -892,11 +894,12 @@ export declare function createContractsAdminRoutes(options?: ContractsRouteOptio
|
|
|
892
894
|
updatedAt: string;
|
|
893
895
|
} | null;
|
|
894
896
|
signature: {
|
|
897
|
+
metadata: import("hono/utils/types").JSONValue;
|
|
895
898
|
id: string;
|
|
896
899
|
createdAt: string;
|
|
900
|
+
ipAddress: string | null;
|
|
901
|
+
userAgent: string | null;
|
|
897
902
|
personId: string | null;
|
|
898
|
-
metadata: import("hono/utils/types").JSONValue;
|
|
899
|
-
contractId: string;
|
|
900
903
|
signerName: string;
|
|
901
904
|
signerEmail: string | null;
|
|
902
905
|
signerRole: string | null;
|
|
@@ -904,8 +907,7 @@ export declare function createContractsAdminRoutes(options?: ContractsRouteOptio
|
|
|
904
907
|
provider: string | null;
|
|
905
908
|
externalReference: string | null;
|
|
906
909
|
signatureData: string | null;
|
|
907
|
-
|
|
908
|
-
userAgent: string | null;
|
|
910
|
+
contractId: string;
|
|
909
911
|
signedAt: string;
|
|
910
912
|
} | null;
|
|
911
913
|
};
|
|
@@ -949,7 +951,7 @@ export declare function createContractsAdminRoutes(options?: ContractsRouteOptio
|
|
|
949
951
|
id: string;
|
|
950
952
|
contractNumber: string | null;
|
|
951
953
|
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
952
|
-
status: "
|
|
954
|
+
status: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
953
955
|
title: string;
|
|
954
956
|
templateVersionId: string | null;
|
|
955
957
|
seriesId: string | null;
|
|
@@ -1012,7 +1014,7 @@ export declare function createContractsAdminRoutes(options?: ContractsRouteOptio
|
|
|
1012
1014
|
id: string;
|
|
1013
1015
|
contractNumber: string | null;
|
|
1014
1016
|
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
1015
|
-
status: "
|
|
1017
|
+
status: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
1016
1018
|
title: string;
|
|
1017
1019
|
templateVersionId: string | null;
|
|
1018
1020
|
seriesId: string | null;
|
|
@@ -1126,20 +1128,20 @@ export declare function createContractsAdminRoutes(options?: ContractsRouteOptio
|
|
|
1126
1128
|
} | {
|
|
1127
1129
|
status: "generated";
|
|
1128
1130
|
contractId: string;
|
|
1129
|
-
contractStatus: "
|
|
1131
|
+
contractStatus: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
1130
1132
|
renderedBodyFormat: "markdown" | "html" | "lexical_json";
|
|
1131
1133
|
renderedBody: string;
|
|
1132
1134
|
attachment: {
|
|
1135
|
+
metadata: import("hono/utils/types").JSONValue;
|
|
1133
1136
|
id: string;
|
|
1134
1137
|
name: string;
|
|
1135
1138
|
createdAt: string;
|
|
1136
1139
|
kind: string;
|
|
1137
|
-
metadata: import("hono/utils/types").JSONValue;
|
|
1138
|
-
contractId: string;
|
|
1139
1140
|
mimeType: string | null;
|
|
1140
1141
|
fileSize: number | null;
|
|
1141
1142
|
storageKey: string | null;
|
|
1142
1143
|
checksum: string | null;
|
|
1144
|
+
contractId: string;
|
|
1143
1145
|
};
|
|
1144
1146
|
};
|
|
1145
1147
|
};
|
|
@@ -1205,20 +1207,20 @@ export declare function createContractsAdminRoutes(options?: ContractsRouteOptio
|
|
|
1205
1207
|
} | {
|
|
1206
1208
|
status: "generated";
|
|
1207
1209
|
contractId: string;
|
|
1208
|
-
contractStatus: "
|
|
1210
|
+
contractStatus: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
1209
1211
|
renderedBodyFormat: "markdown" | "html" | "lexical_json";
|
|
1210
1212
|
renderedBody: string;
|
|
1211
1213
|
attachment: {
|
|
1214
|
+
metadata: import("hono/utils/types").JSONValue;
|
|
1212
1215
|
id: string;
|
|
1213
1216
|
name: string;
|
|
1214
1217
|
createdAt: string;
|
|
1215
1218
|
kind: string;
|
|
1216
|
-
metadata: import("hono/utils/types").JSONValue;
|
|
1217
|
-
contractId: string;
|
|
1218
1219
|
mimeType: string | null;
|
|
1219
1220
|
fileSize: number | null;
|
|
1220
1221
|
storageKey: string | null;
|
|
1221
1222
|
checksum: string | null;
|
|
1223
|
+
contractId: string;
|
|
1222
1224
|
};
|
|
1223
1225
|
};
|
|
1224
1226
|
};
|
|
@@ -1304,16 +1306,16 @@ export declare function createContractsAdminRoutes(options?: ContractsRouteOptio
|
|
|
1304
1306
|
};
|
|
1305
1307
|
output: {
|
|
1306
1308
|
data: {
|
|
1309
|
+
metadata: import("hono/utils/types").JSONValue;
|
|
1307
1310
|
id: string;
|
|
1308
1311
|
name: string;
|
|
1309
1312
|
createdAt: string;
|
|
1310
1313
|
kind: string;
|
|
1311
|
-
metadata: import("hono/utils/types").JSONValue;
|
|
1312
|
-
contractId: string;
|
|
1313
1314
|
mimeType: string | null;
|
|
1314
1315
|
fileSize: number | null;
|
|
1315
1316
|
storageKey: string | null;
|
|
1316
1317
|
checksum: string | null;
|
|
1318
|
+
contractId: string;
|
|
1317
1319
|
};
|
|
1318
1320
|
};
|
|
1319
1321
|
outputFormat: "json";
|
|
@@ -1357,6 +1359,41 @@ export declare function createContractsAdminRoutes(options?: ContractsRouteOptio
|
|
|
1357
1359
|
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
1358
1360
|
};
|
|
1359
1361
|
};
|
|
1362
|
+
} & {
|
|
1363
|
+
"/attachments/:attachmentId/download": {
|
|
1364
|
+
$get: {
|
|
1365
|
+
input: {
|
|
1366
|
+
param: {
|
|
1367
|
+
attachmentId: string;
|
|
1368
|
+
};
|
|
1369
|
+
};
|
|
1370
|
+
output: {
|
|
1371
|
+
error: string;
|
|
1372
|
+
};
|
|
1373
|
+
outputFormat: "json";
|
|
1374
|
+
status: 404;
|
|
1375
|
+
} | {
|
|
1376
|
+
input: {
|
|
1377
|
+
param: {
|
|
1378
|
+
attachmentId: string;
|
|
1379
|
+
};
|
|
1380
|
+
};
|
|
1381
|
+
output: {
|
|
1382
|
+
error: string;
|
|
1383
|
+
};
|
|
1384
|
+
outputFormat: "json";
|
|
1385
|
+
status: 501;
|
|
1386
|
+
} | {
|
|
1387
|
+
input: {
|
|
1388
|
+
param: {
|
|
1389
|
+
attachmentId: string;
|
|
1390
|
+
};
|
|
1391
|
+
};
|
|
1392
|
+
output: undefined;
|
|
1393
|
+
outputFormat: "redirect";
|
|
1394
|
+
status: 302;
|
|
1395
|
+
};
|
|
1396
|
+
};
|
|
1360
1397
|
} & {
|
|
1361
1398
|
"/attachments/:attachmentId": {
|
|
1362
1399
|
$delete: {
|
|
@@ -1452,13 +1489,13 @@ export declare const contractsAdminRoutes: import("hono/hono-base").HonoBase<Env
|
|
|
1452
1489
|
data: {
|
|
1453
1490
|
id: string;
|
|
1454
1491
|
name: string;
|
|
1455
|
-
active: boolean;
|
|
1456
1492
|
createdAt: string;
|
|
1457
1493
|
updatedAt: string;
|
|
1458
|
-
description: string | null;
|
|
1459
|
-
slug: string;
|
|
1460
1494
|
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
1495
|
+
slug: string;
|
|
1496
|
+
description: string | null;
|
|
1461
1497
|
language: string;
|
|
1498
|
+
active: boolean;
|
|
1462
1499
|
bodyFormat: "markdown" | "html" | "lexical_json";
|
|
1463
1500
|
body: string;
|
|
1464
1501
|
variableSchema: import("hono/utils/types").JSONValue;
|
|
@@ -1655,10 +1692,10 @@ export declare const contractsAdminRoutes: import("hono/hono-base").HonoBase<Env
|
|
|
1655
1692
|
bodyFormat: "markdown" | "html" | "lexical_json";
|
|
1656
1693
|
body: string;
|
|
1657
1694
|
variableSchema: import("hono/utils/types").JSONValue;
|
|
1658
|
-
templateId: string;
|
|
1659
|
-
version: number;
|
|
1660
1695
|
changelog: string | null;
|
|
1661
1696
|
createdBy: string | null;
|
|
1697
|
+
templateId: string;
|
|
1698
|
+
version: number;
|
|
1662
1699
|
};
|
|
1663
1700
|
};
|
|
1664
1701
|
outputFormat: "json";
|
|
@@ -1734,16 +1771,16 @@ export declare const contractsAdminRoutes: import("hono/hono-base").HonoBase<Env
|
|
|
1734
1771
|
data: {
|
|
1735
1772
|
id: string;
|
|
1736
1773
|
name: string;
|
|
1737
|
-
|
|
1774
|
+
prefix: string;
|
|
1738
1775
|
createdAt: string;
|
|
1739
1776
|
updatedAt: string;
|
|
1740
|
-
code: string;
|
|
1741
1777
|
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
1742
|
-
|
|
1778
|
+
code: string;
|
|
1779
|
+
active: boolean;
|
|
1743
1780
|
separator: string;
|
|
1744
1781
|
padLength: number;
|
|
1745
|
-
currentSequence: number;
|
|
1746
1782
|
resetStrategy: "never" | "annual" | "monthly";
|
|
1783
|
+
currentSequence: number;
|
|
1747
1784
|
resetAt: string | null;
|
|
1748
1785
|
} | null;
|
|
1749
1786
|
};
|
|
@@ -1866,7 +1903,7 @@ export declare const contractsAdminRoutes: import("hono/hono-base").HonoBase<Env
|
|
|
1866
1903
|
id: string;
|
|
1867
1904
|
contractNumber: string | null;
|
|
1868
1905
|
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
1869
|
-
status: "
|
|
1906
|
+
status: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
1870
1907
|
title: string;
|
|
1871
1908
|
templateVersionId: string | null;
|
|
1872
1909
|
seriesId: string | null;
|
|
@@ -1903,31 +1940,31 @@ export declare const contractsAdminRoutes: import("hono/hono-base").HonoBase<Env
|
|
|
1903
1940
|
input: {};
|
|
1904
1941
|
output: {
|
|
1905
1942
|
data: {
|
|
1943
|
+
metadata: import("hono/utils/types").JSONValue;
|
|
1906
1944
|
id: string;
|
|
1907
|
-
status: "draft" | "sent" | "expired" | "issued" | "signed" | "executed" | "void";
|
|
1908
1945
|
createdAt: string;
|
|
1909
1946
|
updatedAt: string;
|
|
1947
|
+
expiresAt: string | null;
|
|
1948
|
+
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
1910
1949
|
organizationId: string | null;
|
|
1950
|
+
status: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
1951
|
+
language: string;
|
|
1952
|
+
variables: import("hono/utils/types").JSONValue;
|
|
1911
1953
|
personId: string | null;
|
|
1912
|
-
sentAt: string | null;
|
|
1913
|
-
title: string;
|
|
1914
|
-
metadata: import("hono/utils/types").JSONValue;
|
|
1915
1954
|
supplierId: string | null;
|
|
1916
|
-
|
|
1917
|
-
|
|
1918
|
-
|
|
1955
|
+
bookingId: string | null;
|
|
1956
|
+
orderId: string | null;
|
|
1957
|
+
title: string;
|
|
1919
1958
|
templateVersionId: string | null;
|
|
1920
1959
|
seriesId: string | null;
|
|
1921
1960
|
channelId: string | null;
|
|
1922
|
-
|
|
1923
|
-
|
|
1961
|
+
sentAt: string | null;
|
|
1962
|
+
contractNumber: string | null;
|
|
1924
1963
|
issuedAt: string | null;
|
|
1925
1964
|
executedAt: string | null;
|
|
1926
|
-
expiresAt: string | null;
|
|
1927
1965
|
voidedAt: string | null;
|
|
1928
1966
|
renderedBodyFormat: "markdown" | "html" | "lexical_json";
|
|
1929
1967
|
renderedBody: string | null;
|
|
1930
|
-
variables: import("hono/utils/types").JSONValue;
|
|
1931
1968
|
} | null;
|
|
1932
1969
|
};
|
|
1933
1970
|
outputFormat: "json";
|
|
@@ -1958,7 +1995,7 @@ export declare const contractsAdminRoutes: import("hono/hono-base").HonoBase<Env
|
|
|
1958
1995
|
id: string;
|
|
1959
1996
|
contractNumber: string | null;
|
|
1960
1997
|
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
1961
|
-
status: "
|
|
1998
|
+
status: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
1962
1999
|
title: string;
|
|
1963
2000
|
templateVersionId: string | null;
|
|
1964
2001
|
seriesId: string | null;
|
|
@@ -2010,7 +2047,7 @@ export declare const contractsAdminRoutes: import("hono/hono-base").HonoBase<Env
|
|
|
2010
2047
|
id: string;
|
|
2011
2048
|
contractNumber: string | null;
|
|
2012
2049
|
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
2013
|
-
status: "
|
|
2050
|
+
status: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
2014
2051
|
title: string;
|
|
2015
2052
|
templateVersionId: string | null;
|
|
2016
2053
|
seriesId: string | null;
|
|
@@ -2110,7 +2147,7 @@ export declare const contractsAdminRoutes: import("hono/hono-base").HonoBase<Env
|
|
|
2110
2147
|
id: string;
|
|
2111
2148
|
contractNumber: string | null;
|
|
2112
2149
|
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
2113
|
-
status: "
|
|
2150
|
+
status: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
2114
2151
|
title: string;
|
|
2115
2152
|
templateVersionId: string | null;
|
|
2116
2153
|
seriesId: string | null;
|
|
@@ -2173,7 +2210,7 @@ export declare const contractsAdminRoutes: import("hono/hono-base").HonoBase<Env
|
|
|
2173
2210
|
id: string;
|
|
2174
2211
|
contractNumber: string | null;
|
|
2175
2212
|
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
2176
|
-
status: "
|
|
2213
|
+
status: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
2177
2214
|
title: string;
|
|
2178
2215
|
templateVersionId: string | null;
|
|
2179
2216
|
seriesId: string | null;
|
|
@@ -2237,7 +2274,7 @@ export declare const contractsAdminRoutes: import("hono/hono-base").HonoBase<Env
|
|
|
2237
2274
|
id: string;
|
|
2238
2275
|
contractNumber: string | null;
|
|
2239
2276
|
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
2240
|
-
status: "
|
|
2277
|
+
status: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
2241
2278
|
title: string;
|
|
2242
2279
|
templateVersionId: string | null;
|
|
2243
2280
|
seriesId: string | null;
|
|
@@ -2261,11 +2298,12 @@ export declare const contractsAdminRoutes: import("hono/hono-base").HonoBase<Env
|
|
|
2261
2298
|
updatedAt: string;
|
|
2262
2299
|
} | null;
|
|
2263
2300
|
signature: {
|
|
2301
|
+
metadata: import("hono/utils/types").JSONValue;
|
|
2264
2302
|
id: string;
|
|
2265
2303
|
createdAt: string;
|
|
2304
|
+
ipAddress: string | null;
|
|
2305
|
+
userAgent: string | null;
|
|
2266
2306
|
personId: string | null;
|
|
2267
|
-
metadata: import("hono/utils/types").JSONValue;
|
|
2268
|
-
contractId: string;
|
|
2269
2307
|
signerName: string;
|
|
2270
2308
|
signerEmail: string | null;
|
|
2271
2309
|
signerRole: string | null;
|
|
@@ -2273,8 +2311,7 @@ export declare const contractsAdminRoutes: import("hono/hono-base").HonoBase<Env
|
|
|
2273
2311
|
provider: string | null;
|
|
2274
2312
|
externalReference: string | null;
|
|
2275
2313
|
signatureData: string | null;
|
|
2276
|
-
|
|
2277
|
-
userAgent: string | null;
|
|
2314
|
+
contractId: string;
|
|
2278
2315
|
signedAt: string;
|
|
2279
2316
|
} | null;
|
|
2280
2317
|
};
|
|
@@ -2318,7 +2355,7 @@ export declare const contractsAdminRoutes: import("hono/hono-base").HonoBase<Env
|
|
|
2318
2355
|
id: string;
|
|
2319
2356
|
contractNumber: string | null;
|
|
2320
2357
|
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
2321
|
-
status: "
|
|
2358
|
+
status: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
2322
2359
|
title: string;
|
|
2323
2360
|
templateVersionId: string | null;
|
|
2324
2361
|
seriesId: string | null;
|
|
@@ -2381,7 +2418,7 @@ export declare const contractsAdminRoutes: import("hono/hono-base").HonoBase<Env
|
|
|
2381
2418
|
id: string;
|
|
2382
2419
|
contractNumber: string | null;
|
|
2383
2420
|
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
2384
|
-
status: "
|
|
2421
|
+
status: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
2385
2422
|
title: string;
|
|
2386
2423
|
templateVersionId: string | null;
|
|
2387
2424
|
seriesId: string | null;
|
|
@@ -2495,20 +2532,20 @@ export declare const contractsAdminRoutes: import("hono/hono-base").HonoBase<Env
|
|
|
2495
2532
|
} | {
|
|
2496
2533
|
status: "generated";
|
|
2497
2534
|
contractId: string;
|
|
2498
|
-
contractStatus: "
|
|
2535
|
+
contractStatus: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
2499
2536
|
renderedBodyFormat: "markdown" | "html" | "lexical_json";
|
|
2500
2537
|
renderedBody: string;
|
|
2501
2538
|
attachment: {
|
|
2539
|
+
metadata: import("hono/utils/types").JSONValue;
|
|
2502
2540
|
id: string;
|
|
2503
2541
|
name: string;
|
|
2504
2542
|
createdAt: string;
|
|
2505
2543
|
kind: string;
|
|
2506
|
-
metadata: import("hono/utils/types").JSONValue;
|
|
2507
|
-
contractId: string;
|
|
2508
2544
|
mimeType: string | null;
|
|
2509
2545
|
fileSize: number | null;
|
|
2510
2546
|
storageKey: string | null;
|
|
2511
2547
|
checksum: string | null;
|
|
2548
|
+
contractId: string;
|
|
2512
2549
|
};
|
|
2513
2550
|
};
|
|
2514
2551
|
};
|
|
@@ -2574,20 +2611,20 @@ export declare const contractsAdminRoutes: import("hono/hono-base").HonoBase<Env
|
|
|
2574
2611
|
} | {
|
|
2575
2612
|
status: "generated";
|
|
2576
2613
|
contractId: string;
|
|
2577
|
-
contractStatus: "
|
|
2614
|
+
contractStatus: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
2578
2615
|
renderedBodyFormat: "markdown" | "html" | "lexical_json";
|
|
2579
2616
|
renderedBody: string;
|
|
2580
2617
|
attachment: {
|
|
2618
|
+
metadata: import("hono/utils/types").JSONValue;
|
|
2581
2619
|
id: string;
|
|
2582
2620
|
name: string;
|
|
2583
2621
|
createdAt: string;
|
|
2584
2622
|
kind: string;
|
|
2585
|
-
metadata: import("hono/utils/types").JSONValue;
|
|
2586
|
-
contractId: string;
|
|
2587
2623
|
mimeType: string | null;
|
|
2588
2624
|
fileSize: number | null;
|
|
2589
2625
|
storageKey: string | null;
|
|
2590
2626
|
checksum: string | null;
|
|
2627
|
+
contractId: string;
|
|
2591
2628
|
};
|
|
2592
2629
|
};
|
|
2593
2630
|
};
|
|
@@ -2673,16 +2710,16 @@ export declare const contractsAdminRoutes: import("hono/hono-base").HonoBase<Env
|
|
|
2673
2710
|
};
|
|
2674
2711
|
output: {
|
|
2675
2712
|
data: {
|
|
2713
|
+
metadata: import("hono/utils/types").JSONValue;
|
|
2676
2714
|
id: string;
|
|
2677
2715
|
name: string;
|
|
2678
2716
|
createdAt: string;
|
|
2679
2717
|
kind: string;
|
|
2680
|
-
metadata: import("hono/utils/types").JSONValue;
|
|
2681
|
-
contractId: string;
|
|
2682
2718
|
mimeType: string | null;
|
|
2683
2719
|
fileSize: number | null;
|
|
2684
2720
|
storageKey: string | null;
|
|
2685
2721
|
checksum: string | null;
|
|
2722
|
+
contractId: string;
|
|
2686
2723
|
};
|
|
2687
2724
|
};
|
|
2688
2725
|
outputFormat: "json";
|
|
@@ -2726,6 +2763,41 @@ export declare const contractsAdminRoutes: import("hono/hono-base").HonoBase<Env
|
|
|
2726
2763
|
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
2727
2764
|
};
|
|
2728
2765
|
};
|
|
2766
|
+
} & {
|
|
2767
|
+
"/attachments/:attachmentId/download": {
|
|
2768
|
+
$get: {
|
|
2769
|
+
input: {
|
|
2770
|
+
param: {
|
|
2771
|
+
attachmentId: string;
|
|
2772
|
+
};
|
|
2773
|
+
};
|
|
2774
|
+
output: {
|
|
2775
|
+
error: string;
|
|
2776
|
+
};
|
|
2777
|
+
outputFormat: "json";
|
|
2778
|
+
status: 404;
|
|
2779
|
+
} | {
|
|
2780
|
+
input: {
|
|
2781
|
+
param: {
|
|
2782
|
+
attachmentId: string;
|
|
2783
|
+
};
|
|
2784
|
+
};
|
|
2785
|
+
output: {
|
|
2786
|
+
error: string;
|
|
2787
|
+
};
|
|
2788
|
+
outputFormat: "json";
|
|
2789
|
+
status: 501;
|
|
2790
|
+
} | {
|
|
2791
|
+
input: {
|
|
2792
|
+
param: {
|
|
2793
|
+
attachmentId: string;
|
|
2794
|
+
};
|
|
2795
|
+
};
|
|
2796
|
+
output: undefined;
|
|
2797
|
+
outputFormat: "redirect";
|
|
2798
|
+
status: 302;
|
|
2799
|
+
};
|
|
2800
|
+
};
|
|
2729
2801
|
} & {
|
|
2730
2802
|
"/attachments/:attachmentId": {
|
|
2731
2803
|
$delete: {
|
|
@@ -2838,7 +2910,7 @@ export declare function createContractsPublicRoutes(): import("hono/hono-base").
|
|
|
2838
2910
|
id: string;
|
|
2839
2911
|
contractNumber: string | null;
|
|
2840
2912
|
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
2841
|
-
status: "
|
|
2913
|
+
status: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
2842
2914
|
title: string;
|
|
2843
2915
|
templateVersionId: string | null;
|
|
2844
2916
|
seriesId: string | null;
|
|
@@ -2898,11 +2970,12 @@ export declare function createContractsPublicRoutes(): import("hono/hono-base").
|
|
|
2898
2970
|
output: {
|
|
2899
2971
|
data: {
|
|
2900
2972
|
signature: {
|
|
2973
|
+
metadata: import("hono/utils/types").JSONValue;
|
|
2901
2974
|
id: string;
|
|
2902
2975
|
createdAt: string;
|
|
2976
|
+
ipAddress: string | null;
|
|
2977
|
+
userAgent: string | null;
|
|
2903
2978
|
personId: string | null;
|
|
2904
|
-
metadata: import("hono/utils/types").JSONValue;
|
|
2905
|
-
contractId: string;
|
|
2906
2979
|
signerName: string;
|
|
2907
2980
|
signerEmail: string | null;
|
|
2908
2981
|
signerRole: string | null;
|
|
@@ -2910,8 +2983,7 @@ export declare function createContractsPublicRoutes(): import("hono/hono-base").
|
|
|
2910
2983
|
provider: string | null;
|
|
2911
2984
|
externalReference: string | null;
|
|
2912
2985
|
signatureData: string | null;
|
|
2913
|
-
|
|
2914
|
-
userAgent: string | null;
|
|
2986
|
+
contractId: string;
|
|
2915
2987
|
signedAt: string;
|
|
2916
2988
|
} | null;
|
|
2917
2989
|
};
|
|
@@ -3006,7 +3078,7 @@ export declare const contractsPublicRoutes: import("hono/hono-base").HonoBase<En
|
|
|
3006
3078
|
id: string;
|
|
3007
3079
|
contractNumber: string | null;
|
|
3008
3080
|
scope: "customer" | "partner" | "supplier" | "other" | "channel";
|
|
3009
|
-
status: "
|
|
3081
|
+
status: "void" | "draft" | "issued" | "sent" | "signed" | "executed" | "expired";
|
|
3010
3082
|
title: string;
|
|
3011
3083
|
templateVersionId: string | null;
|
|
3012
3084
|
seriesId: string | null;
|
|
@@ -3066,11 +3138,12 @@ export declare const contractsPublicRoutes: import("hono/hono-base").HonoBase<En
|
|
|
3066
3138
|
output: {
|
|
3067
3139
|
data: {
|
|
3068
3140
|
signature: {
|
|
3141
|
+
metadata: import("hono/utils/types").JSONValue;
|
|
3069
3142
|
id: string;
|
|
3070
3143
|
createdAt: string;
|
|
3144
|
+
ipAddress: string | null;
|
|
3145
|
+
userAgent: string | null;
|
|
3071
3146
|
personId: string | null;
|
|
3072
|
-
metadata: import("hono/utils/types").JSONValue;
|
|
3073
|
-
contractId: string;
|
|
3074
3147
|
signerName: string;
|
|
3075
3148
|
signerEmail: string | null;
|
|
3076
3149
|
signerRole: string | null;
|
|
@@ -3078,8 +3151,7 @@ export declare const contractsPublicRoutes: import("hono/hono-base").HonoBase<En
|
|
|
3078
3151
|
provider: string | null;
|
|
3079
3152
|
externalReference: string | null;
|
|
3080
3153
|
signatureData: string | null;
|
|
3081
|
-
|
|
3082
|
-
userAgent: string | null;
|
|
3154
|
+
contractId: string;
|
|
3083
3155
|
signedAt: string;
|
|
3084
3156
|
} | null;
|
|
3085
3157
|
};
|