@insurance-broker/api-client 1.13.0 → 1.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 (2) hide show
  1. package/dist/schema.d.ts +315 -0
  2. package/package.json +1 -1
package/dist/schema.d.ts CHANGED
@@ -851,6 +851,130 @@ export interface paths {
851
851
  patch?: never;
852
852
  trace?: never;
853
853
  };
854
+ "/api/v1/claims": {
855
+ parameters: {
856
+ query?: never;
857
+ header?: never;
858
+ path?: never;
859
+ cookie?: never;
860
+ };
861
+ get?: never;
862
+ put?: never;
863
+ /**
864
+ * Record a first notice of loss against a policy
865
+ * @description CLM-001. Opens a claim-assistance case: the broker is helping, and nothing here decides anything about cover.
866
+ *
867
+ * **The insurer decides, and this platform records.** A claim has no `Approved`, `Declined` or `Settled` state, because those are not states this platform can enter (ADR-0041 section 2). `status` says what the broker is doing.
868
+ *
869
+ * **One refusal covers four facts.** A policy that does not exist, one belonging to another broker, one belonging to another customer, and one not in force on the incident date are all answered the same way, so the route cannot be used to discover which policies a broker holds.
870
+ *
871
+ * The customer is named in the request and is not believed: it is checked against the policy, and the claim records the owner the policy gave.
872
+ */
873
+ post: operations["NotifyClaim"];
874
+ delete?: never;
875
+ options?: never;
876
+ head?: never;
877
+ patch?: never;
878
+ trace?: never;
879
+ };
880
+ "/api/v1/claims/{id}": {
881
+ parameters: {
882
+ query?: never;
883
+ header?: never;
884
+ path?: never;
885
+ cookie?: never;
886
+ };
887
+ /**
888
+ * Read one claim
889
+ * @description CLM-001. The claim's identifiers, the day of the incident, when the broker was told, and what the broker is doing about it.
890
+ *
891
+ * Another broker's claim, another customer's claim and a claim that does not exist are one 404, so the route cannot be used to discover which claims exist.
892
+ *
893
+ * `retentionAnchorAtUtc` is null while the claim is open. A claim open for two years has not started its disposal clock (ADR-0041 section 8).
894
+ */
895
+ get: operations["GetClaim"];
896
+ put?: never;
897
+ post?: never;
898
+ delete?: never;
899
+ options?: never;
900
+ head?: never;
901
+ patch?: never;
902
+ trace?: never;
903
+ };
904
+ "/api/v1/claims/{id}/withdrawal": {
905
+ parameters: {
906
+ query?: never;
907
+ header?: never;
908
+ path?: never;
909
+ cookie?: never;
910
+ };
911
+ get?: never;
912
+ put?: never;
913
+ /**
914
+ * Retract a claim
915
+ * @description CLM-001. Retracts a notice: the customer decided not to claim, or the notice was raised against the wrong policy.
916
+ *
917
+ * **This is not a decision about cover.** Nothing here says an insurer refused anything, and nothing says the incident did not happen. It records that the broker stopped.
918
+ *
919
+ * Withdrawing concludes the claim, which is what starts its retention clock. A claim that has already concluded is refused with 409 rather than re-stamped, because re-stamping would move the anchor of a record that concluded earlier.
920
+ */
921
+ post: operations["WithdrawClaim"];
922
+ delete?: never;
923
+ options?: never;
924
+ head?: never;
925
+ patch?: never;
926
+ trace?: never;
927
+ };
928
+ "/api/v1/customer/claims": {
929
+ parameters: {
930
+ query?: never;
931
+ header?: never;
932
+ path?: never;
933
+ cookie?: never;
934
+ };
935
+ get?: never;
936
+ put?: never;
937
+ /**
938
+ * Report a loss on one of your own policies
939
+ * @description CLM-001, the customer's half. Opens a claim-assistance case against a policy you own: the broker is helping, and nothing here decides anything about cover.
940
+ *
941
+ * **You are not named in the request.** The claim is opened for whoever is signed in, resolved from the session; there is no customer field, and a policy belonging to somebody else is answered exactly as one that does not exist.
942
+ *
943
+ * **The insurer decides, and this platform records.** A claim has no approved, declined or settled state, because those are not states this platform can enter (ADR-0041 section 2).
944
+ *
945
+ * To retract a claim, tell your broker. Concluding a case starts its retention clock, so it is recorded by the person who was told.
946
+ */
947
+ post: operations["ReportOwnClaim"];
948
+ delete?: never;
949
+ options?: never;
950
+ head?: never;
951
+ patch?: never;
952
+ trace?: never;
953
+ };
954
+ "/api/v1/customer/claims/{id}": {
955
+ parameters: {
956
+ query?: never;
957
+ header?: never;
958
+ path?: never;
959
+ cookie?: never;
960
+ };
961
+ /**
962
+ * Follow one of your own claims
963
+ * @description CLM-006. The claim's identifiers, the day of the incident, when your broker was told, and what your broker is doing about it.
964
+ *
965
+ * Another person's claim and a claim that does not exist are one 404, because a claim belonging to somebody else is not visible to this route at all rather than hidden from it by a filter somebody remembered to write.
966
+ *
967
+ * **This is not the timeline.** CLM-006's customer-visible timeline is step 8.8, and it is a separate append-only record a broker writes to deliberately — nothing a member of staff notes internally reaches it, or this response.
968
+ */
969
+ get: operations["GetOwnClaim"];
970
+ put?: never;
971
+ post?: never;
972
+ delete?: never;
973
+ options?: never;
974
+ head?: never;
975
+ patch?: never;
976
+ trace?: never;
977
+ };
854
978
  "/api/v1/leads": {
855
979
  parameters: {
856
980
  query?: never;
@@ -2819,6 +2943,21 @@ export interface components {
2819
2943
  items: components["schemas"]["ProductResponse"][];
2820
2944
  nextCursor: null | string;
2821
2945
  };
2946
+ ClaimResponse: {
2947
+ /** Format: uuid */
2948
+ id: string;
2949
+ /** Format: uuid */
2950
+ policyId: string;
2951
+ /** Format: uuid */
2952
+ customerId: string;
2953
+ /** Format: date */
2954
+ incidentOn: string;
2955
+ /** Format: date-time */
2956
+ notifiedAtUtc: string;
2957
+ status: string;
2958
+ /** Format: date-time */
2959
+ retentionAnchorAtUtc: null | string;
2960
+ };
2822
2961
  ComparedAttributeResponse: {
2823
2962
  key: string;
2824
2963
  label: string;
@@ -3350,6 +3489,14 @@ export interface components {
3350
3489
  releaseReason: null | string;
3351
3490
  isOpen: boolean;
3352
3491
  };
3492
+ NotifyClaimRequest: {
3493
+ /** Format: uuid */
3494
+ policyId: string;
3495
+ /** Format: uuid */
3496
+ customerId: string;
3497
+ /** Format: date */
3498
+ incidentOn: string;
3499
+ };
3353
3500
  OfferedFormResponse: {
3354
3501
  /** Format: uuid */
3355
3502
  id: string;
@@ -3948,6 +4095,12 @@ export interface components {
3948
4095
  carriedAnswerKeys: string[];
3949
4096
  droppedAnswerKeys: string[];
3950
4097
  };
4098
+ ReportClaimRequest: {
4099
+ /** Format: uuid */
4100
+ policyId: string;
4101
+ /** Format: date */
4102
+ incidentOn: string;
4103
+ };
3951
4104
  RetentionPeriodResponse: {
3952
4105
  /** Format: int32 */
3953
4106
  amount: number | string;
@@ -6539,6 +6692,168 @@ export interface operations {
6539
6692
  };
6540
6693
  };
6541
6694
  };
6695
+ NotifyClaim: {
6696
+ parameters: {
6697
+ query?: never;
6698
+ header?: never;
6699
+ path?: never;
6700
+ cookie?: never;
6701
+ };
6702
+ requestBody: {
6703
+ content: {
6704
+ "application/json": components["schemas"]["NotifyClaimRequest"];
6705
+ };
6706
+ };
6707
+ responses: {
6708
+ /** @description Created */
6709
+ 201: {
6710
+ headers: {
6711
+ [name: string]: unknown;
6712
+ };
6713
+ content: {
6714
+ "application/json": components["schemas"]["ClaimResponse"];
6715
+ };
6716
+ };
6717
+ /** @description Bad Request */
6718
+ 400: {
6719
+ headers: {
6720
+ [name: string]: unknown;
6721
+ };
6722
+ content: {
6723
+ "application/problem+json": components["schemas"]["HttpValidationProblemDetails"];
6724
+ };
6725
+ };
6726
+ };
6727
+ };
6728
+ GetClaim: {
6729
+ parameters: {
6730
+ query?: never;
6731
+ header?: never;
6732
+ path: {
6733
+ id: string;
6734
+ };
6735
+ cookie?: never;
6736
+ };
6737
+ requestBody?: never;
6738
+ responses: {
6739
+ /** @description OK */
6740
+ 200: {
6741
+ headers: {
6742
+ [name: string]: unknown;
6743
+ };
6744
+ content: {
6745
+ "application/json": components["schemas"]["ClaimResponse"];
6746
+ };
6747
+ };
6748
+ /** @description Not Found */
6749
+ 404: {
6750
+ headers: {
6751
+ [name: string]: unknown;
6752
+ };
6753
+ content?: never;
6754
+ };
6755
+ };
6756
+ };
6757
+ WithdrawClaim: {
6758
+ parameters: {
6759
+ query?: never;
6760
+ header?: never;
6761
+ path: {
6762
+ id: string;
6763
+ };
6764
+ cookie?: never;
6765
+ };
6766
+ requestBody?: never;
6767
+ responses: {
6768
+ /** @description OK */
6769
+ 200: {
6770
+ headers: {
6771
+ [name: string]: unknown;
6772
+ };
6773
+ content: {
6774
+ "application/json": components["schemas"]["ClaimResponse"];
6775
+ };
6776
+ };
6777
+ /** @description Not Found */
6778
+ 404: {
6779
+ headers: {
6780
+ [name: string]: unknown;
6781
+ };
6782
+ content?: never;
6783
+ };
6784
+ /** @description Conflict */
6785
+ 409: {
6786
+ headers: {
6787
+ [name: string]: unknown;
6788
+ };
6789
+ content: {
6790
+ "application/problem+json": components["schemas"]["ProblemDetails"];
6791
+ };
6792
+ };
6793
+ };
6794
+ };
6795
+ ReportOwnClaim: {
6796
+ parameters: {
6797
+ query?: never;
6798
+ header?: never;
6799
+ path?: never;
6800
+ cookie?: never;
6801
+ };
6802
+ requestBody: {
6803
+ content: {
6804
+ "application/json": components["schemas"]["ReportClaimRequest"];
6805
+ };
6806
+ };
6807
+ responses: {
6808
+ /** @description Created */
6809
+ 201: {
6810
+ headers: {
6811
+ [name: string]: unknown;
6812
+ };
6813
+ content: {
6814
+ "application/json": components["schemas"]["ClaimResponse"];
6815
+ };
6816
+ };
6817
+ /** @description Bad Request */
6818
+ 400: {
6819
+ headers: {
6820
+ [name: string]: unknown;
6821
+ };
6822
+ content: {
6823
+ "application/problem+json": components["schemas"]["HttpValidationProblemDetails"];
6824
+ };
6825
+ };
6826
+ };
6827
+ };
6828
+ GetOwnClaim: {
6829
+ parameters: {
6830
+ query?: never;
6831
+ header?: never;
6832
+ path: {
6833
+ id: string;
6834
+ };
6835
+ cookie?: never;
6836
+ };
6837
+ requestBody?: never;
6838
+ responses: {
6839
+ /** @description OK */
6840
+ 200: {
6841
+ headers: {
6842
+ [name: string]: unknown;
6843
+ };
6844
+ content: {
6845
+ "application/json": components["schemas"]["ClaimResponse"];
6846
+ };
6847
+ };
6848
+ /** @description Not Found */
6849
+ 404: {
6850
+ headers: {
6851
+ [name: string]: unknown;
6852
+ };
6853
+ content?: never;
6854
+ };
6855
+ };
6856
+ };
6542
6857
  ListLeads: {
6543
6858
  parameters: {
6544
6859
  query?: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@insurance-broker/api-client",
3
- "version": "1.13.0",
3
+ "version": "1.15.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,