@hectare/platform.clients.trading 1.1.161 → 1.1.162

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/index.d.ts CHANGED
@@ -1,8 +1,4 @@
1
1
  export type { AcceptBid } from './models/AcceptBid.js';
2
- export type { AdvancePayContractSchema } from './models/AdvancePayContractSchema.js';
3
- export type { AdvancePayOfferSchema } from './models/AdvancePayOfferSchema.js';
4
- export type { AdvancePayRequestOfferSchema } from './models/AdvancePayRequestOfferSchema.js';
5
- export type { AdvancePayUploadCollectionReceiptSchema } from './models/AdvancePayUploadCollectionReceiptSchema.js';
6
2
  export type { AskAnExpertBuyerRallyReportSchema } from './models/AskAnExpertBuyerRallyReportSchema.js';
7
3
  export type { Availability } from './models/Availability.js';
8
4
  export type { BidAlerts } from './models/BidAlerts.js';
@@ -35,8 +31,6 @@ export type { ExFarmPricesRegionSchema } from './models/ExFarmPricesRegionSchema
35
31
  export type { ExFarmPricesSchema } from './models/ExFarmPricesSchema.js';
36
32
  export type { ExpiredBidOffer } from './models/ExpiredBidOffer.js';
37
33
  export type { FeedItem } from './models/FeedItem.js';
38
- export type { FinMidWebhook } from './models/FinMidWebhook.js';
39
- export type { FinMidWebhookEvent } from './models/FinMidWebhookEvent.js';
40
34
  export type { InsightPrices } from './models/InsightPrices.js';
41
35
  export type { InsightsDailySpotPricesByDateRangeSchema } from './models/InsightsDailySpotPricesByDateRangeSchema.js';
42
36
  export type { InsightsDailySpotPricesSchema } from './models/InsightsDailySpotPricesSchema.js';
@@ -266,9 +266,6 @@ export type BidDetail = {
266
266
  weight?: number;
267
267
  } | null;
268
268
  expiredOfferExpireAtUTC: string | null;
269
- isAdvancePayEligible: boolean;
270
- advancePayStatus?: string;
271
- advancePayContractId: string | null;
272
269
  acceptedAtUTC: string | null;
273
270
  soldWeight: number | null;
274
271
  haulageType: 'ex-farm' | 'delivered';
@@ -308,146 +305,6 @@ export type BidDetail = {
308
305
  } | null> | null;
309
306
  reference: string | null;
310
307
  };
311
- isAdvancePayEligible: boolean;
312
- advancePayStatus?: string;
313
- advancePayContract: {
314
- id: string;
315
- finmidPaymentId: string;
316
- status: 'pending' | 'captured' | 'settled';
317
- inventory: {
318
- harvestYear: string;
319
- commodity: {
320
- commodity: {
321
- id: number;
322
- name: string;
323
- };
324
- type: {
325
- id: number;
326
- name: string;
327
- };
328
- grade: {
329
- id: number;
330
- name: string;
331
- };
332
- variety?: string;
333
- varieties: Array<string>;
334
- attributes: Array<{
335
- id: number;
336
- name: string;
337
- }>;
338
- tags?: Array<number>;
339
- weight: {
340
- name: string;
341
- conversion: number;
342
- weight?: number;
343
- };
344
- };
345
- };
346
- trade: {
347
- listingId: string;
348
- bidId: string;
349
- buyer: {
350
- userId: string;
351
- organisationId: string;
352
- organisationName: string;
353
- };
354
- seller: {
355
- userId: string;
356
- organisationId: string;
357
- organisationName: string;
358
- };
359
- movement: {
360
- startDateUTC: string;
361
- endDateUTC: string;
362
- type: 'date' | 'month';
363
- };
364
- settlementDateUTC: string;
365
- buyerTermDays: number;
366
- amount: {
367
- amount: number;
368
- currency: string;
369
- };
370
- };
371
- offer: {
372
- totalWeight: {
373
- name: string;
374
- conversion: number;
375
- weight?: number;
376
- };
377
- totalTradeValue: {
378
- amount: number;
379
- currency: string;
380
- };
381
- totalSellerReceivable: {
382
- amount: number;
383
- currency: string;
384
- };
385
- movementTermUTC: string;
386
- pricePerUnit: {
387
- amount: number;
388
- currency: string;
389
- };
390
- payments: {
391
- fees: {
392
- amount: number;
393
- currency: string;
394
- };
395
- };
396
- };
397
- payments: {
398
- advance: {
399
- percentage: number;
400
- amount: {
401
- amount: number;
402
- currency: string;
403
- };
404
- amountAfterFees?: {
405
- amount: number;
406
- currency: string;
407
- } | null;
408
- status: 'pending' | 'captured';
409
- capturedAtUTC: string;
410
- dueAtUTC: string;
411
- };
412
- intermediate: {
413
- percentage: number;
414
- amount: {
415
- amount: number;
416
- currency: string;
417
- };
418
- amountAfterFees?: {
419
- amount: number;
420
- currency: string;
421
- } | null;
422
- status: 'pending' | 'captured';
423
- capturedAtUTC: string;
424
- dueAtUTC: string;
425
- } | null;
426
- settlement: {
427
- percentage: number;
428
- amount: {
429
- amount: number;
430
- currency: string;
431
- };
432
- amountAfterFees?: {
433
- amount: number;
434
- currency: string;
435
- } | null;
436
- status: 'pending' | 'captured';
437
- capturedAtUTC: string;
438
- };
439
- };
440
- collectionReceipts: Array<{
441
- name?: string;
442
- id: string;
443
- url?: string | null;
444
- userId?: string | null;
445
- userName?: string | null;
446
- organisationId?: string | null;
447
- createdAtUTC?: string | null;
448
- } | null>;
449
- tags: Array<string>;
450
- } | null;
451
308
  buyerContact: {
452
309
  email: string;
453
310
  phone: {
@@ -277,13 +277,6 @@ export type ContractDetail = {
277
277
  } | null;
278
278
  assuranceId?: string;
279
279
  assuranceScheme?: 'RT' | 'SQC';
280
- advancePay?: {
281
- accountName: string;
282
- sortCode: string;
283
- accountNumber: string;
284
- enabled: boolean;
285
- eligible: boolean;
286
- } | null;
287
280
  salesforceId?: string;
288
281
  salesforceUpdates?: Array<string>;
289
282
  };
@@ -252,7 +252,6 @@ export type ListingDetail = {
252
252
  currency: string;
253
253
  } | null;
254
254
  contractId: string;
255
- advancePayContractId: string;
256
255
  movementPeriod: {
257
256
  startDateUTC: string;
258
257
  endDateUTC: string;
@@ -528,9 +527,6 @@ export type ListingDetail = {
528
527
  weight?: number;
529
528
  } | null;
530
529
  expiredOfferExpireAtUTC: string | null;
531
- isAdvancePayEligible: boolean;
532
- advancePayStatus?: string;
533
- advancePayContractId: string | null;
534
530
  acceptedAtUTC: string | null;
535
531
  soldWeight: number | null;
536
532
  haulageType: 'ex-farm' | 'delivered';
@@ -570,146 +566,6 @@ export type ListingDetail = {
570
566
  } | null> | null;
571
567
  reference: string | null;
572
568
  };
573
- isAdvancePayEligible: boolean;
574
- advancePayStatus?: string;
575
- advancePayContract: {
576
- id: string;
577
- finmidPaymentId: string;
578
- status: 'pending' | 'captured' | 'settled';
579
- inventory: {
580
- harvestYear: string;
581
- commodity: {
582
- commodity: {
583
- id: number;
584
- name: string;
585
- };
586
- type: {
587
- id: number;
588
- name: string;
589
- };
590
- grade: {
591
- id: number;
592
- name: string;
593
- };
594
- variety?: string;
595
- varieties: Array<string>;
596
- attributes: Array<{
597
- id: number;
598
- name: string;
599
- }>;
600
- tags?: Array<number>;
601
- weight: {
602
- name: string;
603
- conversion: number;
604
- weight?: number;
605
- };
606
- };
607
- };
608
- trade: {
609
- listingId: string;
610
- bidId: string;
611
- buyer: {
612
- userId: string;
613
- organisationId: string;
614
- organisationName: string;
615
- };
616
- seller: {
617
- userId: string;
618
- organisationId: string;
619
- organisationName: string;
620
- };
621
- movement: {
622
- startDateUTC: string;
623
- endDateUTC: string;
624
- type: 'date' | 'month';
625
- };
626
- settlementDateUTC: string;
627
- buyerTermDays: number;
628
- amount: {
629
- amount: number;
630
- currency: string;
631
- };
632
- };
633
- offer: {
634
- totalWeight: {
635
- name: string;
636
- conversion: number;
637
- weight?: number;
638
- };
639
- totalTradeValue: {
640
- amount: number;
641
- currency: string;
642
- };
643
- totalSellerReceivable: {
644
- amount: number;
645
- currency: string;
646
- };
647
- movementTermUTC: string;
648
- pricePerUnit: {
649
- amount: number;
650
- currency: string;
651
- };
652
- payments: {
653
- fees: {
654
- amount: number;
655
- currency: string;
656
- };
657
- };
658
- };
659
- payments: {
660
- advance: {
661
- percentage: number;
662
- amount: {
663
- amount: number;
664
- currency: string;
665
- };
666
- amountAfterFees?: {
667
- amount: number;
668
- currency: string;
669
- } | null;
670
- status: 'pending' | 'captured';
671
- capturedAtUTC: string;
672
- dueAtUTC: string;
673
- };
674
- intermediate: {
675
- percentage: number;
676
- amount: {
677
- amount: number;
678
- currency: string;
679
- };
680
- amountAfterFees?: {
681
- amount: number;
682
- currency: string;
683
- } | null;
684
- status: 'pending' | 'captured';
685
- capturedAtUTC: string;
686
- dueAtUTC: string;
687
- } | null;
688
- settlement: {
689
- percentage: number;
690
- amount: {
691
- amount: number;
692
- currency: string;
693
- };
694
- amountAfterFees?: {
695
- amount: number;
696
- currency: string;
697
- } | null;
698
- status: 'pending' | 'captured';
699
- capturedAtUTC: string;
700
- };
701
- };
702
- collectionReceipts: Array<{
703
- name?: string;
704
- id: string;
705
- url?: string | null;
706
- userId?: string | null;
707
- userName?: string | null;
708
- organisationId?: string | null;
709
- createdAtUTC?: string | null;
710
- } | null>;
711
- tags: Array<string>;
712
- } | null;
713
569
  buyerContact: {
714
570
  email: string;
715
571
  phone: {
@@ -267,9 +267,6 @@ export type SearchResultsBidSchema = {
267
267
  weight?: number;
268
268
  } | null;
269
269
  expiredOfferExpireAtUTC: string | null;
270
- isAdvancePayEligible: boolean;
271
- advancePayStatus?: string;
272
- advancePayContractId: string | null;
273
270
  acceptedAtUTC: string | null;
274
271
  soldWeight: number | null;
275
272
  haulageType: 'ex-farm' | 'delivered';
@@ -309,146 +306,6 @@ export type SearchResultsBidSchema = {
309
306
  } | null> | null;
310
307
  reference: string | null;
311
308
  };
312
- isAdvancePayEligible: boolean;
313
- advancePayStatus?: string;
314
- advancePayContract: {
315
- id: string;
316
- finmidPaymentId: string;
317
- status: 'pending' | 'captured' | 'settled';
318
- inventory: {
319
- harvestYear: string;
320
- commodity: {
321
- commodity: {
322
- id: number;
323
- name: string;
324
- };
325
- type: {
326
- id: number;
327
- name: string;
328
- };
329
- grade: {
330
- id: number;
331
- name: string;
332
- };
333
- variety?: string;
334
- varieties: Array<string>;
335
- attributes: Array<{
336
- id: number;
337
- name: string;
338
- }>;
339
- tags?: Array<number>;
340
- weight: {
341
- name: string;
342
- conversion: number;
343
- weight?: number;
344
- };
345
- };
346
- };
347
- trade: {
348
- listingId: string;
349
- bidId: string;
350
- buyer: {
351
- userId: string;
352
- organisationId: string;
353
- organisationName: string;
354
- };
355
- seller: {
356
- userId: string;
357
- organisationId: string;
358
- organisationName: string;
359
- };
360
- movement: {
361
- startDateUTC: string;
362
- endDateUTC: string;
363
- type: 'date' | 'month';
364
- };
365
- settlementDateUTC: string;
366
- buyerTermDays: number;
367
- amount: {
368
- amount: number;
369
- currency: string;
370
- };
371
- };
372
- offer: {
373
- totalWeight: {
374
- name: string;
375
- conversion: number;
376
- weight?: number;
377
- };
378
- totalTradeValue: {
379
- amount: number;
380
- currency: string;
381
- };
382
- totalSellerReceivable: {
383
- amount: number;
384
- currency: string;
385
- };
386
- movementTermUTC: string;
387
- pricePerUnit: {
388
- amount: number;
389
- currency: string;
390
- };
391
- payments: {
392
- fees: {
393
- amount: number;
394
- currency: string;
395
- };
396
- };
397
- };
398
- payments: {
399
- advance: {
400
- percentage: number;
401
- amount: {
402
- amount: number;
403
- currency: string;
404
- };
405
- amountAfterFees?: {
406
- amount: number;
407
- currency: string;
408
- } | null;
409
- status: 'pending' | 'captured';
410
- capturedAtUTC: string;
411
- dueAtUTC: string;
412
- };
413
- intermediate: {
414
- percentage: number;
415
- amount: {
416
- amount: number;
417
- currency: string;
418
- };
419
- amountAfterFees?: {
420
- amount: number;
421
- currency: string;
422
- } | null;
423
- status: 'pending' | 'captured';
424
- capturedAtUTC: string;
425
- dueAtUTC: string;
426
- } | null;
427
- settlement: {
428
- percentage: number;
429
- amount: {
430
- amount: number;
431
- currency: string;
432
- };
433
- amountAfterFees?: {
434
- amount: number;
435
- currency: string;
436
- } | null;
437
- status: 'pending' | 'captured';
438
- capturedAtUTC: string;
439
- };
440
- };
441
- collectionReceipts: Array<{
442
- name?: string;
443
- id: string;
444
- url?: string | null;
445
- userId?: string | null;
446
- userName?: string | null;
447
- organisationId?: string | null;
448
- createdAtUTC?: string | null;
449
- } | null>;
450
- tags: Array<string>;
451
- } | null;
452
309
  buyerContact: {
453
310
  email: string;
454
311
  phone: {
@@ -25,33 +25,6 @@ export type TradingConfig = {
25
25
  id: number;
26
26
  description: string;
27
27
  }>;
28
- advancePay: {
29
- harvestYears: Array<string>;
30
- interestRates: {
31
- finmid: Array<{
32
- termDays: number;
33
- ratePct: number;
34
- periodDays: number;
35
- }>;
36
- ecb: {
37
- ratePct: number;
38
- periodDays: number;
39
- };
40
- hectare: {
41
- ratePct: number;
42
- periodDays: number;
43
- };
44
- };
45
- maxEligibilityDays: number;
46
- commercialTerms: Array<{
47
- termDaysThreshold: number;
48
- upfrontPct: number;
49
- intermediatePct: number;
50
- settlementPct: number;
51
- }>;
52
- settlementAdjustmentPerUnit: number;
53
- gracePeriodDays: number;
54
- };
55
28
  bidExpiredOfferExpiryTimeframe: {
56
29
  isEnabled: boolean;
57
30
  expiryHours: number;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hectare/platform.clients.trading",
3
- "version": "1.1.161",
3
+ "version": "1.1.162",
4
4
  "main": "index.js",
5
5
  "exported": true,
6
6
  "types": "index.d.ts",
@@ -1,138 +0,0 @@
1
- export type AdvancePayContractSchema = {
2
- id: string;
3
- finmidPaymentId: string;
4
- status: 'pending' | 'captured' | 'settled';
5
- inventory: {
6
- harvestYear: string;
7
- commodity: {
8
- commodity: {
9
- id: number;
10
- name: string;
11
- };
12
- type: {
13
- id: number;
14
- name: string;
15
- };
16
- grade: {
17
- id: number;
18
- name: string;
19
- };
20
- variety?: string;
21
- varieties: Array<string>;
22
- attributes: Array<{
23
- id: number;
24
- name: string;
25
- }>;
26
- tags?: Array<number>;
27
- weight: {
28
- name: string;
29
- conversion: number;
30
- weight?: number;
31
- };
32
- };
33
- };
34
- trade: {
35
- listingId: string;
36
- bidId: string;
37
- buyer: {
38
- userId: string;
39
- organisationId: string;
40
- organisationName: string;
41
- };
42
- seller: {
43
- userId: string;
44
- organisationId: string;
45
- organisationName: string;
46
- };
47
- movement: {
48
- startDateUTC: string;
49
- endDateUTC: string;
50
- type: 'date' | 'month';
51
- };
52
- settlementDateUTC: string;
53
- buyerTermDays: number;
54
- amount: {
55
- amount: number;
56
- currency: string;
57
- };
58
- };
59
- offer: {
60
- totalWeight: {
61
- name: string;
62
- conversion: number;
63
- weight?: number;
64
- };
65
- totalTradeValue: {
66
- amount: number;
67
- currency: string;
68
- };
69
- totalSellerReceivable: {
70
- amount: number;
71
- currency: string;
72
- };
73
- movementTermUTC: string;
74
- pricePerUnit: {
75
- amount: number;
76
- currency: string;
77
- };
78
- payments: {
79
- fees: {
80
- amount: number;
81
- currency: string;
82
- };
83
- };
84
- };
85
- payments: {
86
- advance: {
87
- percentage: number;
88
- amount: {
89
- amount: number;
90
- currency: string;
91
- };
92
- amountAfterFees?: {
93
- amount: number;
94
- currency: string;
95
- } | null;
96
- status: 'pending' | 'captured';
97
- capturedAtUTC: string;
98
- dueAtUTC: string;
99
- };
100
- intermediate: {
101
- percentage: number;
102
- amount: {
103
- amount: number;
104
- currency: string;
105
- };
106
- amountAfterFees?: {
107
- amount: number;
108
- currency: string;
109
- } | null;
110
- status: 'pending' | 'captured';
111
- capturedAtUTC: string;
112
- dueAtUTC: string;
113
- } | null;
114
- settlement: {
115
- percentage: number;
116
- amount: {
117
- amount: number;
118
- currency: string;
119
- };
120
- amountAfterFees?: {
121
- amount: number;
122
- currency: string;
123
- } | null;
124
- status: 'pending' | 'captured';
125
- capturedAtUTC: string;
126
- };
127
- };
128
- collectionReceipts: Array<{
129
- name?: string;
130
- id: string;
131
- url?: string | null;
132
- userId?: string | null;
133
- userName?: string | null;
134
- organisationId?: string | null;
135
- createdAtUTC?: string | null;
136
- } | null>;
137
- tags: Array<string>;
138
- };
@@ -1 +0,0 @@
1
- export {};
@@ -1,62 +0,0 @@
1
- export type AdvancePayOfferSchema = {
2
- totalWeight: {
3
- name: string;
4
- conversion: number;
5
- weight?: number;
6
- };
7
- totalTradeValue: {
8
- amount: number;
9
- currency: string;
10
- };
11
- totalSellerReceivable: {
12
- amount: number;
13
- currency: string;
14
- };
15
- movementTermUTC: string;
16
- pricePerUnit: {
17
- amount: number;
18
- currency: string;
19
- };
20
- payments: {
21
- fees: {
22
- amount: number;
23
- currency: string;
24
- };
25
- advance: {
26
- amount: {
27
- amount: number;
28
- currency: string;
29
- };
30
- amountAfterFees?: {
31
- amount: number;
32
- currency: string;
33
- } | null;
34
- percentage: number;
35
- type: 'advance' | 'intermediate' | 'settlement';
36
- };
37
- intermediate?: {
38
- amount: {
39
- amount: number;
40
- currency: string;
41
- };
42
- amountAfterFees?: {
43
- amount: number;
44
- currency: string;
45
- } | null;
46
- percentage: number;
47
- type: 'advance' | 'intermediate' | 'settlement';
48
- };
49
- settlement: {
50
- amount: {
51
- amount: number;
52
- currency: string;
53
- };
54
- amountAfterFees?: {
55
- amount: number;
56
- currency: string;
57
- } | null;
58
- percentage: number;
59
- type: 'advance' | 'intermediate' | 'settlement';
60
- };
61
- };
62
- };
@@ -1 +0,0 @@
1
- export {};
@@ -1,13 +0,0 @@
1
- export type AdvancePayRequestOfferSchema = {
2
- weight: {
3
- name: string;
4
- conversion: number;
5
- weight?: number;
6
- };
7
- pricePerUnit: {
8
- amount: number;
9
- currency: string;
10
- };
11
- movementPeriodDays: number;
12
- repaymentDays: number;
13
- };
@@ -1 +0,0 @@
1
- export {};
@@ -1,12 +0,0 @@
1
- export type AdvancePayUploadCollectionReceiptSchema = {
2
- collectionReceipts: Array<{
3
- name?: string;
4
- id: string;
5
- url?: string | null;
6
- userId?: string | null;
7
- userName?: string | null;
8
- organisationId?: string | null;
9
- createdAtUTC?: string | null;
10
- } | null>;
11
- movementDateUTC: string;
12
- };
@@ -1 +0,0 @@
1
- export {};
@@ -1,10 +0,0 @@
1
- export type FinMidWebhook = {
2
- webhook_id: string;
3
- timestamp: string;
4
- events: Array<{
5
- event_id?: string;
6
- timestamp?: string;
7
- type?: string;
8
- data?: any;
9
- }> | null;
10
- };
@@ -1 +0,0 @@
1
- export {};
@@ -1,6 +0,0 @@
1
- export type FinMidWebhookEvent = {
2
- event_id?: string;
3
- timestamp?: string;
4
- type?: string;
5
- data?: any;
6
- };
@@ -1 +0,0 @@
1
- export {};