@hubbyesim/sdk 2.1.0 → 2.2.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/CHANGELOG.md +21 -0
- package/README.md +51 -7
- package/dist/index.cjs +30 -3
- package/dist/index.d.cts +278 -120
- package/dist/index.d.ts +278 -120
- package/dist/index.js +30 -3
- package/llms.txt +16 -3
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -28,11 +28,11 @@ type SigningClientOptions = {
|
|
|
28
28
|
/**
|
|
29
29
|
* AnalyticsActivation
|
|
30
30
|
*/
|
|
31
|
-
type AnalyticsActivation = {
|
|
31
|
+
type AnalyticsActivation$1 = {
|
|
32
32
|
/**
|
|
33
33
|
* Activated over claimed, as a rate.
|
|
34
34
|
*/
|
|
35
|
-
rate: AnalyticsRatio;
|
|
35
|
+
rate: AnalyticsRatio$1;
|
|
36
36
|
/**
|
|
37
37
|
* Booking codes first claimed in the judged part of the range.
|
|
38
38
|
*/
|
|
@@ -66,7 +66,7 @@ type AnalyticsActivation = {
|
|
|
66
66
|
/**
|
|
67
67
|
* AnalyticsBreakdowns
|
|
68
68
|
*/
|
|
69
|
-
type AnalyticsBreakdowns = {
|
|
69
|
+
type AnalyticsBreakdowns$1 = {
|
|
70
70
|
/**
|
|
71
71
|
* Codes issued in the range, by destination. Includes codes of bookings moved over from the previous platform.
|
|
72
72
|
*/
|
|
@@ -78,7 +78,7 @@ type AnalyticsBreakdowns = {
|
|
|
78
78
|
/**
|
|
79
79
|
* Every destination with a code issued in the range, most codes first.
|
|
80
80
|
*/
|
|
81
|
-
top: Array<AnalyticsDestinationCount>;
|
|
81
|
+
top: Array<AnalyticsDestinationCount$1>;
|
|
82
82
|
};
|
|
83
83
|
/**
|
|
84
84
|
* Codes issued in the range, by bundle size. Includes codes of bookings moved over from the previous platform.
|
|
@@ -91,7 +91,7 @@ type AnalyticsBreakdowns = {
|
|
|
91
91
|
/**
|
|
92
92
|
* One row per bundle size, most codes first.
|
|
93
93
|
*/
|
|
94
|
-
distribution: Array<AnalyticsBundleSizeCount>;
|
|
94
|
+
distribution: Array<AnalyticsBundleSizeCount$1>;
|
|
95
95
|
};
|
|
96
96
|
/**
|
|
97
97
|
* Discounts given on payments that went through in the range.
|
|
@@ -104,13 +104,13 @@ type AnalyticsBreakdowns = {
|
|
|
104
104
|
/**
|
|
105
105
|
* The discount given through each discount code, per currency. A discount from an offer has no code, so it is counted in `discounted_payments` only.
|
|
106
106
|
*/
|
|
107
|
-
by_code: Array<AnalyticsDiscountCode>;
|
|
107
|
+
by_code: Array<AnalyticsDiscountCode$1>;
|
|
108
108
|
};
|
|
109
109
|
};
|
|
110
110
|
/**
|
|
111
111
|
* AnalyticsBundleSizeCount
|
|
112
112
|
*/
|
|
113
|
-
type AnalyticsBundleSizeCount = {
|
|
113
|
+
type AnalyticsBundleSizeCount$1 = {
|
|
114
114
|
/**
|
|
115
115
|
* The bundle's data allowance in bytes. Null for an unlimited bundle.
|
|
116
116
|
*/
|
|
@@ -127,7 +127,7 @@ type AnalyticsBundleSizeCount = {
|
|
|
127
127
|
/**
|
|
128
128
|
* AnalyticsDestinationCount
|
|
129
129
|
*/
|
|
130
|
-
type AnalyticsDestinationCount = {
|
|
130
|
+
type AnalyticsDestinationCount$1 = {
|
|
131
131
|
/**
|
|
132
132
|
* The destination's id. A destination withdrawn since keeps its row and its name.
|
|
133
133
|
*/
|
|
@@ -144,7 +144,7 @@ type AnalyticsDestinationCount = {
|
|
|
144
144
|
/**
|
|
145
145
|
* AnalyticsDiscountCode
|
|
146
146
|
*/
|
|
147
|
-
type AnalyticsDiscountCode = {
|
|
147
|
+
type AnalyticsDiscountCode$1 = {
|
|
148
148
|
/**
|
|
149
149
|
* The discount code as travellers enter it.
|
|
150
150
|
*/
|
|
@@ -159,7 +159,7 @@ type AnalyticsDiscountCode = {
|
|
|
159
159
|
/**
|
|
160
160
|
* AnalyticsFunnel
|
|
161
161
|
*/
|
|
162
|
-
type AnalyticsFunnel = {
|
|
162
|
+
type AnalyticsFunnel$1 = {
|
|
163
163
|
/**
|
|
164
164
|
* Always `new`: the funnel covers bookings made on this platform only. Bookings moved over from the previous platform are left out, so `cohort.codes` can differ from the summary's `bookings.total`, which includes them.
|
|
165
165
|
*/
|
|
@@ -192,7 +192,7 @@ type AnalyticsFunnel = {
|
|
|
192
192
|
/**
|
|
193
193
|
* The steps, in order: `codes_issued`, `claimed`, `paid`, `esim_installed`, `package_activated`, `used_data`. Empty when no new booking was created in the range.
|
|
194
194
|
*/
|
|
195
|
-
steps: Array<AnalyticsFunnelStep>;
|
|
195
|
+
steps: Array<AnalyticsFunnelStep$1>;
|
|
196
196
|
/**
|
|
197
197
|
* The `dimension` the funnel is broken down by, as requested; null when none was.
|
|
198
198
|
*/
|
|
@@ -200,12 +200,12 @@ type AnalyticsFunnel = {
|
|
|
200
200
|
/**
|
|
201
201
|
* The funnel split by `dimension`, one group per value, whose codes and step counts add up to the funnel above. Null when no `dimension` was requested or no new booking was created in the range.
|
|
202
202
|
*/
|
|
203
|
-
breakdown: Array<AnalyticsFunnelGroup> | null;
|
|
203
|
+
breakdown: Array<AnalyticsFunnelGroup$1> | null;
|
|
204
204
|
};
|
|
205
205
|
/**
|
|
206
206
|
* AnalyticsFunnelGroup
|
|
207
207
|
*/
|
|
208
|
-
type AnalyticsFunnelGroup = {
|
|
208
|
+
type AnalyticsFunnelGroup$1 = {
|
|
209
209
|
/**
|
|
210
210
|
* The dimension's value: a destination id, a bundle size in bytes, a sales channel, a booking source or a transaction type. Null for the codes that have none: an unlimited bundle has no size, and a code not sold in the app has no sales channel or transaction type.
|
|
211
211
|
*/
|
|
@@ -221,12 +221,12 @@ type AnalyticsFunnelGroup = {
|
|
|
221
221
|
/**
|
|
222
222
|
* This group's funnel, with the same steps as the whole funnel.
|
|
223
223
|
*/
|
|
224
|
-
steps: Array<AnalyticsFunnelStep>;
|
|
224
|
+
steps: Array<AnalyticsFunnelStep$1>;
|
|
225
225
|
};
|
|
226
226
|
/**
|
|
227
227
|
* AnalyticsFunnelStep
|
|
228
228
|
*/
|
|
229
|
-
type AnalyticsFunnelStep = {
|
|
229
|
+
type AnalyticsFunnelStep$1 = {
|
|
230
230
|
/**
|
|
231
231
|
* Which step: `codes_issued` (every booking code of the bookings created in the range), `claimed` (the traveller claimed the code), `paid` (the code was paid for in the app; only codes sold in the app can be), `esim_installed` (the eSIM carrying the code's package was installed), `package_activated` (the package went live on the network, at any time after the booking was created, with no 14-day window) or `used_data` (the package carried its first byte of data). Always in this order.
|
|
232
232
|
*/
|
|
@@ -239,13 +239,13 @@ type AnalyticsFunnelStep = {
|
|
|
239
239
|
* How many codes reached this step, whenever that happened. For `paid`, out of the codes sold in the app only. Null when the step is not recorded or not applicable.
|
|
240
240
|
*/
|
|
241
241
|
count: number | null;
|
|
242
|
-
rate: AnalyticsRatio | null;
|
|
243
|
-
share_of_codes: AnalyticsRatio | null;
|
|
242
|
+
rate: AnalyticsRatio$1 | null;
|
|
243
|
+
share_of_codes: AnalyticsRatio$1 | null;
|
|
244
244
|
};
|
|
245
245
|
/**
|
|
246
246
|
* AnalyticsMeta
|
|
247
247
|
*/
|
|
248
|
-
type AnalyticsMeta = {
|
|
248
|
+
type AnalyticsMeta$1 = {
|
|
249
249
|
/**
|
|
250
250
|
* The range the figures cover, as UTC dates with both ends included.
|
|
251
251
|
*/
|
|
@@ -286,7 +286,7 @@ type AnalyticsMeta = {
|
|
|
286
286
|
/**
|
|
287
287
|
* AnalyticsPartnerContribution
|
|
288
288
|
*/
|
|
289
|
-
type AnalyticsPartnerContribution = {
|
|
289
|
+
type AnalyticsPartnerContribution$1 = {
|
|
290
290
|
/**
|
|
291
291
|
* The Partner these figures are for, one of `meta.partner_ids`.
|
|
292
292
|
*/
|
|
@@ -317,7 +317,7 @@ type AnalyticsPartnerContribution = {
|
|
|
317
317
|
/**
|
|
318
318
|
* AnalyticsRatio
|
|
319
319
|
*/
|
|
320
|
-
type AnalyticsRatio = {
|
|
320
|
+
type AnalyticsRatio$1 = {
|
|
321
321
|
/**
|
|
322
322
|
* The rate as a percentage from 0 to 100, rounded to two decimals; null when suppressed.
|
|
323
323
|
*/
|
|
@@ -338,7 +338,7 @@ type AnalyticsRatio = {
|
|
|
338
338
|
/**
|
|
339
339
|
* AnalyticsSummary
|
|
340
340
|
*/
|
|
341
|
-
type AnalyticsSummary = {
|
|
341
|
+
type AnalyticsSummary$1 = {
|
|
342
342
|
/**
|
|
343
343
|
* Bookings created in the range, test bookings left out. Includes bookings moved over from the previous platform, created here on the day they moved.
|
|
344
344
|
*/
|
|
@@ -397,7 +397,7 @@ type AnalyticsSummary = {
|
|
|
397
397
|
/**
|
|
398
398
|
* The 14-day claim-to-activation rate for codes claimed in the range.
|
|
399
399
|
*/
|
|
400
|
-
activation: AnalyticsActivation;
|
|
400
|
+
activation: AnalyticsActivation$1;
|
|
401
401
|
/**
|
|
402
402
|
* Net revenue in the range: purchases minus refunds, per ISO 4217 currency code, in integer minor units. Currencies are never converted or added together. Empty when there was none.
|
|
403
403
|
*/
|
|
@@ -415,7 +415,7 @@ type AnalyticsSummary = {
|
|
|
415
415
|
/**
|
|
416
416
|
* Each Partner in `meta.partner_ids`, with its part of bookings, customers, net revenue and data consumed. The rows add up to the totals above. One row when the figures are for your own Partner alone.
|
|
417
417
|
*/
|
|
418
|
-
by_partner: Array<AnalyticsPartnerContribution>;
|
|
418
|
+
by_partner: Array<AnalyticsPartnerContribution$1>;
|
|
419
419
|
/**
|
|
420
420
|
* The same headline figures for the preceding period of equal length, when `compare` was set. Null otherwise.
|
|
421
421
|
*/
|
|
@@ -450,7 +450,7 @@ type AnalyticsSummary = {
|
|
|
450
450
|
/**
|
|
451
451
|
* The activation rate for codes claimed in the preceding period.
|
|
452
452
|
*/
|
|
453
|
-
activation: AnalyticsActivation;
|
|
453
|
+
activation: AnalyticsActivation$1;
|
|
454
454
|
/**
|
|
455
455
|
* Packages that started using data in the preceding period.
|
|
456
456
|
*/
|
|
@@ -460,7 +460,7 @@ type AnalyticsSummary = {
|
|
|
460
460
|
/**
|
|
461
461
|
* AnalyticsTimeseries
|
|
462
462
|
*/
|
|
463
|
-
type AnalyticsTimeseries = {
|
|
463
|
+
type AnalyticsTimeseries$1 = {
|
|
464
464
|
/**
|
|
465
465
|
* The bucket every row covers: `day`, `week` (ISO weeks, Monday to Sunday) or `month`.
|
|
466
466
|
*/
|
|
@@ -468,12 +468,12 @@ type AnalyticsTimeseries = {
|
|
|
468
468
|
/**
|
|
469
469
|
* One row per bucket, oldest first, from the bucket holding `meta.range.from` to the bucket holding `meta.range.to`.
|
|
470
470
|
*/
|
|
471
|
-
series: Array<AnalyticsTimeseriesBucket>;
|
|
471
|
+
series: Array<AnalyticsTimeseriesBucket$1>;
|
|
472
472
|
};
|
|
473
473
|
/**
|
|
474
474
|
* AnalyticsTimeseriesBucket
|
|
475
475
|
*/
|
|
476
|
-
type AnalyticsTimeseriesBucket = {
|
|
476
|
+
type AnalyticsTimeseriesBucket$1 = {
|
|
477
477
|
/**
|
|
478
478
|
* The bucket's first day (UTC): the day itself, the Monday of the week, or the first of the month. A week or month bucket at either end of the range can start before or end after it; only the days inside the range are counted.
|
|
479
479
|
*/
|
|
@@ -508,13 +508,13 @@ type AnalyticsTimeseriesBucket = {
|
|
|
508
508
|
/**
|
|
509
509
|
* Booking
|
|
510
510
|
*/
|
|
511
|
-
type Booking = {
|
|
511
|
+
type Booking$1 = {
|
|
512
512
|
id: string;
|
|
513
513
|
partner_id: string;
|
|
514
514
|
visual_identity_id: string | null;
|
|
515
515
|
external_reference: string | null;
|
|
516
516
|
external_reference_secondary: string | null;
|
|
517
|
-
source: BookingSource;
|
|
517
|
+
source: BookingSource$1;
|
|
518
518
|
depart_at: string | null;
|
|
519
519
|
return_at: string | null;
|
|
520
520
|
locale: string | null;
|
|
@@ -547,7 +547,7 @@ type Booking = {
|
|
|
547
547
|
/**
|
|
548
548
|
* The booking's items, one per package specification. Each item's `id` is the `{item}` you issue, read and terminate its package with.
|
|
549
549
|
*/
|
|
550
|
-
items?: Array<BookingItem & {
|
|
550
|
+
items?: Array<BookingItem$1 & {
|
|
551
551
|
[key: string]: unknown;
|
|
552
552
|
}>;
|
|
553
553
|
created_at: string | null;
|
|
@@ -556,7 +556,7 @@ type Booking = {
|
|
|
556
556
|
/**
|
|
557
557
|
* BookingItem
|
|
558
558
|
*/
|
|
559
|
-
type BookingItem = {
|
|
559
|
+
type BookingItem$1 = {
|
|
560
560
|
id: string;
|
|
561
561
|
/**
|
|
562
562
|
* The human-typeable redemption code for this package, twelve
|
|
@@ -602,12 +602,12 @@ type BookingItem = {
|
|
|
602
602
|
* iso2 for countries, iso3 for regions (which carry only one of the two).
|
|
603
603
|
*/
|
|
604
604
|
destination?: string | null;
|
|
605
|
-
package_type: PackageType | null;
|
|
605
|
+
package_type: PackageType$1 | null;
|
|
606
606
|
size_bytes: number | null;
|
|
607
607
|
duration_seconds: number | null;
|
|
608
608
|
start_at: string | null;
|
|
609
609
|
end_at: string | null;
|
|
610
|
-
status: PackageQueueStatus;
|
|
610
|
+
status: PackageQueueStatus$1;
|
|
611
611
|
/**
|
|
612
612
|
* The bundle this item books: the one named by `bundle_id` at booking, or, once issued, the bundle the closest match chose. Null while an item specified by dimensions is not issued yet.
|
|
613
613
|
*/
|
|
@@ -615,17 +615,17 @@ type BookingItem = {
|
|
|
615
615
|
/**
|
|
616
616
|
* Where this item is in its lifecycle. Read it instead of `status`: `queued` (reserved, not issued yet; you can issue it), `unavailable` (cannot be issued now: no bundle answers its specification, or a payment is still pending; cancel the booking or book again), `redeemed` (issued, install material available), `installed` (the eSIM is on a phone), `activated` (live on the network, validity running), `expired` (validity elapsed or consumed), `terminated` (ended before activation), `cancelled` (the booking was cancelled).
|
|
617
617
|
*/
|
|
618
|
-
state: PackageLifecycleState;
|
|
619
|
-
package: IssuedPackage | null;
|
|
618
|
+
state: PackageLifecycleState$1;
|
|
619
|
+
package: IssuedPackage$1 | null;
|
|
620
620
|
};
|
|
621
621
|
/**
|
|
622
622
|
* BookingSource
|
|
623
623
|
*/
|
|
624
|
-
type BookingSource = 'api' | 'platform' | 'manual' | 'synthetic' | 'migrated' | 'free_esim' | 'import' | 'membership';
|
|
624
|
+
type BookingSource$1 = 'api' | 'platform' | 'manual' | 'synthetic' | 'migrated' | 'free_esim' | 'import' | 'membership';
|
|
625
625
|
/**
|
|
626
626
|
* Bundle
|
|
627
627
|
*/
|
|
628
|
-
type Bundle = {
|
|
628
|
+
type Bundle$1 = {
|
|
629
629
|
/**
|
|
630
630
|
* The bundle's id. Stable: name it as `bundle_id` to book exactly this bundle.
|
|
631
631
|
*/
|
|
@@ -633,11 +633,7 @@ type Bundle = {
|
|
|
633
633
|
/**
|
|
634
634
|
* The destination the bundle is sold for. `iso2` and `iso3` are null on a region.
|
|
635
635
|
*/
|
|
636
|
-
destination:
|
|
637
|
-
id: string;
|
|
638
|
-
iso2: string | null;
|
|
639
|
-
iso3: string | null;
|
|
640
|
-
};
|
|
636
|
+
destination: DestinationSummary$1;
|
|
641
637
|
/**
|
|
642
638
|
* `data_limited`, `starter` or `unlimited`.
|
|
643
639
|
*/
|
|
@@ -661,7 +657,7 @@ type Bundle = {
|
|
|
661
657
|
traffic_policy: {
|
|
662
658
|
description: string | null;
|
|
663
659
|
} | null;
|
|
664
|
-
fair_use_throttle: FairUseThrottle | null;
|
|
660
|
+
fair_use_throttle: FairUseThrottle$1 | null;
|
|
665
661
|
is_active: boolean;
|
|
666
662
|
is_visible: boolean;
|
|
667
663
|
priority: number;
|
|
@@ -810,7 +806,7 @@ type CreateRedirectTokenData = {
|
|
|
810
806
|
/**
|
|
811
807
|
* Destination
|
|
812
808
|
*/
|
|
813
|
-
type Destination = {
|
|
809
|
+
type Destination$1 = {
|
|
814
810
|
id: string;
|
|
815
811
|
name: string | null;
|
|
816
812
|
type: string;
|
|
@@ -841,10 +837,14 @@ type Destination = {
|
|
|
841
837
|
[key: string]: string;
|
|
842
838
|
};
|
|
843
839
|
};
|
|
840
|
+
/**
|
|
841
|
+
* DestinationKind
|
|
842
|
+
*/
|
|
843
|
+
type DestinationKind$1 = 'country' | 'region';
|
|
844
844
|
/**
|
|
845
845
|
* DestinationResource
|
|
846
846
|
*/
|
|
847
|
-
type DestinationResource = {
|
|
847
|
+
type DestinationResource$1 = {
|
|
848
848
|
id: string;
|
|
849
849
|
type: string;
|
|
850
850
|
tier: null;
|
|
@@ -860,12 +860,78 @@ type DestinationResource = {
|
|
|
860
860
|
updated_at: string | null;
|
|
861
861
|
created_by: string | null;
|
|
862
862
|
updated_by: string | null;
|
|
863
|
-
bundles: Array<Bundle>;
|
|
863
|
+
bundles: Array<Bundle$1>;
|
|
864
|
+
};
|
|
865
|
+
/**
|
|
866
|
+
* DestinationSummary
|
|
867
|
+
*/
|
|
868
|
+
type DestinationSummary$1 = {
|
|
869
|
+
/**
|
|
870
|
+
* The destination's id: the `id` of `GET /v1/destinations/{destination}`.
|
|
871
|
+
*/
|
|
872
|
+
id: string;
|
|
873
|
+
/**
|
|
874
|
+
* The destination's English name, for example `Spain` or `Europe`.
|
|
875
|
+
*/
|
|
876
|
+
name: string | null;
|
|
877
|
+
/**
|
|
878
|
+
* `country` or `region`.
|
|
879
|
+
*/
|
|
880
|
+
type: DestinationKind$1;
|
|
881
|
+
/**
|
|
882
|
+
* The country's ISO 3166-1 alpha-2 code. Null on a region.
|
|
883
|
+
*/
|
|
884
|
+
iso2: string | null;
|
|
885
|
+
/**
|
|
886
|
+
* The country's ISO 3166-1 alpha-3 code. Null on a region.
|
|
887
|
+
*/
|
|
888
|
+
iso3: string | null;
|
|
889
|
+
};
|
|
890
|
+
/**
|
|
891
|
+
* DestinationUsage
|
|
892
|
+
*/
|
|
893
|
+
type DestinationUsage$1 = {
|
|
894
|
+
/**
|
|
895
|
+
* The destination every package in this entry is for, the same object a bundle carries in `GET /v1/bundles`. A country and a region that covers it are two entries. Top up this entry with a bundle for this destination.
|
|
896
|
+
*/
|
|
897
|
+
destination: DestinationSummary$1;
|
|
898
|
+
/**
|
|
899
|
+
* True for unlimited packages. `total_bytes` and `remaining_bytes` are then null; `used_bytes` is still set. A destination with unlimited and data packages has one entry of each.
|
|
900
|
+
*/
|
|
901
|
+
is_unlimited: boolean;
|
|
902
|
+
/**
|
|
903
|
+
* The data allowance of every package in `package_ids` added up, in bytes, ended packages included. Always `used_bytes + remaining_bytes`. Draw a gauge from `remaining_bytes` against `total_bytes`, as the Hubby app does. Null when `is_unlimited`.
|
|
904
|
+
*/
|
|
905
|
+
total_bytes: number | null;
|
|
906
|
+
/**
|
|
907
|
+
* The data that is no longer available, in bytes: `total_bytes - remaining_bytes`, the figure the Hubby app shows as used. Data an ended package of the same trip did not use counts as used, because it can no longer be used. On unlimited entries, where there is no total, the data the packages in `package_ids` used, added up.
|
|
908
|
+
*/
|
|
909
|
+
used_bytes: number;
|
|
910
|
+
/**
|
|
911
|
+
* The data the traveller can still use, in bytes: what the live packages have left, added up, and never below `0`. A provider can report a package slightly over its allowance; that overrun is taken from what the entry's other live packages have left. `0` means used up, even when `valid_until` is still ahead; a top-up adds to it. Null when `is_unlimited`.
|
|
912
|
+
*/
|
|
913
|
+
remaining_bytes: number | null;
|
|
914
|
+
/**
|
|
915
|
+
* When this entry's data stops working. For data packages, which run side by side, the end of the live package with the most time left; for unlimited packages, which run one after the other, the end of their added-up time. Null while that time has not started: the package it belongs to has not been used on the network yet, and its clock starts on first use. Null does not mean the entry is unused: an older package in it can already be in use. Use `remaining_seconds` for the time left.
|
|
916
|
+
*/
|
|
917
|
+
valid_until: string | null;
|
|
918
|
+
/**
|
|
919
|
+
* The time left on this entry, in seconds, the figure behind "N days left" in the Hubby app. Set even while `valid_until` is null: a package that has not started counts its whole validity. For data packages, the time left on the live package with the most time left; for unlimited packages, the time left on their added-up time. Counts down only once the time has started.
|
|
920
|
+
*/
|
|
921
|
+
remaining_seconds: number;
|
|
922
|
+
/**
|
|
923
|
+
* Every package this entry adds up, oldest first, ended packages of the same trip included: the `id` of packages in `GET /v1/esims/{iccid}`. Packages the traveller bought in the Hubby app count too.
|
|
924
|
+
*/
|
|
925
|
+
package_ids: Array<string>;
|
|
926
|
+
/**
|
|
927
|
+
* When these figures were last read from the network: the oldest read among the entry's live packages. Null when one of them was never read. Send `refresh=true` to read them now.
|
|
928
|
+
*/
|
|
929
|
+
synced_at: string | null;
|
|
864
930
|
};
|
|
865
931
|
/**
|
|
866
932
|
* DeviceCompatibility
|
|
867
933
|
*/
|
|
868
|
-
type DeviceCompatibility = {
|
|
934
|
+
type DeviceCompatibility$1 = {
|
|
869
935
|
phone_brand: string;
|
|
870
936
|
phone_model: string;
|
|
871
937
|
is_compatible: boolean;
|
|
@@ -873,17 +939,17 @@ type DeviceCompatibility = {
|
|
|
873
939
|
/**
|
|
874
940
|
* DeviceCompatibilityList
|
|
875
941
|
*/
|
|
876
|
-
type DeviceCompatibilityList = {
|
|
942
|
+
type DeviceCompatibilityList$1 = {
|
|
877
943
|
devices: Array<unknown>;
|
|
878
944
|
};
|
|
879
945
|
/**
|
|
880
946
|
* EndCustomerChannel
|
|
881
947
|
*/
|
|
882
|
-
type EndCustomerChannel = 'webapp' | 'native_app' | 'partner_app';
|
|
948
|
+
type EndCustomerChannel$1 = 'webapp' | 'native_app' | 'partner_app';
|
|
883
949
|
/**
|
|
884
950
|
* Esim
|
|
885
951
|
*/
|
|
886
|
-
type Esim = {
|
|
952
|
+
type Esim$1 = {
|
|
887
953
|
/**
|
|
888
954
|
* The eSIM's ICCID.
|
|
889
955
|
*/
|
|
@@ -899,7 +965,7 @@ type Esim = {
|
|
|
899
965
|
/**
|
|
900
966
|
* Every package on this eSIM, oldest first, ended ones included.
|
|
901
967
|
*/
|
|
902
|
-
packages: Array<EsimPackage>;
|
|
968
|
+
packages: Array<EsimPackage$1>;
|
|
903
969
|
/**
|
|
904
970
|
* When the usage figures were last read from the network. Null when they never were. Send `refresh=true` to read them now.
|
|
905
971
|
*/
|
|
@@ -908,7 +974,7 @@ type Esim = {
|
|
|
908
974
|
/**
|
|
909
975
|
* EsimInstallMaterial
|
|
910
976
|
*/
|
|
911
|
-
type EsimInstallMaterial = {
|
|
977
|
+
type EsimInstallMaterial$1 = {
|
|
912
978
|
iccid: string;
|
|
913
979
|
/**
|
|
914
980
|
* When this eSIM was first installed on a phone, whichever package it was installed for. Set for a repeat traveller: the eSIM is already on their phone, so skip the install screen and show that the new package is ready. Null until the eSIM is installed.
|
|
@@ -937,7 +1003,7 @@ type EsimInstallMaterial = {
|
|
|
937
1003
|
/**
|
|
938
1004
|
* EsimPackage
|
|
939
1005
|
*/
|
|
940
|
-
type EsimPackage = {
|
|
1006
|
+
type EsimPackage$1 = {
|
|
941
1007
|
id: string;
|
|
942
1008
|
/**
|
|
943
1009
|
* The booking this package was issued from. Null for a package the traveller bought in the Hubby app.
|
|
@@ -946,8 +1012,12 @@ type EsimPackage = {
|
|
|
946
1012
|
/**
|
|
947
1013
|
* Where this package is in its lifecycle, the same `state` its booking item carries: `redeemed`, `installed`, `activated`, `expired` or `terminated`.
|
|
948
1014
|
*/
|
|
949
|
-
state: PackageLifecycleState;
|
|
1015
|
+
state: PackageLifecycleState$1;
|
|
950
1016
|
bundle_id: string;
|
|
1017
|
+
/**
|
|
1018
|
+
* The destination this package is for, the same object a bundle carries in `GET /v1/bundles`. Always set, also on a package that has ended and on a package whose bundle is no longer sold.
|
|
1019
|
+
*/
|
|
1020
|
+
destination: DestinationSummary$1;
|
|
951
1021
|
/**
|
|
952
1022
|
* When the package first attached on the network and its validity started. Null before.
|
|
953
1023
|
*/
|
|
@@ -972,7 +1042,7 @@ type EsimPackage = {
|
|
|
972
1042
|
/**
|
|
973
1043
|
* FairUseThrottle
|
|
974
1044
|
*/
|
|
975
|
-
type FairUseThrottle = {
|
|
1045
|
+
type FairUseThrottle$1 = {
|
|
976
1046
|
/**
|
|
977
1047
|
* The daily threshold, in bytes: the data a traveller can use in one day at full speed. The threshold applies per day, not to the whole package.
|
|
978
1048
|
*/
|
|
@@ -987,7 +1057,7 @@ type FairUseThrottle = {
|
|
|
987
1057
|
* |---|
|
|
988
1058
|
* | `daily` <br/> Each day: the threshold applies to the data used in one day. |
|
|
989
1059
|
*/
|
|
990
|
-
resets: FairUseThrottleReset;
|
|
1060
|
+
resets: FairUseThrottleReset$1;
|
|
991
1061
|
};
|
|
992
1062
|
/**
|
|
993
1063
|
* FairUseThrottleReset
|
|
@@ -997,11 +1067,11 @@ type FairUseThrottle = {
|
|
|
997
1067
|
* |---|
|
|
998
1068
|
* | `daily` <br/> Each day: the threshold applies to the data used in one day. |
|
|
999
1069
|
*/
|
|
1000
|
-
type FairUseThrottleReset = 'daily';
|
|
1070
|
+
type FairUseThrottleReset$1 = 'daily';
|
|
1001
1071
|
/**
|
|
1002
1072
|
* InstallInstructionSection
|
|
1003
1073
|
*/
|
|
1004
|
-
type InstallInstructionSection = {
|
|
1074
|
+
type InstallInstructionSection$1 = {
|
|
1005
1075
|
/**
|
|
1006
1076
|
* What the section does, in this order: `rename` the line, `turn_on` the line, enable `roaming`, pick the line for `mobile_data`.
|
|
1007
1077
|
*/
|
|
@@ -1017,12 +1087,12 @@ type InstallInstructionSection = {
|
|
|
1017
1087
|
/**
|
|
1018
1088
|
* The steps, in order.
|
|
1019
1089
|
*/
|
|
1020
|
-
steps: Array<InstallInstructionStep>;
|
|
1090
|
+
steps: Array<InstallInstructionStep$1>;
|
|
1021
1091
|
};
|
|
1022
1092
|
/**
|
|
1023
1093
|
* InstallInstructionSet
|
|
1024
1094
|
*/
|
|
1025
|
-
type InstallInstructionSet = {
|
|
1095
|
+
type InstallInstructionSet$1 = {
|
|
1026
1096
|
/**
|
|
1027
1097
|
* The phone family: `iphone` on iOS; `samsung`, `pixel` or `xiaomi` on Android. For an Android phone you cannot place, use `samsung`.
|
|
1028
1098
|
*/
|
|
@@ -1041,7 +1111,7 @@ type InstallInstructionSet = {
|
|
|
1041
1111
|
*/
|
|
1042
1112
|
install_link: string | null;
|
|
1043
1113
|
clip_url: string | null;
|
|
1044
|
-
steps: Array<InstallInstructionStep>;
|
|
1114
|
+
steps: Array<InstallInstructionStep$1>;
|
|
1045
1115
|
};
|
|
1046
1116
|
/**
|
|
1047
1117
|
* Install from a second screen: render `lpa` as a QR code and scan it with the phone.
|
|
@@ -1053,7 +1123,7 @@ type InstallInstructionSet = {
|
|
|
1053
1123
|
*/
|
|
1054
1124
|
lpa: string | null;
|
|
1055
1125
|
clip_url: string | null;
|
|
1056
|
-
steps: Array<InstallInstructionStep>;
|
|
1126
|
+
steps: Array<InstallInstructionStep$1>;
|
|
1057
1127
|
};
|
|
1058
1128
|
/**
|
|
1059
1129
|
* Install by typing the SM-DP+ address and the matching id in the phone's settings.
|
|
@@ -1069,17 +1139,17 @@ type InstallInstructionSet = {
|
|
|
1069
1139
|
*/
|
|
1070
1140
|
matching_id: string | null;
|
|
1071
1141
|
clip_url: string | null;
|
|
1072
|
-
steps: Array<InstallInstructionStep>;
|
|
1142
|
+
steps: Array<InstallInstructionStep$1>;
|
|
1073
1143
|
};
|
|
1074
1144
|
/**
|
|
1075
1145
|
* What to do on arrival, in order: rename the line, turn it on, enable roaming, pick it for mobile data.
|
|
1076
1146
|
*/
|
|
1077
|
-
on_arrival: Array<InstallInstructionSection>;
|
|
1147
|
+
on_arrival: Array<InstallInstructionSection$1>;
|
|
1078
1148
|
};
|
|
1079
1149
|
/**
|
|
1080
1150
|
* InstallInstructionStep
|
|
1081
1151
|
*/
|
|
1082
|
-
type InstallInstructionStep = {
|
|
1152
|
+
type InstallInstructionStep$1 = {
|
|
1083
1153
|
/**
|
|
1084
1154
|
* The step, localized. Tap targets are marked with markdown bold, `**Activate**`, and nothing else; render or strip it.
|
|
1085
1155
|
*/
|
|
@@ -1092,7 +1162,7 @@ type InstallInstructionStep = {
|
|
|
1092
1162
|
/**
|
|
1093
1163
|
* InstallInstructions
|
|
1094
1164
|
*/
|
|
1095
|
-
type InstallInstructions = {
|
|
1165
|
+
type InstallInstructions$1 = {
|
|
1096
1166
|
/**
|
|
1097
1167
|
* The eSIM's ICCID.
|
|
1098
1168
|
*/
|
|
@@ -1108,11 +1178,11 @@ type InstallInstructions = {
|
|
|
1108
1178
|
/**
|
|
1109
1179
|
* One entry per iOS phone family: `iphone`.
|
|
1110
1180
|
*/
|
|
1111
|
-
ios: Array<InstallInstructionSet>;
|
|
1181
|
+
ios: Array<InstallInstructionSet$1>;
|
|
1112
1182
|
/**
|
|
1113
1183
|
* One entry per Android phone family: `samsung`, `pixel`, `xiaomi`.
|
|
1114
1184
|
*/
|
|
1115
|
-
android: Array<InstallInstructionSet>;
|
|
1185
|
+
android: Array<InstallInstructionSet$1>;
|
|
1116
1186
|
};
|
|
1117
1187
|
/**
|
|
1118
1188
|
* IssuePackageRequest
|
|
@@ -1128,12 +1198,12 @@ type IssuePackageRequest = {
|
|
|
1128
1198
|
/**
|
|
1129
1199
|
* IssuedPackage
|
|
1130
1200
|
*/
|
|
1131
|
-
type IssuedPackage = {
|
|
1201
|
+
type IssuedPackage$1 = {
|
|
1132
1202
|
id: string;
|
|
1133
1203
|
/**
|
|
1134
1204
|
* Where this package is in its lifecycle: `redeemed` (issued, install material available), `installed` (the eSIM is on a phone), `activated` (live on the network, validity running), `expired` (validity elapsed or consumed), `terminated` (ended before activation).
|
|
1135
1205
|
*/
|
|
1136
|
-
state: PackageLifecycleState;
|
|
1206
|
+
state: PackageLifecycleState$1;
|
|
1137
1207
|
/**
|
|
1138
1208
|
* The bundle this package was issued from.
|
|
1139
1209
|
*/
|
|
@@ -1162,7 +1232,7 @@ type IssuedPackage = {
|
|
|
1162
1232
|
* When the package was ended before it activated. Null otherwise.
|
|
1163
1233
|
*/
|
|
1164
1234
|
terminated_at: string | null;
|
|
1165
|
-
esim: EsimInstallMaterial;
|
|
1235
|
+
esim: EsimInstallMaterial$1;
|
|
1166
1236
|
};
|
|
1167
1237
|
/**
|
|
1168
1238
|
* PackageLifecycleState
|
|
@@ -1170,25 +1240,25 @@ type IssuedPackage = {
|
|
|
1170
1240
|
* The lifecycle state a Partner reads on a booking item and on the package issued from it (partner v1 `state`), so it never interprets the internal `status`. Derived, never stored: from the item's status until a package is issued, then from the package's own timestamps and its eSIM's install.
|
|
1171
1241
|
*
|
|
1172
1242
|
*/
|
|
1173
|
-
type PackageLifecycleState = 'queued' | 'unavailable' | 'redeemed' | 'installed' | 'activated' | 'expired' | 'terminated' | 'cancelled';
|
|
1243
|
+
type PackageLifecycleState$1 = 'queued' | 'unavailable' | 'redeemed' | 'installed' | 'activated' | 'expired' | 'terminated' | 'cancelled';
|
|
1174
1244
|
/**
|
|
1175
1245
|
* PackageQueueStatus
|
|
1176
1246
|
*/
|
|
1177
|
-
type PackageQueueStatus = 'queued' | 'pending_payment' | 'paid' | 'activated' | 'cancelled' | 'reverted' | 'unresolved';
|
|
1247
|
+
type PackageQueueStatus$1 = 'queued' | 'pending_payment' | 'paid' | 'activated' | 'cancelled' | 'reverted' | 'unresolved';
|
|
1178
1248
|
/**
|
|
1179
1249
|
* PackageType
|
|
1180
1250
|
*/
|
|
1181
|
-
type PackageType = 'data_limited' | 'starter' | 'unlimited';
|
|
1251
|
+
type PackageType$1 = 'data_limited' | 'starter' | 'unlimited';
|
|
1182
1252
|
/**
|
|
1183
1253
|
* Partner
|
|
1184
1254
|
*/
|
|
1185
|
-
type Partner = {
|
|
1255
|
+
type Partner$1 = {
|
|
1186
1256
|
id: string;
|
|
1187
1257
|
slug: string;
|
|
1188
1258
|
name: string;
|
|
1189
1259
|
is_active: boolean;
|
|
1190
1260
|
parent_id: string | null;
|
|
1191
|
-
end_customer_channel: EndCustomerChannel | null;
|
|
1261
|
+
end_customer_channel: EndCustomerChannel$1 | null;
|
|
1192
1262
|
price_list_id: string | null;
|
|
1193
1263
|
/**
|
|
1194
1264
|
* The fixed package dimensions applied to every booking you create
|
|
@@ -1252,7 +1322,7 @@ type PresignBookingUploadData = {
|
|
|
1252
1322
|
/**
|
|
1253
1323
|
* RedirectToken
|
|
1254
1324
|
*/
|
|
1255
|
-
type RedirectToken = {
|
|
1325
|
+
type RedirectToken$1 = {
|
|
1256
1326
|
redirect_token: string;
|
|
1257
1327
|
/**
|
|
1258
1328
|
* Lifetime of the redirect token in seconds.
|
|
@@ -1342,11 +1412,11 @@ type PartnerApiV1AnalyticsSummaryResponses = {
|
|
|
1342
1412
|
* `AnalyticsSummary`
|
|
1343
1413
|
*/
|
|
1344
1414
|
200: {
|
|
1345
|
-
data: AnalyticsSummary;
|
|
1415
|
+
data: AnalyticsSummary$1;
|
|
1346
1416
|
/**
|
|
1347
1417
|
* What the figures cover.
|
|
1348
1418
|
*/
|
|
1349
|
-
meta: AnalyticsMeta;
|
|
1419
|
+
meta: AnalyticsMeta$1;
|
|
1350
1420
|
};
|
|
1351
1421
|
};
|
|
1352
1422
|
type PartnerApiV1AnalyticsSummaryResponse = PartnerApiV1AnalyticsSummaryResponses[keyof PartnerApiV1AnalyticsSummaryResponses];
|
|
@@ -1370,11 +1440,11 @@ type PartnerApiV1AnalyticsFunnelResponses = {
|
|
|
1370
1440
|
* `AnalyticsFunnel`
|
|
1371
1441
|
*/
|
|
1372
1442
|
200: {
|
|
1373
|
-
data: AnalyticsFunnel;
|
|
1443
|
+
data: AnalyticsFunnel$1;
|
|
1374
1444
|
/**
|
|
1375
1445
|
* What the figures cover.
|
|
1376
1446
|
*/
|
|
1377
|
-
meta: AnalyticsMeta;
|
|
1447
|
+
meta: AnalyticsMeta$1;
|
|
1378
1448
|
};
|
|
1379
1449
|
};
|
|
1380
1450
|
type PartnerApiV1AnalyticsFunnelResponse = PartnerApiV1AnalyticsFunnelResponses[keyof PartnerApiV1AnalyticsFunnelResponses];
|
|
@@ -1398,11 +1468,11 @@ type PartnerApiV1AnalyticsTimeseriesResponses = {
|
|
|
1398
1468
|
* `AnalyticsTimeseries`
|
|
1399
1469
|
*/
|
|
1400
1470
|
200: {
|
|
1401
|
-
data: AnalyticsTimeseries;
|
|
1471
|
+
data: AnalyticsTimeseries$1;
|
|
1402
1472
|
/**
|
|
1403
1473
|
* What the figures cover.
|
|
1404
1474
|
*/
|
|
1405
|
-
meta: AnalyticsMeta;
|
|
1475
|
+
meta: AnalyticsMeta$1;
|
|
1406
1476
|
};
|
|
1407
1477
|
};
|
|
1408
1478
|
type PartnerApiV1AnalyticsTimeseriesResponse = PartnerApiV1AnalyticsTimeseriesResponses[keyof PartnerApiV1AnalyticsTimeseriesResponses];
|
|
@@ -1422,11 +1492,11 @@ type PartnerApiV1AnalyticsBreakdownsResponses = {
|
|
|
1422
1492
|
* `AnalyticsBreakdowns`
|
|
1423
1493
|
*/
|
|
1424
1494
|
200: {
|
|
1425
|
-
data: AnalyticsBreakdowns;
|
|
1495
|
+
data: AnalyticsBreakdowns$1;
|
|
1426
1496
|
/**
|
|
1427
1497
|
* What the figures cover.
|
|
1428
1498
|
*/
|
|
1429
|
-
meta: AnalyticsMeta;
|
|
1499
|
+
meta: AnalyticsMeta$1;
|
|
1430
1500
|
};
|
|
1431
1501
|
};
|
|
1432
1502
|
type PartnerApiV1AnalyticsBreakdownsResponse = PartnerApiV1AnalyticsBreakdownsResponses[keyof PartnerApiV1AnalyticsBreakdownsResponses];
|
|
@@ -1455,7 +1525,7 @@ type PartnerApiV1BookingsIndexData = {
|
|
|
1455
1525
|
};
|
|
1456
1526
|
type PartnerApiV1BookingsIndexResponses = {
|
|
1457
1527
|
200: {
|
|
1458
|
-
data: Array<Booking>;
|
|
1528
|
+
data: Array<Booking$1>;
|
|
1459
1529
|
pagination: {
|
|
1460
1530
|
perPage: number;
|
|
1461
1531
|
nextCursor: string | null;
|
|
@@ -1464,7 +1534,7 @@ type PartnerApiV1BookingsIndexResponses = {
|
|
|
1464
1534
|
hasPrevPage: boolean;
|
|
1465
1535
|
};
|
|
1466
1536
|
} | {
|
|
1467
|
-
data: Array<Booking>;
|
|
1537
|
+
data: Array<Booking$1>;
|
|
1468
1538
|
pagination: {
|
|
1469
1539
|
hasNextPage: boolean;
|
|
1470
1540
|
};
|
|
@@ -1494,13 +1564,13 @@ type PartnerApiV1BookingsUpdatePackageSpecificationsResponses = {
|
|
|
1494
1564
|
type PartnerApiV1BookingsUpdatePackageSpecificationsResponse = PartnerApiV1BookingsUpdatePackageSpecificationsResponses[keyof PartnerApiV1BookingsUpdatePackageSpecificationsResponses];
|
|
1495
1565
|
type PartnerApiV1BookingsShowResponses = {
|
|
1496
1566
|
200: {
|
|
1497
|
-
data: Booking;
|
|
1567
|
+
data: Booking$1;
|
|
1498
1568
|
};
|
|
1499
1569
|
};
|
|
1500
1570
|
type PartnerApiV1BookingsShowResponse = PartnerApiV1BookingsShowResponses[keyof PartnerApiV1BookingsShowResponses];
|
|
1501
1571
|
type PartnerApiV1BookingsItemsPackageShowResponses = {
|
|
1502
1572
|
200: {
|
|
1503
|
-
data: IssuedPackage;
|
|
1573
|
+
data: IssuedPackage$1;
|
|
1504
1574
|
};
|
|
1505
1575
|
};
|
|
1506
1576
|
type PartnerApiV1BookingsItemsPackageShowResponse = PartnerApiV1BookingsItemsPackageShowResponses[keyof PartnerApiV1BookingsItemsPackageShowResponses];
|
|
@@ -1509,7 +1579,7 @@ type PartnerApiV1BundlesIndexResponses = {
|
|
|
1509
1579
|
* Array of `Bundle`
|
|
1510
1580
|
*/
|
|
1511
1581
|
200: {
|
|
1512
|
-
data: Array<Bundle>;
|
|
1582
|
+
data: Array<Bundle$1>;
|
|
1513
1583
|
};
|
|
1514
1584
|
};
|
|
1515
1585
|
type PartnerApiV1BundlesIndexResponse = PartnerApiV1BundlesIndexResponses[keyof PartnerApiV1BundlesIndexResponses];
|
|
@@ -1518,7 +1588,7 @@ type PartnerApiV1MeResponses = {
|
|
|
1518
1588
|
* `Partner`
|
|
1519
1589
|
*/
|
|
1520
1590
|
200: {
|
|
1521
|
-
data: Partner;
|
|
1591
|
+
data: Partner$1;
|
|
1522
1592
|
};
|
|
1523
1593
|
};
|
|
1524
1594
|
type PartnerApiV1MeResponse = PartnerApiV1MeResponses[keyof PartnerApiV1MeResponses];
|
|
@@ -1532,8 +1602,8 @@ type PartnerApiV1DestinationsData = {
|
|
|
1532
1602
|
};
|
|
1533
1603
|
type PartnerApiV1DestinationsResponses = {
|
|
1534
1604
|
200: {
|
|
1535
|
-
countries: Array<Destination>;
|
|
1536
|
-
regions: Array<Destination>;
|
|
1605
|
+
countries: Array<Destination$1>;
|
|
1606
|
+
regions: Array<Destination$1>;
|
|
1537
1607
|
};
|
|
1538
1608
|
};
|
|
1539
1609
|
type PartnerApiV1DestinationsResponse = PartnerApiV1DestinationsResponses[keyof PartnerApiV1DestinationsResponses];
|
|
@@ -1542,7 +1612,7 @@ type PartnerApiV1DestinationsShowResponses = {
|
|
|
1542
1612
|
* `DestinationResource`
|
|
1543
1613
|
*/
|
|
1544
1614
|
200: {
|
|
1545
|
-
data: DestinationResource;
|
|
1615
|
+
data: DestinationResource$1;
|
|
1546
1616
|
};
|
|
1547
1617
|
};
|
|
1548
1618
|
type PartnerApiV1DestinationsShowResponse = PartnerApiV1DestinationsShowResponses[keyof PartnerApiV1DestinationsShowResponses];
|
|
@@ -1551,7 +1621,7 @@ type PartnerApiV1DeviceCompatibilityIndexResponses = {
|
|
|
1551
1621
|
* `DeviceCompatibilityList`
|
|
1552
1622
|
*/
|
|
1553
1623
|
200: {
|
|
1554
|
-
data: DeviceCompatibilityList;
|
|
1624
|
+
data: DeviceCompatibilityList$1;
|
|
1555
1625
|
};
|
|
1556
1626
|
};
|
|
1557
1627
|
type PartnerApiV1DeviceCompatibilityIndexResponse = PartnerApiV1DeviceCompatibilityIndexResponses[keyof PartnerApiV1DeviceCompatibilityIndexResponses];
|
|
@@ -1560,7 +1630,7 @@ type PartnerApiV1DeviceCompatibilityCheckResponses = {
|
|
|
1560
1630
|
* `DeviceCompatibility`
|
|
1561
1631
|
*/
|
|
1562
1632
|
200: {
|
|
1563
|
-
data: DeviceCompatibility;
|
|
1633
|
+
data: DeviceCompatibility$1;
|
|
1564
1634
|
};
|
|
1565
1635
|
};
|
|
1566
1636
|
type PartnerApiV1DeviceCompatibilityCheckResponse = PartnerApiV1DeviceCompatibilityCheckResponses[keyof PartnerApiV1DeviceCompatibilityCheckResponses];
|
|
@@ -1569,16 +1639,25 @@ type PartnerApiV1EsimsShowResponses = {
|
|
|
1569
1639
|
* `Esim`
|
|
1570
1640
|
*/
|
|
1571
1641
|
200: {
|
|
1572
|
-
data: Esim;
|
|
1642
|
+
data: Esim$1;
|
|
1573
1643
|
};
|
|
1574
1644
|
};
|
|
1575
1645
|
type PartnerApiV1EsimsShowResponse = PartnerApiV1EsimsShowResponses[keyof PartnerApiV1EsimsShowResponses];
|
|
1646
|
+
type PartnerApiV1EsimsUsageResponses = {
|
|
1647
|
+
/**
|
|
1648
|
+
* Array of `DestinationUsage`
|
|
1649
|
+
*/
|
|
1650
|
+
200: {
|
|
1651
|
+
data: Array<DestinationUsage$1>;
|
|
1652
|
+
};
|
|
1653
|
+
};
|
|
1654
|
+
type PartnerApiV1EsimsUsageResponse = PartnerApiV1EsimsUsageResponses[keyof PartnerApiV1EsimsUsageResponses];
|
|
1576
1655
|
type PartnerApiV1EsimsInstructionsResponses = {
|
|
1577
1656
|
/**
|
|
1578
1657
|
* `InstallInstructions`
|
|
1579
1658
|
*/
|
|
1580
1659
|
200: {
|
|
1581
|
-
data: InstallInstructions;
|
|
1660
|
+
data: InstallInstructions$1;
|
|
1582
1661
|
};
|
|
1583
1662
|
};
|
|
1584
1663
|
type PartnerApiV1EsimsInstructionsResponse = PartnerApiV1EsimsInstructionsResponses[keyof PartnerApiV1EsimsInstructionsResponses];
|
|
@@ -1587,17 +1666,88 @@ type PartnerApiV1RedirectTokensCreateResponses = {
|
|
|
1587
1666
|
* `RedirectToken`
|
|
1588
1667
|
*/
|
|
1589
1668
|
200: {
|
|
1590
|
-
data: RedirectToken;
|
|
1669
|
+
data: RedirectToken$1;
|
|
1591
1670
|
};
|
|
1592
1671
|
};
|
|
1593
1672
|
type PartnerApiV1RedirectTokensCreateResponse = PartnerApiV1RedirectTokensCreateResponses[keyof PartnerApiV1RedirectTokensCreateResponses];
|
|
1594
1673
|
|
|
1674
|
+
/**
|
|
1675
|
+
* Open response enums. The Partner API may add a value to a response enum in a
|
|
1676
|
+
* minor release (a new Package `state`, say), so the SDK types every response
|
|
1677
|
+
* enum as its known values or any other string. Code that branches on one
|
|
1678
|
+
* needs a `default` branch; editors still complete the known values. Request
|
|
1679
|
+
* enums stay closed, because the server refuses a value it does not know.
|
|
1680
|
+
*
|
|
1681
|
+
* The generated types in ../src are closed; lib/types.ts opens them here, so a
|
|
1682
|
+
* regeneration keeps the open types without a generator post-process.
|
|
1683
|
+
*/
|
|
1684
|
+
/**
|
|
1685
|
+
* A response enum: one of the known values `Known`, or a string a later
|
|
1686
|
+
* Partner API minor adds. `string & {}` keeps the literals from collapsing
|
|
1687
|
+
* into `string`, which is what keeps editor completion.
|
|
1688
|
+
*/
|
|
1689
|
+
type Open<Known extends string> = Known | (string & {});
|
|
1690
|
+
/**
|
|
1691
|
+
* `T` with every string enum inside it opened: each union of string literals,
|
|
1692
|
+
* at any depth (objects, arrays, nullable fields), becomes `Open` of itself.
|
|
1693
|
+
* Plain `string` fields and every other type stay as they are.
|
|
1694
|
+
*/
|
|
1695
|
+
type OpenEnums<T> = T extends string ? string extends T ? T : Open<T> : T extends object ? {
|
|
1696
|
+
[K in keyof T]: OpenEnums<T[K]>;
|
|
1697
|
+
} : T;
|
|
1698
|
+
|
|
1595
1699
|
/**
|
|
1596
1700
|
* The types a Partner names: a readable alias for each method's input and
|
|
1597
1701
|
* response, over the generated operation types, and the resource types under
|
|
1598
1702
|
* their schema names. Every name is listed, never a wildcard (ADR 0058).
|
|
1703
|
+
*
|
|
1704
|
+
* Every response and resource type is wrapped in `OpenEnums`, and every
|
|
1705
|
+
* response enum in `Open`, so a value a later Partner API minor adds still
|
|
1706
|
+
* type-checks (lib/open-enums.ts). Inputs, query filters and request enums
|
|
1707
|
+
* stay as generated: closed.
|
|
1599
1708
|
*/
|
|
1600
1709
|
|
|
1710
|
+
type BookingSource = Open<BookingSource$1>;
|
|
1711
|
+
type DestinationKind = Open<DestinationKind$1>;
|
|
1712
|
+
type EndCustomerChannel = Open<EndCustomerChannel$1>;
|
|
1713
|
+
type FairUseThrottleReset = Open<FairUseThrottleReset$1>;
|
|
1714
|
+
type PackageLifecycleState = Open<PackageLifecycleState$1>;
|
|
1715
|
+
type PackageQueueStatus = Open<PackageQueueStatus$1>;
|
|
1716
|
+
type PackageType = Open<PackageType$1>;
|
|
1717
|
+
type AnalyticsActivation = OpenEnums<AnalyticsActivation$1>;
|
|
1718
|
+
type AnalyticsBreakdowns = OpenEnums<AnalyticsBreakdowns$1>;
|
|
1719
|
+
type AnalyticsBundleSizeCount = OpenEnums<AnalyticsBundleSizeCount$1>;
|
|
1720
|
+
type AnalyticsDestinationCount = OpenEnums<AnalyticsDestinationCount$1>;
|
|
1721
|
+
type AnalyticsDiscountCode = OpenEnums<AnalyticsDiscountCode$1>;
|
|
1722
|
+
type AnalyticsFunnel = OpenEnums<AnalyticsFunnel$1>;
|
|
1723
|
+
type AnalyticsFunnelGroup = OpenEnums<AnalyticsFunnelGroup$1>;
|
|
1724
|
+
type AnalyticsFunnelStep = OpenEnums<AnalyticsFunnelStep$1>;
|
|
1725
|
+
type AnalyticsMeta = OpenEnums<AnalyticsMeta$1>;
|
|
1726
|
+
type AnalyticsPartnerContribution = OpenEnums<AnalyticsPartnerContribution$1>;
|
|
1727
|
+
type AnalyticsRatio = OpenEnums<AnalyticsRatio$1>;
|
|
1728
|
+
type AnalyticsSummary = OpenEnums<AnalyticsSummary$1>;
|
|
1729
|
+
type AnalyticsTimeseries = OpenEnums<AnalyticsTimeseries$1>;
|
|
1730
|
+
type AnalyticsTimeseriesBucket = OpenEnums<AnalyticsTimeseriesBucket$1>;
|
|
1731
|
+
type Booking = OpenEnums<Booking$1>;
|
|
1732
|
+
type BookingItem = OpenEnums<BookingItem$1>;
|
|
1733
|
+
type Bundle = OpenEnums<Bundle$1>;
|
|
1734
|
+
type Destination = OpenEnums<Destination$1>;
|
|
1735
|
+
type DestinationResource = OpenEnums<DestinationResource$1>;
|
|
1736
|
+
type DestinationSummary = OpenEnums<DestinationSummary$1>;
|
|
1737
|
+
type DestinationUsage = OpenEnums<DestinationUsage$1>;
|
|
1738
|
+
type DeviceCompatibility = OpenEnums<DeviceCompatibility$1>;
|
|
1739
|
+
type DeviceCompatibilityList = OpenEnums<DeviceCompatibilityList$1>;
|
|
1740
|
+
type Esim = OpenEnums<Esim$1>;
|
|
1741
|
+
type EsimInstallMaterial = OpenEnums<EsimInstallMaterial$1>;
|
|
1742
|
+
type EsimPackage = OpenEnums<EsimPackage$1>;
|
|
1743
|
+
type FairUseThrottle = OpenEnums<FairUseThrottle$1>;
|
|
1744
|
+
type InstallInstructions = OpenEnums<InstallInstructions$1>;
|
|
1745
|
+
type InstallInstructionSection = OpenEnums<InstallInstructionSection$1>;
|
|
1746
|
+
type InstallInstructionSet = OpenEnums<InstallInstructionSet$1>;
|
|
1747
|
+
type InstallInstructionStep = OpenEnums<InstallInstructionStep$1>;
|
|
1748
|
+
type IssuedPackage = OpenEnums<IssuedPackage$1>;
|
|
1749
|
+
type Partner = OpenEnums<Partner$1>;
|
|
1750
|
+
type RedirectToken = OpenEnums<RedirectToken$1>;
|
|
1601
1751
|
/** `createBooking(input)`. */
|
|
1602
1752
|
type CreateBookingInput = CreateBookingRequest;
|
|
1603
1753
|
/** `updateBooking(id, input)`. */
|
|
@@ -1620,7 +1770,7 @@ type IssuePackageInput = IssuePackageRequest & {
|
|
|
1620
1770
|
type TerminatePackageInput = {
|
|
1621
1771
|
reason?: PartnerTerminateReason;
|
|
1622
1772
|
};
|
|
1623
|
-
/** `getEsim(iccid, input?)`. `refresh: true` reads the eSIM from the network now. */
|
|
1773
|
+
/** `getEsim(iccid, input?)` and `getEsimUsage(iccid, input?)`. `refresh: true` reads the eSIM from the network now. */
|
|
1624
1774
|
type EsimReadOptions = {
|
|
1625
1775
|
refresh?: boolean;
|
|
1626
1776
|
};
|
|
@@ -1641,41 +1791,43 @@ type AnalyticsFunnelQuery = NonNullable<PartnerApiV1AnalyticsFunnelData['query']
|
|
|
1641
1791
|
/** `getAnalyticsTimeseries(query?)`. */
|
|
1642
1792
|
type AnalyticsTimeseriesQuery = NonNullable<PartnerApiV1AnalyticsTimeseriesData['query']>;
|
|
1643
1793
|
/** `getPartner()`. */
|
|
1644
|
-
type PartnerResponse = PartnerApiV1MeResponse
|
|
1794
|
+
type PartnerResponse = OpenEnums<PartnerApiV1MeResponse>;
|
|
1645
1795
|
/** `getBundles()` and `getDestinationBundles(code)`. */
|
|
1646
|
-
type BundleListResponse = PartnerApiV1BundlesIndexResponse
|
|
1796
|
+
type BundleListResponse = OpenEnums<PartnerApiV1BundlesIndexResponse>;
|
|
1647
1797
|
/** `getDestinations(filters?)`: countries and regions. */
|
|
1648
|
-
type DestinationListResponse = PartnerApiV1DestinationsResponse
|
|
1798
|
+
type DestinationListResponse = OpenEnums<PartnerApiV1DestinationsResponse>;
|
|
1649
1799
|
/** `getDestination(code)`. */
|
|
1650
|
-
type DestinationResponse = PartnerApiV1DestinationsShowResponse
|
|
1800
|
+
type DestinationResponse = OpenEnums<PartnerApiV1DestinationsShowResponse>;
|
|
1651
1801
|
/** `createBooking`, `getBooking` and `updateBooking`. */
|
|
1652
|
-
type BookingResponse = PartnerApiV1BookingsShowResponse
|
|
1802
|
+
type BookingResponse = OpenEnums<PartnerApiV1BookingsShowResponse>;
|
|
1653
1803
|
/** `getBookings(filters?)`: a page of bookings and its cursors. */
|
|
1654
|
-
type BookingListResponse = PartnerApiV1BookingsIndexResponse
|
|
1804
|
+
type BookingListResponse = OpenEnums<PartnerApiV1BookingsIndexResponse>;
|
|
1655
1805
|
/** `updatePackageSpecification` and `updatePackageSpecifications`. */
|
|
1656
|
-
type PackageSpecificationUpdateResponse = PartnerApiV1BookingsUpdatePackageSpecificationsResponse
|
|
1806
|
+
type PackageSpecificationUpdateResponse = OpenEnums<PartnerApiV1BookingsUpdatePackageSpecificationsResponse>;
|
|
1657
1807
|
/** `presignBookingImport(input)`: where to upload the import file, and how. */
|
|
1658
|
-
type BookingImportPresignResponse = PartnerApiV1BookingsImportsPresignUploadResponse
|
|
1808
|
+
type BookingImportPresignResponse = OpenEnums<PartnerApiV1BookingsImportsPresignUploadResponse>;
|
|
1659
1809
|
/** `issuePackage` and `getPackage`. */
|
|
1660
|
-
type PackageResponse = PartnerApiV1BookingsItemsPackageShowResponse
|
|
1810
|
+
type PackageResponse = OpenEnums<PartnerApiV1BookingsItemsPackageShowResponse>;
|
|
1661
1811
|
/** `getEsim(iccid, input?)`. */
|
|
1662
|
-
type EsimResponse = PartnerApiV1EsimsShowResponse
|
|
1812
|
+
type EsimResponse = OpenEnums<PartnerApiV1EsimsShowResponse>;
|
|
1813
|
+
/** `getEsimUsage(iccid, input?)`: one `DestinationUsage` per destination. */
|
|
1814
|
+
type EsimUsageResponse = OpenEnums<PartnerApiV1EsimsUsageResponse>;
|
|
1663
1815
|
/** `getEsimInstructions(iccid, input?)`. */
|
|
1664
|
-
type EsimInstructionsResponse = PartnerApiV1EsimsInstructionsResponse
|
|
1816
|
+
type EsimInstructionsResponse = OpenEnums<PartnerApiV1EsimsInstructionsResponse>;
|
|
1665
1817
|
/** `getCompatibleDevices()`. */
|
|
1666
|
-
type DeviceCompatibilityListResponse = PartnerApiV1DeviceCompatibilityIndexResponse
|
|
1818
|
+
type DeviceCompatibilityListResponse = OpenEnums<PartnerApiV1DeviceCompatibilityIndexResponse>;
|
|
1667
1819
|
/** `checkDeviceCompatibility(input)`. */
|
|
1668
|
-
type DeviceCompatibilityResponse = PartnerApiV1DeviceCompatibilityCheckResponse
|
|
1820
|
+
type DeviceCompatibilityResponse = OpenEnums<PartnerApiV1DeviceCompatibilityCheckResponse>;
|
|
1669
1821
|
/** `createRedirectToken(input)`. */
|
|
1670
|
-
type RedirectTokenResponse = PartnerApiV1RedirectTokensCreateResponse
|
|
1822
|
+
type RedirectTokenResponse = OpenEnums<PartnerApiV1RedirectTokensCreateResponse>;
|
|
1671
1823
|
/** `getAnalyticsSummary(query?)`. */
|
|
1672
|
-
type AnalyticsSummaryResponse = PartnerApiV1AnalyticsSummaryResponse
|
|
1824
|
+
type AnalyticsSummaryResponse = OpenEnums<PartnerApiV1AnalyticsSummaryResponse>;
|
|
1673
1825
|
/** `getAnalyticsFunnel(query?)`. */
|
|
1674
|
-
type AnalyticsFunnelResponse = PartnerApiV1AnalyticsFunnelResponse
|
|
1826
|
+
type AnalyticsFunnelResponse = OpenEnums<PartnerApiV1AnalyticsFunnelResponse>;
|
|
1675
1827
|
/** `getAnalyticsTimeseries(query?)`. */
|
|
1676
|
-
type AnalyticsTimeseriesResponse = PartnerApiV1AnalyticsTimeseriesResponse
|
|
1828
|
+
type AnalyticsTimeseriesResponse = OpenEnums<PartnerApiV1AnalyticsTimeseriesResponse>;
|
|
1677
1829
|
/** `getAnalyticsBreakdowns(query?)`. */
|
|
1678
|
-
type AnalyticsBreakdownsResponse = PartnerApiV1AnalyticsBreakdownsResponse
|
|
1830
|
+
type AnalyticsBreakdownsResponse = OpenEnums<PartnerApiV1AnalyticsBreakdownsResponse>;
|
|
1679
1831
|
|
|
1680
1832
|
type HubbyOptions = Omit<SigningClientOptions, 'baseUrl'> & {
|
|
1681
1833
|
/** Default `https://core.hubbyesim.com/api`; staging is `https://core-staging.hubbyesim.com/api`. */
|
|
@@ -1726,6 +1878,12 @@ declare class Hubby {
|
|
|
1726
1878
|
* rate-limited per Partner.
|
|
1727
1879
|
*/
|
|
1728
1880
|
getEsim(iccid: string, input?: EsimReadOptions, options?: RequestOptions): Promise<EsimResponse>;
|
|
1881
|
+
/**
|
|
1882
|
+
* `GET /v1/esims/{iccid}/usage`: what the traveller can still use on the
|
|
1883
|
+
* eSIM, one entry per destination, newest first. `refresh: true` reads
|
|
1884
|
+
* the network now; it shares `getEsim`'s per-Partner rate limit.
|
|
1885
|
+
*/
|
|
1886
|
+
getEsimUsage(iccid: string, input?: EsimReadOptions, options?: RequestOptions): Promise<EsimUsageResponse>;
|
|
1729
1887
|
/** `GET /v1/destinations`: the destinations, filtered by `iso3` when given. */
|
|
1730
1888
|
getDestinations(filters?: DestinationListFilters, options?: RequestOptions): Promise<DestinationListResponse>;
|
|
1731
1889
|
/**
|
|
@@ -1872,6 +2030,6 @@ declare function verifyWebhook<TData = Record<string, unknown>>(options: VerifyW
|
|
|
1872
2030
|
* scripts/check-api-version.mjs reads this line and fails CI when the exported
|
|
1873
2031
|
* Partner document's `info.version` differs, so keep it a single-quoted literal.
|
|
1874
2032
|
*/
|
|
1875
|
-
declare const SUPPORTED_API_VERSION = "5.
|
|
2033
|
+
declare const SUPPORTED_API_VERSION = "5.14.0";
|
|
1876
2034
|
|
|
1877
|
-
export { type AnalyticsActivation, type AnalyticsBreakdowns, type AnalyticsBreakdownsResponse, type AnalyticsBundleSizeCount, type AnalyticsDestinationCount, type AnalyticsDiscountCode, type AnalyticsFunnel, type AnalyticsFunnelGroup, type AnalyticsFunnelQuery, type AnalyticsFunnelResponse, type AnalyticsFunnelStep, type AnalyticsMeta, type AnalyticsPartnerContribution, type AnalyticsQuery, type AnalyticsRatio, type AnalyticsSummary, type AnalyticsSummaryQuery, type AnalyticsSummaryResponse, type AnalyticsTimeseries, type AnalyticsTimeseriesBucket, type AnalyticsTimeseriesQuery, type AnalyticsTimeseriesResponse, type Booking, type BookingImportPresignResponse, type BookingItem, type BookingListFilters, type BookingListResponse, type BookingResponse, type BookingSource, type Bundle, type BundleListResponse, type CommunicationChannel, type CreateBookingInput, DEFAULT_WEBHOOK_TOLERANCE_SECONDS, type Destination, type DestinationListFilters, type DestinationListResponse, type DestinationResource, type DestinationResponse, type DeviceCompatibility, type DeviceCompatibilityInput, type DeviceCompatibilityList, type DeviceCompatibilityListResponse, type DeviceCompatibilityResponse, type EndCustomerChannel, type Esim, type EsimInstallMaterial, type EsimInstructionsOptions, type EsimInstructionsResponse, type EsimPackage, type EsimReadOptions, type EsimResponse, type FairUseThrottle, type FairUseThrottleReset, Hubby, HubbyApiError, type HubbyOptions, type InstallInstructionSection, type InstallInstructionSet, type InstallInstructionStep, type InstallInstructions, type IssuePackageInput, type IssuedPackage, type PackageLifecycleState, type PackageQueueStatus, type PackageResponse, type PackageSpecificationInput, type PackageSpecificationUpdateResponse, type PackageSpecificationsInput, type PackageType, type Partner, type PartnerResponse, type PartnerTerminateReason, type PresignBookingImportInput, type RedirectToken, type RedirectTokenInput, type RedirectTokenResponse, type RequestOptions, type RetryOptions, SIGNATURE_VERSION, SUPPORTED_API_VERSION, type SignableRequest, type SupportedLocale, type TerminatePackageInput, type UpdateBookingInput, type VerifyWebhookOptions, type WebhookEvent, type WebhookHeaders, WebhookVerificationError, type WebhookVerificationFailure, signRequest, verifyWebhook };
|
|
2035
|
+
export { type AnalyticsActivation, type AnalyticsBreakdowns, type AnalyticsBreakdownsResponse, type AnalyticsBundleSizeCount, type AnalyticsDestinationCount, type AnalyticsDiscountCode, type AnalyticsFunnel, type AnalyticsFunnelGroup, type AnalyticsFunnelQuery, type AnalyticsFunnelResponse, type AnalyticsFunnelStep, type AnalyticsMeta, type AnalyticsPartnerContribution, type AnalyticsQuery, type AnalyticsRatio, type AnalyticsSummary, type AnalyticsSummaryQuery, type AnalyticsSummaryResponse, type AnalyticsTimeseries, type AnalyticsTimeseriesBucket, type AnalyticsTimeseriesQuery, type AnalyticsTimeseriesResponse, type Booking, type BookingImportPresignResponse, type BookingItem, type BookingListFilters, type BookingListResponse, type BookingResponse, type BookingSource, type Bundle, type BundleListResponse, type CommunicationChannel, type CreateBookingInput, DEFAULT_WEBHOOK_TOLERANCE_SECONDS, type Destination, type DestinationKind, type DestinationListFilters, type DestinationListResponse, type DestinationResource, type DestinationResponse, type DestinationSummary, type DestinationUsage, type DeviceCompatibility, type DeviceCompatibilityInput, type DeviceCompatibilityList, type DeviceCompatibilityListResponse, type DeviceCompatibilityResponse, type EndCustomerChannel, type Esim, type EsimInstallMaterial, type EsimInstructionsOptions, type EsimInstructionsResponse, type EsimPackage, type EsimReadOptions, type EsimResponse, type EsimUsageResponse, type FairUseThrottle, type FairUseThrottleReset, Hubby, HubbyApiError, type HubbyOptions, type InstallInstructionSection, type InstallInstructionSet, type InstallInstructionStep, type InstallInstructions, type IssuePackageInput, type IssuedPackage, type PackageLifecycleState, type PackageQueueStatus, type PackageResponse, type PackageSpecificationInput, type PackageSpecificationUpdateResponse, type PackageSpecificationsInput, type PackageType, type Partner, type PartnerResponse, type PartnerTerminateReason, type PresignBookingImportInput, type RedirectToken, type RedirectTokenInput, type RedirectTokenResponse, type RequestOptions, type RetryOptions, SIGNATURE_VERSION, SUPPORTED_API_VERSION, type SignableRequest, type SupportedLocale, type TerminatePackageInput, type UpdateBookingInput, type VerifyWebhookOptions, type WebhookEvent, type WebhookHeaders, WebhookVerificationError, type WebhookVerificationFailure, signRequest, verifyWebhook };
|