@bisondesk/commons-sdk 1.0.197 → 1.0.198

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/src/hyperdms.ts DELETED
@@ -1,614 +0,0 @@
1
- export enum HdmsActivities {
2
- DOCUMENT_UPSERT = 'DOCUMENT_UPSERT',
3
- ORGANIZATION_UPSERT = 'ORGANIZATION_UPSERT',
4
- VEHICLE_MODIFY = 'VEHICLE_MODIFY',
5
- }
6
-
7
- export type HdmsOrganization = {
8
- billingEmail?: string;
9
- countryCode: string;
10
- createdAt: number;
11
- createdBy: string;
12
- deleted?: boolean;
13
- externalId: number;
14
- id: string;
15
- name: string;
16
- ownerOrg: string;
17
- ownerOrgs: string[];
18
- parentId?: string;
19
- segment?: string;
20
- type?: 'COMPANY' | 'INDIVIDUAL';
21
- vatNumber?: string;
22
- website?: string;
23
- };
24
-
25
- export type HdmsContact = {
26
- accountManagers: string[];
27
- createdAt: number;
28
- createdBy: string;
29
- deleted?: boolean;
30
- emails: { label: string; value: string }[];
31
- firstName?: string;
32
- id: string;
33
- job?: string;
34
- language: string; // the english name of the language, ex: Portuguese
35
- lastName?: string;
36
- nickname?: string;
37
- notes?: string;
38
- phones: { label: string; value: string }[];
39
- };
40
-
41
- export type HdmsAddress = {
42
- addressLines: string[];
43
- city?: string;
44
- countryCode: string;
45
- createdAt: number;
46
- createdBy: string;
47
- deleted?: boolean;
48
- id: string;
49
- labels: Array<'TRANSPORT_ADDRESS' | 'LEGAL_ADDRESS'>;
50
- zipCode?: string;
51
- position?: {
52
- lat: number;
53
- lon: number;
54
- };
55
- };
56
-
57
- export type HdmsRecurringLeasingInvoice = {
58
- id: string;
59
- vehicleId: string;
60
- vehicleSaleId: string;
61
- vehicleAdministrativeNumber: string;
62
- vehicleStockNumber: string;
63
- organizationId: string;
64
- startDate: string;
65
- totalExecutions: number;
66
- executions: number;
67
- active: boolean;
68
- billingEmail: string;
69
- invoiceNotes: string;
70
- lineDescription: string;
71
- lineSubcategory: string;
72
- ownerOrg: string;
73
- journal: string;
74
- vatCode: string;
75
- amountExclusive: number;
76
- createdBy: string;
77
- createdAt: number;
78
- lastModifiedBy: string;
79
- lastModifiedAt: number;
80
- lastExecutedAt: number;
81
- lastExecutedFinanceDocumentId: string;
82
- };
83
-
84
- export type HdmsPicklistValue = {
85
- property: string;
86
- id: string;
87
- name: string;
88
- lang: string;
89
- sort: number;
90
- dependency?: {
91
- property_dependency: string;
92
- allowed_dependency_ids: string[];
93
- };
94
- };
95
-
96
- export type HdmsActivityEvent<T = {}> = {
97
- who: string;
98
- what: string;
99
- when: number;
100
- metadata: T;
101
- };
102
-
103
- export type HdmsRole = {
104
- id: string;
105
- vehicleId: string;
106
- designation: string;
107
- };
108
-
109
- export type HdmsVehicle = HdmsBaseVehicle & {
110
- administrative_number: string;
111
- deleted_date?: number;
112
- id: string;
113
- location?: string;
114
- meta_id: string;
115
- offer_id?: string;
116
- organization: string;
117
- stock_number: string;
118
- transaction_type: string;
119
- segments?: string[];
120
- };
121
-
122
- export type HdmsBaseVehicle = {
123
- created_at: number;
124
- created_by: string;
125
- last_updated_at: number;
126
- last_updated_by: string;
127
- advertised_year?: number;
128
- leasing_eligible: boolean;
129
- external_id?: string;
130
- category: string;
131
- bodywork?: string;
132
- extended_length?: string;
133
- extended_height?: string;
134
- make: string;
135
- year?: number;
136
- advertise_targets?: {
137
- PUBLIC_WEBSITE: boolean;
138
- HEXON: boolean;
139
- };
140
- advertise_overrides?: {
141
- PUBLIC_WEBSITE?: boolean;
142
- HEXON?: boolean;
143
- };
144
- description?: string;
145
- public_description?: string;
146
- licence_plate?: string;
147
- technical_description?: string;
148
- registration_country?: string;
149
- first_registration_date?: number;
150
- coc_pvg?: string;
151
- technical_inspection_end_date?: number;
152
- gearbox?: 'Automatic' | 'Manual' | 'Semi-Automatic';
153
- gearbox_make?: string;
154
- gearbox_type?: string;
155
- number_of_gears?: number;
156
- kilometers?: number;
157
- euronorm?: string;
158
- configuration?: string;
159
- option_retarder?: boolean;
160
- option_engine_brake?: boolean;
161
- option_damaged?: boolean;
162
- option_lift?: boolean;
163
- option_crane?: boolean;
164
- crane_make?: string;
165
- crane_model?: string;
166
- crane_position?: 'Behind the cabin' | 'Rear';
167
- crane_year?: number;
168
- cabin?: 'Day' | 'Sleep / Small' | 'Sleep / Medium' | 'Sleep / Large';
169
- cabin_model?: string;
170
- total_load_kg?: number;
171
- weight_empty_vehicle_kg?: number;
172
- power_hp?: number;
173
- number_of_cylinders?: number;
174
- chassis_number?: string;
175
- suspension?: 'Air' | 'Air/Steel' | 'Steel';
176
- height_cm?: number;
177
- width_cm?: number;
178
- length_cm?: number;
179
- wheelbase_cm?: number;
180
- bodywork_height_cm?: number;
181
- bodywork_width_cm?: number;
182
- bodywork_length_cm?: number;
183
- bodywork_make?: string;
184
- bodywork_type?: string;
185
- cooling_engine_make?: string;
186
- bodywork_volume_l?: number;
187
- bodywork_number_of_compartments?: number;
188
- option_sliding_roof?: boolean;
189
- option_pump?: boolean;
190
- option_hoses?: boolean;
191
- option_counter?: boolean;
192
- option_high_pressure_pump?: boolean;
193
- tank_transport_material?: string;
194
- option_tipper_left?: boolean;
195
- option_tipper_right?: boolean;
196
- option_tipper_back?: boolean;
197
- bodywork_floor_height_cm?: number;
198
- bodywork_number_of_cars?: number;
199
- cooling_engine?: string;
200
- electric_cooling_operating_hours?: number;
201
- diesel_cooling_operating_hours?: number;
202
- tailgate_make?: string;
203
- tailgate_model?: string;
204
- tailgate_type?: string;
205
- tailgate_max_load_kg?: number;
206
- option_extensible?: boolean;
207
- option_airco?: boolean;
208
- option_standard_airco?: boolean;
209
- option_alloy_wheels?: boolean;
210
- option_aluminium_fuel_tank?: boolean;
211
- option_abs?: boolean;
212
- option_central_locking?: boolean;
213
- option_central_lubrication?: boolean;
214
- option_trailer_coupling?: boolean;
215
- option_cruise_control?: boolean;
216
- option_electric_door_mirrors?: boolean;
217
- option_electric_windows?: boolean;
218
- option_low_noise?: boolean;
219
- option_gps?: boolean;
220
- option_particle_filter?: boolean;
221
- option_power_take_off?: boolean;
222
- option_cd_player?: boolean;
223
- option_refrigerator?: boolean;
224
- option_reversing_camera?: boolean;
225
- option_roof_spoiler?: boolean;
226
- option_spoilers?: boolean;
227
- option_side_skirts?: boolean;
228
- option_speed_limiter?: boolean;
229
- option_spotlights?: boolean;
230
- option_stability_control?: boolean;
231
- option_television?: boolean;
232
- option_toolbox?: boolean;
233
- option_twin_fuel_tank?: boolean;
234
- option_parking_heater?: boolean;
235
- option_visor?: boolean;
236
- option_xenon_lights?: boolean;
237
- option_tailgate?: boolean;
238
- option_spare_wheel?: boolean;
239
- option_forklift?: boolean;
240
- option_adr?: boolean;
241
- option_spare_key?: boolean;
242
- option_hydraulic_tipper_kit?: boolean;
243
- number_of_doors?: number;
244
- fuel?: string;
245
- engine_displacement_cc?: number;
246
- make_model?: string;
247
- make_model_type?: string;
248
- option_low_deck?: boolean;
249
- first_hand?: boolean;
250
- axles?: HdmsAxle[];
251
- };
252
-
253
- export type HdmsAxle = {
254
- axle_number: number;
255
- axle_position?: string;
256
- make?: string;
257
- tire_size?: string;
258
- tire_profile_left?: number;
259
- tire_profile_right?: number;
260
- tire_profile_inner_left?: number;
261
- tire_profile_inner_right?: number;
262
- brakes?: 'Disc' | 'Drum';
263
- suspension?: 'Steel' | 'Air' | 'Hydraulic';
264
- reduction?: string;
265
- option_lift?: boolean;
266
- option_twin_wheel?: boolean;
267
- option_steering?: boolean;
268
- option_alloy_wheels?: boolean;
269
- option_driven?: boolean;
270
- option_differential_lock?: boolean;
271
- };
272
-
273
- export type HdmsVehicleSaleDealStatus =
274
- | 'SALE_AGREED'
275
- | 'FIRST_PAYMENT_RECEIVED'
276
- | 'FULL_PAYMENT_RECEIVED'
277
- | 'DELETED';
278
-
279
- export type HdmsVehiclePurchaseDealStatus =
280
- | 'PURCHASE_AGREED'
281
- | 'FIRST_PAYMENT_ALLOWED'
282
- | 'FIRST_PAYMENT_SENT'
283
- | 'FULL_PAYMENT_ALLOWED'
284
- | 'FULL_PAYMENT_SENT'
285
- | 'DELETED';
286
-
287
- export type HdmsVehicleSaleLogisticsStatus = 'AT_ORIGIN' | 'DELIVERED';
288
- export type HdmsVehiclePurchaseLogisticsStatus = 'AT_ORIGIN' | 'ARRIVED' | 'CHECKED_IN';
289
-
290
- export type HdmsVehicleStatus = {
291
- deleted: boolean;
292
- option?: {
293
- id: string;
294
- expirationDate: number;
295
- };
296
- sale?: {
297
- id: string;
298
- dealStatus: HdmsVehicleSaleDealStatus;
299
- logisticsStatus: HdmsVehicleSaleLogisticsStatus;
300
- };
301
- purchase?: {
302
- id: string;
303
- dealStatus: HdmsVehiclePurchaseDealStatus;
304
- logisticsStatus: HdmsVehiclePurchaseLogisticsStatus;
305
- };
306
- };
307
-
308
- export type HdmsPrice = {
309
- currency?: string; // EUR
310
- premium?: number;
311
- } & (
312
- | {
313
- internet: number;
314
- minimum?: number;
315
- }
316
- | {
317
- internet?: number;
318
- minimum: number;
319
- }
320
- );
321
-
322
- export type HdmsVehicleOrganizationSummary = {
323
- organization_id: string;
324
- contact_id: string;
325
- address_id: string;
326
- transport_address_id?: string;
327
- };
328
-
329
- export type HdmsVehicleSale = {
330
- id: string;
331
- vehicle_id: string;
332
- organization_summary: HdmsVehicleOrganizationSummary;
333
- modified_at: number;
334
- modified_by: string;
335
- log: {
336
- sale_agreed_date?: number;
337
- };
338
- leasing_contract?: string;
339
-
340
- // TODO
341
- };
342
-
343
- export type HdmsClientSaleRef = {
344
- vehicle_id: string;
345
- sale_id: string;
346
- created_at: number;
347
- status: HdmsVehicleSaleDealStatus;
348
- };
349
-
350
- export type HdmsClientSales = {
351
- sales: HdmsClientSaleRef[];
352
- organization_id: string;
353
- contact_id: string;
354
- };
355
-
356
- export enum HdmsDocumentStatusValue {
357
- SCANNED = 'SCANNED',
358
- DRAFT = 'DRAFT',
359
- CREATED = 'CREATED',
360
- REJECTED = 'REJECTED',
361
- SAVING = 'SAVING',
362
- VALIDATED = 'VALIDATED',
363
- }
364
-
365
- export type HdmsDocumentStatus = {
366
- documentId: string;
367
- status: HdmsDocumentStatusValue;
368
- createdBy: string;
369
- createdAt: number;
370
- };
371
-
372
- export type HdmsTag = {
373
- value: string;
374
- sourceId: string;
375
- sourceType: string;
376
- };
377
-
378
- export type HdmsViewer = {
379
- username: string;
380
- sourceId: string;
381
- sourceType: string;
382
- };
383
-
384
- export type HdmsAssociation = {
385
- type: string;
386
- id: string;
387
- description: string;
388
- };
389
-
390
- export type HdmsAdminDocument = {
391
- id: string;
392
- scanId?: string;
393
- metaId: string;
394
- ownerOrg: string;
395
-
396
- supertype: 'Administrative';
397
- type?:
398
- | 'General Administrative'
399
- | 'Logistics Administrative'
400
- | 'Sale Administrative'
401
- | 'Purchase Administrative';
402
- subtype?: string;
403
- number?: string;
404
- qrCode?: string;
405
-
406
- organizationSummary?: HdmsDocumentOrganizationSummary;
407
-
408
- attachment: HdmsAttachment;
409
-
410
- notes?: string;
411
-
412
- associations: HdmsAssociation[];
413
- tags: HdmsTag[];
414
- viewers: HdmsViewer[];
415
-
416
- createdAt: number;
417
- createdBy: string;
418
- lastUpdatedAt: number;
419
- lastUpdatedBy: string;
420
- deletedAt?: number;
421
- deletedBy?: string;
422
- };
423
-
424
- export type HdmsFinanceDocument = {
425
- id: string;
426
- scanId?: string;
427
- metaId: string;
428
- ownerOrg: string;
429
-
430
- supertype: 'Finance';
431
- type: 'Sale Finance' | 'Purchase Finance';
432
- subtype: 'Invoice' | 'Credit Note' | 'Proforma' | 'Purchase Order';
433
- number: string;
434
- qrCode?: string;
435
-
436
- organizationSummary?: HdmsDocumentOrganizationSummary;
437
-
438
- attachment: HdmsAttachment;
439
-
440
- notes?: string;
441
-
442
- associations: HdmsAssociation[];
443
- tags: HdmsTag[];
444
- viewers: HdmsViewer[];
445
-
446
- createdAt: number;
447
- createdBy: string;
448
- lastUpdatedAt: number;
449
- lastUpdatedBy: string;
450
- deletedAt?: number;
451
- deletedBy?: string;
452
-
453
- issueDate: number;
454
- amountInclusive: number;
455
- amountVat: number;
456
- salesperson?: {
457
- username: string;
458
- displayName: string;
459
- };
460
- journal?: string;
461
- };
462
-
463
- export type HdmsFinanceLine = {
464
- id: string;
465
- financeDocumentId: string;
466
-
467
- categoryContext: string; // vehicle, other
468
- category: string; // sale, purchase, other
469
- subcategory: string; // purchase_cost, ...
470
- description: string;
471
- unitPriceExclusive: number;
472
- vatCode: string;
473
- vatCoefficient: number;
474
- quantity: number;
475
-
476
- createdAt: number;
477
- createdBy: string;
478
-
479
- associations: HdmsAssociation[];
480
- };
481
-
482
- export type NewHdmsBooking = {
483
- bookingNumber: string;
484
- financeDocumentId: string;
485
- };
486
-
487
- export type HdmsBooking = NewHdmsBooking & {
488
- amount?: number;
489
- createdAt: number;
490
- createdBy: string;
491
- journal?: string;
492
- modifiedAt: number;
493
- modifiedBy: string;
494
- organization: string;
495
- paid?: boolean;
496
- reportingPeriod?: number;
497
- reportingYear?: number;
498
- };
499
-
500
- export type HdmsVehiclePurchase = {
501
- id: string;
502
- vehicle_id: string;
503
- organization_summary: HdmsVehicleOrganizationSummary;
504
- purchase_cost?: number;
505
- purchase_cost_taxable?: number;
506
- vat_percentage?: number;
507
- commission_cost?: number;
508
- available_week?: string;
509
- pickup_location?: string;
510
- internal_transport_cost?: number;
511
- external_transport_cost?: number;
512
- internal_garage_cost?: number;
513
- external_garage_cost?: number;
514
- carwash_cost?: number;
515
- spoiler_mounting_cost?: number;
516
- load_stack_cost?: number;
517
- total_cost: number;
518
- other_costs?: number;
519
- status: string;
520
- logistics_status: string;
521
- log: {
522
- purchase_agreed_date?: number;
523
- purchase_agreed_reporter?: string;
524
- first_payment_allowed_date?: number;
525
- first_payment_allowed_reporter?: string;
526
- first_payment_sent_date?: number;
527
- first_payment_sent_reporter?: string;
528
- full_payment_allowed_date?: number;
529
- full_payment_allowed_reporter?: string;
530
- full_payment_sent_date?: number;
531
- full_payment_sent_reporter?: string;
532
- checked_in_date?: number;
533
- checked_in_reporter?: string;
534
- deleted_date?: number;
535
- deleted_reporter?: string;
536
- };
537
- };
538
-
539
- export type HdmsAttachment = {
540
- id: string;
541
- folder: string;
542
- extension: string;
543
- original_name: string;
544
- mime_type?: string;
545
- category: 'Image' | 'Document';
546
- main_picture?: boolean;
547
- orientation?: number;
548
- upload_date: number;
549
- upload_by_employee_name?: string;
550
- unrestricted?: boolean;
551
- properties?: {
552
- NUMBER_OF_PAGES?: string;
553
- };
554
- url?: string;
555
- };
556
-
557
- export type HdmsAccount = {
558
- username: string;
559
- email: string;
560
- otherEmails: string[];
561
- };
562
-
563
- export type HdmsAccountQueryRequest = {
564
- emails: string[];
565
- phones: string[];
566
- };
567
-
568
- export type HdmsDocumentOrganizationSummary = {
569
- id: string;
570
- code: string;
571
- name: string;
572
- country: string;
573
- vatNumber?: string;
574
-
575
- addressLine1?: string;
576
- addressLine2?: string;
577
- addressLine3?: string;
578
- postcode?: string;
579
- city?: string;
580
-
581
- email?: string;
582
- phone?: string;
583
- fax?: string;
584
- };
585
-
586
- export type HdmsDebtDossier = {
587
- overdueSince?: number;
588
- overdueInvoices: number;
589
- overdueAmount: number;
590
- unpaidInvoices: number;
591
- unpaidAmount: number;
592
- };
593
-
594
- export type HdmsExactPurchaseLine = {
595
- description: string;
596
- glAccountCode: string;
597
- quantity: number;
598
- unitPrice: number;
599
- vatCode: string;
600
- };
601
-
602
- export type NewHdmsExactPurchase = {
603
- description: string;
604
- invoiceDate: number;
605
- invoiceNumber: string;
606
- journal: string;
607
- lines: HdmsExactPurchaseLine[];
608
- supplierCode: string;
609
- attachment?: HdmsAttachment;
610
- };
611
-
612
- export type HdmsExactPurchase = NewHdmsExactPurchase & {
613
- bookingNumber: string;
614
- };