@sphereon/ssi-sdk.data-store 0.34.1-feature.SSISDK.78.306 → 0.34.1-feature.SSISDK.82.linkedVP.325

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 CHANGED
@@ -2071,6 +2071,8 @@ var DigitalCredentialEntity = class extends import_typeorm17.BaseEntity {
2071
2071
  rpCorrelationId;
2072
2072
  verifiedState;
2073
2073
  tenantId;
2074
+ linkedVpId;
2075
+ linkedVpFrom;
2074
2076
  createdAt;
2075
2077
  presentedAt;
2076
2078
  lastUpdatedAt;
@@ -2233,6 +2235,21 @@ _ts_decorate18([
2233
2235
  }),
2234
2236
  _ts_metadata17("design:type", String)
2235
2237
  ], DigitalCredentialEntity.prototype, "tenantId", void 0);
2238
+ _ts_decorate18([
2239
+ (0, import_typeorm17.Column)("text", {
2240
+ name: "linked_vp_id",
2241
+ nullable: true
2242
+ }),
2243
+ _ts_metadata17("design:type", String)
2244
+ ], DigitalCredentialEntity.prototype, "linkedVpId", void 0);
2245
+ _ts_decorate18([
2246
+ (0, import_typeorm17.CreateDateColumn)({
2247
+ name: "linked_vp_from",
2248
+ nullable: true,
2249
+ type: (0, import_ssi_sdk14.typeOrmDateTime)()
2250
+ }),
2251
+ _ts_metadata17("design:type", typeof Date === "undefined" ? Object : Date)
2252
+ ], DigitalCredentialEntity.prototype, "linkedVpFrom", void 0);
2236
2253
  _ts_decorate18([
2237
2254
  (0, import_typeorm17.CreateDateColumn)({
2238
2255
  name: "created_at",
@@ -5430,6 +5447,37 @@ var DigitalCredentialStore = class extends import_ssi_sdk26.AbstractDigitalCrede
5430
5447
  total
5431
5448
  };
5432
5449
  }, "getCredentials");
5450
+ updateCredential = /* @__PURE__ */ __name(async (args) => {
5451
+ const dcRepo = await this.getRepository();
5452
+ const whereClause = {};
5453
+ if ("id" in args) {
5454
+ whereClause.id = args.id;
5455
+ } else if ("hash" in args) {
5456
+ whereClause.hash = args.hash;
5457
+ } else {
5458
+ return Promise.reject(Error("No id or hash param is provided."));
5459
+ }
5460
+ const credential = await dcRepo.findOne({
5461
+ where: whereClause
5462
+ });
5463
+ if (!credential) {
5464
+ return Promise.reject(Error(`No credential found for args: ${JSON.stringify(whereClause)}`));
5465
+ }
5466
+ const { id, hash, ...updates } = args;
5467
+ const updatedCredential = {
5468
+ ...credential,
5469
+ ...updates,
5470
+ id: credential.id,
5471
+ hash: credential.hash,
5472
+ createdAt: credential.createdAt,
5473
+ lastUpdatedAt: /* @__PURE__ */ new Date()
5474
+ };
5475
+ debug2("Updating credential", updatedCredential);
5476
+ const updatedResult = await dcRepo.save(updatedCredential, {
5477
+ transaction: true
5478
+ });
5479
+ return digitalCredentialFrom(updatedResult);
5480
+ }, "updateCredential");
5433
5481
  removeCredential = /* @__PURE__ */ __name(async (args) => {
5434
5482
  if (!args) {
5435
5483
  return false;
@@ -7898,32 +7946,148 @@ var CreateDcqlQueryItem1726617600000 = class {
7898
7946
  }
7899
7947
  };
7900
7948
 
7901
- // src/migrations/generic/2-CreateIssuanceBranding.ts
7949
+ // src/migrations/generic/14-AddLinkedVpFields.ts
7902
7950
  var import_debug13 = __toESM(require("debug"), 1);
7951
+
7952
+ // src/migrations/postgres/1763387280001-AddLinkedVpFields.ts
7953
+ var AddLinkedVpFields1763387280001 = class {
7954
+ static {
7955
+ __name(this, "AddLinkedVpFields1763387280001");
7956
+ }
7957
+ name = "AddLinkedVpFields1763387280001";
7958
+ async up(queryRunner) {
7959
+ await queryRunner.query(`
7960
+ ALTER TABLE "DigitalCredential"
7961
+ ADD COLUMN "linked_vp_id" text
7962
+ `);
7963
+ await queryRunner.query(`
7964
+ ALTER TABLE "DigitalCredential"
7965
+ ADD COLUMN "linked_vp_from" TIMESTAMP
7966
+ `);
7967
+ }
7968
+ async down(queryRunner) {
7969
+ await queryRunner.query(`
7970
+ ALTER TABLE "DigitalCredential"
7971
+ DROP COLUMN "linked_vp_from"
7972
+ `);
7973
+ await queryRunner.query(`
7974
+ ALTER TABLE "DigitalCredential"
7975
+ DROP COLUMN "linked_vp_id"
7976
+ `);
7977
+ }
7978
+ };
7979
+
7980
+ // src/migrations/sqlite/1763387280002-AddLinkedVpFields.ts
7981
+ var AddLinkedVpFields1763387280002 = class {
7982
+ static {
7983
+ __name(this, "AddLinkedVpFields1763387280002");
7984
+ }
7985
+ name = "AddLinkedVpFields1763387280002";
7986
+ async up(queryRunner) {
7987
+ await queryRunner.query(`
7988
+ ALTER TABLE "DigitalCredential"
7989
+ ADD COLUMN "linked_vp_id" text
7990
+ `);
7991
+ await queryRunner.query(`
7992
+ ALTER TABLE "DigitalCredential"
7993
+ ADD COLUMN "linked_vp_from" datetime
7994
+ `);
7995
+ }
7996
+ async down(queryRunner) {
7997
+ await queryRunner.query(`
7998
+ ALTER TABLE "DigitalCredential"
7999
+ DROP COLUMN "linked_vp_from"
8000
+ `);
8001
+ await queryRunner.query(`
8002
+ ALTER TABLE "DigitalCredential"
8003
+ DROP COLUMN "linked_vp_id"
8004
+ `);
8005
+ }
8006
+ };
8007
+
8008
+ // src/migrations/generic/14-AddLinkedVpFields.ts
7903
8009
  var debug13 = (0, import_debug13.default)("sphereon:ssi-sdk:migrations");
8010
+ var AddLinkedVpFields1763387280000 = class {
8011
+ static {
8012
+ __name(this, "AddLinkedVpFields1763387280000");
8013
+ }
8014
+ name = "AddLinkedVpFields1763387280000";
8015
+ async up(queryRunner) {
8016
+ debug13("migration: adding linked VP fields to DigitalCredential table");
8017
+ const dbType = queryRunner.connection.driver.options.type;
8018
+ switch (dbType) {
8019
+ case "postgres": {
8020
+ debug13("using postgres migration file for AddLinkedVpFields");
8021
+ const mig = new AddLinkedVpFields1763387280001();
8022
+ await mig.up(queryRunner);
8023
+ debug13("Postgres migration statements for AddLinkedVpFields executed");
8024
+ return;
8025
+ }
8026
+ case "sqlite":
8027
+ case "expo":
8028
+ case "react-native": {
8029
+ debug13("using sqlite/react-native migration file for AddLinkedVpFields");
8030
+ const mig = new AddLinkedVpFields1763387280002();
8031
+ await mig.up(queryRunner);
8032
+ debug13("SQLite migration statements for AddLinkedVpFields executed");
8033
+ return;
8034
+ }
8035
+ default:
8036
+ return Promise.reject(`Migrations are currently only supported for sqlite, react-native, expo, and postgres for AddLinkedVpFields. Was ${dbType}. Please run your database without migrations and with 'migrationsRun: false' and 'synchronize: true' for now`);
8037
+ }
8038
+ }
8039
+ async down(queryRunner) {
8040
+ debug13("migration: reverting linked VP fields from DigitalCredential table");
8041
+ const dbType = queryRunner.connection.driver.options.type;
8042
+ switch (dbType) {
8043
+ case "postgres": {
8044
+ debug13("using postgres migration file for AddLinkedVpFields");
8045
+ const mig = new AddLinkedVpFields1763387280001();
8046
+ await mig.down(queryRunner);
8047
+ debug13("Postgres migration statements for AddLinkedVpFields reverted");
8048
+ return;
8049
+ }
8050
+ case "sqlite":
8051
+ case "expo":
8052
+ case "react-native": {
8053
+ debug13("using sqlite/react-native migration file for AddLinkedVpFields");
8054
+ const mig = new AddLinkedVpFields1763387280002();
8055
+ await mig.down(queryRunner);
8056
+ debug13("SQLite migration statements for AddLinkedVpFields reverted");
8057
+ return;
8058
+ }
8059
+ default:
8060
+ return Promise.reject(`Migrations are currently only supported for sqlite, react-native, expo, and postgres for AddLinkedVpFields. Was ${dbType}. Please run your database without migrations and with 'migrationsRun: false' and 'synchronize: true' for now`);
8061
+ }
8062
+ }
8063
+ };
8064
+
8065
+ // src/migrations/generic/2-CreateIssuanceBranding.ts
8066
+ var import_debug14 = __toESM(require("debug"), 1);
8067
+ var debug14 = (0, import_debug14.default)("sphereon:ssi-sdk:migrations");
7904
8068
  var CreateIssuanceBranding1659463079429 = class {
7905
8069
  static {
7906
8070
  __name(this, "CreateIssuanceBranding1659463079429");
7907
8071
  }
7908
8072
  name = "CreateIssuanceBranding1659463079429";
7909
8073
  async up(queryRunner) {
7910
- debug13("migration: creating issuance branding tables");
8074
+ debug14("migration: creating issuance branding tables");
7911
8075
  const dbType = queryRunner.connection.driver.options.type;
7912
8076
  switch (dbType) {
7913
8077
  case "postgres": {
7914
- debug13("using postgres migration file");
8078
+ debug14("using postgres migration file");
7915
8079
  const mig = new CreateIssuanceBranding1685628974232();
7916
8080
  await mig.up(queryRunner);
7917
- debug13("Migration statements executed");
8081
+ debug14("Migration statements executed");
7918
8082
  return;
7919
8083
  }
7920
8084
  case "sqlite":
7921
8085
  case "expo":
7922
8086
  case "react-native": {
7923
- debug13("using sqlite/react-native migration file");
8087
+ debug14("using sqlite/react-native migration file");
7924
8088
  const mig = new CreateIssuanceBranding1685628973231();
7925
8089
  await mig.up(queryRunner);
7926
- debug13("Migration statements executed");
8090
+ debug14("Migration statements executed");
7927
8091
  return;
7928
8092
  }
7929
8093
  default:
@@ -7931,23 +8095,23 @@ var CreateIssuanceBranding1659463079429 = class {
7931
8095
  }
7932
8096
  }
7933
8097
  async down(queryRunner) {
7934
- debug13("migration: reverting issuance branding tables");
8098
+ debug14("migration: reverting issuance branding tables");
7935
8099
  const dbType = queryRunner.connection.driver.options.type;
7936
8100
  switch (dbType) {
7937
8101
  case "postgres": {
7938
- debug13("using postgres migration file");
8102
+ debug14("using postgres migration file");
7939
8103
  const mig = new CreateIssuanceBranding1685628974232();
7940
8104
  await mig.down(queryRunner);
7941
- debug13("Migration statements executed");
8105
+ debug14("Migration statements executed");
7942
8106
  return;
7943
8107
  }
7944
8108
  case "sqlite":
7945
8109
  case "expo":
7946
8110
  case "react-native": {
7947
- debug13("using sqlite/react-native migration file");
8111
+ debug14("using sqlite/react-native migration file");
7948
8112
  const mig = new CreateIssuanceBranding1685628973231();
7949
8113
  await mig.down(queryRunner);
7950
- debug13("Migration statements executed");
8114
+ debug14("Migration statements executed");
7951
8115
  return;
7952
8116
  }
7953
8117
  default:
@@ -7957,7 +8121,7 @@ var CreateIssuanceBranding1659463079429 = class {
7957
8121
  };
7958
8122
 
7959
8123
  // src/migrations/generic/3-CreateContacts.ts
7960
- var import_debug14 = __toESM(require("debug"), 1);
8124
+ var import_debug15 = __toESM(require("debug"), 1);
7961
8125
 
7962
8126
  // src/migrations/postgres/1690925872592-CreateContacts.ts
7963
8127
  var import_ssi_sdk33 = require("@sphereon/ssi-sdk.core");
@@ -8178,30 +8342,30 @@ var CreateContacts1690925872693 = class {
8178
8342
  };
8179
8343
 
8180
8344
  // src/migrations/generic/3-CreateContacts.ts
8181
- var debug14 = (0, import_debug14.default)("sphereon:ssi-sdk:migrations");
8345
+ var debug15 = (0, import_debug15.default)("sphereon:ssi-sdk:migrations");
8182
8346
  var CreateContacts1690925872318 = class {
8183
8347
  static {
8184
8348
  __name(this, "CreateContacts1690925872318");
8185
8349
  }
8186
8350
  name = "CreateContacts1690925872318";
8187
8351
  async up(queryRunner) {
8188
- debug14("migration: creating contacts tables");
8352
+ debug15("migration: creating contacts tables");
8189
8353
  const dbType = queryRunner.connection.driver.options.type;
8190
8354
  switch (dbType) {
8191
8355
  case "postgres": {
8192
- debug14("using postgres migration file");
8356
+ debug15("using postgres migration file");
8193
8357
  const mig = new CreateContacts1690925872592();
8194
8358
  await mig.up(queryRunner);
8195
- debug14("Migration statements executed");
8359
+ debug15("Migration statements executed");
8196
8360
  return;
8197
8361
  }
8198
8362
  case "sqlite":
8199
8363
  case "expo":
8200
8364
  case "react-native": {
8201
- debug14("using sqlite/react-native migration file");
8365
+ debug15("using sqlite/react-native migration file");
8202
8366
  const mig = new CreateContacts1690925872693();
8203
8367
  await mig.up(queryRunner);
8204
- debug14("Migration statements executed");
8368
+ debug15("Migration statements executed");
8205
8369
  return;
8206
8370
  }
8207
8371
  default:
@@ -8209,23 +8373,23 @@ var CreateContacts1690925872318 = class {
8209
8373
  }
8210
8374
  }
8211
8375
  async down(queryRunner) {
8212
- debug14("migration: reverting contacts tables");
8376
+ debug15("migration: reverting contacts tables");
8213
8377
  const dbType = queryRunner.connection.driver.options.type;
8214
8378
  switch (dbType) {
8215
8379
  case "postgres": {
8216
- debug14("using postgres migration file");
8380
+ debug15("using postgres migration file");
8217
8381
  const mig = new CreateContacts1690925872592();
8218
8382
  await mig.down(queryRunner);
8219
- debug14("Migration statements executed");
8383
+ debug15("Migration statements executed");
8220
8384
  return;
8221
8385
  }
8222
8386
  case "sqlite":
8223
8387
  case "expo":
8224
8388
  case "react-native": {
8225
- debug14("using sqlite/react-native migration file");
8389
+ debug15("using sqlite/react-native migration file");
8226
8390
  const mig = new CreateContacts1690925872693();
8227
8391
  await mig.down(queryRunner);
8228
- debug14("Migration statements executed");
8392
+ debug15("Migration statements executed");
8229
8393
  return;
8230
8394
  }
8231
8395
  default:
@@ -8235,7 +8399,7 @@ var CreateContacts1690925872318 = class {
8235
8399
  };
8236
8400
 
8237
8401
  // src/migrations/generic/4-CreateStatusList.ts
8238
- var import_debug15 = __toESM(require("debug"), 1);
8402
+ var import_debug16 = __toESM(require("debug"), 1);
8239
8403
 
8240
8404
  // src/migrations/postgres/1693866470001-CreateStatusList.ts
8241
8405
  var CreateStatusList1693866470001 = class {
@@ -8441,53 +8605,53 @@ var UpdateStatusList1737110469000 = class {
8441
8605
  };
8442
8606
 
8443
8607
  // src/migrations/generic/4-CreateStatusList.ts
8444
- var debug15 = (0, import_debug15.default)("sphereon:ssi-sdk:migrations");
8608
+ var debug16 = (0, import_debug16.default)("sphereon:ssi-sdk:migrations");
8445
8609
  var CreateStatusList1693866470000 = class {
8446
8610
  static {
8447
8611
  __name(this, "CreateStatusList1693866470000");
8448
8612
  }
8449
8613
  name = "CreateStatusList1693866470000";
8450
8614
  async up(queryRunner) {
8451
- debug15("migration: creating issuance branding tables");
8615
+ debug16("migration: creating issuance branding tables");
8452
8616
  const dbType = queryRunner.connection.driver.options.type;
8453
8617
  if (dbType === "postgres") {
8454
- debug15("using postgres migration files");
8618
+ debug16("using postgres migration files");
8455
8619
  const createMig = new CreateStatusList1693866470001();
8456
8620
  await createMig.up(queryRunner);
8457
8621
  const updateMig = new UpdateStatusList1737110469001();
8458
8622
  const up = await updateMig.up(queryRunner);
8459
- debug15("Migration statements executed");
8623
+ debug16("Migration statements executed");
8460
8624
  return up;
8461
8625
  } else if (dbType === "sqlite" || dbType === "react-native" || dbType === "expo") {
8462
- debug15("using sqlite/react-native migration files");
8626
+ debug16("using sqlite/react-native migration files");
8463
8627
  const createMig = new CreateStatusList1693866470002();
8464
8628
  await createMig.up(queryRunner);
8465
8629
  const updateMig = new UpdateStatusList1737110469000();
8466
8630
  const up = await updateMig.up(queryRunner);
8467
- debug15("Migration statements executed");
8631
+ debug16("Migration statements executed");
8468
8632
  return up;
8469
8633
  } else {
8470
8634
  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`);
8471
8635
  }
8472
8636
  }
8473
8637
  async down(queryRunner) {
8474
- debug15("migration: reverting issuance branding tables");
8638
+ debug16("migration: reverting issuance branding tables");
8475
8639
  const dbType = queryRunner.connection.driver.options.type;
8476
8640
  if (dbType === "postgres") {
8477
- debug15("using postgres migration files");
8641
+ debug16("using postgres migration files");
8478
8642
  const updateMig = new UpdateStatusList1737110469001();
8479
8643
  await updateMig.down(queryRunner);
8480
8644
  const createMig = new CreateStatusList1693866470001();
8481
8645
  const down = await createMig.down(queryRunner);
8482
- debug15("Migration statements executed");
8646
+ debug16("Migration statements executed");
8483
8647
  return down;
8484
8648
  } else if (dbType === "sqlite" || dbType === "react-native" || dbType === "expo") {
8485
- debug15("using sqlite/react-native migration files");
8649
+ debug16("using sqlite/react-native migration files");
8486
8650
  const updateMig = new UpdateStatusList1737110469000();
8487
8651
  await updateMig.down(queryRunner);
8488
8652
  const createMig = new CreateStatusList1693866470002();
8489
8653
  const down = await createMig.down(queryRunner);
8490
- debug15("Migration statements executed");
8654
+ debug16("Migration statements executed");
8491
8655
  return down;
8492
8656
  } else {
8493
8657
  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`);
@@ -8496,7 +8660,7 @@ var CreateStatusList1693866470000 = class {
8496
8660
  };
8497
8661
 
8498
8662
  // src/migrations/generic/5-CreateAuditEvents.ts
8499
- var import_debug16 = __toESM(require("debug"), 1);
8663
+ var import_debug17 = __toESM(require("debug"), 1);
8500
8664
 
8501
8665
  // src/migrations/postgres/1701634812183-CreateAuditEvents.ts
8502
8666
  var CreateAuditEvents1701634812183 = class {
@@ -8595,30 +8759,30 @@ var CreateAuditEvents1701634819487 = class {
8595
8759
  };
8596
8760
 
8597
8761
  // src/migrations/generic/5-CreateAuditEvents.ts
8598
- var debug16 = (0, import_debug16.default)("sphereon:ssi-sdk:migrations");
8762
+ var debug17 = (0, import_debug17.default)("sphereon:ssi-sdk:migrations");
8599
8763
  var CreateAuditEvents1701635835330 = class {
8600
8764
  static {
8601
8765
  __name(this, "CreateAuditEvents1701635835330");
8602
8766
  }
8603
8767
  name = "CreateAuditEvents1701635835330";
8604
8768
  async up(queryRunner) {
8605
- debug16("migration: creating audit events tables");
8769
+ debug17("migration: creating audit events tables");
8606
8770
  const dbType = queryRunner.connection.driver.options.type;
8607
8771
  switch (dbType) {
8608
8772
  case "postgres": {
8609
- debug16("using postgres migration file");
8773
+ debug17("using postgres migration file");
8610
8774
  const mig = new CreateAuditEvents1701634812183();
8611
8775
  await mig.up(queryRunner);
8612
- debug16("Migration statements executed");
8776
+ debug17("Migration statements executed");
8613
8777
  return;
8614
8778
  }
8615
8779
  case "sqlite":
8616
8780
  case "expo":
8617
8781
  case "react-native": {
8618
- debug16("using sqlite/react-native migration file");
8782
+ debug17("using sqlite/react-native migration file");
8619
8783
  const mig = new CreateAuditEvents1701634819487();
8620
8784
  await mig.up(queryRunner);
8621
- debug16("Migration statements executed");
8785
+ debug17("Migration statements executed");
8622
8786
  return;
8623
8787
  }
8624
8788
  default:
@@ -8626,23 +8790,23 @@ var CreateAuditEvents1701635835330 = class {
8626
8790
  }
8627
8791
  }
8628
8792
  async down(queryRunner) {
8629
- debug16("migration: reverting audit events tables");
8793
+ debug17("migration: reverting audit events tables");
8630
8794
  const dbType = queryRunner.connection.driver.options.type;
8631
8795
  switch (dbType) {
8632
8796
  case "postgres": {
8633
- debug16("using postgres migration file");
8797
+ debug17("using postgres migration file");
8634
8798
  const mig = new CreateAuditEvents1701634812183();
8635
8799
  await mig.down(queryRunner);
8636
- debug16("Migration statements executed");
8800
+ debug17("Migration statements executed");
8637
8801
  return;
8638
8802
  }
8639
8803
  case "sqlite":
8640
8804
  case "expo":
8641
8805
  case "react-native": {
8642
- debug16("using sqlite/react-native migration file");
8806
+ debug17("using sqlite/react-native migration file");
8643
8807
  const mig = new CreateAuditEvents1701634819487();
8644
8808
  await mig.down(queryRunner);
8645
- debug16("Migration statements executed");
8809
+ debug17("Migration statements executed");
8646
8810
  return;
8647
8811
  }
8648
8812
  default:
@@ -8652,7 +8816,7 @@ var CreateAuditEvents1701635835330 = class {
8652
8816
  };
8653
8817
 
8654
8818
  // src/migrations/generic/6-CreateDigitalCredential.ts
8655
- var import_debug17 = __toESM(require("debug"), 1);
8819
+ var import_debug18 = __toESM(require("debug"), 1);
8656
8820
 
8657
8821
  // src/migrations/postgres/1708525189001-CreateDigitalCredential.ts
8658
8822
  var CreateDigitalCredential1708525189001 = class {
@@ -8760,30 +8924,30 @@ var CreateDigitalCredential1708525189002 = class {
8760
8924
  };
8761
8925
 
8762
8926
  // src/migrations/generic/6-CreateDigitalCredential.ts
8763
- var debug17 = (0, import_debug17.default)("sphereon:ssi-sdk:migrations");
8927
+ var debug18 = (0, import_debug18.default)("sphereon:ssi-sdk:migrations");
8764
8928
  var CreateDigitalCredential1708525189000 = class {
8765
8929
  static {
8766
8930
  __name(this, "CreateDigitalCredential1708525189000");
8767
8931
  }
8768
8932
  name = "CreateDigitalCredential1708525189000";
8769
8933
  async up(queryRunner) {
8770
- debug17("migration: creating DigitalCredential tables");
8934
+ debug18("migration: creating DigitalCredential tables");
8771
8935
  const dbType = queryRunner.connection.driver.options.type;
8772
8936
  switch (dbType) {
8773
8937
  case "postgres": {
8774
- debug17("using postgres migration file for DigitalCredential");
8938
+ debug18("using postgres migration file for DigitalCredential");
8775
8939
  const mig = new CreateDigitalCredential1708525189001();
8776
8940
  await mig.up(queryRunner);
8777
- debug17("Postgres Migration statements for DigitalCredential executed");
8941
+ debug18("Postgres Migration statements for DigitalCredential executed");
8778
8942
  return;
8779
8943
  }
8780
8944
  case "sqlite":
8781
8945
  case "expo":
8782
8946
  case "react-native": {
8783
- debug17("using sqlite/react-native migration file for DigitalCredential");
8947
+ debug18("using sqlite/react-native migration file for DigitalCredential");
8784
8948
  const mig = new CreateDigitalCredential1708525189002();
8785
8949
  await mig.up(queryRunner);
8786
- debug17("SQLite Migration statements for DigitalCredential executed");
8950
+ debug18("SQLite Migration statements for DigitalCredential executed");
8787
8951
  return;
8788
8952
  }
8789
8953
  default:
@@ -8791,23 +8955,23 @@ var CreateDigitalCredential1708525189000 = class {
8791
8955
  }
8792
8956
  }
8793
8957
  async down(queryRunner) {
8794
- debug17("migration: reverting DigitalCredential tables");
8958
+ debug18("migration: reverting DigitalCredential tables");
8795
8959
  const dbType = queryRunner.connection.driver.options.type;
8796
8960
  switch (dbType) {
8797
8961
  case "postgres": {
8798
- debug17("using postgres migration file for DigitalCredential");
8962
+ debug18("using postgres migration file for DigitalCredential");
8799
8963
  const mig = new CreateDigitalCredential1708525189001();
8800
8964
  await mig.down(queryRunner);
8801
- debug17("Postgres Migration statements for DigitalCredential reverted");
8965
+ debug18("Postgres Migration statements for DigitalCredential reverted");
8802
8966
  return;
8803
8967
  }
8804
8968
  case "sqlite":
8805
8969
  case "expo":
8806
8970
  case "react-native": {
8807
- debug17("using sqlite/react-native migration file for DigitalCredential");
8971
+ debug18("using sqlite/react-native migration file for DigitalCredential");
8808
8972
  const mig = new CreateDigitalCredential1708525189002();
8809
8973
  await mig.down(queryRunner);
8810
- debug17("SQLite Migration statements for DigitalCredential reverted");
8974
+ debug18("SQLite Migration statements for DigitalCredential reverted");
8811
8975
  return;
8812
8976
  }
8813
8977
  default:
@@ -8817,7 +8981,7 @@ var CreateDigitalCredential1708525189000 = class {
8817
8981
  };
8818
8982
 
8819
8983
  // src/migrations/generic/7-CreateMachineStateStore.ts
8820
- var import_debug18 = __toESM(require("debug"), 1);
8984
+ var import_debug19 = __toESM(require("debug"), 1);
8821
8985
 
8822
8986
  // src/migrations/postgres/1708797018115-CreateMachineStateStore.ts
8823
8987
  var CreateMachineStateStore1708797018115 = class {
@@ -8879,30 +9043,30 @@ var CreateMachineStateStore1708796002272 = class {
8879
9043
  };
8880
9044
 
8881
9045
  // src/migrations/generic/7-CreateMachineStateStore.ts
8882
- var debug18 = (0, import_debug18.default)("sphereon:ssi-sdk:migrations");
9046
+ var debug19 = (0, import_debug19.default)("sphereon:ssi-sdk:migrations");
8883
9047
  var CreateMachineStateStore1708098041262 = class {
8884
9048
  static {
8885
9049
  __name(this, "CreateMachineStateStore1708098041262");
8886
9050
  }
8887
9051
  name = "CreateMachineStateStore1708098041262";
8888
9052
  async up(queryRunner) {
8889
- debug18("migration: creating machine state tables");
9053
+ debug19("migration: creating machine state tables");
8890
9054
  const dbType = queryRunner.connection.driver.options.type;
8891
9055
  switch (dbType) {
8892
9056
  case "postgres": {
8893
- debug18("using postgres migration file");
9057
+ debug19("using postgres migration file");
8894
9058
  const mig = new CreateMachineStateStore1708797018115();
8895
9059
  await mig.up(queryRunner);
8896
- debug18("Migration statements executed");
9060
+ debug19("Migration statements executed");
8897
9061
  return;
8898
9062
  }
8899
9063
  case "sqlite":
8900
9064
  case "expo":
8901
9065
  case "react-native": {
8902
- debug18("using sqlite/react-native migration file");
9066
+ debug19("using sqlite/react-native migration file");
8903
9067
  const mig = new CreateMachineStateStore1708796002272();
8904
9068
  await mig.up(queryRunner);
8905
- debug18("Migration statements executed");
9069
+ debug19("Migration statements executed");
8906
9070
  return;
8907
9071
  }
8908
9072
  default:
@@ -8910,23 +9074,23 @@ var CreateMachineStateStore1708098041262 = class {
8910
9074
  }
8911
9075
  }
8912
9076
  async down(queryRunner) {
8913
- debug18("migration: reverting machine state tables");
9077
+ debug19("migration: reverting machine state tables");
8914
9078
  const dbType = queryRunner.connection.driver.options.type;
8915
9079
  switch (dbType) {
8916
9080
  case "postgres": {
8917
- debug18("using postgres migration file");
9081
+ debug19("using postgres migration file");
8918
9082
  const mig = new CreateMachineStateStore1708797018115();
8919
9083
  await mig.down(queryRunner);
8920
- debug18("Migration statements executed");
9084
+ debug19("Migration statements executed");
8921
9085
  return;
8922
9086
  }
8923
9087
  case "sqlite":
8924
9088
  case "expo":
8925
9089
  case "react-native": {
8926
- debug18("using sqlite/react-native migration file");
9090
+ debug19("using sqlite/react-native migration file");
8927
9091
  const mig = new CreateMachineStateStore1708796002272();
8928
9092
  await mig.down(queryRunner);
8929
- debug18("Migration statements executed");
9093
+ debug19("Migration statements executed");
8930
9094
  return;
8931
9095
  }
8932
9096
  default:
@@ -8936,7 +9100,7 @@ var CreateMachineStateStore1708098041262 = class {
8936
9100
  };
8937
9101
 
8938
9102
  // src/migrations/generic/8-CreateContacts.ts
8939
- var import_debug19 = __toESM(require("debug"), 1);
9103
+ var import_debug20 = __toESM(require("debug"), 1);
8940
9104
 
8941
9105
  // src/migrations/postgres/1710438363001-CreateContacts.ts
8942
9106
  var CreateContacts1710438363001 = class {
@@ -9050,30 +9214,30 @@ var CreateContacts1710438363002 = class {
9050
9214
  };
9051
9215
 
9052
9216
  // src/migrations/generic/8-CreateContacts.ts
9053
- var debug19 = (0, import_debug19.default)("sphereon:ssi-sdk:migrations");
9217
+ var debug20 = (0, import_debug20.default)("sphereon:ssi-sdk:migrations");
9054
9218
  var CreateContacts1708525189000 = class {
9055
9219
  static {
9056
9220
  __name(this, "CreateContacts1708525189000");
9057
9221
  }
9058
9222
  name = "CreateContacts1708525189000";
9059
9223
  async up(queryRunner) {
9060
- debug19("migration: updating contact tables");
9224
+ debug20("migration: updating contact tables");
9061
9225
  const dbType = queryRunner.connection.driver.options.type;
9062
9226
  switch (dbType) {
9063
9227
  case "postgres": {
9064
- debug19("using postgres migration file");
9228
+ debug20("using postgres migration file");
9065
9229
  const mig = new CreateContacts1710438363001();
9066
9230
  await mig.up(queryRunner);
9067
- debug19("Migration statements executed");
9231
+ debug20("Migration statements executed");
9068
9232
  return;
9069
9233
  }
9070
9234
  case "sqlite":
9071
9235
  case "expo":
9072
9236
  case "react-native": {
9073
- debug19("using sqlite/react-native migration file");
9237
+ debug20("using sqlite/react-native migration file");
9074
9238
  const mig = new CreateContacts1710438363002();
9075
9239
  await mig.up(queryRunner);
9076
- debug19("Migration statements executed");
9240
+ debug20("Migration statements executed");
9077
9241
  return;
9078
9242
  }
9079
9243
  default:
@@ -9081,23 +9245,23 @@ var CreateContacts1708525189000 = class {
9081
9245
  }
9082
9246
  }
9083
9247
  async down(queryRunner) {
9084
- debug19("migration: reverting machine state tables");
9248
+ debug20("migration: reverting machine state tables");
9085
9249
  const dbType = queryRunner.connection.driver.options.type;
9086
9250
  switch (dbType) {
9087
9251
  case "postgres": {
9088
- debug19("using postgres migration file");
9252
+ debug20("using postgres migration file");
9089
9253
  const mig = new CreateContacts1710438363001();
9090
9254
  await mig.down(queryRunner);
9091
- debug19("Migration statements executed");
9255
+ debug20("Migration statements executed");
9092
9256
  return;
9093
9257
  }
9094
9258
  case "sqlite":
9095
9259
  case "expo":
9096
9260
  case "react-native": {
9097
- debug19("using sqlite/react-native migration file");
9261
+ debug20("using sqlite/react-native migration file");
9098
9262
  const mig = new CreateContacts1710438363002();
9099
9263
  await mig.down(queryRunner);
9100
- debug19("Migration statements executed");
9264
+ debug20("Migration statements executed");
9101
9265
  return;
9102
9266
  }
9103
9267
  default:
@@ -9107,7 +9271,7 @@ var CreateContacts1708525189000 = class {
9107
9271
  };
9108
9272
 
9109
9273
  // src/migrations/generic/9-CreateContacts.ts
9110
- var import_debug20 = __toESM(require("debug"), 1);
9274
+ var import_debug21 = __toESM(require("debug"), 1);
9111
9275
 
9112
9276
  // src/migrations/postgres/1715761125001-CreateContacts.ts
9113
9277
  var CreateContacts1715761125001 = class {
@@ -9219,30 +9383,30 @@ var CreateContacts1715761125002 = class {
9219
9383
  };
9220
9384
 
9221
9385
  // src/migrations/generic/9-CreateContacts.ts
9222
- var debug20 = (0, import_debug20.default)("sphereon:ssi-sdk:migrations");
9386
+ var debug21 = (0, import_debug21.default)("sphereon:ssi-sdk:migrations");
9223
9387
  var CreateContacts1715761125000 = class {
9224
9388
  static {
9225
9389
  __name(this, "CreateContacts1715761125000");
9226
9390
  }
9227
9391
  name = "CreateContacts1715761125000";
9228
9392
  async up(queryRunner) {
9229
- debug20("migration: updating contact tables");
9393
+ debug21("migration: updating contact tables");
9230
9394
  const dbType = queryRunner.connection.driver.options.type;
9231
9395
  switch (dbType) {
9232
9396
  case "postgres": {
9233
- debug20("using postgres migration file");
9397
+ debug21("using postgres migration file");
9234
9398
  const mig = new CreateContacts1715761125001();
9235
9399
  await mig.up(queryRunner);
9236
- debug20("Migration statements executed");
9400
+ debug21("Migration statements executed");
9237
9401
  return;
9238
9402
  }
9239
9403
  case "sqlite":
9240
9404
  case "expo":
9241
9405
  case "react-native": {
9242
- debug20("using sqlite/react-native migration file");
9406
+ debug21("using sqlite/react-native migration file");
9243
9407
  const mig = new CreateContacts1715761125002();
9244
9408
  await mig.up(queryRunner);
9245
- debug20("Migration statements executed");
9409
+ debug21("Migration statements executed");
9246
9410
  return;
9247
9411
  }
9248
9412
  default:
@@ -9250,23 +9414,23 @@ var CreateContacts1715761125000 = class {
9250
9414
  }
9251
9415
  }
9252
9416
  async down(queryRunner) {
9253
- debug20("migration: reverting machine state tables");
9417
+ debug21("migration: reverting machine state tables");
9254
9418
  const dbType = queryRunner.connection.driver.options.type;
9255
9419
  switch (dbType) {
9256
9420
  case "postgres": {
9257
- debug20("using postgres migration file");
9421
+ debug21("using postgres migration file");
9258
9422
  const mig = new CreateContacts1715761125001();
9259
9423
  await mig.down(queryRunner);
9260
- debug20("Migration statements executed");
9424
+ debug21("Migration statements executed");
9261
9425
  return;
9262
9426
  }
9263
9427
  case "sqlite":
9264
9428
  case "expo":
9265
9429
  case "react-native": {
9266
- debug20("using sqlite/react-native migration file");
9430
+ debug21("using sqlite/react-native migration file");
9267
9431
  const mig = new CreateContacts1715761125002();
9268
9432
  await mig.down(queryRunner);
9269
- debug20("Migration statements executed");
9433
+ debug21("Migration statements executed");
9270
9434
  return;
9271
9435
  }
9272
9436
  default:
@@ -9295,7 +9459,8 @@ var DataStoreEventLoggerMigrations = [
9295
9459
  CreateAuditEvents1701635835330
9296
9460
  ];
9297
9461
  var DataStoreDigitalCredentialMigrations = [
9298
- CreateDigitalCredential1708525189000
9462
+ CreateDigitalCredential1708525189000,
9463
+ AddLinkedVpFields1763387280000
9299
9464
  ];
9300
9465
  var DataStoreMachineStateMigrations = [
9301
9466
  CreateMachineStateStore1708098041262