@icure/cardinal-sdk 2.14.0 → 2.15.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (60) hide show
  1. package/api/AccessLogApi.d.mts +11 -0
  2. package/api/AccessLogBasicApi.d.mts +11 -0
  3. package/api/AccessLogBasicInGroupApi.d.mts +6 -0
  4. package/api/AccessLogInGroupApi.d.mts +33 -1
  5. package/api/AuthApi.d.mts +11 -0
  6. package/api/CalendarItemApi.d.mts +11 -0
  7. package/api/CalendarItemBasicApi.d.mts +11 -0
  8. package/api/CalendarItemBasicInGroupApi.d.mts +6 -0
  9. package/api/CalendarItemInGroupApi.d.mts +6 -0
  10. package/api/ContactApi.d.mts +22 -0
  11. package/api/ContactBasicApi.d.mts +22 -0
  12. package/api/ContactBasicInGroupApi.d.mts +11 -0
  13. package/api/ContactInGroupApi.d.mts +11 -0
  14. package/api/DocumentApi.d.mts +11 -0
  15. package/api/DocumentBasicApi.d.mts +11 -0
  16. package/api/DocumentBasicInGroupApi.d.mts +6 -0
  17. package/api/DocumentInGroupApi.d.mts +6 -0
  18. package/api/FormApi.d.mts +11 -0
  19. package/api/FormBasicApi.d.mts +11 -0
  20. package/api/FormBasicInGroupApi.d.mts +6 -0
  21. package/api/FormInGroupApi.d.mts +6 -0
  22. package/api/HealthElementApi.d.mts +11 -0
  23. package/api/HealthElementBasicApi.d.mts +11 -0
  24. package/api/HealthElementBasicInGroupApi.d.mts +6 -0
  25. package/api/HealthElementInGroupApi.d.mts +6 -0
  26. package/api/InvoiceApi.d.mts +11 -0
  27. package/api/InvoiceBasicApi.d.mts +11 -0
  28. package/api/InvoiceBasicInGroupApi.d.mts +6 -0
  29. package/api/InvoiceInGroupApi.d.mts +6 -0
  30. package/api/MessageApi.d.mts +11 -0
  31. package/api/MessageBasicApi.d.mts +11 -0
  32. package/api/MessageBasicInGroupApi.d.mts +6 -0
  33. package/api/MessageInGroupApi.d.mts +6 -0
  34. package/api/ReceiptApi.d.mts +11 -0
  35. package/api/ReceiptBasicApi.d.mts +11 -0
  36. package/api/ReceiptBasicInGroupApi.d.mts +6 -0
  37. package/api/ReceiptInGroupApi.d.mts +6 -0
  38. package/api/RelatedPersonApi.d.mts +11 -0
  39. package/api/RelatedPersonBasicApi.d.mts +11 -0
  40. package/api/RelatedPersonBasicInGroupApi.d.mts +6 -0
  41. package/api/RelatedPersonInGroupApi.d.mts +6 -0
  42. package/api/TopicApi.d.mts +11 -0
  43. package/api/TopicBasicApi.d.mts +11 -0
  44. package/api/TopicBasicInGroupApi.d.mts +6 -0
  45. package/api/TopicInGroupApi.d.mts +6 -0
  46. package/api/UserApi.d.mts +32 -0
  47. package/cardinal-sdk-ts.mjs +47773 -43898
  48. package/cardinal-sdk.mjs +78037 -76803
  49. package/kotlin-kotlin-stdlib.mjs +30 -30
  50. package/kotlinx-coroutines-core.mjs +3 -3
  51. package/ktor-ktor-utils.mjs +2 -2
  52. package/model/base/CryptoActor.mjs +4 -4
  53. package/model/embed/form/template/Field.d.mts +1 -1
  54. package/model/embed/form/template/StructureElement.d.mts +1 -1
  55. package/model/embed/form/template/StructureElement.mjs +8 -8
  56. package/model/filter/predicate/Predicate.d.mts +1 -1
  57. package/model/filter/predicate/Predicate.mjs +2 -2
  58. package/options/AuthenticationMethod.d.mts +17 -1
  59. package/options/AuthenticationMethod.mjs +15 -0
  60. package/package.json +1 -1
@@ -48,12 +48,6 @@ if (typeof Math.clz32 === 'undefined') {
48
48
  };
49
49
  }(Math.log, Math.LN2);
50
50
  }
51
- if (typeof String.prototype.startsWith === 'undefined') {
52
- Object.defineProperty(String.prototype, 'startsWith', {value: function (searchString, position) {
53
- position = position || 0;
54
- return this.lastIndexOf(searchString, position) === position;
55
- }});
56
- }
57
51
  if (typeof String.prototype.endsWith === 'undefined') {
58
52
  Object.defineProperty(String.prototype, 'endsWith', {value: function (searchString, position) {
59
53
  var subjectString = this.toString();
@@ -65,6 +59,12 @@ if (typeof String.prototype.endsWith === 'undefined') {
65
59
  return lastIndex !== -1 && lastIndex === position;
66
60
  }});
67
61
  }
62
+ if (typeof String.prototype.startsWith === 'undefined') {
63
+ Object.defineProperty(String.prototype, 'startsWith', {value: function (searchString, position) {
64
+ position = position || 0;
65
+ return this.lastIndexOf(searchString, position) === position;
66
+ }});
67
+ }
68
68
  //endregion
69
69
  //region block: imports
70
70
  var imul_0 = Math.imul;
@@ -93,8 +93,8 @@ initMetadataForInterface(Entry, 'Entry');
93
93
  initMetadataForInterface(KtMap, 'Map');
94
94
  initMetadataForInterface(KtSet, 'Set', VOID, VOID, [Collection]);
95
95
  initMetadataForInterface(MutableIterable, 'MutableIterable');
96
- initMetadataForInterface(KtMutableList, 'MutableList', VOID, VOID, [KtList, MutableIterable, Collection]);
97
- initMetadataForInterface(KtMutableSet, 'MutableSet', VOID, VOID, [KtSet, MutableIterable, Collection]);
96
+ initMetadataForInterface(KtMutableList, 'MutableList', VOID, VOID, [KtList, Collection, MutableIterable]);
97
+ initMetadataForInterface(KtMutableSet, 'MutableSet', VOID, VOID, [KtSet, Collection, MutableIterable]);
98
98
  initMetadataForInterface(KtMutableMap, 'MutableMap', VOID, VOID, [KtMap]);
99
99
  initMetadataForCompanion(Companion_0);
100
100
  initMetadataForClass(Enum, 'Enum', VOID, VOID, [Comparable]);
@@ -115,7 +115,7 @@ initMetadataForInterface(AutoCloseable, 'AutoCloseable');
115
115
  initMetadataForInterface(Comparator, 'Comparator');
116
116
  initMetadataForObject(Unit, 'Unit');
117
117
  initMetadataForClass(AbstractCollection, 'AbstractCollection', VOID, VOID, [Collection]);
118
- initMetadataForClass(AbstractMutableCollection, 'AbstractMutableCollection', VOID, AbstractCollection, [MutableIterable, Collection]);
118
+ initMetadataForClass(AbstractMutableCollection, 'AbstractMutableCollection', VOID, AbstractCollection, [Collection, MutableIterable]);
119
119
  initMetadataForClass(IteratorImpl, 'IteratorImpl');
120
120
  initMetadataForClass(ListIteratorImpl, 'ListIteratorImpl', VOID, IteratorImpl);
121
121
  initMetadataForClass(AbstractMutableList, 'AbstractMutableList', VOID, AbstractMutableCollection, [KtMutableList]);
@@ -128,7 +128,7 @@ initMetadataForCompanion(Companion_2);
128
128
  initMetadataForClass(ArrayList, 'ArrayList', ArrayList_init_$Create$, AbstractMutableList, [KtMutableList, RandomAccess]);
129
129
  initMetadataForClass(HashMap, 'HashMap', HashMap_init_$Create$, AbstractMutableMap, [KtMutableMap]);
130
130
  initMetadataForClass(HashMapKeys, 'HashMapKeys', VOID, AbstractMutableSet, [KtMutableSet]);
131
- initMetadataForClass(HashMapValues, 'HashMapValues', VOID, AbstractMutableCollection, [MutableIterable, Collection]);
131
+ initMetadataForClass(HashMapValues, 'HashMapValues', VOID, AbstractMutableCollection, [Collection, MutableIterable]);
132
132
  initMetadataForClass(HashMapEntrySetBase, 'HashMapEntrySetBase', VOID, AbstractMutableSet, [KtMutableSet]);
133
133
  initMetadataForClass(HashMapEntrySet, 'HashMapEntrySet', VOID, HashMapEntrySetBase);
134
134
  initMetadataForClass(HashMapKeysDefault$iterator$1);
@@ -1626,12 +1626,6 @@ function minus(_this__u8e3s4, element) {
1626
1626
  }
1627
1627
  return result;
1628
1628
  }
1629
- function plus_6(_this__u8e3s4, element) {
1630
- var result = LinkedHashSet_init_$Create$_1(mapCapacity(_this__u8e3s4.m1() + 1 | 0));
1631
- result.n1(_this__u8e3s4);
1632
- result.j1(element);
1633
- return result;
1634
- }
1635
1629
  function minus_0(_this__u8e3s4, elements) {
1636
1630
  var other = convertToListIfNotCollection(elements);
1637
1631
  if (other.r())
@@ -1649,7 +1643,13 @@ function minus_0(_this__u8e3s4, elements) {
1649
1643
  return destination;
1650
1644
  }
1651
1645
  var result = LinkedHashSet_init_$Create$_0(_this__u8e3s4);
1652
- result.e2(other);
1646
+ result.d2(other);
1647
+ return result;
1648
+ }
1649
+ function plus_6(_this__u8e3s4, element) {
1650
+ var result = LinkedHashSet_init_$Create$_1(mapCapacity(_this__u8e3s4.m1() + 1 | 0));
1651
+ result.n1(_this__u8e3s4);
1652
+ result.j1(element);
1653
1653
  return result;
1654
1654
  }
1655
1655
  function takeLast_0(_this__u8e3s4, n) {
@@ -4028,7 +4028,7 @@ protoOf(AbstractMutableCollection).n1 = function (elements) {
4028
4028
  }
4029
4029
  return modified;
4030
4030
  };
4031
- protoOf(AbstractMutableCollection).e2 = function (elements) {
4031
+ protoOf(AbstractMutableCollection).d2 = function (elements) {
4032
4032
  this.g4();
4033
4033
  var tmp = isInterface(this, MutableIterable) ? this : THROW_CCE();
4034
4034
  return removeAll_0(tmp, AbstractMutableCollection$removeAll$lambda(elements));
@@ -4145,7 +4145,7 @@ protoOf(AbstractMutableList).y2 = function () {
4145
4145
  this.g4();
4146
4146
  this.y4(0, this.m1());
4147
4147
  };
4148
- protoOf(AbstractMutableList).e2 = function (elements) {
4148
+ protoOf(AbstractMutableList).d2 = function (elements) {
4149
4149
  this.g4();
4150
4150
  return removeAll(this, AbstractMutableList$removeAll$lambda(elements));
4151
4151
  };
@@ -4857,7 +4857,7 @@ protoOf(HashMapValuesDefault).g4 = function () {
4857
4857
  function HashSet_init_$Init$(map, $this) {
4858
4858
  AbstractMutableSet.call($this);
4859
4859
  HashSet.call($this);
4860
- $this.d2_1 = map;
4860
+ $this.e2_1 = map;
4861
4861
  return $this;
4862
4862
  }
4863
4863
  function HashSet_init_$Init$_0($this) {
@@ -4872,7 +4872,7 @@ function HashSet_init_$Init$_1(elements, $this) {
4872
4872
  var _iterator__ex2g4s = elements.t();
4873
4873
  while (_iterator__ex2g4s.u()) {
4874
4874
  var element = _iterator__ex2g4s.v();
4875
- $this.d2_1.c3(element, true);
4875
+ $this.e2_1.c3(element, true);
4876
4876
  }
4877
4877
  return $this;
4878
4878
  }
@@ -4891,22 +4891,22 @@ function HashSet_init_$Create$_1(initialCapacity) {
4891
4891
  return HashSet_init_$Init$_3(initialCapacity, objectCreate(protoOf(HashSet)));
4892
4892
  }
4893
4893
  protoOf(HashSet).j1 = function (element) {
4894
- return this.d2_1.c3(element, true) == null;
4894
+ return this.e2_1.c3(element, true) == null;
4895
4895
  };
4896
4896
  protoOf(HashSet).y2 = function () {
4897
- this.d2_1.y2();
4897
+ this.e2_1.y2();
4898
4898
  };
4899
4899
  protoOf(HashSet).q1 = function (element) {
4900
- return this.d2_1.x5(element);
4900
+ return this.e2_1.x5(element);
4901
4901
  };
4902
4902
  protoOf(HashSet).r = function () {
4903
- return this.d2_1.m1() === 0;
4903
+ return this.e2_1.m1() === 0;
4904
4904
  };
4905
4905
  protoOf(HashSet).t = function () {
4906
- return this.d2_1.z5();
4906
+ return this.e2_1.z5();
4907
4907
  };
4908
4908
  protoOf(HashSet).m1 = function () {
4909
- return this.d2_1.m1();
4909
+ return this.e2_1.m1();
4910
4910
  };
4911
4911
  function HashSet() {
4912
4912
  }
@@ -5568,7 +5568,7 @@ function LinkedHashSet_init_$Create$_1(initialCapacity) {
5568
5568
  return LinkedHashSet_init_$Init$_2(initialCapacity, objectCreate(protoOf(LinkedHashSet)));
5569
5569
  }
5570
5570
  protoOf(LinkedHashSet).g4 = function () {
5571
- return this.d2_1.a6();
5571
+ return this.e2_1.a6();
5572
5572
  };
5573
5573
  function LinkedHashSet() {
5574
5574
  }
@@ -9203,7 +9203,7 @@ protoOf(ArrayDeque).b3 = function (index) {
9203
9203
  this.je_1 = this.je_1 - 1 | 0;
9204
9204
  return element;
9205
9205
  };
9206
- protoOf(ArrayDeque).e2 = function (elements) {
9206
+ protoOf(ArrayDeque).d2 = function (elements) {
9207
9207
  var tmp$ret$0;
9208
9208
  $l$block: {
9209
9209
  // Inline function 'kotlin.collections.ArrayDeque.filterInPlace' call
@@ -9901,7 +9901,7 @@ function filterInPlace_0(_this__u8e3s4, predicate, predicateResultToRemove) {
9901
9901
  return result;
9902
9902
  }
9903
9903
  function removeAll_1(_this__u8e3s4, elements) {
9904
- return _this__u8e3s4.e2(convertToListIfNotCollection(elements));
9904
+ return _this__u8e3s4.d2(convertToListIfNotCollection(elements));
9905
9905
  }
9906
9906
  function convertToListIfNotCollection(_this__u8e3s4) {
9907
9907
  var tmp;
@@ -294,7 +294,7 @@ initMetadataForClass(ContextScope, 'ContextScope', VOID, VOID, [CoroutineScope])
294
294
  initMetadataForClass(Symbol, 'Symbol');
295
295
  initMetadataForInterface(SelectInstance, 'SelectInstance');
296
296
  initMetadataForClass(ClauseData, 'ClauseData', VOID, VOID, VOID, [1]);
297
- initMetadataForClass(SelectImplementation, 'SelectImplementation', VOID, VOID, [CancelHandler, Waiter, SelectInstance], [0, 2]);
297
+ initMetadataForClass(SelectImplementation, 'SelectImplementation', VOID, VOID, [CancelHandler, SelectInstance, Waiter], [0, 2]);
298
298
  initMetadataForClass(TrySelectDetailedResult, 'TrySelectDetailedResult', VOID, Enum);
299
299
  initMetadataForClass(CancellableContinuationWithOwner, 'CancellableContinuationWithOwner', VOID, VOID, [CancellableContinuation, Waiter]);
300
300
  initMetadataForClass(SemaphoreAndMutexImpl, 'SemaphoreAndMutexImpl', VOID, VOID, VOID, [0]);
@@ -10506,9 +10506,9 @@ protoOf(MessageQueue).n1 = function (elements) {
10506
10506
  return this.k1m(elements);
10507
10507
  };
10508
10508
  protoOf(MessageQueue).l1m = function (elements) {
10509
- return this.a1m_1.e2(elements);
10509
+ return this.a1m_1.d2(elements);
10510
10510
  };
10511
- protoOf(MessageQueue).e2 = function (elements) {
10511
+ protoOf(MessageQueue).d2 = function (elements) {
10512
10512
  return this.l1m(elements);
10513
10513
  };
10514
10514
  protoOf(MessageQueue).y2 = function () {
@@ -622,9 +622,9 @@ protoOf(DelegatingMutableSet).y2 = function () {
622
622
  this.l4p_1.y2();
623
623
  };
624
624
  protoOf(DelegatingMutableSet).t4p = function (elements) {
625
- return this.l4p_1.e2(toSet(this.p4p(elements)));
625
+ return this.l4p_1.d2(toSet(this.p4p(elements)));
626
626
  };
627
- protoOf(DelegatingMutableSet).e2 = function (elements) {
627
+ protoOf(DelegatingMutableSet).d2 = function (elements) {
628
628
  return this.t4p(elements);
629
629
  };
630
630
  protoOf(DelegatingMutableSet).u4p = function (element) {
@@ -7,11 +7,11 @@ export var CryptoActor;
7
7
  (function (CryptoActor) {
8
8
  function fromJSON(json, ignoreUnknownKeys = false, path = ['CryptoActor']) {
9
9
  switch (json.$ktClass) {
10
- case 'com.icure.cardinal.sdk.model.CryptoActorStub': return CryptoActorStub.fromJSON(json, ignoreUnknownKeys);
11
- case 'com.icure.cardinal.sdk.model.Device': return Device.fromJSON(json, ignoreUnknownKeys);
12
- case 'com.icure.cardinal.sdk.model.DecryptedPatient': return DecryptedPatient.fromJSON(json, ignoreUnknownKeys);
13
- case 'com.icure.cardinal.sdk.model.EncryptedPatient': return EncryptedPatient.fromJSON(json, ignoreUnknownKeys);
14
10
  case 'com.icure.cardinal.sdk.model.HealthcareParty': return HealthcareParty.fromJSON(json, ignoreUnknownKeys);
11
+ case 'com.icure.cardinal.sdk.model.EncryptedPatient': return EncryptedPatient.fromJSON(json, ignoreUnknownKeys);
12
+ case 'com.icure.cardinal.sdk.model.DecryptedPatient': return DecryptedPatient.fromJSON(json, ignoreUnknownKeys);
13
+ case 'com.icure.cardinal.sdk.model.Device': return Device.fromJSON(json, ignoreUnknownKeys);
14
+ case 'com.icure.cardinal.sdk.model.CryptoActorStub': return CryptoActorStub.fromJSON(json, ignoreUnknownKeys);
15
15
  default: throw new Error('Unexpected discriminator for CryptoActor: ' + json.$ktClass);
16
16
  }
17
17
  }
@@ -17,4 +17,4 @@ import { TimePicker } from './TimePicker.mjs';
17
17
  * validation rules, and optional codification and tagging.
18
18
  * /
19
19
  */
20
- export type Field = TextField | RadioButton | NumberField | DropdownField | DateTimePicker | DatePicker | MultipleChoice | TimePicker | MeasureField | CheckBox;
20
+ export type Field = MultipleChoice | NumberField | CheckBox | RadioButton | TextField | TimePicker | DatePicker | MeasureField | DropdownField | DateTimePicker;
@@ -6,7 +6,7 @@ import { FieldsGroup } from './FieldsGroup.mjs';
6
6
  * groups.
7
7
  * /
8
8
  */
9
- export type StructureElement = FieldsGroup | Field;
9
+ export type StructureElement = Field | FieldsGroup;
10
10
  export declare namespace StructureElement {
11
11
  function fromJSON(json: any, ignoreUnknownKeys?: boolean, path?: Array<string>): StructureElement;
12
12
  }
@@ -14,17 +14,17 @@ export var StructureElement;
14
14
  (function (StructureElement) {
15
15
  function fromJSON(json, ignoreUnknownKeys = false, path = ['StructureElement']) {
16
16
  switch (json.$ktClass) {
17
- case 'com.icure.cardinal.sdk.model.embed.form.template.FieldsGroup': return FieldsGroup.fromJSON(json, ignoreUnknownKeys);
18
- case 'com.icure.cardinal.sdk.model.embed.form.template.TextField': return TextField.fromJSON(json, ignoreUnknownKeys);
19
- case 'com.icure.cardinal.sdk.model.embed.form.template.RadioButton': return RadioButton.fromJSON(json, ignoreUnknownKeys);
20
- case 'com.icure.cardinal.sdk.model.embed.form.template.NumberField': return NumberField.fromJSON(json, ignoreUnknownKeys);
21
- case 'com.icure.cardinal.sdk.model.embed.form.template.DropdownField': return DropdownField.fromJSON(json, ignoreUnknownKeys);
22
- case 'com.icure.cardinal.sdk.model.embed.form.template.DateTimePicker': return DateTimePicker.fromJSON(json, ignoreUnknownKeys);
23
- case 'com.icure.cardinal.sdk.model.embed.form.template.DatePicker': return DatePicker.fromJSON(json, ignoreUnknownKeys);
24
17
  case 'com.icure.cardinal.sdk.model.embed.form.template.MultipleChoice': return MultipleChoice.fromJSON(json, ignoreUnknownKeys);
18
+ case 'com.icure.cardinal.sdk.model.embed.form.template.NumberField': return NumberField.fromJSON(json, ignoreUnknownKeys);
19
+ case 'com.icure.cardinal.sdk.model.embed.form.template.CheckBox': return CheckBox.fromJSON(json, ignoreUnknownKeys);
20
+ case 'com.icure.cardinal.sdk.model.embed.form.template.RadioButton': return RadioButton.fromJSON(json, ignoreUnknownKeys);
21
+ case 'com.icure.cardinal.sdk.model.embed.form.template.TextField': return TextField.fromJSON(json, ignoreUnknownKeys);
25
22
  case 'com.icure.cardinal.sdk.model.embed.form.template.TimePicker': return TimePicker.fromJSON(json, ignoreUnknownKeys);
23
+ case 'com.icure.cardinal.sdk.model.embed.form.template.DatePicker': return DatePicker.fromJSON(json, ignoreUnknownKeys);
26
24
  case 'com.icure.cardinal.sdk.model.embed.form.template.MeasureField': return MeasureField.fromJSON(json, ignoreUnknownKeys);
27
- case 'com.icure.cardinal.sdk.model.embed.form.template.CheckBox': return CheckBox.fromJSON(json, ignoreUnknownKeys);
25
+ case 'com.icure.cardinal.sdk.model.embed.form.template.DropdownField': return DropdownField.fromJSON(json, ignoreUnknownKeys);
26
+ case 'com.icure.cardinal.sdk.model.embed.form.template.DateTimePicker': return DateTimePicker.fromJSON(json, ignoreUnknownKeys);
27
+ case 'com.icure.cardinal.sdk.model.embed.form.template.FieldsGroup': return FieldsGroup.fromJSON(json, ignoreUnknownKeys);
28
28
  default: throw new Error('Unexpected discriminator for StructureElement: ' + json.$ktClass);
29
29
  }
30
30
  }
@@ -9,7 +9,7 @@ import { OrPredicate } from './OrPredicate.mjs';
9
9
  * chain.
10
10
  * /
11
11
  */
12
- export type Predicate = KeyValuePredicate | OrPredicate | NotPredicate | AlwaysPredicate | AndPredicate;
12
+ export type Predicate = KeyValuePredicate | AlwaysPredicate | NotPredicate | OrPredicate | AndPredicate;
13
13
  export declare namespace Predicate {
14
14
  function fromJSON(json: any, ignoreUnknownKeys?: boolean, path?: Array<string>): Predicate;
15
15
  }
@@ -9,9 +9,9 @@ export var Predicate;
9
9
  function fromJSON(json, ignoreUnknownKeys = false, path = ['Predicate']) {
10
10
  switch (json.$ktClass) {
11
11
  case 'com.icure.cardinal.sdk.model.filter.predicate.KeyValuePredicate': return KeyValuePredicate.fromJSON(json, ignoreUnknownKeys);
12
- case 'com.icure.cardinal.sdk.model.filter.predicate.OrPredicate': return OrPredicate.fromJSON(json, ignoreUnknownKeys);
13
- case 'com.icure.cardinal.sdk.model.filter.predicate.NotPredicate': return NotPredicate.fromJSON(json, ignoreUnknownKeys);
14
12
  case 'com.icure.cardinal.sdk.model.filter.predicate.AlwaysPredicate': return AlwaysPredicate.fromJSON(json, ignoreUnknownKeys);
13
+ case 'com.icure.cardinal.sdk.model.filter.predicate.NotPredicate': return NotPredicate.fromJSON(json, ignoreUnknownKeys);
14
+ case 'com.icure.cardinal.sdk.model.filter.predicate.OrPredicate': return OrPredicate.fromJSON(json, ignoreUnknownKeys);
15
15
  case 'com.icure.cardinal.sdk.model.filter.predicate.AndPredicate': return AndPredicate.fromJSON(json, ignoreUnknownKeys);
16
16
  default: throw new Error('Unexpected discriminator for Predicate: ' + json.$ktClass);
17
17
  }
@@ -175,6 +175,9 @@ export interface SecretProviderAuthenticationOptions {
175
175
  readonly existingJwt?: string;
176
176
  /**
177
177
  * If not null the authentication provider will use the refresh jwt while valid.
178
+ * If the refresh jwt is expired or not valid the authentication provider will silently fall back to the
179
+ * {@link initialSecret} or to the secret provider: if you want the initialization to fail instead, pass the refresh
180
+ * jwt as {@link SecretProviderAuthenticationOptions.InitialSecret.RefreshToken}.
178
181
  */
179
182
  readonly existingRefreshJwt?: string;
180
183
  /**
@@ -194,6 +197,19 @@ export declare namespace SecretProviderAuthenticationOptions {
194
197
  readonly token: string;
195
198
  constructor(token: string);
196
199
  }
200
+ /**
201
+ * A refresh jwt, for example obtained from {@link AuthApi.getRefreshToken}.
202
+ *
203
+ * Unless {@link SecretProviderAuthenticationOptions.existingJwt} is still valid, the refresh jwt is used immediately
204
+ * during the initialization of the SDK, and if it is expired or not valid the initialization fails.
205
+ * Once the refresh jwt expires the authentication provider will need to ask the secret provider for a secret.
206
+ *
207
+ * Can't be used together with {@link SecretProviderAuthenticationOptions.existingRefreshJwt}.
208
+ */
209
+ class RefreshToken {
210
+ readonly token: string;
211
+ constructor(token: string);
212
+ }
197
213
  class ExternalAuthenticationToken {
198
214
  readonly token: string;
199
215
  readonly configId: string;
@@ -203,7 +219,7 @@ export declare namespace SecretProviderAuthenticationOptions {
203
219
  });
204
220
  }
205
221
  }
206
- type InitialSecret = InitialSecret.Password | InitialSecret.LongLivedToken | InitialSecret.ExternalAuthenticationToken;
222
+ type InitialSecret = InitialSecret.Password | InitialSecret.LongLivedToken | InitialSecret.ExternalAuthenticationToken | InitialSecret.RefreshToken;
207
223
  }
208
224
  export interface AuthSecretProvider {
209
225
  /**
@@ -131,6 +131,21 @@ export var SecretProviderAuthenticationOptions;
131
131
  }
132
132
  }
133
133
  InitialSecret.LongLivedToken = LongLivedToken;
134
+ /**
135
+ * A refresh jwt, for example obtained from {@link AuthApi.getRefreshToken}.
136
+ *
137
+ * Unless {@link SecretProviderAuthenticationOptions.existingJwt} is still valid, the refresh jwt is used immediately
138
+ * during the initialization of the SDK, and if it is expired or not valid the initialization fails.
139
+ * Once the refresh jwt expires the authentication provider will need to ask the secret provider for a secret.
140
+ *
141
+ * Can't be used together with {@link SecretProviderAuthenticationOptions.existingRefreshJwt}.
142
+ */
143
+ class RefreshToken {
144
+ constructor(token) {
145
+ this.token = token;
146
+ }
147
+ }
148
+ InitialSecret.RefreshToken = RefreshToken;
134
149
  class ExternalAuthenticationToken {
135
150
  constructor(token, configId, props = {}) {
136
151
  this.token = token;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@icure/cardinal-sdk",
3
- "version": "2.14.0",
3
+ "version": "2.15.0",
4
4
  "main": "cardinal-sdk-ts.mjs",
5
5
  "types": "cardinal-sdk-ts.d.mts",
6
6
  "devDependencies": {