@star-insure/sdk 0.1.4 → 0.1.7
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/types/models/quotes/QuoteRequest.d.ts +85 -79
- package/dist/types/models/quotes/QuoteRequestDeclaration.d.ts +3 -3
- package/dist/types/models/quotes/{QuoteRequestForm.d.ts → QuoteRequestIncident.d.ts} +0 -0
- package/dist/types/models/quotes/index.d.ts +1 -1
- package/package.json +1 -1
- package/src/types/models/quotes/QuoteRequest.ts +87 -80
- package/src/types/models/quotes/QuoteRequestDeclaration.ts +4 -3
- package/src/types/models/quotes/{QuoteRequestForm.ts → QuoteRequestIncident.ts} +0 -0
- package/src/types/models/quotes/index.ts +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Product, VehicleType } from "../../api";
|
|
2
2
|
import { Club } from "./Club";
|
|
3
|
-
import { QuoteRequestIncident } from "./
|
|
3
|
+
import { QuoteRequestIncident } from "./QuoteRequestIncident";
|
|
4
4
|
import { Lead } from "./Lead";
|
|
5
5
|
import { PostalAddress } from "./PostalAddress";
|
|
6
6
|
import { QuoteRequestDeclaration } from "./QuoteRequestDeclaration";
|
|
@@ -33,8 +33,8 @@ export interface QuoteRequest {
|
|
|
33
33
|
phone: string | null;
|
|
34
34
|
mobile: string | null;
|
|
35
35
|
email: string | null;
|
|
36
|
-
|
|
37
|
-
|
|
36
|
+
licence: string | null;
|
|
37
|
+
licence_other: string | null;
|
|
38
38
|
has_automatch: boolean | null;
|
|
39
39
|
automatch_by: QuoteRequestAutomatch;
|
|
40
40
|
automatch_client_id: string | null;
|
|
@@ -81,94 +81,100 @@ export interface QuoteRequestForm {
|
|
|
81
81
|
id?: string;
|
|
82
82
|
status?: QuoteRequestStatus;
|
|
83
83
|
source?: QuoteRequestSource;
|
|
84
|
-
reference?: string
|
|
85
|
-
client_number?: string
|
|
86
|
-
first_name?: string
|
|
87
|
-
last_name?: string
|
|
88
|
-
phone?: string
|
|
89
|
-
mobile?: string
|
|
90
|
-
email?: string
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
promo_code?: string
|
|
94
|
-
club_membership_number?: string
|
|
95
|
-
broker_fee?: number
|
|
96
|
-
length_of_insurance?: string
|
|
97
|
-
theme?: string
|
|
98
|
-
dob?: string
|
|
99
|
-
sold_at?: string
|
|
100
|
-
sent_at?: string
|
|
101
|
-
pricing_expires_at?: string
|
|
102
|
-
follow_up_at?: string
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
84
|
+
reference?: string;
|
|
85
|
+
client_number?: string;
|
|
86
|
+
first_name?: string;
|
|
87
|
+
last_name?: string;
|
|
88
|
+
phone?: string;
|
|
89
|
+
mobile?: string;
|
|
90
|
+
email?: string;
|
|
91
|
+
licence?: string;
|
|
92
|
+
licence_other?: string;
|
|
93
|
+
promo_code?: string;
|
|
94
|
+
club_membership_number?: string;
|
|
95
|
+
broker_fee?: number;
|
|
96
|
+
length_of_insurance?: string;
|
|
97
|
+
theme?: string;
|
|
98
|
+
dob?: string;
|
|
99
|
+
sold_at?: string;
|
|
100
|
+
sent_at?: string;
|
|
101
|
+
pricing_expires_at?: string;
|
|
102
|
+
follow_up_at?: string;
|
|
103
|
+
referrer_id?: QuoteRequestReferrer['id'];
|
|
104
|
+
referrer_category_id?: QuoteRequestReferrerCategory['id'];
|
|
105
|
+
staff_member_id?: QuoteRequestUser['id'];
|
|
106
|
+
agent_id?: QuoteRequestUser['id'];
|
|
107
|
+
agent_firm_id?: QuoteRequestUserGroup['id'];
|
|
108
|
+
broker_firm_id?: QuoteRequestUserGroup['id'];
|
|
109
|
+
broker_id?: QuoteRequestUser['id'];
|
|
110
|
+
club_id?: Club['id'];
|
|
111
|
+
street_address: {
|
|
112
|
+
id?: number;
|
|
113
|
+
address?: string;
|
|
114
|
+
unit?: string;
|
|
115
|
+
suburb?: string;
|
|
116
|
+
city?: string;
|
|
117
|
+
post_code?: string;
|
|
118
|
+
};
|
|
113
119
|
declaration: {
|
|
114
120
|
id?: number;
|
|
115
|
-
had_incident?: boolean
|
|
116
|
-
incidents?: QuoteRequestIncident[]
|
|
117
|
-
has_demerit_points?: boolean
|
|
118
|
-
demerit_points?: string
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
was_refused_insurance?: boolean
|
|
122
|
-
refused_insurance_details?: string
|
|
123
|
-
has_criminal_conviction?: boolean
|
|
124
|
-
criminal_conviction_details?: string
|
|
125
|
-
has_vehicle_modifications?: boolean
|
|
126
|
-
vehicle_modifications_details?: string
|
|
127
|
-
has_previous_insurer?: boolean
|
|
128
|
-
previous_insurer_details?: string
|
|
129
|
-
previous_insurer_expires_at?: string
|
|
130
|
-
additional_details?: string
|
|
121
|
+
had_incident?: boolean;
|
|
122
|
+
incidents?: QuoteRequestIncident[];
|
|
123
|
+
has_demerit_points?: boolean;
|
|
124
|
+
demerit_points?: string;
|
|
125
|
+
has_lost_licence?: boolean;
|
|
126
|
+
lost_licence_details?: string;
|
|
127
|
+
was_refused_insurance?: boolean;
|
|
128
|
+
refused_insurance_details?: string;
|
|
129
|
+
has_criminal_conviction?: boolean;
|
|
130
|
+
criminal_conviction_details?: string;
|
|
131
|
+
has_vehicle_modifications?: boolean;
|
|
132
|
+
vehicle_modifications_details?: string;
|
|
133
|
+
has_previous_insurer?: boolean;
|
|
134
|
+
previous_insurer_details?: string;
|
|
135
|
+
previous_insurer_expires_at?: string;
|
|
136
|
+
additional_details?: string;
|
|
131
137
|
};
|
|
132
138
|
vehicles: {
|
|
133
139
|
id?: number;
|
|
134
|
-
vehicle_type?: VehicleType
|
|
135
|
-
registration?: string
|
|
136
|
-
make?: string
|
|
137
|
-
model?: string
|
|
138
|
-
year?: string
|
|
139
|
-
usage?: string
|
|
140
|
-
product?: Product
|
|
141
|
-
has_financially_interested_party?: boolean
|
|
142
|
-
financially_interested_party_detail?: string
|
|
143
|
-
owned_duration?: string
|
|
144
|
-
value?: number
|
|
145
|
-
storage_location?: string
|
|
146
|
-
is_heavy?: boolean
|
|
140
|
+
vehicle_type?: VehicleType;
|
|
141
|
+
registration?: string;
|
|
142
|
+
make?: string;
|
|
143
|
+
model?: string;
|
|
144
|
+
year?: string;
|
|
145
|
+
usage?: string;
|
|
146
|
+
product?: Product;
|
|
147
|
+
has_financially_interested_party?: boolean;
|
|
148
|
+
financially_interested_party_detail?: string;
|
|
149
|
+
owned_duration?: string;
|
|
150
|
+
value?: number;
|
|
151
|
+
storage_location?: string;
|
|
152
|
+
is_heavy?: boolean;
|
|
147
153
|
drivers: {
|
|
148
154
|
id?: number;
|
|
149
155
|
first_name?: string;
|
|
150
156
|
last_name?: string;
|
|
151
|
-
dob?: string
|
|
152
|
-
relationship?: string
|
|
153
|
-
licence?: string
|
|
154
|
-
licence_other?: string
|
|
157
|
+
dob?: string;
|
|
158
|
+
relationship?: string;
|
|
159
|
+
licence?: string;
|
|
160
|
+
licence_other?: string;
|
|
155
161
|
}[];
|
|
156
162
|
}[];
|
|
157
163
|
purchaseOptions?: {
|
|
158
164
|
id?: number;
|
|
159
|
-
level_of_insurance_id?: number
|
|
160
|
-
sort_order?: number
|
|
161
|
-
description?: string
|
|
162
|
-
base_premium?: number
|
|
163
|
-
premium?: number
|
|
164
|
-
monthly_premium?: number
|
|
165
|
-
show_monthly?: boolean
|
|
166
|
-
fsl?: number
|
|
167
|
-
gst?: number
|
|
168
|
-
premium_type?: PremiumType
|
|
169
|
-
policy_starts_at?: string
|
|
170
|
-
sold_at?: string
|
|
171
|
-
is_paid?: boolean
|
|
172
|
-
payment_frequency?: PaymentFrequency
|
|
165
|
+
level_of_insurance_id?: number;
|
|
166
|
+
sort_order?: number;
|
|
167
|
+
description?: string;
|
|
168
|
+
base_premium?: number;
|
|
169
|
+
premium?: number;
|
|
170
|
+
monthly_premium?: number;
|
|
171
|
+
show_monthly?: boolean;
|
|
172
|
+
fsl?: number;
|
|
173
|
+
gst?: number;
|
|
174
|
+
premium_type?: PremiumType;
|
|
175
|
+
policy_starts_at?: string;
|
|
176
|
+
sold_at?: string;
|
|
177
|
+
is_paid?: boolean;
|
|
178
|
+
payment_frequency?: PaymentFrequency;
|
|
173
179
|
};
|
|
174
180
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { QuoteRequest } from "./QuoteRequest";
|
|
2
|
-
import { QuoteRequestIncident } from "./
|
|
2
|
+
import { QuoteRequestIncident } from "./QuoteRequestIncident";
|
|
3
3
|
export interface QuoteRequestDeclaration {
|
|
4
4
|
id: number;
|
|
5
5
|
quote_request_id: QuoteRequest['id'] | null;
|
|
@@ -7,8 +7,8 @@ export interface QuoteRequestDeclaration {
|
|
|
7
7
|
incidents: QuoteRequestIncident[] | null;
|
|
8
8
|
has_demerit_points: boolean | null;
|
|
9
9
|
demerit_points: string | null;
|
|
10
|
-
|
|
11
|
-
|
|
10
|
+
has_lost_licence: boolean | null;
|
|
11
|
+
lost_licence_details: string | null;
|
|
12
12
|
was_refused_insurance: boolean | null;
|
|
13
13
|
refused_insurance_details: string | null;
|
|
14
14
|
has_criminal_conviction: boolean | null;
|
|
File without changes
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@star-insure/sdk",
|
|
3
3
|
"description": "The SDK for Star Insure client apps with shared helper functions and TypeScript definitions.",
|
|
4
4
|
"author": "alexclark_nz",
|
|
5
|
-
"version": "0.1.
|
|
5
|
+
"version": "0.1.7",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"repository": {
|
|
8
8
|
"type": "git",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Product, VehicleType } from "../../api";
|
|
2
2
|
import { Club } from "./Club";
|
|
3
|
-
import { QuoteRequestIncident } from "./
|
|
3
|
+
import { QuoteRequestIncident } from "./QuoteRequestIncident";
|
|
4
4
|
import { Lead } from "./Lead";
|
|
5
5
|
import { PostalAddress } from "./PostalAddress";
|
|
6
6
|
import { QuoteRequestDeclaration } from "./QuoteRequestDeclaration";
|
|
@@ -39,8 +39,8 @@ export interface QuoteRequest {
|
|
|
39
39
|
phone: string | null;
|
|
40
40
|
mobile: string | null;
|
|
41
41
|
email: string | null;
|
|
42
|
-
|
|
43
|
-
|
|
42
|
+
licence: string | null;
|
|
43
|
+
licence_other: string | null;
|
|
44
44
|
has_automatch: boolean | null;
|
|
45
45
|
automatch_by: QuoteRequestAutomatch;
|
|
46
46
|
automatch_client_id: string | null;
|
|
@@ -94,100 +94,107 @@ export interface QuoteRequestForm {
|
|
|
94
94
|
id?: string;
|
|
95
95
|
status?: QuoteRequestStatus;
|
|
96
96
|
source?: QuoteRequestSource;
|
|
97
|
-
reference?: string
|
|
98
|
-
client_number?: string
|
|
99
|
-
first_name?: string
|
|
100
|
-
last_name?: string
|
|
101
|
-
phone?: string
|
|
102
|
-
mobile?: string
|
|
103
|
-
email?: string
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
promo_code?: string
|
|
107
|
-
club_membership_number?: string
|
|
108
|
-
broker_fee?: number
|
|
109
|
-
length_of_insurance?: string
|
|
110
|
-
theme?: string
|
|
111
|
-
|
|
112
|
-
dob?: string
|
|
113
|
-
sold_at?: string
|
|
114
|
-
sent_at?: string
|
|
115
|
-
pricing_expires_at?: string
|
|
116
|
-
follow_up_at?: string
|
|
97
|
+
reference?: string;
|
|
98
|
+
client_number?: string;
|
|
99
|
+
first_name?: string;
|
|
100
|
+
last_name?: string;
|
|
101
|
+
phone?: string;
|
|
102
|
+
mobile?: string;
|
|
103
|
+
email?: string;
|
|
104
|
+
licence?: string;
|
|
105
|
+
licence_other?: string;
|
|
106
|
+
promo_code?: string;
|
|
107
|
+
club_membership_number?: string;
|
|
108
|
+
broker_fee?: number;
|
|
109
|
+
length_of_insurance?: string;
|
|
110
|
+
theme?: string;
|
|
111
|
+
|
|
112
|
+
dob?: string;
|
|
113
|
+
sold_at?: string;
|
|
114
|
+
sent_at?: string;
|
|
115
|
+
pricing_expires_at?: string;
|
|
116
|
+
follow_up_at?: string;
|
|
117
117
|
|
|
118
118
|
// Foreign keys
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
119
|
+
referrer_id?: QuoteRequestReferrer['id'];
|
|
120
|
+
referrer_category_id?: QuoteRequestReferrerCategory['id'];
|
|
121
|
+
staff_member_id?: QuoteRequestUser['id'];
|
|
122
|
+
agent_id?: QuoteRequestUser['id'];
|
|
123
|
+
agent_firm_id?: QuoteRequestUserGroup['id'];
|
|
124
|
+
broker_firm_id?: QuoteRequestUserGroup['id'];
|
|
125
|
+
broker_id?: QuoteRequestUser['id'];
|
|
126
|
+
club_id?: Club['id'];
|
|
127
|
+
|
|
128
|
+
street_address: {
|
|
129
|
+
id?: number;
|
|
130
|
+
address?: string;
|
|
131
|
+
unit?: string;
|
|
132
|
+
suburb?: string;
|
|
133
|
+
city?: string;
|
|
134
|
+
post_code?: string;
|
|
135
|
+
},
|
|
129
136
|
|
|
130
137
|
declaration: {
|
|
131
138
|
id?: number;
|
|
132
|
-
had_incident?: boolean
|
|
133
|
-
incidents?: QuoteRequestIncident[]
|
|
134
|
-
has_demerit_points?: boolean
|
|
135
|
-
demerit_points?: string
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
was_refused_insurance?: boolean
|
|
139
|
-
refused_insurance_details?: string
|
|
140
|
-
has_criminal_conviction?: boolean
|
|
141
|
-
criminal_conviction_details?: string
|
|
142
|
-
has_vehicle_modifications?: boolean
|
|
143
|
-
vehicle_modifications_details?: string
|
|
144
|
-
has_previous_insurer?: boolean
|
|
145
|
-
previous_insurer_details?: string
|
|
146
|
-
previous_insurer_expires_at?: string
|
|
147
|
-
additional_details?: string
|
|
139
|
+
had_incident?: boolean;
|
|
140
|
+
incidents?: QuoteRequestIncident[];
|
|
141
|
+
has_demerit_points?: boolean;
|
|
142
|
+
demerit_points?: string;
|
|
143
|
+
has_lost_licence?: boolean;
|
|
144
|
+
lost_licence_details?: string;
|
|
145
|
+
was_refused_insurance?: boolean;
|
|
146
|
+
refused_insurance_details?: string;
|
|
147
|
+
has_criminal_conviction?: boolean;
|
|
148
|
+
criminal_conviction_details?: string;
|
|
149
|
+
has_vehicle_modifications?: boolean;
|
|
150
|
+
vehicle_modifications_details?: string;
|
|
151
|
+
has_previous_insurer?: boolean;
|
|
152
|
+
previous_insurer_details?: string;
|
|
153
|
+
previous_insurer_expires_at?: string;
|
|
154
|
+
additional_details?: string;
|
|
148
155
|
}
|
|
149
156
|
|
|
150
157
|
vehicles: {
|
|
151
158
|
id?: number;
|
|
152
|
-
vehicle_type?: VehicleType
|
|
153
|
-
registration?: string
|
|
154
|
-
make?: string
|
|
155
|
-
model?: string
|
|
156
|
-
year?: string
|
|
157
|
-
usage?: string
|
|
158
|
-
product?: Product
|
|
159
|
-
has_financially_interested_party?: boolean
|
|
160
|
-
financially_interested_party_detail?: string
|
|
161
|
-
owned_duration?: string
|
|
162
|
-
value?: number
|
|
163
|
-
storage_location?: string
|
|
164
|
-
is_heavy?: boolean
|
|
159
|
+
vehicle_type?: VehicleType;
|
|
160
|
+
registration?: string;
|
|
161
|
+
make?: string;
|
|
162
|
+
model?: string;
|
|
163
|
+
year?: string;
|
|
164
|
+
usage?: string;
|
|
165
|
+
product?: Product;
|
|
166
|
+
has_financially_interested_party?: boolean;
|
|
167
|
+
financially_interested_party_detail?: string;
|
|
168
|
+
owned_duration?: string;
|
|
169
|
+
value?: number;
|
|
170
|
+
storage_location?: string;
|
|
171
|
+
is_heavy?: boolean;
|
|
165
172
|
drivers: {
|
|
166
173
|
id?: number;
|
|
167
174
|
first_name?: string;
|
|
168
175
|
last_name?: string;
|
|
169
|
-
dob?: string
|
|
170
|
-
relationship?: string
|
|
171
|
-
licence?: string
|
|
172
|
-
licence_other?: string
|
|
176
|
+
dob?: string;
|
|
177
|
+
relationship?: string;
|
|
178
|
+
licence?: string;
|
|
179
|
+
licence_other?: string;
|
|
173
180
|
}[];
|
|
174
181
|
}[],
|
|
175
182
|
|
|
176
183
|
purchaseOptions?: {
|
|
177
184
|
id?: number;
|
|
178
|
-
level_of_insurance_id?: number
|
|
179
|
-
sort_order?: number
|
|
180
|
-
description?: string
|
|
181
|
-
base_premium?: number
|
|
182
|
-
premium?: number
|
|
183
|
-
monthly_premium?: number
|
|
184
|
-
show_monthly?: boolean
|
|
185
|
-
fsl?: number
|
|
186
|
-
gst?: number
|
|
187
|
-
premium_type?: PremiumType
|
|
188
|
-
policy_starts_at?: string
|
|
189
|
-
sold_at?: string
|
|
190
|
-
is_paid?: boolean
|
|
191
|
-
payment_frequency?: PaymentFrequency
|
|
185
|
+
level_of_insurance_id?: number;
|
|
186
|
+
sort_order?: number;
|
|
187
|
+
description?: string;
|
|
188
|
+
base_premium?: number;
|
|
189
|
+
premium?: number;
|
|
190
|
+
monthly_premium?: number;
|
|
191
|
+
show_monthly?: boolean;
|
|
192
|
+
fsl?: number;
|
|
193
|
+
gst?: number;
|
|
194
|
+
premium_type?: PremiumType;
|
|
195
|
+
policy_starts_at?: string;
|
|
196
|
+
sold_at?: string;
|
|
197
|
+
is_paid?: boolean;
|
|
198
|
+
payment_frequency?: PaymentFrequency;
|
|
192
199
|
},
|
|
193
200
|
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { QuoteRequest } from "./QuoteRequest";
|
|
2
|
-
import { QuoteRequestIncident } from "./
|
|
2
|
+
import { QuoteRequestIncident } from "./QuoteRequestIncident";
|
|
3
|
+
|
|
3
4
|
export interface QuoteRequestDeclaration {
|
|
4
5
|
id: number;
|
|
5
6
|
quote_request_id: QuoteRequest['id'] | null;
|
|
@@ -7,8 +8,8 @@ export interface QuoteRequestDeclaration {
|
|
|
7
8
|
incidents: QuoteRequestIncident[] | null;
|
|
8
9
|
has_demerit_points: boolean | null;
|
|
9
10
|
demerit_points: string | null;
|
|
10
|
-
|
|
11
|
-
|
|
11
|
+
has_lost_licence: boolean | null;
|
|
12
|
+
lost_licence_details: string | null;
|
|
12
13
|
was_refused_insurance: boolean | null;
|
|
13
14
|
refused_insurance_details: string | null;
|
|
14
15
|
has_criminal_conviction: boolean | null;
|
|
File without changes
|