@sphereon/ssi-sdk.data-store 0.36.1-feature.integration.fides.88 → 0.36.1-feature.vdx24.einvoice.inbox.127
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/index.cjs +238 -96
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +12 -1
- package/dist/index.d.ts +12 -1
- package/dist/index.js +240 -96
- package/dist/index.js.map +1 -1
- package/package.json +9 -8
- package/src/__tests__/contact.entities.test.ts +3 -3
- package/src/__tests__/contact.store.test.ts +3 -3
- package/src/__tests__/issuanceBranding.entities.test.ts +4 -4
- package/src/__tests__/issuanceBranding.store.test.ts +4 -4
- package/src/index.ts +12 -0
- package/src/migrations/generic/15-AddServiceMetadata.ts +66 -0
- package/src/migrations/generic/index.ts +15 -0
- package/src/migrations/index.ts +4 -0
- package/src/migrations/postgres/1764000000001-AddServiceMetadata.ts +44 -0
- package/src/migrations/sqlite/1764000000002-AddServiceMetadata.ts +41 -0
package/dist/index.js
CHANGED
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
var __defProp = Object.defineProperty;
|
|
2
2
|
var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
|
|
3
3
|
|
|
4
|
+
// src/index.ts
|
|
5
|
+
import { Entities as VeramoDataStoreEntities2 } from "@veramo/data-store";
|
|
6
|
+
|
|
4
7
|
// src/entities/contact/BaseConfigEntity.ts
|
|
5
8
|
import { BaseEntity as BaseEntity10, Entity as Entity12, JoinColumn as JoinColumn7, OneToOne as OneToOne6, PrimaryGeneratedColumn as PrimaryGeneratedColumn12, TableInheritance as TableInheritance2 } from "typeorm";
|
|
6
9
|
|
|
@@ -6894,6 +6897,9 @@ var cleanFilter = /* @__PURE__ */ __name((filter) => {
|
|
|
6894
6897
|
});
|
|
6895
6898
|
}, "cleanFilter");
|
|
6896
6899
|
|
|
6900
|
+
// src/migrations/generic/index.ts
|
|
6901
|
+
import { migrations as VeramoDataStoreMigrations, Entities as VeramoDataStoreEntities } from "@veramo/data-store";
|
|
6902
|
+
|
|
6897
6903
|
// src/migrations/generic/1-CreateContacts.ts
|
|
6898
6904
|
import Debug8 from "debug";
|
|
6899
6905
|
|
|
@@ -7942,32 +7948,153 @@ var AddLinkedVpFields1763387280000 = class {
|
|
|
7942
7948
|
}
|
|
7943
7949
|
};
|
|
7944
7950
|
|
|
7945
|
-
// src/migrations/generic/
|
|
7951
|
+
// src/migrations/generic/15-AddServiceMetadata.ts
|
|
7952
|
+
import Debug16 from "debug";
|
|
7953
|
+
|
|
7954
|
+
// src/migrations/postgres/1764000000001-AddServiceMetadata.ts
|
|
7946
7955
|
import Debug14 from "debug";
|
|
7947
7956
|
var debug14 = Debug14("sphereon:ssi-sdk:migrations");
|
|
7957
|
+
var AddServiceMetadata1764000000001 = class {
|
|
7958
|
+
static {
|
|
7959
|
+
__name(this, "AddServiceMetadata1764000000001");
|
|
7960
|
+
}
|
|
7961
|
+
name = "AddServiceMetadata1764000000001";
|
|
7962
|
+
async up(queryRunner) {
|
|
7963
|
+
const table = await queryRunner.getTable("service");
|
|
7964
|
+
if (!table) {
|
|
7965
|
+
debug14("AddServiceMetadata: Skipping migration - service table does not exist. This is expected if Veramo DID Manager is not being used. If you need service metadata support, ensure Veramo migrations run before SSI-SDK migrations.");
|
|
7966
|
+
console.warn("[SSI-SDK Migration] AddServiceMetadata: Skipping - service table does not exist (Veramo DID Manager not in use)");
|
|
7967
|
+
return;
|
|
7968
|
+
}
|
|
7969
|
+
await queryRunner.query(`
|
|
7970
|
+
ALTER TABLE "service"
|
|
7971
|
+
ADD COLUMN IF NOT EXISTS "metadata" jsonb
|
|
7972
|
+
`);
|
|
7973
|
+
debug14("AddServiceMetadata: Added metadata column to service table");
|
|
7974
|
+
}
|
|
7975
|
+
async down(queryRunner) {
|
|
7976
|
+
const table = await queryRunner.getTable("service");
|
|
7977
|
+
if (!table) {
|
|
7978
|
+
return;
|
|
7979
|
+
}
|
|
7980
|
+
await queryRunner.query(`
|
|
7981
|
+
ALTER TABLE "service"
|
|
7982
|
+
DROP COLUMN IF EXISTS "metadata"
|
|
7983
|
+
`);
|
|
7984
|
+
}
|
|
7985
|
+
};
|
|
7986
|
+
|
|
7987
|
+
// src/migrations/sqlite/1764000000002-AddServiceMetadata.ts
|
|
7988
|
+
import Debug15 from "debug";
|
|
7989
|
+
var debug15 = Debug15("sphereon:ssi-sdk:migrations");
|
|
7990
|
+
var AddServiceMetadata1764000000002 = class {
|
|
7991
|
+
static {
|
|
7992
|
+
__name(this, "AddServiceMetadata1764000000002");
|
|
7993
|
+
}
|
|
7994
|
+
name = "AddServiceMetadata1764000000002";
|
|
7995
|
+
async up(queryRunner) {
|
|
7996
|
+
const table = await queryRunner.getTable("service");
|
|
7997
|
+
if (!table) {
|
|
7998
|
+
debug15("AddServiceMetadata: Skipping migration - service table does not exist. This is expected if Veramo DID Manager is not being used. If you need service metadata support, ensure Veramo migrations run before SSI-SDK migrations.");
|
|
7999
|
+
console.warn("[SSI-SDK Migration] AddServiceMetadata: Skipping - service table does not exist (Veramo DID Manager not in use)");
|
|
8000
|
+
return;
|
|
8001
|
+
}
|
|
8002
|
+
const hasMetadataColumn = table.columns.some((col) => col.name === "metadata");
|
|
8003
|
+
if (!hasMetadataColumn) {
|
|
8004
|
+
await queryRunner.query(`
|
|
8005
|
+
ALTER TABLE "service"
|
|
8006
|
+
ADD COLUMN "metadata" text
|
|
8007
|
+
`);
|
|
8008
|
+
debug15("AddServiceMetadata: Added metadata column to service table");
|
|
8009
|
+
}
|
|
8010
|
+
}
|
|
8011
|
+
async down(queryRunner) {
|
|
8012
|
+
}
|
|
8013
|
+
};
|
|
8014
|
+
|
|
8015
|
+
// src/migrations/generic/15-AddServiceMetadata.ts
|
|
8016
|
+
var debug16 = Debug16("sphereon:ssi-sdk:migrations");
|
|
8017
|
+
var AddServiceMetadata1764000000000 = class {
|
|
8018
|
+
static {
|
|
8019
|
+
__name(this, "AddServiceMetadata1764000000000");
|
|
8020
|
+
}
|
|
8021
|
+
name = "AddServiceMetadata1764000000000";
|
|
8022
|
+
async up(queryRunner) {
|
|
8023
|
+
debug16("migration: adding metadata column to service table");
|
|
8024
|
+
const dbType = queryRunner.connection.driver.options.type;
|
|
8025
|
+
switch (dbType) {
|
|
8026
|
+
case "postgres": {
|
|
8027
|
+
debug16("using postgres migration file for AddServiceMetadata");
|
|
8028
|
+
const mig = new AddServiceMetadata1764000000001();
|
|
8029
|
+
await mig.up(queryRunner);
|
|
8030
|
+
debug16("Postgres migration statements for AddServiceMetadata executed");
|
|
8031
|
+
return;
|
|
8032
|
+
}
|
|
8033
|
+
case "sqlite":
|
|
8034
|
+
case "expo":
|
|
8035
|
+
case "react-native": {
|
|
8036
|
+
debug16("using sqlite/react-native migration file for AddServiceMetadata");
|
|
8037
|
+
const mig = new AddServiceMetadata1764000000002();
|
|
8038
|
+
await mig.up(queryRunner);
|
|
8039
|
+
debug16("SQLite migration statements for AddServiceMetadata executed");
|
|
8040
|
+
return;
|
|
8041
|
+
}
|
|
8042
|
+
default:
|
|
8043
|
+
return Promise.reject(`Migrations are currently only supported for sqlite, react-native, expo, and postgres for AddServiceMetadata. Was ${dbType}. Please run your database without migrations and with 'migrationsRun: false' and 'synchronize: true' for now`);
|
|
8044
|
+
}
|
|
8045
|
+
}
|
|
8046
|
+
async down(queryRunner) {
|
|
8047
|
+
debug16("migration: reverting metadata column from service table");
|
|
8048
|
+
const dbType = queryRunner.connection.driver.options.type;
|
|
8049
|
+
switch (dbType) {
|
|
8050
|
+
case "postgres": {
|
|
8051
|
+
debug16("using postgres migration file for AddServiceMetadata");
|
|
8052
|
+
const mig = new AddServiceMetadata1764000000001();
|
|
8053
|
+
await mig.down(queryRunner);
|
|
8054
|
+
debug16("Postgres migration statements for AddServiceMetadata reverted");
|
|
8055
|
+
return;
|
|
8056
|
+
}
|
|
8057
|
+
case "sqlite":
|
|
8058
|
+
case "expo":
|
|
8059
|
+
case "react-native": {
|
|
8060
|
+
debug16("using sqlite/react-native migration file for AddServiceMetadata");
|
|
8061
|
+
const mig = new AddServiceMetadata1764000000002();
|
|
8062
|
+
await mig.down(queryRunner);
|
|
8063
|
+
debug16("SQLite migration statements for AddServiceMetadata reverted");
|
|
8064
|
+
return;
|
|
8065
|
+
}
|
|
8066
|
+
default:
|
|
8067
|
+
return Promise.reject(`Migrations are currently only supported for sqlite, react-native, expo, and postgres for AddServiceMetadata. Was ${dbType}. Please run your database without migrations and with 'migrationsRun: false' and 'synchronize: true' for now`);
|
|
8068
|
+
}
|
|
8069
|
+
}
|
|
8070
|
+
};
|
|
8071
|
+
|
|
8072
|
+
// src/migrations/generic/2-CreateIssuanceBranding.ts
|
|
8073
|
+
import Debug17 from "debug";
|
|
8074
|
+
var debug17 = Debug17("sphereon:ssi-sdk:migrations");
|
|
7948
8075
|
var CreateIssuanceBranding1659463079429 = class {
|
|
7949
8076
|
static {
|
|
7950
8077
|
__name(this, "CreateIssuanceBranding1659463079429");
|
|
7951
8078
|
}
|
|
7952
8079
|
name = "CreateIssuanceBranding1659463079429";
|
|
7953
8080
|
async up(queryRunner) {
|
|
7954
|
-
|
|
8081
|
+
debug17("migration: creating issuance branding tables");
|
|
7955
8082
|
const dbType = queryRunner.connection.driver.options.type;
|
|
7956
8083
|
switch (dbType) {
|
|
7957
8084
|
case "postgres": {
|
|
7958
|
-
|
|
8085
|
+
debug17("using postgres migration file");
|
|
7959
8086
|
const mig = new CreateIssuanceBranding1685628974232();
|
|
7960
8087
|
await mig.up(queryRunner);
|
|
7961
|
-
|
|
8088
|
+
debug17("Migration statements executed");
|
|
7962
8089
|
return;
|
|
7963
8090
|
}
|
|
7964
8091
|
case "sqlite":
|
|
7965
8092
|
case "expo":
|
|
7966
8093
|
case "react-native": {
|
|
7967
|
-
|
|
8094
|
+
debug17("using sqlite/react-native migration file");
|
|
7968
8095
|
const mig = new CreateIssuanceBranding1685628973231();
|
|
7969
8096
|
await mig.up(queryRunner);
|
|
7970
|
-
|
|
8097
|
+
debug17("Migration statements executed");
|
|
7971
8098
|
return;
|
|
7972
8099
|
}
|
|
7973
8100
|
default:
|
|
@@ -7975,23 +8102,23 @@ var CreateIssuanceBranding1659463079429 = class {
|
|
|
7975
8102
|
}
|
|
7976
8103
|
}
|
|
7977
8104
|
async down(queryRunner) {
|
|
7978
|
-
|
|
8105
|
+
debug17("migration: reverting issuance branding tables");
|
|
7979
8106
|
const dbType = queryRunner.connection.driver.options.type;
|
|
7980
8107
|
switch (dbType) {
|
|
7981
8108
|
case "postgres": {
|
|
7982
|
-
|
|
8109
|
+
debug17("using postgres migration file");
|
|
7983
8110
|
const mig = new CreateIssuanceBranding1685628974232();
|
|
7984
8111
|
await mig.down(queryRunner);
|
|
7985
|
-
|
|
8112
|
+
debug17("Migration statements executed");
|
|
7986
8113
|
return;
|
|
7987
8114
|
}
|
|
7988
8115
|
case "sqlite":
|
|
7989
8116
|
case "expo":
|
|
7990
8117
|
case "react-native": {
|
|
7991
|
-
|
|
8118
|
+
debug17("using sqlite/react-native migration file");
|
|
7992
8119
|
const mig = new CreateIssuanceBranding1685628973231();
|
|
7993
8120
|
await mig.down(queryRunner);
|
|
7994
|
-
|
|
8121
|
+
debug17("Migration statements executed");
|
|
7995
8122
|
return;
|
|
7996
8123
|
}
|
|
7997
8124
|
default:
|
|
@@ -8001,7 +8128,7 @@ var CreateIssuanceBranding1659463079429 = class {
|
|
|
8001
8128
|
};
|
|
8002
8129
|
|
|
8003
8130
|
// src/migrations/generic/3-CreateContacts.ts
|
|
8004
|
-
import
|
|
8131
|
+
import Debug18 from "debug";
|
|
8005
8132
|
|
|
8006
8133
|
// src/migrations/postgres/1690925872592-CreateContacts.ts
|
|
8007
8134
|
import { enablePostgresUuidExtension as enablePostgresUuidExtension3 } from "@sphereon/ssi-sdk.core";
|
|
@@ -8222,30 +8349,30 @@ var CreateContacts1690925872693 = class {
|
|
|
8222
8349
|
};
|
|
8223
8350
|
|
|
8224
8351
|
// src/migrations/generic/3-CreateContacts.ts
|
|
8225
|
-
var
|
|
8352
|
+
var debug18 = Debug18("sphereon:ssi-sdk:migrations");
|
|
8226
8353
|
var CreateContacts1690925872318 = class {
|
|
8227
8354
|
static {
|
|
8228
8355
|
__name(this, "CreateContacts1690925872318");
|
|
8229
8356
|
}
|
|
8230
8357
|
name = "CreateContacts1690925872318";
|
|
8231
8358
|
async up(queryRunner) {
|
|
8232
|
-
|
|
8359
|
+
debug18("migration: creating contacts tables");
|
|
8233
8360
|
const dbType = queryRunner.connection.driver.options.type;
|
|
8234
8361
|
switch (dbType) {
|
|
8235
8362
|
case "postgres": {
|
|
8236
|
-
|
|
8363
|
+
debug18("using postgres migration file");
|
|
8237
8364
|
const mig = new CreateContacts1690925872592();
|
|
8238
8365
|
await mig.up(queryRunner);
|
|
8239
|
-
|
|
8366
|
+
debug18("Migration statements executed");
|
|
8240
8367
|
return;
|
|
8241
8368
|
}
|
|
8242
8369
|
case "sqlite":
|
|
8243
8370
|
case "expo":
|
|
8244
8371
|
case "react-native": {
|
|
8245
|
-
|
|
8372
|
+
debug18("using sqlite/react-native migration file");
|
|
8246
8373
|
const mig = new CreateContacts1690925872693();
|
|
8247
8374
|
await mig.up(queryRunner);
|
|
8248
|
-
|
|
8375
|
+
debug18("Migration statements executed");
|
|
8249
8376
|
return;
|
|
8250
8377
|
}
|
|
8251
8378
|
default:
|
|
@@ -8253,23 +8380,23 @@ var CreateContacts1690925872318 = class {
|
|
|
8253
8380
|
}
|
|
8254
8381
|
}
|
|
8255
8382
|
async down(queryRunner) {
|
|
8256
|
-
|
|
8383
|
+
debug18("migration: reverting contacts tables");
|
|
8257
8384
|
const dbType = queryRunner.connection.driver.options.type;
|
|
8258
8385
|
switch (dbType) {
|
|
8259
8386
|
case "postgres": {
|
|
8260
|
-
|
|
8387
|
+
debug18("using postgres migration file");
|
|
8261
8388
|
const mig = new CreateContacts1690925872592();
|
|
8262
8389
|
await mig.down(queryRunner);
|
|
8263
|
-
|
|
8390
|
+
debug18("Migration statements executed");
|
|
8264
8391
|
return;
|
|
8265
8392
|
}
|
|
8266
8393
|
case "sqlite":
|
|
8267
8394
|
case "expo":
|
|
8268
8395
|
case "react-native": {
|
|
8269
|
-
|
|
8396
|
+
debug18("using sqlite/react-native migration file");
|
|
8270
8397
|
const mig = new CreateContacts1690925872693();
|
|
8271
8398
|
await mig.down(queryRunner);
|
|
8272
|
-
|
|
8399
|
+
debug18("Migration statements executed");
|
|
8273
8400
|
return;
|
|
8274
8401
|
}
|
|
8275
8402
|
default:
|
|
@@ -8279,7 +8406,7 @@ var CreateContacts1690925872318 = class {
|
|
|
8279
8406
|
};
|
|
8280
8407
|
|
|
8281
8408
|
// src/migrations/generic/4-CreateStatusList.ts
|
|
8282
|
-
import
|
|
8409
|
+
import Debug19 from "debug";
|
|
8283
8410
|
|
|
8284
8411
|
// src/migrations/postgres/1693866470001-CreateStatusList.ts
|
|
8285
8412
|
var CreateStatusList1693866470001 = class {
|
|
@@ -8485,53 +8612,53 @@ var UpdateStatusList1737110469000 = class {
|
|
|
8485
8612
|
};
|
|
8486
8613
|
|
|
8487
8614
|
// src/migrations/generic/4-CreateStatusList.ts
|
|
8488
|
-
var
|
|
8615
|
+
var debug19 = Debug19("sphereon:ssi-sdk:migrations");
|
|
8489
8616
|
var CreateStatusList1693866470000 = class {
|
|
8490
8617
|
static {
|
|
8491
8618
|
__name(this, "CreateStatusList1693866470000");
|
|
8492
8619
|
}
|
|
8493
8620
|
name = "CreateStatusList1693866470000";
|
|
8494
8621
|
async up(queryRunner) {
|
|
8495
|
-
|
|
8622
|
+
debug19("migration: creating issuance branding tables");
|
|
8496
8623
|
const dbType = queryRunner.connection.driver.options.type;
|
|
8497
8624
|
if (dbType === "postgres") {
|
|
8498
|
-
|
|
8625
|
+
debug19("using postgres migration files");
|
|
8499
8626
|
const createMig = new CreateStatusList1693866470001();
|
|
8500
8627
|
await createMig.up(queryRunner);
|
|
8501
8628
|
const updateMig = new UpdateStatusList1737110469001();
|
|
8502
8629
|
const up = await updateMig.up(queryRunner);
|
|
8503
|
-
|
|
8630
|
+
debug19("Migration statements executed");
|
|
8504
8631
|
return up;
|
|
8505
8632
|
} else if (dbType === "sqlite" || dbType === "react-native" || dbType === "expo") {
|
|
8506
|
-
|
|
8633
|
+
debug19("using sqlite/react-native migration files");
|
|
8507
8634
|
const createMig = new CreateStatusList1693866470002();
|
|
8508
8635
|
await createMig.up(queryRunner);
|
|
8509
8636
|
const updateMig = new UpdateStatusList1737110469000();
|
|
8510
8637
|
const up = await updateMig.up(queryRunner);
|
|
8511
|
-
|
|
8638
|
+
debug19("Migration statements executed");
|
|
8512
8639
|
return up;
|
|
8513
8640
|
} else {
|
|
8514
8641
|
return Promise.reject(`Migrations are currently only supported for sqlite, react-native, expo and postgres. Was ${dbType}. Please run your database without migrations and with 'migrationsRun: false' and 'synchronize: true' for now`);
|
|
8515
8642
|
}
|
|
8516
8643
|
}
|
|
8517
8644
|
async down(queryRunner) {
|
|
8518
|
-
|
|
8645
|
+
debug19("migration: reverting issuance branding tables");
|
|
8519
8646
|
const dbType = queryRunner.connection.driver.options.type;
|
|
8520
8647
|
if (dbType === "postgres") {
|
|
8521
|
-
|
|
8648
|
+
debug19("using postgres migration files");
|
|
8522
8649
|
const updateMig = new UpdateStatusList1737110469001();
|
|
8523
8650
|
await updateMig.down(queryRunner);
|
|
8524
8651
|
const createMig = new CreateStatusList1693866470001();
|
|
8525
8652
|
const down = await createMig.down(queryRunner);
|
|
8526
|
-
|
|
8653
|
+
debug19("Migration statements executed");
|
|
8527
8654
|
return down;
|
|
8528
8655
|
} else if (dbType === "sqlite" || dbType === "react-native" || dbType === "expo") {
|
|
8529
|
-
|
|
8656
|
+
debug19("using sqlite/react-native migration files");
|
|
8530
8657
|
const updateMig = new UpdateStatusList1737110469000();
|
|
8531
8658
|
await updateMig.down(queryRunner);
|
|
8532
8659
|
const createMig = new CreateStatusList1693866470002();
|
|
8533
8660
|
const down = await createMig.down(queryRunner);
|
|
8534
|
-
|
|
8661
|
+
debug19("Migration statements executed");
|
|
8535
8662
|
return down;
|
|
8536
8663
|
} else {
|
|
8537
8664
|
return Promise.reject(`Migrations are currently only supported for sqlite, react-native, expo and postgres. Was ${dbType}. Please run your database without migrations and with 'migrationsRun: false' and 'synchronize: true' for now`);
|
|
@@ -8540,7 +8667,7 @@ var CreateStatusList1693866470000 = class {
|
|
|
8540
8667
|
};
|
|
8541
8668
|
|
|
8542
8669
|
// src/migrations/generic/5-CreateAuditEvents.ts
|
|
8543
|
-
import
|
|
8670
|
+
import Debug20 from "debug";
|
|
8544
8671
|
|
|
8545
8672
|
// src/migrations/postgres/1701634812183-CreateAuditEvents.ts
|
|
8546
8673
|
var CreateAuditEvents1701634812183 = class {
|
|
@@ -8639,30 +8766,30 @@ var CreateAuditEvents1701634819487 = class {
|
|
|
8639
8766
|
};
|
|
8640
8767
|
|
|
8641
8768
|
// src/migrations/generic/5-CreateAuditEvents.ts
|
|
8642
|
-
var
|
|
8769
|
+
var debug20 = Debug20("sphereon:ssi-sdk:migrations");
|
|
8643
8770
|
var CreateAuditEvents1701635835330 = class {
|
|
8644
8771
|
static {
|
|
8645
8772
|
__name(this, "CreateAuditEvents1701635835330");
|
|
8646
8773
|
}
|
|
8647
8774
|
name = "CreateAuditEvents1701635835330";
|
|
8648
8775
|
async up(queryRunner) {
|
|
8649
|
-
|
|
8776
|
+
debug20("migration: creating audit events tables");
|
|
8650
8777
|
const dbType = queryRunner.connection.driver.options.type;
|
|
8651
8778
|
switch (dbType) {
|
|
8652
8779
|
case "postgres": {
|
|
8653
|
-
|
|
8780
|
+
debug20("using postgres migration file");
|
|
8654
8781
|
const mig = new CreateAuditEvents1701634812183();
|
|
8655
8782
|
await mig.up(queryRunner);
|
|
8656
|
-
|
|
8783
|
+
debug20("Migration statements executed");
|
|
8657
8784
|
return;
|
|
8658
8785
|
}
|
|
8659
8786
|
case "sqlite":
|
|
8660
8787
|
case "expo":
|
|
8661
8788
|
case "react-native": {
|
|
8662
|
-
|
|
8789
|
+
debug20("using sqlite/react-native migration file");
|
|
8663
8790
|
const mig = new CreateAuditEvents1701634819487();
|
|
8664
8791
|
await mig.up(queryRunner);
|
|
8665
|
-
|
|
8792
|
+
debug20("Migration statements executed");
|
|
8666
8793
|
return;
|
|
8667
8794
|
}
|
|
8668
8795
|
default:
|
|
@@ -8670,23 +8797,23 @@ var CreateAuditEvents1701635835330 = class {
|
|
|
8670
8797
|
}
|
|
8671
8798
|
}
|
|
8672
8799
|
async down(queryRunner) {
|
|
8673
|
-
|
|
8800
|
+
debug20("migration: reverting audit events tables");
|
|
8674
8801
|
const dbType = queryRunner.connection.driver.options.type;
|
|
8675
8802
|
switch (dbType) {
|
|
8676
8803
|
case "postgres": {
|
|
8677
|
-
|
|
8804
|
+
debug20("using postgres migration file");
|
|
8678
8805
|
const mig = new CreateAuditEvents1701634812183();
|
|
8679
8806
|
await mig.down(queryRunner);
|
|
8680
|
-
|
|
8807
|
+
debug20("Migration statements executed");
|
|
8681
8808
|
return;
|
|
8682
8809
|
}
|
|
8683
8810
|
case "sqlite":
|
|
8684
8811
|
case "expo":
|
|
8685
8812
|
case "react-native": {
|
|
8686
|
-
|
|
8813
|
+
debug20("using sqlite/react-native migration file");
|
|
8687
8814
|
const mig = new CreateAuditEvents1701634819487();
|
|
8688
8815
|
await mig.down(queryRunner);
|
|
8689
|
-
|
|
8816
|
+
debug20("Migration statements executed");
|
|
8690
8817
|
return;
|
|
8691
8818
|
}
|
|
8692
8819
|
default:
|
|
@@ -8696,7 +8823,7 @@ var CreateAuditEvents1701635835330 = class {
|
|
|
8696
8823
|
};
|
|
8697
8824
|
|
|
8698
8825
|
// src/migrations/generic/6-CreateDigitalCredential.ts
|
|
8699
|
-
import
|
|
8826
|
+
import Debug21 from "debug";
|
|
8700
8827
|
|
|
8701
8828
|
// src/migrations/postgres/1708525189001-CreateDigitalCredential.ts
|
|
8702
8829
|
var CreateDigitalCredential1708525189001 = class {
|
|
@@ -8804,30 +8931,30 @@ var CreateDigitalCredential1708525189002 = class {
|
|
|
8804
8931
|
};
|
|
8805
8932
|
|
|
8806
8933
|
// src/migrations/generic/6-CreateDigitalCredential.ts
|
|
8807
|
-
var
|
|
8934
|
+
var debug21 = Debug21("sphereon:ssi-sdk:migrations");
|
|
8808
8935
|
var CreateDigitalCredential1708525189000 = class {
|
|
8809
8936
|
static {
|
|
8810
8937
|
__name(this, "CreateDigitalCredential1708525189000");
|
|
8811
8938
|
}
|
|
8812
8939
|
name = "CreateDigitalCredential1708525189000";
|
|
8813
8940
|
async up(queryRunner) {
|
|
8814
|
-
|
|
8941
|
+
debug21("migration: creating DigitalCredential tables");
|
|
8815
8942
|
const dbType = queryRunner.connection.driver.options.type;
|
|
8816
8943
|
switch (dbType) {
|
|
8817
8944
|
case "postgres": {
|
|
8818
|
-
|
|
8945
|
+
debug21("using postgres migration file for DigitalCredential");
|
|
8819
8946
|
const mig = new CreateDigitalCredential1708525189001();
|
|
8820
8947
|
await mig.up(queryRunner);
|
|
8821
|
-
|
|
8948
|
+
debug21("Postgres Migration statements for DigitalCredential executed");
|
|
8822
8949
|
return;
|
|
8823
8950
|
}
|
|
8824
8951
|
case "sqlite":
|
|
8825
8952
|
case "expo":
|
|
8826
8953
|
case "react-native": {
|
|
8827
|
-
|
|
8954
|
+
debug21("using sqlite/react-native migration file for DigitalCredential");
|
|
8828
8955
|
const mig = new CreateDigitalCredential1708525189002();
|
|
8829
8956
|
await mig.up(queryRunner);
|
|
8830
|
-
|
|
8957
|
+
debug21("SQLite Migration statements for DigitalCredential executed");
|
|
8831
8958
|
return;
|
|
8832
8959
|
}
|
|
8833
8960
|
default:
|
|
@@ -8835,23 +8962,23 @@ var CreateDigitalCredential1708525189000 = class {
|
|
|
8835
8962
|
}
|
|
8836
8963
|
}
|
|
8837
8964
|
async down(queryRunner) {
|
|
8838
|
-
|
|
8965
|
+
debug21("migration: reverting DigitalCredential tables");
|
|
8839
8966
|
const dbType = queryRunner.connection.driver.options.type;
|
|
8840
8967
|
switch (dbType) {
|
|
8841
8968
|
case "postgres": {
|
|
8842
|
-
|
|
8969
|
+
debug21("using postgres migration file for DigitalCredential");
|
|
8843
8970
|
const mig = new CreateDigitalCredential1708525189001();
|
|
8844
8971
|
await mig.down(queryRunner);
|
|
8845
|
-
|
|
8972
|
+
debug21("Postgres Migration statements for DigitalCredential reverted");
|
|
8846
8973
|
return;
|
|
8847
8974
|
}
|
|
8848
8975
|
case "sqlite":
|
|
8849
8976
|
case "expo":
|
|
8850
8977
|
case "react-native": {
|
|
8851
|
-
|
|
8978
|
+
debug21("using sqlite/react-native migration file for DigitalCredential");
|
|
8852
8979
|
const mig = new CreateDigitalCredential1708525189002();
|
|
8853
8980
|
await mig.down(queryRunner);
|
|
8854
|
-
|
|
8981
|
+
debug21("SQLite Migration statements for DigitalCredential reverted");
|
|
8855
8982
|
return;
|
|
8856
8983
|
}
|
|
8857
8984
|
default:
|
|
@@ -8861,7 +8988,7 @@ var CreateDigitalCredential1708525189000 = class {
|
|
|
8861
8988
|
};
|
|
8862
8989
|
|
|
8863
8990
|
// src/migrations/generic/7-CreateMachineStateStore.ts
|
|
8864
|
-
import
|
|
8991
|
+
import Debug22 from "debug";
|
|
8865
8992
|
|
|
8866
8993
|
// src/migrations/postgres/1708797018115-CreateMachineStateStore.ts
|
|
8867
8994
|
var CreateMachineStateStore1708797018115 = class {
|
|
@@ -8923,30 +9050,30 @@ var CreateMachineStateStore1708796002272 = class {
|
|
|
8923
9050
|
};
|
|
8924
9051
|
|
|
8925
9052
|
// src/migrations/generic/7-CreateMachineStateStore.ts
|
|
8926
|
-
var
|
|
9053
|
+
var debug22 = Debug22("sphereon:ssi-sdk:migrations");
|
|
8927
9054
|
var CreateMachineStateStore1708098041262 = class {
|
|
8928
9055
|
static {
|
|
8929
9056
|
__name(this, "CreateMachineStateStore1708098041262");
|
|
8930
9057
|
}
|
|
8931
9058
|
name = "CreateMachineStateStore1708098041262";
|
|
8932
9059
|
async up(queryRunner) {
|
|
8933
|
-
|
|
9060
|
+
debug22("migration: creating machine state tables");
|
|
8934
9061
|
const dbType = queryRunner.connection.driver.options.type;
|
|
8935
9062
|
switch (dbType) {
|
|
8936
9063
|
case "postgres": {
|
|
8937
|
-
|
|
9064
|
+
debug22("using postgres migration file");
|
|
8938
9065
|
const mig = new CreateMachineStateStore1708797018115();
|
|
8939
9066
|
await mig.up(queryRunner);
|
|
8940
|
-
|
|
9067
|
+
debug22("Migration statements executed");
|
|
8941
9068
|
return;
|
|
8942
9069
|
}
|
|
8943
9070
|
case "sqlite":
|
|
8944
9071
|
case "expo":
|
|
8945
9072
|
case "react-native": {
|
|
8946
|
-
|
|
9073
|
+
debug22("using sqlite/react-native migration file");
|
|
8947
9074
|
const mig = new CreateMachineStateStore1708796002272();
|
|
8948
9075
|
await mig.up(queryRunner);
|
|
8949
|
-
|
|
9076
|
+
debug22("Migration statements executed");
|
|
8950
9077
|
return;
|
|
8951
9078
|
}
|
|
8952
9079
|
default:
|
|
@@ -8954,23 +9081,23 @@ var CreateMachineStateStore1708098041262 = class {
|
|
|
8954
9081
|
}
|
|
8955
9082
|
}
|
|
8956
9083
|
async down(queryRunner) {
|
|
8957
|
-
|
|
9084
|
+
debug22("migration: reverting machine state tables");
|
|
8958
9085
|
const dbType = queryRunner.connection.driver.options.type;
|
|
8959
9086
|
switch (dbType) {
|
|
8960
9087
|
case "postgres": {
|
|
8961
|
-
|
|
9088
|
+
debug22("using postgres migration file");
|
|
8962
9089
|
const mig = new CreateMachineStateStore1708797018115();
|
|
8963
9090
|
await mig.down(queryRunner);
|
|
8964
|
-
|
|
9091
|
+
debug22("Migration statements executed");
|
|
8965
9092
|
return;
|
|
8966
9093
|
}
|
|
8967
9094
|
case "sqlite":
|
|
8968
9095
|
case "expo":
|
|
8969
9096
|
case "react-native": {
|
|
8970
|
-
|
|
9097
|
+
debug22("using sqlite/react-native migration file");
|
|
8971
9098
|
const mig = new CreateMachineStateStore1708796002272();
|
|
8972
9099
|
await mig.down(queryRunner);
|
|
8973
|
-
|
|
9100
|
+
debug22("Migration statements executed");
|
|
8974
9101
|
return;
|
|
8975
9102
|
}
|
|
8976
9103
|
default:
|
|
@@ -8980,7 +9107,7 @@ var CreateMachineStateStore1708098041262 = class {
|
|
|
8980
9107
|
};
|
|
8981
9108
|
|
|
8982
9109
|
// src/migrations/generic/8-CreateContacts.ts
|
|
8983
|
-
import
|
|
9110
|
+
import Debug23 from "debug";
|
|
8984
9111
|
|
|
8985
9112
|
// src/migrations/postgres/1710438363001-CreateContacts.ts
|
|
8986
9113
|
var CreateContacts1710438363001 = class {
|
|
@@ -9094,30 +9221,30 @@ var CreateContacts1710438363002 = class {
|
|
|
9094
9221
|
};
|
|
9095
9222
|
|
|
9096
9223
|
// src/migrations/generic/8-CreateContacts.ts
|
|
9097
|
-
var
|
|
9224
|
+
var debug23 = Debug23("sphereon:ssi-sdk:migrations");
|
|
9098
9225
|
var CreateContacts1708525189000 = class {
|
|
9099
9226
|
static {
|
|
9100
9227
|
__name(this, "CreateContacts1708525189000");
|
|
9101
9228
|
}
|
|
9102
9229
|
name = "CreateContacts1708525189000";
|
|
9103
9230
|
async up(queryRunner) {
|
|
9104
|
-
|
|
9231
|
+
debug23("migration: updating contact tables");
|
|
9105
9232
|
const dbType = queryRunner.connection.driver.options.type;
|
|
9106
9233
|
switch (dbType) {
|
|
9107
9234
|
case "postgres": {
|
|
9108
|
-
|
|
9235
|
+
debug23("using postgres migration file");
|
|
9109
9236
|
const mig = new CreateContacts1710438363001();
|
|
9110
9237
|
await mig.up(queryRunner);
|
|
9111
|
-
|
|
9238
|
+
debug23("Migration statements executed");
|
|
9112
9239
|
return;
|
|
9113
9240
|
}
|
|
9114
9241
|
case "sqlite":
|
|
9115
9242
|
case "expo":
|
|
9116
9243
|
case "react-native": {
|
|
9117
|
-
|
|
9244
|
+
debug23("using sqlite/react-native migration file");
|
|
9118
9245
|
const mig = new CreateContacts1710438363002();
|
|
9119
9246
|
await mig.up(queryRunner);
|
|
9120
|
-
|
|
9247
|
+
debug23("Migration statements executed");
|
|
9121
9248
|
return;
|
|
9122
9249
|
}
|
|
9123
9250
|
default:
|
|
@@ -9125,23 +9252,23 @@ var CreateContacts1708525189000 = class {
|
|
|
9125
9252
|
}
|
|
9126
9253
|
}
|
|
9127
9254
|
async down(queryRunner) {
|
|
9128
|
-
|
|
9255
|
+
debug23("migration: reverting machine state tables");
|
|
9129
9256
|
const dbType = queryRunner.connection.driver.options.type;
|
|
9130
9257
|
switch (dbType) {
|
|
9131
9258
|
case "postgres": {
|
|
9132
|
-
|
|
9259
|
+
debug23("using postgres migration file");
|
|
9133
9260
|
const mig = new CreateContacts1710438363001();
|
|
9134
9261
|
await mig.down(queryRunner);
|
|
9135
|
-
|
|
9262
|
+
debug23("Migration statements executed");
|
|
9136
9263
|
return;
|
|
9137
9264
|
}
|
|
9138
9265
|
case "sqlite":
|
|
9139
9266
|
case "expo":
|
|
9140
9267
|
case "react-native": {
|
|
9141
|
-
|
|
9268
|
+
debug23("using sqlite/react-native migration file");
|
|
9142
9269
|
const mig = new CreateContacts1710438363002();
|
|
9143
9270
|
await mig.down(queryRunner);
|
|
9144
|
-
|
|
9271
|
+
debug23("Migration statements executed");
|
|
9145
9272
|
return;
|
|
9146
9273
|
}
|
|
9147
9274
|
default:
|
|
@@ -9151,7 +9278,7 @@ var CreateContacts1708525189000 = class {
|
|
|
9151
9278
|
};
|
|
9152
9279
|
|
|
9153
9280
|
// src/migrations/generic/9-CreateContacts.ts
|
|
9154
|
-
import
|
|
9281
|
+
import Debug24 from "debug";
|
|
9155
9282
|
|
|
9156
9283
|
// src/migrations/postgres/1715761125001-CreateContacts.ts
|
|
9157
9284
|
var CreateContacts1715761125001 = class {
|
|
@@ -9263,30 +9390,30 @@ var CreateContacts1715761125002 = class {
|
|
|
9263
9390
|
};
|
|
9264
9391
|
|
|
9265
9392
|
// src/migrations/generic/9-CreateContacts.ts
|
|
9266
|
-
var
|
|
9393
|
+
var debug24 = Debug24("sphereon:ssi-sdk:migrations");
|
|
9267
9394
|
var CreateContacts1715761125000 = class {
|
|
9268
9395
|
static {
|
|
9269
9396
|
__name(this, "CreateContacts1715761125000");
|
|
9270
9397
|
}
|
|
9271
9398
|
name = "CreateContacts1715761125000";
|
|
9272
9399
|
async up(queryRunner) {
|
|
9273
|
-
|
|
9400
|
+
debug24("migration: updating contact tables");
|
|
9274
9401
|
const dbType = queryRunner.connection.driver.options.type;
|
|
9275
9402
|
switch (dbType) {
|
|
9276
9403
|
case "postgres": {
|
|
9277
|
-
|
|
9404
|
+
debug24("using postgres migration file");
|
|
9278
9405
|
const mig = new CreateContacts1715761125001();
|
|
9279
9406
|
await mig.up(queryRunner);
|
|
9280
|
-
|
|
9407
|
+
debug24("Migration statements executed");
|
|
9281
9408
|
return;
|
|
9282
9409
|
}
|
|
9283
9410
|
case "sqlite":
|
|
9284
9411
|
case "expo":
|
|
9285
9412
|
case "react-native": {
|
|
9286
|
-
|
|
9413
|
+
debug24("using sqlite/react-native migration file");
|
|
9287
9414
|
const mig = new CreateContacts1715761125002();
|
|
9288
9415
|
await mig.up(queryRunner);
|
|
9289
|
-
|
|
9416
|
+
debug24("Migration statements executed");
|
|
9290
9417
|
return;
|
|
9291
9418
|
}
|
|
9292
9419
|
default:
|
|
@@ -9294,23 +9421,23 @@ var CreateContacts1715761125000 = class {
|
|
|
9294
9421
|
}
|
|
9295
9422
|
}
|
|
9296
9423
|
async down(queryRunner) {
|
|
9297
|
-
|
|
9424
|
+
debug24("migration: reverting machine state tables");
|
|
9298
9425
|
const dbType = queryRunner.connection.driver.options.type;
|
|
9299
9426
|
switch (dbType) {
|
|
9300
9427
|
case "postgres": {
|
|
9301
|
-
|
|
9428
|
+
debug24("using postgres migration file");
|
|
9302
9429
|
const mig = new CreateContacts1715761125001();
|
|
9303
9430
|
await mig.down(queryRunner);
|
|
9304
|
-
|
|
9431
|
+
debug24("Migration statements executed");
|
|
9305
9432
|
return;
|
|
9306
9433
|
}
|
|
9307
9434
|
case "sqlite":
|
|
9308
9435
|
case "expo":
|
|
9309
9436
|
case "react-native": {
|
|
9310
|
-
|
|
9437
|
+
debug24("using sqlite/react-native migration file");
|
|
9311
9438
|
const mig = new CreateContacts1715761125002();
|
|
9312
9439
|
await mig.down(queryRunner);
|
|
9313
|
-
|
|
9440
|
+
debug24("Migration statements executed");
|
|
9314
9441
|
return;
|
|
9315
9442
|
}
|
|
9316
9443
|
default:
|
|
@@ -9349,6 +9476,9 @@ var DataStorePresentationDefinitionMigrations = [
|
|
|
9349
9476
|
CreatePresentationDefinitions1716533767523,
|
|
9350
9477
|
CreateDcqlQueryItem1726617600000
|
|
9351
9478
|
];
|
|
9479
|
+
var DataStoreServiceMigrations = [
|
|
9480
|
+
AddServiceMetadata1764000000000
|
|
9481
|
+
];
|
|
9352
9482
|
var DataStoreMigrations = [
|
|
9353
9483
|
...DataStoreContactMigrations,
|
|
9354
9484
|
...DataStoreIssuanceBrandingMigrations,
|
|
@@ -9356,7 +9486,12 @@ var DataStoreMigrations = [
|
|
|
9356
9486
|
...DataStoreEventLoggerMigrations,
|
|
9357
9487
|
...DataStoreDigitalCredentialMigrations,
|
|
9358
9488
|
...DataStoreMachineStateMigrations,
|
|
9359
|
-
...DataStorePresentationDefinitionMigrations
|
|
9489
|
+
...DataStorePresentationDefinitionMigrations,
|
|
9490
|
+
...DataStoreServiceMigrations
|
|
9491
|
+
];
|
|
9492
|
+
var DataStoreMigrationsWithVeramo = [
|
|
9493
|
+
...VeramoDataStoreMigrations,
|
|
9494
|
+
...DataStoreMigrations
|
|
9360
9495
|
];
|
|
9361
9496
|
|
|
9362
9497
|
// src/utils/digitalCredential/MappingUtils.ts
|
|
@@ -9587,6 +9722,10 @@ var DataStoreEntities = [
|
|
|
9587
9722
|
...DataStoreMachineStateEntities,
|
|
9588
9723
|
...DataStorePresentationDefinitionEntities
|
|
9589
9724
|
];
|
|
9725
|
+
var DataStoreEntitiesWithVeramo = [
|
|
9726
|
+
...VeramoDataStoreEntities2,
|
|
9727
|
+
...DataStoreEntities
|
|
9728
|
+
];
|
|
9590
9729
|
export {
|
|
9591
9730
|
AbstractEventLoggerStore2 as AbstractEventLoggerStore,
|
|
9592
9731
|
AuditEventEntity,
|
|
@@ -9608,6 +9747,7 @@ export {
|
|
|
9608
9747
|
DataStoreDigitalCredentialEntities,
|
|
9609
9748
|
DataStoreDigitalCredentialMigrations,
|
|
9610
9749
|
DataStoreEntities,
|
|
9750
|
+
DataStoreEntitiesWithVeramo,
|
|
9611
9751
|
DataStoreEventLoggerEntities,
|
|
9612
9752
|
DataStoreEventLoggerMigrations,
|
|
9613
9753
|
DataStoreIssuanceBrandingEntities,
|
|
@@ -9615,9 +9755,11 @@ export {
|
|
|
9615
9755
|
DataStoreMachineStateEntities,
|
|
9616
9756
|
DataStoreMachineStateMigrations,
|
|
9617
9757
|
DataStoreMigrations,
|
|
9758
|
+
DataStoreMigrationsWithVeramo,
|
|
9618
9759
|
DataStoreOid4vcStateEntities,
|
|
9619
9760
|
DataStorePresentationDefinitionEntities,
|
|
9620
9761
|
DataStorePresentationDefinitionMigrations,
|
|
9762
|
+
DataStoreServiceMigrations,
|
|
9621
9763
|
DataStoreStatusListEntities,
|
|
9622
9764
|
DataStoreStatusListMigrations,
|
|
9623
9765
|
DcqlQueryItemEntity,
|
|
@@ -9646,6 +9788,8 @@ export {
|
|
|
9646
9788
|
StatusListEntryEntity,
|
|
9647
9789
|
StatusListStore,
|
|
9648
9790
|
TextAttributesEntity,
|
|
9791
|
+
VeramoDataStoreEntities,
|
|
9792
|
+
VeramoDataStoreMigrations,
|
|
9649
9793
|
activityEventEntityFrom,
|
|
9650
9794
|
activityEventFrom,
|
|
9651
9795
|
auditEventEntityFrom,
|