@insurance-broker/api-client 1.37.0 → 1.38.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.
- package/dist/schema.d.ts +250 -1
- package/package.json +1 -1
package/dist/schema.d.ts
CHANGED
|
@@ -2841,7 +2841,9 @@ export interface paths {
|
|
|
2841
2841
|
put?: never;
|
|
2842
2842
|
/**
|
|
2843
2843
|
* Record what the insurer confirmed
|
|
2844
|
-
* @description Records the insurer's own reference and the date the insurer confirmed cover from
|
|
2844
|
+
* @description Records the insurer's own reference and the date the insurer confirmed cover from. This is the only way a policy leaves `pendingInsurer`: the platform does not bind cover, so what happens next is what an insurer confirmed and never something a caller asserts.
|
|
2845
|
+
*
|
|
2846
|
+
* **Where it lands depends on whether this broker has declared a payment gate** (`GET /policies/payment-gates`, BR-004). With no gate - which is every broker that has configured nothing - the policy becomes `active`. With one, it becomes `pendingPayment`, and cover begins when somebody records that the requirement was met.
|
|
2845
2847
|
*/
|
|
2846
2848
|
post: operations["RecordInsurerConfirmation"];
|
|
2847
2849
|
delete?: never;
|
|
@@ -2850,6 +2852,32 @@ export interface paths {
|
|
|
2850
2852
|
patch?: never;
|
|
2851
2853
|
trace?: never;
|
|
2852
2854
|
};
|
|
2855
|
+
"/api/v1/policies/{id}/payment-requirement": {
|
|
2856
|
+
parameters: {
|
|
2857
|
+
query?: never;
|
|
2858
|
+
header?: never;
|
|
2859
|
+
path?: never;
|
|
2860
|
+
cookie?: never;
|
|
2861
|
+
};
|
|
2862
|
+
get?: never;
|
|
2863
|
+
put?: never;
|
|
2864
|
+
/**
|
|
2865
|
+
* Record that the outstanding payment requirement has been met
|
|
2866
|
+
* @description BR-004. Releases a policy this broker's payment gate is holding, naming the billing record the recorder relied on, and makes it `active`.
|
|
2867
|
+
*
|
|
2868
|
+
* **A payment posting does not do this** (ADR-0042 section 7). If it did, the platform would be asserting that cover began. A person looks at a payment and records that the requirement is discharged: the payment is the evidence, the person is the actor, and the platform is neither. There is no consumer, no sweep and no side effect that reaches this route.
|
|
2869
|
+
*
|
|
2870
|
+
* **Only a policy in `pendingPayment` can be released, and only once.** Recording it against a policy no gate ever held would write an evidence trail for a requirement that never existed.
|
|
2871
|
+
*
|
|
2872
|
+
* **The `paymentId` is recorded and not verified.** The payment lives in another module this one may not read (ADR-0002), so a mistyped identifier is a bad record rather than a refusal - issue #306 carries the contract that would check it.
|
|
2873
|
+
*/
|
|
2874
|
+
post: operations["RecordPaymentRequirementMet"];
|
|
2875
|
+
delete?: never;
|
|
2876
|
+
options?: never;
|
|
2877
|
+
head?: never;
|
|
2878
|
+
patch?: never;
|
|
2879
|
+
trace?: never;
|
|
2880
|
+
};
|
|
2853
2881
|
"/api/v1/policies/{id}": {
|
|
2854
2882
|
parameters: {
|
|
2855
2883
|
query?: never;
|
|
@@ -2867,6 +2895,62 @@ export interface paths {
|
|
|
2867
2895
|
patch?: never;
|
|
2868
2896
|
trace?: never;
|
|
2869
2897
|
};
|
|
2898
|
+
"/api/v1/policies/payment-gates": {
|
|
2899
|
+
parameters: {
|
|
2900
|
+
query?: never;
|
|
2901
|
+
header?: never;
|
|
2902
|
+
path?: never;
|
|
2903
|
+
cookie?: never;
|
|
2904
|
+
};
|
|
2905
|
+
/**
|
|
2906
|
+
* Whether this broker's cover waits for a payment
|
|
2907
|
+
* @description BR-004. Every gate this broker has declared: one for its whole book, one per product, or any combination.
|
|
2908
|
+
*
|
|
2909
|
+
* **An empty list is the normal answer and it means no gate.** Cover begins when the insurer's confirmation is recorded, which is what this platform did before step 9.11. A row exists only where a broker has asked for the gate, so there is nothing to turn off and nothing to seed.
|
|
2910
|
+
*
|
|
2911
|
+
* **A gate for the whole book cannot be exempted for one product.** An exemption would be a claim about a broker's credit policy that BR-004 does not ask this platform to model; a broker wanting to gate all but one product declares the rest.
|
|
2912
|
+
*/
|
|
2913
|
+
get: operations["ReadPaymentGates"];
|
|
2914
|
+
put?: never;
|
|
2915
|
+
/**
|
|
2916
|
+
* Declare that cover waits for a payment
|
|
2917
|
+
* @description BR-004. Records that a payment must be recorded before cover begins - for every product this broker sells, or for one of them.
|
|
2918
|
+
*
|
|
2919
|
+
* **It changes no existing policy.** A confirmation resolves the gate at the instant it is recorded, so a policy already active stays active and one already held stays held. What changes is where the *next* confirmation lands: `PendingPayment` instead of `Active`.
|
|
2920
|
+
*
|
|
2921
|
+
* **Declaring the same gate twice is a `409`.** The row is the declaration, so a second one would be the same fact recorded twice with two authors and two instants.
|
|
2922
|
+
*
|
|
2923
|
+
* **A product this broker does not sell is a `400`.** Checked through the catalogue before the row is written.
|
|
2924
|
+
*/
|
|
2925
|
+
post: operations["DeclarePaymentGate"];
|
|
2926
|
+
delete?: never;
|
|
2927
|
+
options?: never;
|
|
2928
|
+
head?: never;
|
|
2929
|
+
patch?: never;
|
|
2930
|
+
trace?: never;
|
|
2931
|
+
};
|
|
2932
|
+
"/api/v1/policies/payment-gates/{id}": {
|
|
2933
|
+
parameters: {
|
|
2934
|
+
query?: never;
|
|
2935
|
+
header?: never;
|
|
2936
|
+
path?: never;
|
|
2937
|
+
cookie?: never;
|
|
2938
|
+
};
|
|
2939
|
+
get?: never;
|
|
2940
|
+
put?: never;
|
|
2941
|
+
post?: never;
|
|
2942
|
+
/**
|
|
2943
|
+
* Stop requiring a payment before cover begins
|
|
2944
|
+
* @description Deletes the declaration. No gate applies by absence, which is what an empty table means.
|
|
2945
|
+
*
|
|
2946
|
+
* **Policies already held are not released by this.** They stay `PendingPayment` until somebody records that the requirement was met, because releasing cover is an act with an author and evidence (ADR-0042 section 7) and withdrawing a rule is neither. A broker that gated its book by mistake releases each held policy deliberately.
|
|
2947
|
+
*/
|
|
2948
|
+
delete: operations["WithdrawPaymentGate"];
|
|
2949
|
+
options?: never;
|
|
2950
|
+
head?: never;
|
|
2951
|
+
patch?: never;
|
|
2952
|
+
trace?: never;
|
|
2953
|
+
};
|
|
2870
2954
|
"/api/v1/policies/{id}/documents/{kind}": {
|
|
2871
2955
|
parameters: {
|
|
2872
2956
|
query?: never;
|
|
@@ -4451,6 +4535,10 @@ export interface components {
|
|
|
4451
4535
|
key: null | string;
|
|
4452
4536
|
name: null | string;
|
|
4453
4537
|
};
|
|
4538
|
+
DeclarePaymentGateRequest: {
|
|
4539
|
+
/** Format: uuid */
|
|
4540
|
+
productId: null | string;
|
|
4541
|
+
};
|
|
4454
4542
|
DeclineQuoteRequest: {
|
|
4455
4543
|
/** Format: uuid */
|
|
4456
4544
|
presentationVersionId: null | string;
|
|
@@ -5092,6 +5180,16 @@ export interface components {
|
|
|
5092
5180
|
PaymentEvidenceUpload: {
|
|
5093
5181
|
file: components["schemas"]["IFormFile"];
|
|
5094
5182
|
};
|
|
5183
|
+
PaymentGateResponse: {
|
|
5184
|
+
/** Format: uuid */
|
|
5185
|
+
id: string;
|
|
5186
|
+
/** Format: uuid */
|
|
5187
|
+
productId: null | string;
|
|
5188
|
+
appliesToEveryProduct: boolean;
|
|
5189
|
+
/** Format: date-time */
|
|
5190
|
+
setAtUtc: string;
|
|
5191
|
+
setBySubjectId: string;
|
|
5192
|
+
};
|
|
5095
5193
|
PaymentPage: {
|
|
5096
5194
|
items: components["schemas"]["PaymentSummaryResponse"][];
|
|
5097
5195
|
nextCursor: null | string;
|
|
@@ -5240,6 +5338,11 @@ export interface components {
|
|
|
5240
5338
|
/** Format: date-time */
|
|
5241
5339
|
importedAtUtc: null | string;
|
|
5242
5340
|
importedBySubjectId: null | string;
|
|
5341
|
+
/** Format: date-time */
|
|
5342
|
+
paymentRequirementMetAtUtc: null | string;
|
|
5343
|
+
paymentRequirementMetBySubjectId: null | string;
|
|
5344
|
+
/** Format: uuid */
|
|
5345
|
+
paymentEvidenceReference: null | string;
|
|
5243
5346
|
};
|
|
5244
5347
|
PresentationBodyResponse: {
|
|
5245
5348
|
version: components["schemas"]["PresentationVersionResponse"];
|
|
@@ -5552,6 +5655,10 @@ export interface components {
|
|
|
5552
5655
|
source: string;
|
|
5553
5656
|
externalReference: string;
|
|
5554
5657
|
};
|
|
5658
|
+
RecordPaymentRequirementMetRequest: {
|
|
5659
|
+
/** Format: uuid */
|
|
5660
|
+
paymentId: null | string;
|
|
5661
|
+
};
|
|
5555
5662
|
RecordRenewalCustomerInformationRequest: {
|
|
5556
5663
|
/** Format: uuid */
|
|
5557
5664
|
formSubmissionId: null | string;
|
|
@@ -12527,6 +12634,59 @@ export interface operations {
|
|
|
12527
12634
|
};
|
|
12528
12635
|
};
|
|
12529
12636
|
};
|
|
12637
|
+
RecordPaymentRequirementMet: {
|
|
12638
|
+
parameters: {
|
|
12639
|
+
query?: never;
|
|
12640
|
+
header?: never;
|
|
12641
|
+
path: {
|
|
12642
|
+
id: string;
|
|
12643
|
+
};
|
|
12644
|
+
cookie?: never;
|
|
12645
|
+
};
|
|
12646
|
+
requestBody: {
|
|
12647
|
+
content: {
|
|
12648
|
+
"application/json": components["schemas"]["RecordPaymentRequirementMetRequest"];
|
|
12649
|
+
};
|
|
12650
|
+
};
|
|
12651
|
+
responses: {
|
|
12652
|
+
/** @description OK */
|
|
12653
|
+
200: {
|
|
12654
|
+
headers: {
|
|
12655
|
+
[name: string]: unknown;
|
|
12656
|
+
};
|
|
12657
|
+
content: {
|
|
12658
|
+
"application/json": components["schemas"]["PolicyResponse"];
|
|
12659
|
+
};
|
|
12660
|
+
};
|
|
12661
|
+
/** @description Bad Request */
|
|
12662
|
+
400: {
|
|
12663
|
+
headers: {
|
|
12664
|
+
[name: string]: unknown;
|
|
12665
|
+
};
|
|
12666
|
+
content: {
|
|
12667
|
+
"application/problem+json": components["schemas"]["HttpValidationProblemDetails"];
|
|
12668
|
+
};
|
|
12669
|
+
};
|
|
12670
|
+
/** @description Not Found */
|
|
12671
|
+
404: {
|
|
12672
|
+
headers: {
|
|
12673
|
+
[name: string]: unknown;
|
|
12674
|
+
};
|
|
12675
|
+
content: {
|
|
12676
|
+
"application/problem+json": components["schemas"]["ProblemDetails"];
|
|
12677
|
+
};
|
|
12678
|
+
};
|
|
12679
|
+
/** @description Conflict */
|
|
12680
|
+
409: {
|
|
12681
|
+
headers: {
|
|
12682
|
+
[name: string]: unknown;
|
|
12683
|
+
};
|
|
12684
|
+
content: {
|
|
12685
|
+
"application/problem+json": components["schemas"]["ProblemDetails"];
|
|
12686
|
+
};
|
|
12687
|
+
};
|
|
12688
|
+
};
|
|
12689
|
+
};
|
|
12530
12690
|
GetPolicy: {
|
|
12531
12691
|
parameters: {
|
|
12532
12692
|
query?: never;
|
|
@@ -12558,6 +12718,95 @@ export interface operations {
|
|
|
12558
12718
|
};
|
|
12559
12719
|
};
|
|
12560
12720
|
};
|
|
12721
|
+
ReadPaymentGates: {
|
|
12722
|
+
parameters: {
|
|
12723
|
+
query?: never;
|
|
12724
|
+
header?: never;
|
|
12725
|
+
path?: never;
|
|
12726
|
+
cookie?: never;
|
|
12727
|
+
};
|
|
12728
|
+
requestBody?: never;
|
|
12729
|
+
responses: {
|
|
12730
|
+
/** @description OK */
|
|
12731
|
+
200: {
|
|
12732
|
+
headers: {
|
|
12733
|
+
[name: string]: unknown;
|
|
12734
|
+
};
|
|
12735
|
+
content: {
|
|
12736
|
+
"application/json": components["schemas"]["PaymentGateResponse"][];
|
|
12737
|
+
};
|
|
12738
|
+
};
|
|
12739
|
+
};
|
|
12740
|
+
};
|
|
12741
|
+
DeclarePaymentGate: {
|
|
12742
|
+
parameters: {
|
|
12743
|
+
query?: never;
|
|
12744
|
+
header?: never;
|
|
12745
|
+
path?: never;
|
|
12746
|
+
cookie?: never;
|
|
12747
|
+
};
|
|
12748
|
+
requestBody: {
|
|
12749
|
+
content: {
|
|
12750
|
+
"application/json": components["schemas"]["DeclarePaymentGateRequest"];
|
|
12751
|
+
};
|
|
12752
|
+
};
|
|
12753
|
+
responses: {
|
|
12754
|
+
/** @description Created */
|
|
12755
|
+
201: {
|
|
12756
|
+
headers: {
|
|
12757
|
+
[name: string]: unknown;
|
|
12758
|
+
};
|
|
12759
|
+
content: {
|
|
12760
|
+
"application/json": components["schemas"]["PaymentGateResponse"];
|
|
12761
|
+
};
|
|
12762
|
+
};
|
|
12763
|
+
/** @description Bad Request */
|
|
12764
|
+
400: {
|
|
12765
|
+
headers: {
|
|
12766
|
+
[name: string]: unknown;
|
|
12767
|
+
};
|
|
12768
|
+
content: {
|
|
12769
|
+
"application/problem+json": components["schemas"]["HttpValidationProblemDetails"];
|
|
12770
|
+
};
|
|
12771
|
+
};
|
|
12772
|
+
/** @description Conflict */
|
|
12773
|
+
409: {
|
|
12774
|
+
headers: {
|
|
12775
|
+
[name: string]: unknown;
|
|
12776
|
+
};
|
|
12777
|
+
content: {
|
|
12778
|
+
"application/problem+json": components["schemas"]["ProblemDetails"];
|
|
12779
|
+
};
|
|
12780
|
+
};
|
|
12781
|
+
};
|
|
12782
|
+
};
|
|
12783
|
+
WithdrawPaymentGate: {
|
|
12784
|
+
parameters: {
|
|
12785
|
+
query?: never;
|
|
12786
|
+
header?: never;
|
|
12787
|
+
path: {
|
|
12788
|
+
id: string;
|
|
12789
|
+
};
|
|
12790
|
+
cookie?: never;
|
|
12791
|
+
};
|
|
12792
|
+
requestBody?: never;
|
|
12793
|
+
responses: {
|
|
12794
|
+
/** @description No Content */
|
|
12795
|
+
204: {
|
|
12796
|
+
headers: {
|
|
12797
|
+
[name: string]: unknown;
|
|
12798
|
+
};
|
|
12799
|
+
content?: never;
|
|
12800
|
+
};
|
|
12801
|
+
/** @description Not Found */
|
|
12802
|
+
404: {
|
|
12803
|
+
headers: {
|
|
12804
|
+
[name: string]: unknown;
|
|
12805
|
+
};
|
|
12806
|
+
content?: never;
|
|
12807
|
+
};
|
|
12808
|
+
};
|
|
12809
|
+
};
|
|
12561
12810
|
UploadPolicyDocument: {
|
|
12562
12811
|
parameters: {
|
|
12563
12812
|
query?: never;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@insurance-broker/api-client",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.38.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,
|