@insurance-broker/api-client 5.10.0 → 5.12.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 (2) hide show
  1. package/dist/schema.d.ts +15 -7
  2. package/package.json +1 -1
package/dist/schema.d.ts CHANGED
@@ -331,7 +331,9 @@ export interface paths {
331
331
  *
332
332
  * The currency is **not** a field: it is the obligation's, held by a foreign key rather than by this handler. Nil is refused — a payment of nothing is nothing having arrived.
333
333
  *
334
- * **Name a payment method or type a source, exactly one** (#530). `paymentMethodId` is one of this broker's active payment methods: its code becomes the payment's `source`, and customers see the method's label. `source` alone is free text, as before, and customers see it as typed. Both, neither, a retired method or another broker's method are refused with `400` and nothing is recorded. A typed source containing a control character is refused with `400` on `Source` (#601).
334
+ * **Name a payment method or type a source, exactly one** (#530). `paymentMethodId` is one of this broker's active payment methods: its code becomes the payment's `source`, and customers see the method's label. `source` alone is free text, as before, and customers see it as typed. Both, neither, a retired method or another broker's method are refused with `400` and nothing is recorded. A typed source containing a character that does not print as text is refused with `400` on `Source`, and a reference with one on `ExternalReference` (#601): a control or format character (a direction override, a zero-width character), U+2028 or U+2029, a private-use or unassigned code point, or an unpaired surrogate. A payment stored with one before #601 is refused the same way when its text is sent again.
335
+ *
336
+ * **A typed source is stored in Unicode normalisation form C** (#601), so a composed and a decomposed spelling of the same words are one source and the same money cannot be recorded once under each. The response carries the stored spelling. The reference is stored as sent.
335
337
  *
336
338
  * **Each `409` carries a `type`** (#593): `urn:brokerplatform:problem:payment-already-recorded` (the same money is already recorded; the problem names the payment), `urn:brokerplatform:problem:payment-reference-amount-conflict` (that reference is recorded for a different amount), `urn:brokerplatform:problem:obligation-concluded` (the charge is settled, cancelled or written off, so nothing can be paid against it; nothing is recorded), and the platform's `urn:brokerplatform:problem:concurrency-conflict` with `retryable: true`. Only the last is worth retrying.
337
339
  */
@@ -927,6 +929,8 @@ export interface paths {
927
929
  * Say which payment method the payments with a free-text source came through
928
930
  * @description #568. Every payment of this broker whose `source` is exactly the given text (after trimming, case as typed) and that names no payment method is given this method. Customers then see the method's label for those payments as `sourceLabel`. **The stored `source` is not changed**, and no amount or reference is.
929
931
  *
932
+ * **The text is compared exactly, code point for code point, and is not normalised** (#601). Payments recorded since #601 hold their source in Unicode normalisation form C, which is what a keyboard produces; a source stored in another spelling before then is reached by sending it as `GET /payment-methods/free-text-sources` lists it. A control character is refused with `400` on `Source`; any other character recording refuses (a format character, a line separator, a private-use or unassigned code point) is accepted here, because a source stored with one before #601 is the one most worth mapping to a method.
933
+ *
930
934
  * **A mapping never moves a payment between methods.** Payments with this source that already name this method are counted in `alreadyMapped`, and those naming another method in `mappedToAnotherMethod`; neither is changed.
931
935
  *
932
936
  * **A payment whose reference the method already holds is skipped** and listed in `skipped` with the payment that holds it, because mapping it would put the same reference against the method twice. The method holds a reference through a payment recorded against it, one mapped to it, or a free-text payment typed exactly as its code: the last is cautious, because such a payment is in the method's duplicate space under §5's index. `skippedCount` is the full count and `skipped` lists at most 200, earliest first. The rest are still mapped.
@@ -959,6 +963,8 @@ export interface paths {
959
963
  * Undo a mapping: show the payments with a free-text source as typed again
960
964
  * @description #588. Every payment of this broker whose `source` is exactly the given text (after trimming, case as typed) and that **a mapping** gave this method goes back to naming no method. Customers see the source as typed again, and the source returns to `GET /payment-methods/free-text-sources`. No amount, source or reference changes.
961
965
  *
966
+ * **The text is compared exactly, code point for code point, and is not normalised** (#601), as the mapping route compares it. A control character is refused with `400` on `Source`; any other character recording refuses (a format character, a line separator, a private-use or unassigned code point) is accepted here, so a source stored with one before #601 stays reachable.
967
+ *
962
968
  * **A payment recorded against this method is never changed**: its method is part of what was recorded. Such payments with this text (possible only when the text is the method's own code) are counted in `recordedAgainstMethod`. A payment recorded against the wrong method is corrected by a reversal. A payment that names this method through a mapping not marked as one (made by an API instance from before #588, possible only when the text is not the method's code) is counted in `notYetCorrectable` and left alone: map the source to this method again, which marks it, and then undo.
963
969
  *
964
970
  * **Idempotent.** Repeating the request answers `unmapped: 0` and records nothing. A retired method can be unmapped from. A statement already produced keeps the wording it was produced with. A `409` is the platform's concurrency conflict, with `retryable: true`, when another write changed one of the payments while this ran.
@@ -983,6 +989,8 @@ export interface paths {
983
989
  * Correct a mapping: say the payments with a free-text source came through another method
984
990
  * @description #588. Every payment of this broker whose `source` is exactly the given text and that **a mapping** gave this method is given `paymentMethodId` instead, in one step. Customers then see that method's label. No amount, source or reference changes, and a payment recorded against this method is never moved (counted in `recordedAgainstMethod`). A payment mapped by an API instance from before #588 is counted in `notYetCorrectable` and left alone until the source is mapped to this method again.
985
991
  *
992
+ * **The text is compared exactly, code point for code point, and is not normalised** (#601), as the mapping route compares it. A control character is refused with `400` on `Source`; any other character recording refuses (a format character, a line separator, a private-use or unassigned code point) is accepted here, so a source stored with one before #601 stays reachable.
993
+ *
986
994
  * `paymentMethodId` must be another active method of this broker: the same method, an unknown or another broker's method is `400` on `PaymentMethodId`, and a retired one is `409` `urn:brokerplatform:problem:payment-method-retired`, which is not retryable. The method in the route may be retired.
987
995
  *
988
996
  * **All or nothing.** If the target method already holds the reference of any of the payments (a payment recorded against it, one mapped to it, or a free-text payment typed exactly as its code), nothing is moved and the answer is `409` `urn:brokerplatform:problem:payment-source-remap-collision`, which is not retryable, with `collisionCount`. **`collisions` is present only when the caller also holds `billing.payments.read`**: up to 200 entries naming each payment, its reference and the payment holding it. Undo the mapping instead and map the source to the target: the mapping maps the rest and lists those it skips.
@@ -6433,7 +6441,7 @@ export interface components {
6433
6441
  /** Format: date-time */
6434
6442
  uploadedAtUtc: string;
6435
6443
  uploadedBySubjectId: string;
6436
- scanVerdict: string;
6444
+ scanVerdict: components["schemas"]["ScanVerdict"];
6437
6445
  /** Format: date-time */
6438
6446
  scannedAtUtc: null | string;
6439
6447
  /** Format: date-time */
@@ -6874,7 +6882,7 @@ export interface components {
6874
6882
  contentSha256: string;
6875
6883
  /** Format: date-time */
6876
6884
  uploadedAtUtc: string;
6877
- scanVerdict: string;
6885
+ scanVerdict: components["schemas"]["ScanVerdict"];
6878
6886
  /** Format: date-time */
6879
6887
  scannedAtUtc: null | string;
6880
6888
  classification: null | string;
@@ -7107,7 +7115,7 @@ export interface components {
7107
7115
  contentSha256: string;
7108
7116
  /** Format: date-time */
7109
7117
  uploadedAtUtc: string;
7110
- scanVerdict: string;
7118
+ scanVerdict: components["schemas"]["ScanVerdict"];
7111
7119
  /** Format: date-time */
7112
7120
  scannedAtUtc: null | string;
7113
7121
  classification: null | string;
@@ -8504,7 +8512,7 @@ export interface components {
8504
8512
  /** Format: date-time */
8505
8513
  uploadedAtUtc: string;
8506
8514
  uploadedBySubjectId: string;
8507
- scanVerdict: string;
8515
+ scanVerdict: components["schemas"]["ScanVerdict"];
8508
8516
  /** Format: date-time */
8509
8517
  scannedAtUtc: null | string;
8510
8518
  classification: null | string;
@@ -9492,7 +9500,7 @@ export interface components {
9492
9500
  /** Format: date-time */
9493
9501
  uploadedAtUtc: string;
9494
9502
  uploadedBySubjectId: string;
9495
- scanVerdict: string;
9503
+ scanVerdict: components["schemas"]["ScanVerdict"];
9496
9504
  /** Format: date-time */
9497
9505
  scannedAtUtc: null | string;
9498
9506
  classification: null | string;
@@ -9528,7 +9536,7 @@ export interface components {
9528
9536
  isOutstanding: boolean;
9529
9537
  /** Format: uuid */
9530
9538
  attachmentId: null | string;
9531
- scanVerdict: null | string;
9539
+ scanVerdict: null | components["schemas"]["ScanVerdict"];
9532
9540
  };
9533
9541
  SuspendTenantRequest: {
9534
9542
  reason: null | string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@insurance-broker/api-client",
3
- "version": "5.10.0",
3
+ "version": "5.12.0",
4
4
  "description": "Generated TypeScript client for the Insurance Broker Platform API. Do not edit by hand: regenerate with scripts/update-api-contract.",
5
5
  "license": "UNLICENSED",
6
6
  "private": false,