@revolugo/booking-api-client 6.14.6-beta.16 → 6.14.6-beta.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.es.js +156 -134
- package/dist/index.umd.js +2 -2
- package/dist/types/v1/apis/ResourceBookingPoliciesApi.d.ts +33 -0
- package/package.json +4 -4
package/dist/index.es.js
CHANGED
|
@@ -28,7 +28,7 @@ function Xe(i, e) {
|
|
|
28
28
|
}
|
|
29
29
|
function dt(i, e) {
|
|
30
30
|
const [r, t, n] = Me(i, e), s = Te(e?.locale), u = ke(e?.locale), c = e?.mergeAmbiguousCharacters ? _e(s, u) : et(s, u);
|
|
31
|
-
return r + t.map((h,
|
|
31
|
+
return r + t.map((h, S) => S === 0 ? s(h) : c(h, S)).join(e?.delimiter ?? "") + n;
|
|
32
32
|
}
|
|
33
33
|
function ht(i, e) {
|
|
34
34
|
const [r, t, n] = Me(i, e), s = Te(e?.locale), u = ke(e?.locale), c = e?.mergeAmbiguousCharacters ? _e(s, u) : et(s, u);
|
|
@@ -95,11 +95,11 @@ function gt() {
|
|
|
95
95
|
if (typeof s != "string")
|
|
96
96
|
throw new Error("slugify: string argument expected");
|
|
97
97
|
u = typeof u == "string" ? { replacement: u } : u || {};
|
|
98
|
-
var c = t[u.locale] || {}, h = u.replacement === void 0 ? "-" : u.replacement,
|
|
98
|
+
var c = t[u.locale] || {}, h = u.replacement === void 0 ? "-" : u.replacement, S = u.trim === void 0 ? !0 : u.trim, C = s.normalize().split("").reduce(function(y, m) {
|
|
99
99
|
var A = c[m];
|
|
100
100
|
return A === void 0 && (A = r[m]), A === void 0 && (A = m), A === h && (A = " "), y + A.replace(u.remove || /[^\w\s$*_+~.()'"!\-:@]+/g, "");
|
|
101
101
|
}, "");
|
|
102
|
-
return u.strict && (C = C.replace(/[^A-Za-z0-9\s]/g, "")),
|
|
102
|
+
return u.strict && (C = C.replace(/[^A-Za-z0-9\s]/g, "")), S && (C = C.trim()), C = C.replace(/\s+/g, h), u.lower && (C = C.toLowerCase()), C;
|
|
103
103
|
}
|
|
104
104
|
return n.extend = function(s) {
|
|
105
105
|
Object.assign(r, s);
|
|
@@ -115,7 +115,7 @@ function St(i) {
|
|
|
115
115
|
strict: !0
|
|
116
116
|
});
|
|
117
117
|
}
|
|
118
|
-
var
|
|
118
|
+
var v = /* @__PURE__ */ ((i) => (i.Camel = "camelCase", i.Capital = "capitalCase", i.Param = "paramCase", i.Pascal = "pascalCase", i.Slug = "slugCase", i.Snake = "snakeCase", i))(v || {});
|
|
119
119
|
const Rt = {
|
|
120
120
|
camelCase: dt,
|
|
121
121
|
capitalCase: pt,
|
|
@@ -152,7 +152,7 @@ function tt() {
|
|
|
152
152
|
(function(r, t) {
|
|
153
153
|
i.exports = t();
|
|
154
154
|
})(Mt, (function() {
|
|
155
|
-
var r = 1e3, t = 6e4, n = 36e5, s = "millisecond", u = "second", c = "minute", h = "hour",
|
|
155
|
+
var r = 1e3, t = 6e4, n = 36e5, s = "millisecond", u = "second", c = "minute", h = "hour", S = "day", C = "week", y = "month", m = "quarter", A = "year", T = "date", d = "Invalid Date", M = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, I = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, b = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(R) {
|
|
156
156
|
var o = ["th", "st", "nd", "rd"], a = R % 100;
|
|
157
157
|
return "[" + R + (o[(a - 20) % 10] || o[a] || o[0]) + "]";
|
|
158
158
|
} }, _ = function(R, o, a) {
|
|
@@ -168,13 +168,13 @@ function tt() {
|
|
|
168
168
|
}, a: function(R) {
|
|
169
169
|
return R < 0 ? Math.ceil(R) || 0 : Math.floor(R);
|
|
170
170
|
}, p: function(R) {
|
|
171
|
-
return { M: y, y: A, w: C, d:
|
|
171
|
+
return { M: y, y: A, w: C, d: S, D: T, h, m: c, s: u, ms: s, Q: m }[R] || String(R || "").toLowerCase().replace(/s$/, "");
|
|
172
172
|
}, u: function(R) {
|
|
173
173
|
return R === void 0;
|
|
174
174
|
} }, E = "en", B = {};
|
|
175
175
|
B[E] = b;
|
|
176
|
-
var
|
|
177
|
-
return R instanceof V || !(!R || !R[
|
|
176
|
+
var K = "$isDayjsObject", F = function(R) {
|
|
177
|
+
return R instanceof V || !(!R || !R[K]);
|
|
178
178
|
}, N = function R(o, a, f) {
|
|
179
179
|
var l;
|
|
180
180
|
if (!o) return E;
|
|
@@ -189,16 +189,16 @@ function tt() {
|
|
|
189
189
|
}
|
|
190
190
|
return !f && l && (E = l), l || !f && E;
|
|
191
191
|
}, x = function(R, o) {
|
|
192
|
-
if (
|
|
192
|
+
if (F(R)) return R.clone();
|
|
193
193
|
var a = typeof o == "object" ? o : {};
|
|
194
194
|
return a.date = R, a.args = arguments, new V(a);
|
|
195
195
|
}, O = P;
|
|
196
|
-
O.l = N, O.i =
|
|
196
|
+
O.l = N, O.i = F, O.w = function(R, o) {
|
|
197
197
|
return x(R, { locale: o.$L, utc: o.$u, x: o.$x, $offset: o.$offset });
|
|
198
198
|
};
|
|
199
199
|
var V = (function() {
|
|
200
200
|
function R(a) {
|
|
201
|
-
this.$L = N(a.locale, null, !0), this.parse(a), this.$x = this.$x || a.x || {}, this[
|
|
201
|
+
this.$L = N(a.locale, null, !0), this.parse(a), this.$x = this.$x || a.x || {}, this[K] = !0;
|
|
202
202
|
}
|
|
203
203
|
var o = R.prototype;
|
|
204
204
|
return o.parse = function(a) {
|
|
@@ -239,7 +239,7 @@ function tt() {
|
|
|
239
239
|
}, o.startOf = function(a, f) {
|
|
240
240
|
var l = this, g = !!O.u(f) || f, p = O.p(a), D = function(Q, q) {
|
|
241
241
|
var Z = O.w(l.$u ? Date.UTC(l.$y, q, Q) : new Date(l.$y, q, Q), l);
|
|
242
|
-
return g ? Z : Z.endOf(
|
|
242
|
+
return g ? Z : Z.endOf(S);
|
|
243
243
|
}, L = function(Q, q) {
|
|
244
244
|
return O.w(l.toDate()[Q].apply(l.toDate("s"), (g ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(q)), l);
|
|
245
245
|
}, G = this.$W, k = this.$M, H = this.$D, te = "set" + (this.$u ? "UTC" : "");
|
|
@@ -251,7 +251,7 @@ function tt() {
|
|
|
251
251
|
case C:
|
|
252
252
|
var X = this.$locale().weekStart || 0, ne = (G < X ? G + 7 : G) - X;
|
|
253
253
|
return D(g ? H - ne : H + (6 - ne), k);
|
|
254
|
-
case
|
|
254
|
+
case S:
|
|
255
255
|
case T:
|
|
256
256
|
return L(te + "Hours", 0);
|
|
257
257
|
case h:
|
|
@@ -266,7 +266,7 @@ function tt() {
|
|
|
266
266
|
}, o.endOf = function(a) {
|
|
267
267
|
return this.startOf(a, !1);
|
|
268
268
|
}, o.$set = function(a, f) {
|
|
269
|
-
var l, g = O.p(a), p = "set" + (this.$u ? "UTC" : ""), D = (l = {}, l[
|
|
269
|
+
var l, g = O.p(a), p = "set" + (this.$u ? "UTC" : ""), D = (l = {}, l[S] = p + "Date", l[T] = p + "Date", l[y] = p + "Month", l[A] = p + "FullYear", l[h] = p + "Hours", l[c] = p + "Minutes", l[u] = p + "Seconds", l[s] = p + "Milliseconds", l)[g], L = g === S ? this.$D + (f - this.$W) : f;
|
|
270
270
|
if (g === y || g === A) {
|
|
271
271
|
var G = this.clone().set(T, 1);
|
|
272
272
|
G.$d[D](L), G.init(), this.$d = G.set(T, Math.min(this.$D, G.daysInMonth())).$d;
|
|
@@ -285,7 +285,7 @@ function tt() {
|
|
|
285
285
|
};
|
|
286
286
|
if (p === y) return this.set(y, this.$M + a);
|
|
287
287
|
if (p === A) return this.set(A, this.$y + a);
|
|
288
|
-
if (p ===
|
|
288
|
+
if (p === S) return D(1);
|
|
289
289
|
if (p === C) return D(7);
|
|
290
290
|
var L = (l = {}, l[c] = t, l[h] = n, l[u] = r, l)[p] || 1, G = this.$d.getTime() + a * L;
|
|
291
291
|
return O.w(G, this);
|
|
@@ -376,7 +376,7 @@ function tt() {
|
|
|
376
376
|
case C:
|
|
377
377
|
g = (k - G) / 6048e5;
|
|
378
378
|
break;
|
|
379
|
-
case
|
|
379
|
+
case S:
|
|
380
380
|
g = (k - G) / 864e5;
|
|
381
381
|
break;
|
|
382
382
|
case h:
|
|
@@ -412,13 +412,13 @@ function tt() {
|
|
|
412
412
|
return this.$d.toUTCString();
|
|
413
413
|
}, R;
|
|
414
414
|
})(), oe = V.prototype;
|
|
415
|
-
return x.prototype = oe, [["$ms", s], ["$s", u], ["$m", c], ["$H", h], ["$W",
|
|
415
|
+
return x.prototype = oe, [["$ms", s], ["$s", u], ["$m", c], ["$H", h], ["$W", S], ["$M", y], ["$y", A], ["$D", T]].forEach((function(R) {
|
|
416
416
|
oe[R[1]] = function(o) {
|
|
417
417
|
return this.$g(o, R[0], R[1]);
|
|
418
418
|
};
|
|
419
419
|
})), x.extend = function(R, o) {
|
|
420
420
|
return R.$i || (R(o, V, x), R.$i = !0), x;
|
|
421
|
-
}, x.locale = N, x.isDayjs =
|
|
421
|
+
}, x.locale = N, x.isDayjs = F, x.unix = function(R) {
|
|
422
422
|
return x(1e3 * R);
|
|
423
423
|
}, x.en = B[E], x.Ls = B, x.p = {}, x;
|
|
424
424
|
}));
|
|
@@ -437,7 +437,7 @@ function kt() {
|
|
|
437
437
|
n.format = function(u) {
|
|
438
438
|
var c = this, h = this.$locale();
|
|
439
439
|
if (!this.isValid()) return s.bind(this)(u);
|
|
440
|
-
var
|
|
440
|
+
var S = this.$utils(), C = (u || "YYYY-MM-DDTHH:mm:ssZ").replace(/\[([^\]]+)]|Q|wo|ww|w|WW|W|zzz|z|gggg|GGGG|Do|X|x|k{1,2}|S/g, (function(y) {
|
|
441
441
|
switch (y) {
|
|
442
442
|
case "Q":
|
|
443
443
|
return Math.ceil((c.$M + 1) / 3);
|
|
@@ -451,13 +451,13 @@ function kt() {
|
|
|
451
451
|
return h.ordinal(c.week(), "W");
|
|
452
452
|
case "w":
|
|
453
453
|
case "ww":
|
|
454
|
-
return
|
|
454
|
+
return S.s(c.week(), y === "w" ? 1 : 2, "0");
|
|
455
455
|
case "W":
|
|
456
456
|
case "WW":
|
|
457
|
-
return
|
|
457
|
+
return S.s(c.isoWeek(), y === "W" ? 1 : 2, "0");
|
|
458
458
|
case "k":
|
|
459
459
|
case "kk":
|
|
460
|
-
return
|
|
460
|
+
return S.s(String(c.$H === 0 ? 24 : c.$H), y === "k" ? 1 : 2, "0");
|
|
461
461
|
case "X":
|
|
462
462
|
return Math.floor(c.$d.getTime() / 1e3);
|
|
463
463
|
case "x":
|
|
@@ -486,8 +486,8 @@ function It() {
|
|
|
486
486
|
})(bt, (function() {
|
|
487
487
|
return function(r, t, n) {
|
|
488
488
|
t.prototype.isBetween = function(s, u, c, h) {
|
|
489
|
-
var
|
|
490
|
-
return (y ? this.isAfter(
|
|
489
|
+
var S = n(s), C = n(u), y = (h = h || "()")[0] === "(", m = h[1] === ")";
|
|
490
|
+
return (y ? this.isAfter(S, c) : !this.isBefore(S, c)) && (m ? this.isBefore(C, c) : !this.isAfter(C, c)) || (y ? this.isBefore(S, c) : !this.isAfter(S, c)) && (m ? this.isAfter(C, c) : !this.isBefore(C, c));
|
|
491
491
|
};
|
|
492
492
|
};
|
|
493
493
|
}));
|
|
@@ -526,13 +526,13 @@ function Gt() {
|
|
|
526
526
|
})(pe)), pe.exports;
|
|
527
527
|
}
|
|
528
528
|
var Ht = Gt();
|
|
529
|
-
const
|
|
530
|
-
var me = { exports: {} },
|
|
529
|
+
const Kt = /* @__PURE__ */ j(Ht);
|
|
530
|
+
var me = { exports: {} }, Ft = me.exports, Ge;
|
|
531
531
|
function Yt() {
|
|
532
532
|
return Ge || (Ge = 1, (function(i, e) {
|
|
533
533
|
(function(r, t) {
|
|
534
534
|
i.exports = t();
|
|
535
|
-
})(
|
|
535
|
+
})(Ft, (function() {
|
|
536
536
|
return function(r, t, n) {
|
|
537
537
|
var s = t.prototype, u = function(y) {
|
|
538
538
|
return y && (y.indexOf ? y : y.s);
|
|
@@ -547,7 +547,7 @@ function Yt() {
|
|
|
547
547
|
}));
|
|
548
548
|
}, h = function() {
|
|
549
549
|
return n.Ls[n.locale()];
|
|
550
|
-
},
|
|
550
|
+
}, S = function(y, m) {
|
|
551
551
|
return y.formats[m] || (function(A) {
|
|
552
552
|
return A.replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g, (function(T, d, M) {
|
|
553
553
|
return d || M.slice(1);
|
|
@@ -568,7 +568,7 @@ function Yt() {
|
|
|
568
568
|
}, weekdaysShort: function(m) {
|
|
569
569
|
return m ? m.format("ddd") : c(y, "weekdaysShort", "weekdays", 3);
|
|
570
570
|
}, longDateFormat: function(m) {
|
|
571
|
-
return
|
|
571
|
+
return S(y.$locale(), m);
|
|
572
572
|
}, meridiem: this.$locale().meridiem, ordinal: this.$locale().ordinal };
|
|
573
573
|
};
|
|
574
574
|
s.localeData = function() {
|
|
@@ -588,7 +588,7 @@ function Yt() {
|
|
|
588
588
|
}, monthsShort: function() {
|
|
589
589
|
return n.monthsShort();
|
|
590
590
|
}, longDateFormat: function(m) {
|
|
591
|
-
return
|
|
591
|
+
return S(y, m);
|
|
592
592
|
}, meridiem: y.meridiem, ordinal: y.ordinal };
|
|
593
593
|
}, n.months = function() {
|
|
594
594
|
return c(h(), "months");
|
|
@@ -618,14 +618,14 @@ function zt() {
|
|
|
618
618
|
var u = n.prototype, c = u.format;
|
|
619
619
|
s.en.formats = r, u.format = function(h) {
|
|
620
620
|
h === void 0 && (h = "YYYY-MM-DDTHH:mm:ssZ");
|
|
621
|
-
var
|
|
621
|
+
var S = this.$locale().formats, C = (function(y, m) {
|
|
622
622
|
return y.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g, (function(A, T, d) {
|
|
623
623
|
var M = d && d.toUpperCase();
|
|
624
624
|
return T || m[d] || r[d] || m[M].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g, (function(I, b, _) {
|
|
625
625
|
return b || _.slice(1);
|
|
626
626
|
}));
|
|
627
627
|
}));
|
|
628
|
-
})(h,
|
|
628
|
+
})(h, S === void 0 ? {} : S);
|
|
629
629
|
return c.call(this, C);
|
|
630
630
|
};
|
|
631
631
|
};
|
|
@@ -634,9 +634,9 @@ function zt() {
|
|
|
634
634
|
}
|
|
635
635
|
var Wt = zt();
|
|
636
636
|
const Zt = /* @__PURE__ */ j(Wt);
|
|
637
|
-
var ge = { exports: {} }, Jt = ge.exports,
|
|
637
|
+
var ge = { exports: {} }, Jt = ge.exports, Ke;
|
|
638
638
|
function Xt() {
|
|
639
|
-
return
|
|
639
|
+
return Ke || (Ke = 1, (function(i, e) {
|
|
640
640
|
(function(r, t) {
|
|
641
641
|
i.exports = t();
|
|
642
642
|
})(Jt, (function() {
|
|
@@ -647,7 +647,7 @@ function Xt() {
|
|
|
647
647
|
c.length === 1 && c[0].length > 0 && (c = c[0]), h = (c = c.filter((function(C) {
|
|
648
648
|
return C;
|
|
649
649
|
})))[0];
|
|
650
|
-
for (var
|
|
650
|
+
for (var S = 1; S < c.length; S += 1) c[S].isValid() && !c[S][u](h) || (h = c[S]);
|
|
651
651
|
return h;
|
|
652
652
|
};
|
|
653
653
|
n.max = function() {
|
|
@@ -663,45 +663,45 @@ function Xt() {
|
|
|
663
663
|
}
|
|
664
664
|
var Qt = Xt();
|
|
665
665
|
const er = /* @__PURE__ */ j(Qt);
|
|
666
|
-
var we = { exports: {} }, tr = we.exports,
|
|
666
|
+
var we = { exports: {} }, tr = we.exports, Fe;
|
|
667
667
|
function rr() {
|
|
668
|
-
return
|
|
668
|
+
return Fe || (Fe = 1, (function(i, e) {
|
|
669
669
|
(function(r, t) {
|
|
670
670
|
i.exports = t();
|
|
671
671
|
})(tr, (function() {
|
|
672
672
|
return function(r, t, n) {
|
|
673
673
|
r = r || {};
|
|
674
674
|
var s = t.prototype, u = { future: "in %s", past: "%s ago", s: "a few seconds", m: "a minute", mm: "%d minutes", h: "an hour", hh: "%d hours", d: "a day", dd: "%d days", M: "a month", MM: "%d months", y: "a year", yy: "%d years" };
|
|
675
|
-
function c(
|
|
676
|
-
return s.fromToBase(
|
|
675
|
+
function c(S, C, y, m) {
|
|
676
|
+
return s.fromToBase(S, C, y, m);
|
|
677
677
|
}
|
|
678
|
-
n.en.relativeTime = u, s.fromToBase = function(
|
|
678
|
+
n.en.relativeTime = u, s.fromToBase = function(S, C, y, m, A) {
|
|
679
679
|
for (var T, d, M, I = y.$locale().relativeTime || u, b = r.thresholds || [{ l: "s", r: 44, d: "second" }, { l: "m", r: 89 }, { l: "mm", r: 44, d: "minute" }, { l: "h", r: 89 }, { l: "hh", r: 21, d: "hour" }, { l: "d", r: 35 }, { l: "dd", r: 25, d: "day" }, { l: "M", r: 45 }, { l: "MM", r: 10, d: "month" }, { l: "y", r: 17 }, { l: "yy", d: "year" }], _ = b.length, P = 0; P < _; P += 1) {
|
|
680
680
|
var E = b[P];
|
|
681
|
-
E.d && (T = m ? n(
|
|
681
|
+
E.d && (T = m ? n(S).diff(y, E.d, !0) : y.diff(S, E.d, !0));
|
|
682
682
|
var B = (r.rounding || Math.round)(Math.abs(T));
|
|
683
683
|
if (M = T > 0, B <= E.r || !E.r) {
|
|
684
684
|
B <= 1 && P > 0 && (E = b[P - 1]);
|
|
685
|
-
var
|
|
686
|
-
A && (B = A("" + B)), d = typeof
|
|
685
|
+
var K = I[E.l];
|
|
686
|
+
A && (B = A("" + B)), d = typeof K == "string" ? K.replace("%d", B) : K(B, C, E.l, M);
|
|
687
687
|
break;
|
|
688
688
|
}
|
|
689
689
|
}
|
|
690
690
|
if (C) return d;
|
|
691
|
-
var
|
|
692
|
-
return typeof
|
|
693
|
-
}, s.to = function(
|
|
694
|
-
return c(
|
|
695
|
-
}, s.from = function(
|
|
696
|
-
return c(
|
|
691
|
+
var F = M ? I.future : I.past;
|
|
692
|
+
return typeof F == "function" ? F(d) : F.replace("%s", d);
|
|
693
|
+
}, s.to = function(S, C) {
|
|
694
|
+
return c(S, C, this, !0);
|
|
695
|
+
}, s.from = function(S, C) {
|
|
696
|
+
return c(S, C, this);
|
|
697
697
|
};
|
|
698
|
-
var h = function(
|
|
699
|
-
return
|
|
698
|
+
var h = function(S) {
|
|
699
|
+
return S.$u ? n.utc() : n();
|
|
700
700
|
};
|
|
701
|
-
s.toNow = function(
|
|
702
|
-
return this.to(h(this),
|
|
703
|
-
}, s.fromNow = function(
|
|
704
|
-
return this.from(h(this),
|
|
701
|
+
s.toNow = function(S) {
|
|
702
|
+
return this.to(h(this), S);
|
|
703
|
+
}, s.fromNow = function(S) {
|
|
704
|
+
return this.from(h(this), S);
|
|
705
705
|
};
|
|
706
706
|
};
|
|
707
707
|
}));
|
|
@@ -725,13 +725,13 @@ function ar() {
|
|
|
725
725
|
return E || (E = new Intl.DateTimeFormat("en-US", { hour12: !1, timeZone: I, year: "numeric", month: "2-digit", day: "2-digit", hour: "2-digit", minute: "2-digit", second: "2-digit", timeZoneName: _ }), t[P] = E), E;
|
|
726
726
|
})(A, T);
|
|
727
727
|
return M.formatToParts(d);
|
|
728
|
-
},
|
|
728
|
+
}, S = function(m, A) {
|
|
729
729
|
for (var T = h(m, A), d = [], M = 0; M < T.length; M += 1) {
|
|
730
730
|
var I = T[M], b = I.type, _ = I.value, P = r[b];
|
|
731
731
|
P >= 0 && (d[P] = parseInt(_, 10));
|
|
732
732
|
}
|
|
733
|
-
var E = d[3], B = E === 24 ? 0 : E,
|
|
734
|
-
return (u.utc(
|
|
733
|
+
var E = d[3], B = E === 24 ? 0 : E, K = d[0] + "-" + d[1] + "-" + d[2] + " " + B + ":" + d[4] + ":" + d[5] + ":000", F = +m;
|
|
734
|
+
return (u.utc(K).valueOf() - (F -= F % 1e3)) / 6e4;
|
|
735
735
|
}, C = s.prototype;
|
|
736
736
|
C.tz = function(m, A) {
|
|
737
737
|
m === void 0 && (m = c);
|
|
@@ -754,12 +754,12 @@ function ar() {
|
|
|
754
754
|
var T = u(this.format("YYYY-MM-DD HH:mm:ss:SSS"), { locale: this.$L });
|
|
755
755
|
return y.call(T, m, A).tz(this.$x.$timezone, !0);
|
|
756
756
|
}, u.tz = function(m, A, T) {
|
|
757
|
-
var d = T && A, M = T || A || c, I =
|
|
757
|
+
var d = T && A, M = T || A || c, I = S(+u(), M);
|
|
758
758
|
if (typeof m != "string") return u(m).tz(M);
|
|
759
|
-
var b = (function(B,
|
|
760
|
-
var N = B - 60 *
|
|
761
|
-
if (
|
|
762
|
-
var O =
|
|
759
|
+
var b = (function(B, K, F) {
|
|
760
|
+
var N = B - 60 * K * 1e3, x = S(N, F);
|
|
761
|
+
if (K === x) return [N, K];
|
|
762
|
+
var O = S(N -= 60 * (x - K) * 1e3, F);
|
|
763
763
|
return x === O ? [N, x] : [B - 60 * Math.min(x, O) * 1e3, Math.max(x, O)];
|
|
764
764
|
})(u.utc(m, d).valueOf(), I, M), _ = b[0], P = b[1], E = u(_).utcOffset(P);
|
|
765
765
|
return E.$x.$timezone = M, E;
|
|
@@ -792,9 +792,9 @@ function lr() {
|
|
|
792
792
|
}, h.local = function() {
|
|
793
793
|
return c(this.toDate(), { locale: this.$L, utc: !1 });
|
|
794
794
|
};
|
|
795
|
-
var
|
|
795
|
+
var S = h.parse;
|
|
796
796
|
h.parse = function(d) {
|
|
797
|
-
d.utc && (this.$u = !0), this.$utils().u(d.$offset) || (this.$offset = d.$offset),
|
|
797
|
+
d.utc && (this.$u = !0), this.$utils().u(d.$offset) || (this.$offset = d.$offset), S.call(this, d);
|
|
798
798
|
};
|
|
799
799
|
var C = h.init;
|
|
800
800
|
h.init = function() {
|
|
@@ -811,8 +811,8 @@ function lr() {
|
|
|
811
811
|
E === void 0 && (E = "");
|
|
812
812
|
var B = E.match(t);
|
|
813
813
|
if (!B) return null;
|
|
814
|
-
var
|
|
815
|
-
return N === 0 ? 0 :
|
|
814
|
+
var K = ("" + B[0]).match(n) || ["-", 0, 0], F = K[0], N = 60 * +K[1] + +K[2];
|
|
815
|
+
return N === 0 ? 0 : F === "+" ? N : -N;
|
|
816
816
|
})(d), d === null)) return this;
|
|
817
817
|
var b = Math.abs(d) <= 16 ? 60 * d : d;
|
|
818
818
|
if (b === 0) return this.utc(M);
|
|
@@ -885,7 +885,7 @@ yr();
|
|
|
885
885
|
z.extend(Dt);
|
|
886
886
|
z.extend(xt);
|
|
887
887
|
z.extend(Ut);
|
|
888
|
-
z.extend(
|
|
888
|
+
z.extend(Kt);
|
|
889
889
|
z.extend(Zt);
|
|
890
890
|
z.extend(qt);
|
|
891
891
|
z.extend(er);
|
|
@@ -1004,7 +1004,7 @@ class re {
|
|
|
1004
1004
|
this.events[e](r);
|
|
1005
1005
|
}
|
|
1006
1006
|
async onRequest(e, r, t) {
|
|
1007
|
-
const n = w(e ?? {},
|
|
1007
|
+
const n = w(e ?? {}, v.Camel);
|
|
1008
1008
|
this.isActivePoller(t) && (this.isInProgress(n) && t.callCount && t.maxCallCount && t.callCount < t.maxCallCount || !this.isInProgress(n) && t.callCount && t.minCallCount && t.callCount < t.minCallCount ? (this.isInProgress(n) || (n.meta = n.meta || {}, n.meta.status = "IN_PROGRESS"), t.callCount += 1, this.dispatch("data", n), t.interval && await this.pause(t), this.poll(r, t)) : this.isInProgress(n) ? (n.meta = n.meta || {}, n.meta.status = "COMPLETE", this.onComplete(n, t)) : this.onComplete(n, t));
|
|
1009
1009
|
}
|
|
1010
1010
|
onComplete(e, r) {
|
|
@@ -1953,6 +1953,28 @@ const Jr = {
|
|
|
1953
1953
|
Booking: "PER_BOOKING"
|
|
1954
1954
|
};
|
|
1955
1955
|
class kr extends W {
|
|
1956
|
+
/**
|
|
1957
|
+
* Get Booking Policy
|
|
1958
|
+
*/
|
|
1959
|
+
async retrieveRaw(e, r) {
|
|
1960
|
+
if (e.id === null || e.id === void 0)
|
|
1961
|
+
throw new U("id", "Required parameter requestParameters.id was null or undefined when calling getV1BookingPolicy.");
|
|
1962
|
+
const t = {}, n = {};
|
|
1963
|
+
this.configuration && this.configuration.apiKey && (n["x-api-key"] = this.configuration.apiKey("x-api-key"));
|
|
1964
|
+
const s = await this.request({
|
|
1965
|
+
path: "/v1/booking_policies/{id}".replace("{id}", encodeURIComponent(String(e.id))),
|
|
1966
|
+
method: "GET",
|
|
1967
|
+
headers: n,
|
|
1968
|
+
query: w(t, v.Snake)
|
|
1969
|
+
}, r);
|
|
1970
|
+
return await new $(s, (u) => w(u, v.Camel)).value();
|
|
1971
|
+
}
|
|
1972
|
+
/**
|
|
1973
|
+
* Get Booking Policy
|
|
1974
|
+
*/
|
|
1975
|
+
async retrieve(e, r) {
|
|
1976
|
+
return this.retrieveRaw(e, r);
|
|
1977
|
+
}
|
|
1956
1978
|
/**
|
|
1957
1979
|
* In order to be able to create and confirm a booking against a specific **Hotel Room Offer** package, you need to make a booking policy call. Retrieving a booking policy returns additional information about the booking being made and includes details like cancellation policies. This API call is equivalent to an availability check and it is important not to let long periods between retrieval of this policy and the booking confirmation call itself as this will often reduce the likelihood of the **Hotel Room Offer** being successfully booked. The **booking_policy_id** returned is meant to be used to carry out a pre-book call via **[Pre Book endpoint](/v1/documentation#operation/postV1Bookings)** on the next **Booking Flow** step. ⚠️ This call may take from 1 second up to 15 seconds to return as we may request various suppliers to fulfill this request.
|
|
1958
1980
|
* Create Booking Policies
|
|
@@ -1964,10 +1986,10 @@ class kr extends W {
|
|
|
1964
1986
|
path: "/v1/booking_policies",
|
|
1965
1987
|
method: "POST",
|
|
1966
1988
|
headers: n,
|
|
1967
|
-
query: w(t,
|
|
1968
|
-
body: w(e.bookingPoliciesCreateApi,
|
|
1989
|
+
query: w(t, v.Snake),
|
|
1990
|
+
body: w(e.bookingPoliciesCreateApi, v.Snake)
|
|
1969
1991
|
}, r);
|
|
1970
|
-
return await new $(s, (u) => w(u,
|
|
1992
|
+
return await new $(s, (u) => w(u, v.Camel)).value();
|
|
1971
1993
|
}
|
|
1972
1994
|
/**
|
|
1973
1995
|
* In order to be able to create and confirm a booking against a specific **Hotel Room Offer** package, you need to make a booking policy call. Retrieving a booking policy returns additional information about the booking being made and includes details like cancellation policies. This API call is equivalent to an availability check and it is important not to let long periods between retrieval of this policy and the booking confirmation call itself as this will often reduce the likelihood of the **Hotel Room Offer** being successfully booked. The **booking_policy_id** returned is meant to be used to carry out a pre-book call via **[Pre Book endpoint](/v1/documentation#operation/postV1Bookings)** on the next **Booking Flow** step. ⚠️ This call may take from 1 second up to 15 seconds to return as we may request various suppliers to fulfill this request.
|
|
@@ -1989,9 +2011,9 @@ class _r extends W {
|
|
|
1989
2011
|
path: "/v1/bookings/{token}".replace("{token}", encodeURIComponent(String(e.token))),
|
|
1990
2012
|
method: "DELETE",
|
|
1991
2013
|
headers: n,
|
|
1992
|
-
query: w(t,
|
|
2014
|
+
query: w(t, v.Snake)
|
|
1993
2015
|
}, r);
|
|
1994
|
-
return await new $(s, (u) => w(u,
|
|
2016
|
+
return await new $(s, (u) => w(u, v.Camel)).value();
|
|
1995
2017
|
}
|
|
1996
2018
|
/**
|
|
1997
2019
|
* Cancel a confirmed Booking. A booking can only be cancelled if it\'s in one of the following status: **bkg-cf**, **bkg-pc**.
|
|
@@ -2013,9 +2035,9 @@ class _r extends W {
|
|
|
2013
2035
|
path: "/v1/bookings",
|
|
2014
2036
|
method: "GET",
|
|
2015
2037
|
headers: n,
|
|
2016
|
-
query: w(t,
|
|
2038
|
+
query: w(t, v.Snake)
|
|
2017
2039
|
}, r);
|
|
2018
|
-
return await new $(s, (u) => w(u,
|
|
2040
|
+
return await new $(s, (u) => w(u, v.Camel)).value();
|
|
2019
2041
|
}
|
|
2020
2042
|
/**
|
|
2021
2043
|
* Returns a list of detailed bookings made on behalf of a specific API Key credential.
|
|
@@ -2037,9 +2059,9 @@ class _r extends W {
|
|
|
2037
2059
|
path: "/v1/bookings/{id}".replace("{id}", encodeURIComponent(String(e.id))),
|
|
2038
2060
|
method: "GET",
|
|
2039
2061
|
headers: n,
|
|
2040
|
-
query: w(t,
|
|
2062
|
+
query: w(t, v.Snake)
|
|
2041
2063
|
}, r);
|
|
2042
|
-
return await new $(s, (u) => w(u,
|
|
2064
|
+
return await new $(s, (u) => w(u, v.Camel)).value();
|
|
2043
2065
|
}
|
|
2044
2066
|
/**
|
|
2045
2067
|
* Retrieve the status and information of a booking.
|
|
@@ -2059,9 +2081,9 @@ class _r extends W {
|
|
|
2059
2081
|
path: "/v1/bookings/{token}/public".replace("{token}", encodeURIComponent(String(e.token))),
|
|
2060
2082
|
method: "GET",
|
|
2061
2083
|
headers: n,
|
|
2062
|
-
query: w(t,
|
|
2084
|
+
query: w(t, v.Snake)
|
|
2063
2085
|
}, r);
|
|
2064
|
-
return await new $(s, (u) => w(u,
|
|
2086
|
+
return await new $(s, (u) => w(u, v.Camel)).value();
|
|
2065
2087
|
}
|
|
2066
2088
|
/**
|
|
2067
2089
|
* Retrieve the status and information of a booking based on a valid token. This endpoint is public and does not require a secret API key.
|
|
@@ -2081,10 +2103,10 @@ class _r extends W {
|
|
|
2081
2103
|
path: "/v1/bookings",
|
|
2082
2104
|
method: "POST",
|
|
2083
2105
|
headers: n,
|
|
2084
|
-
query: w(t,
|
|
2085
|
-
body: w(e.bookingCreateApi,
|
|
2106
|
+
query: w(t, v.Snake),
|
|
2107
|
+
body: w(e.bookingCreateApi, v.Snake)
|
|
2086
2108
|
}, r);
|
|
2087
|
-
return await new $(s, (u) => w(u,
|
|
2109
|
+
return await new $(s, (u) => w(u, v.Camel)).value();
|
|
2088
2110
|
}
|
|
2089
2111
|
/**
|
|
2090
2112
|
* Creates an unconfirmed booking
|
|
@@ -2108,9 +2130,9 @@ class _r extends W {
|
|
|
2108
2130
|
path: "/v1/bookings/{id}/coupons/{coupon_id}/charge".replace("{coupon_id}", encodeURIComponent(String(e.couponId))).replace("{id}", encodeURIComponent(String(e.id))),
|
|
2109
2131
|
method: "POST",
|
|
2110
2132
|
headers: n,
|
|
2111
|
-
query: w(t,
|
|
2133
|
+
query: w(t, v.Snake)
|
|
2112
2134
|
}, r);
|
|
2113
|
-
return await new $(s, (u) => w(u,
|
|
2135
|
+
return await new $(s, (u) => w(u, v.Camel)).value();
|
|
2114
2136
|
}
|
|
2115
2137
|
/**
|
|
2116
2138
|
* Confirm booking from Coupon payment method
|
|
@@ -2132,9 +2154,9 @@ class _r extends W {
|
|
|
2132
2154
|
path: "/v1/bookings/{id}/pay-later".replace("{id}", encodeURIComponent(String(e.id))),
|
|
2133
2155
|
method: "POST",
|
|
2134
2156
|
headers: n,
|
|
2135
|
-
query: w(t,
|
|
2157
|
+
query: w(t, v.Snake)
|
|
2136
2158
|
}, r);
|
|
2137
|
-
return await new $(s, (u) => w(u,
|
|
2159
|
+
return await new $(s, (u) => w(u, v.Camel)).value();
|
|
2138
2160
|
}
|
|
2139
2161
|
/**
|
|
2140
2162
|
* Pay later and retrieve the status and information of a booking.
|
|
@@ -2156,9 +2178,9 @@ class _r extends W {
|
|
|
2156
2178
|
path: "/v1/bookings/{id}/pay-later/confirm".replace("{id}", encodeURIComponent(String(e.id))),
|
|
2157
2179
|
method: "POST",
|
|
2158
2180
|
headers: n,
|
|
2159
|
-
query: w(t,
|
|
2181
|
+
query: w(t, v.Snake)
|
|
2160
2182
|
}, r);
|
|
2161
|
-
return await new $(s, (u) => w(u,
|
|
2183
|
+
return await new $(s, (u) => w(u, v.Camel)).value();
|
|
2162
2184
|
}
|
|
2163
2185
|
/**
|
|
2164
2186
|
* Confirm later paid and retrieve the status and information of a booking.
|
|
@@ -2180,9 +2202,9 @@ class _r extends W {
|
|
|
2180
2202
|
path: "/v1/bookings/{id}/confirm".replace("{id}", encodeURIComponent(String(e.id))),
|
|
2181
2203
|
method: "POST",
|
|
2182
2204
|
headers: n,
|
|
2183
|
-
query: w(t,
|
|
2205
|
+
query: w(t, v.Snake)
|
|
2184
2206
|
}, r);
|
|
2185
|
-
return await new $(s, (u) => w(u,
|
|
2207
|
+
return await new $(s, (u) => w(u, v.Camel)).value();
|
|
2186
2208
|
}
|
|
2187
2209
|
/**
|
|
2188
2210
|
* Trigger the actual booking confirmation process. 💡 This endpoint is only available for Bookings in the **bkg-created** status. ⚠️ The booking confirmation is an asynchronous process. The booking won\'t transition immediatly to **bkg-cf** status. Rather, the endpoint will return a booking in **bkg-ip** and you\'ll be required to check booking status calling **[Get Booking endpoint](/v1/documentation#operation/getV1BookingsId)**, ideally with a polling mechanism, and perform further action(s), whether you need to let your customer know about their booking or you just need to update some data on your system, when booking status transitions to **bkg-cf** (confirmed) or **bkg-af** (fail). ⚠️ Once you have called this endpoint, we immediatly send your confirmation request to our supplier(s) and they may confirm it immediatly, so you\'ll be liable for up to the total booking tax included price amount if you need to cancel it at a later time (refer to the booking\'s cancellation policies to get the actual current penalty percentage applied in case of cancellation).
|
|
@@ -2204,10 +2226,10 @@ class _r extends W {
|
|
|
2204
2226
|
path: "/v1/bookings/{id}/payment_methods".replace("{id}", encodeURIComponent(String(e.id))),
|
|
2205
2227
|
method: "PUT",
|
|
2206
2228
|
headers: n,
|
|
2207
|
-
query: w(t,
|
|
2208
|
-
body: w(e.paymentMethodUpdatePayloadApi,
|
|
2229
|
+
query: w(t, v.Snake),
|
|
2230
|
+
body: w(e.paymentMethodUpdatePayloadApi, v.Snake)
|
|
2209
2231
|
}, r);
|
|
2210
|
-
return await new $(s, (u) => w(u,
|
|
2232
|
+
return await new $(s, (u) => w(u, v.Camel)).value();
|
|
2211
2233
|
}
|
|
2212
2234
|
/**
|
|
2213
2235
|
* Updates an ongoing Booking payment methods
|
|
@@ -2241,9 +2263,9 @@ class Dr extends W {
|
|
|
2241
2263
|
path: "/v1/hotels/{id}/images".replace("{id}", encodeURIComponent(String(e.id))),
|
|
2242
2264
|
method: "GET",
|
|
2243
2265
|
headers: n,
|
|
2244
|
-
query: w(t,
|
|
2266
|
+
query: w(t, v.Snake)
|
|
2245
2267
|
}, r);
|
|
2246
|
-
return new $(s, (u) => w(u,
|
|
2268
|
+
return new $(s, (u) => w(u, v.Camel)).value();
|
|
2247
2269
|
}
|
|
2248
2270
|
/**
|
|
2249
2271
|
* Returns a list of images for an Hotel Id with their content localize into the requested **lang**.
|
|
@@ -2276,9 +2298,9 @@ class br extends W {
|
|
|
2276
2298
|
path: "/v1/hotel_offer_requests/{id}".replace("{id}", encodeURIComponent(String(e.id))),
|
|
2277
2299
|
method: "GET",
|
|
2278
2300
|
headers: n,
|
|
2279
|
-
query: w(t,
|
|
2301
|
+
query: w(t, v.Snake)
|
|
2280
2302
|
}, r);
|
|
2281
|
-
return await new $(s, (u) => w(u,
|
|
2303
|
+
return await new $(s, (u) => w(u, v.Camel)).value();
|
|
2282
2304
|
}
|
|
2283
2305
|
/**
|
|
2284
2306
|
* Returns a single Hotel Offer Request by id
|
|
@@ -2298,10 +2320,10 @@ class br extends W {
|
|
|
2298
2320
|
path: "/v1/hotel_offer_requests",
|
|
2299
2321
|
method: "POST",
|
|
2300
2322
|
headers: n,
|
|
2301
|
-
query: w(t,
|
|
2302
|
-
body: w(e.hotelOfferRequestCreateApi,
|
|
2323
|
+
query: w(t, v.Snake),
|
|
2324
|
+
body: w(e.hotelOfferRequestCreateApi, v.Snake)
|
|
2303
2325
|
}, r);
|
|
2304
|
-
return await new $(s, (u) => w(u,
|
|
2326
|
+
return await new $(s, (u) => w(u, v.Camel)).value();
|
|
2305
2327
|
}
|
|
2306
2328
|
/**
|
|
2307
2329
|
* Create an **Hotel Offer Request**. An **Hotel Offer Request** describes the guests (adult and child count), the ideal room count, when they want to check in and check out and obviously the location around which they need their accommodation to be (latitude/longitude pair).
|
|
@@ -2329,9 +2351,9 @@ class Ir extends W {
|
|
|
2329
2351
|
path: "/v1/hotel_offers",
|
|
2330
2352
|
method: "GET",
|
|
2331
2353
|
headers: n,
|
|
2332
|
-
query: w(t,
|
|
2354
|
+
query: w(t, v.Snake)
|
|
2333
2355
|
}, r);
|
|
2334
|
-
return await new $(s, (u) => w(u,
|
|
2356
|
+
return await new $(s, (u) => w(u, v.Camel)).value();
|
|
2335
2357
|
}
|
|
2336
2358
|
/**
|
|
2337
2359
|
* You\'ll then make a call to the **Hotel Offers** endpoint to retrieve a list of **Hotel Offers** associated with your **Hotel Offer Request**. We\'ll send your search to a pool of hotels matching the search parameters you provided previously. The **Hotel Offers** endpoint will return hotels with available rates as **Hotel Room Offers** objects for each hotel in the list. For a detailed overview of the **Hotel Room Offer** object, see **[Retrieve Hotel Room Offers](/v1/documentation#operation/getV1Hotel_room_offers)** endpoint. ⚠️ **IMPORTANT**: The **Hotel Room Offers** included in each **Hotel Offer** returned by the **[Retrieve Hotel Offers](/v1/documentation#operation/getV1Hotel_offers)** endpoint might be **<span style=\"color:red\">cached data</span>**. In that case, the returned prices/availability may be slightly different from actual live inventory. In order to retrieve accurate and live **Hotel Room Offers** for a specific hotel you need to make a call to the **[Retrieve Hotel Room Offers](/v1/documentation#operation/getV1Hotel_room_offers)** endpoint. We do not recommend to systematically call **[Retrieve Hotel Room Offers](/v1/documentation#operation/getV1Hotel_room_offers)** for each hotel offer retrieved as it may trigger rate limiting on your API calls. Rather we recommend to do this as an explicit two-step process: first you check **Hotel Offers** around a location, then, once your customer shows interest in a specific **Hotel Offer**, you check **Hotel Room Offers** on that specific hotel. This endpoint requires ⚛️ **[Polling](/v1/documentation#tag/Polling)**.
|
|
@@ -2377,9 +2399,9 @@ class Br extends W {
|
|
|
2377
2399
|
path: "/v1/hotel_room_offer_requests/{id}".replace("{id}", encodeURIComponent(String(e.id))),
|
|
2378
2400
|
method: "GET",
|
|
2379
2401
|
headers: n,
|
|
2380
|
-
query: w(t,
|
|
2402
|
+
query: w(t, v.Snake)
|
|
2381
2403
|
}, r);
|
|
2382
|
-
return await new $(s, (u) => w(u,
|
|
2404
|
+
return await new $(s, (u) => w(u, v.Camel)).value();
|
|
2383
2405
|
}
|
|
2384
2406
|
/**
|
|
2385
2407
|
* Returns a single Hotel Room Offer Request by id
|
|
@@ -2399,10 +2421,10 @@ class Br extends W {
|
|
|
2399
2421
|
path: "/v1/hotel_room_offer_requests",
|
|
2400
2422
|
method: "POST",
|
|
2401
2423
|
headers: n,
|
|
2402
|
-
query: w(t,
|
|
2403
|
-
body: w(e.hotelRoomOfferRequestCreateApi,
|
|
2424
|
+
query: w(t, v.Snake),
|
|
2425
|
+
body: w(e.hotelRoomOfferRequestCreateApi, v.Snake)
|
|
2404
2426
|
}, r);
|
|
2405
|
-
return await new $(s, (u) => w(u,
|
|
2427
|
+
return await new $(s, (u) => w(u, v.Camel)).value();
|
|
2406
2428
|
}
|
|
2407
2429
|
/**
|
|
2408
2430
|
* To check available rates, or **Hotel Room Offers**, at a specific hotel, you first need to create an **Hotel Room Offer Request**. An **Hotel Room Offer Request** describes the guests (adult and child count), the ideal room count, when they want to check in and check out and the id of the hotel you want to check available rates at.
|
|
@@ -2430,9 +2452,9 @@ class xr extends W {
|
|
|
2430
2452
|
path: "/v1/hotel_room_offers",
|
|
2431
2453
|
method: "GET",
|
|
2432
2454
|
headers: n,
|
|
2433
|
-
query: w(t,
|
|
2455
|
+
query: w(t, v.Snake)
|
|
2434
2456
|
}, r);
|
|
2435
|
-
return await new $(s, (u) => w(u,
|
|
2457
|
+
return await new $(s, (u) => w(u, v.Camel)).value();
|
|
2436
2458
|
}
|
|
2437
2459
|
/**
|
|
2438
2460
|
* You\'ll make a call to the **Hotel Room Offers** endpoint in order to get a list of **Hotel Room Offers** resulting from your **Hotel Room Offer Request** parameters. We\'ll send your rate check request to the specific hotel matching the hotel ID you provided previously and the **Hotel Room Offers** endpoint will return the available rates at this specific hotel. An **Hotel Room Offer** describes hotel rooms: prices, remaining count available (when applicable), details about the room itself (e.g., beds, etc) and other information you\'ll find below. ⚠️ **Cancellation Policies** attached to each **Hotel Room Offer** returned by this endpoint will most likely be **<span style=\"color:red\">cached data</span>** and should not be considered as accurate, although in most case they will reflect the actual/live ones. In order to retrieve accurate and live **Cancellation Policies** for a specific **Hotel Room Offer** you need to make a call to the **[Create Booking Policies endpoint](/v1/documentation#operation/postV1Booking_policies)**. However, we do not recommend to systematically call **[Create Booking Policies endpoint](/v1/documentation#operation/postV1Booking_policies)** for each **Hotel Room Offer** retrieved as it will most likely trigger rate limiting on your API calls. Rather we recommend to do this as an explicit two-step process: first you check **Hotel Room Offers**, then, once your customer shows interest in a specific **Hotel Room Offer**, you make the call to the **[Create Booking Policies endpoint](/v1/documentation#operation/postV1Booking_policies)** on behalf of your customer. This endpoint requires ⚛️ **[Polling](/v1/documentation#tag/Polling)**.
|
|
@@ -2456,10 +2478,10 @@ class xr extends W {
|
|
|
2456
2478
|
path: "/v1/hotel_room_offers",
|
|
2457
2479
|
method: "POST",
|
|
2458
2480
|
headers: n,
|
|
2459
|
-
query: w(t,
|
|
2460
|
-
body: w(e.hotelRoomOffersCreateApi,
|
|
2481
|
+
query: w(t, v.Snake),
|
|
2482
|
+
body: w(e.hotelRoomOffersCreateApi, v.Snake)
|
|
2461
2483
|
}, r);
|
|
2462
|
-
return await new $(s, (u) => w(u,
|
|
2484
|
+
return await new $(s, (u) => w(u, v.Camel)).value();
|
|
2463
2485
|
}
|
|
2464
2486
|
/**
|
|
2465
2487
|
* This enpoint creates a new **Hotel Room Offer** based on previously fetched **Hotel Room Offer(s)** and may be used for the following purposes: - Check a specific **Hotel Room Offer** live availability - Create a new **Hotel Room Offer** with **type = \"PACKAGE\"** based on multiple **Hotel Room Offers** where **type = \"HOTEL_ROOM\"** and be able to call **[Create Booking Policies endpoint](/v1/documentation#operation/postV1Booking_policies)** with it - Update an existing **Hotel Room Offer** with **type = \"PACKAGE\"** in order to include extra option(s) like breakfast in the returned price. We strongly recommend to make use of this endpoint if you want to offer some kind of Shopping Cart experience to your customer when **[Retrieve HotelRoom Offers endpoint](/v1/documentation#operation/getV1Hotel_room_offers)** returns multiple **Hotel Room Offers** with **type = \"HOTEL_ROOM\"**.
|
|
@@ -2492,7 +2514,7 @@ class Lr extends W {
|
|
|
2492
2514
|
path: "/v1/hotel_rooming_list_guests/{token}/{id}".replace("{id}", encodeURIComponent(String(e.id))).replace("{token}", encodeURIComponent(String(e.token))),
|
|
2493
2515
|
method: "DELETE",
|
|
2494
2516
|
headers: n,
|
|
2495
|
-
query: w(t,
|
|
2517
|
+
query: w(t, v.Snake)
|
|
2496
2518
|
}, r);
|
|
2497
2519
|
return new Or(s);
|
|
2498
2520
|
}
|
|
@@ -2518,10 +2540,10 @@ class Lr extends W {
|
|
|
2518
2540
|
path: "/v1/hotel_rooming_list_guests/{token}/{id}".replace("{id}", encodeURIComponent(String(e.id))).replace("{token}", encodeURIComponent(String(e.token))),
|
|
2519
2541
|
method: "PATCH",
|
|
2520
2542
|
headers: n,
|
|
2521
|
-
query: w(t,
|
|
2522
|
-
body: w(e.hotelRoomingListGuestsUpdateApi,
|
|
2543
|
+
query: w(t, v.Snake),
|
|
2544
|
+
body: w(e.hotelRoomingListGuestsUpdateApi, v.Snake)
|
|
2523
2545
|
}, r);
|
|
2524
|
-
return await new $(s, (u) => w(u,
|
|
2546
|
+
return await new $(s, (u) => w(u, v.Camel)).value();
|
|
2525
2547
|
}
|
|
2526
2548
|
/**
|
|
2527
2549
|
* Update a hotel rooming list guest from a booking based on a valid token. This endpoint is public and does not require a secret API key.
|
|
@@ -2543,10 +2565,10 @@ class Lr extends W {
|
|
|
2543
2565
|
path: "/v1/hotel_rooming_list_guests/{token}".replace("{token}", encodeURIComponent(String(e.token))),
|
|
2544
2566
|
method: "POST",
|
|
2545
2567
|
headers: n,
|
|
2546
|
-
query: w(t,
|
|
2547
|
-
body: w(e.hotelRoomingListGuestsCreateApi,
|
|
2568
|
+
query: w(t, v.Snake),
|
|
2569
|
+
body: w(e.hotelRoomingListGuestsCreateApi, v.Snake)
|
|
2548
2570
|
}, r);
|
|
2549
|
-
return await new $(s, (u) => w(u,
|
|
2571
|
+
return await new $(s, (u) => w(u, v.Camel)).value();
|
|
2550
2572
|
}
|
|
2551
2573
|
/**
|
|
2552
2574
|
* Create a new hotel rooming list guest to a booking based on a valid token. This endpoint is public and does not require a secret API key.
|
|
@@ -2570,9 +2592,9 @@ class Pr extends W {
|
|
|
2570
2592
|
path: "/v1/hotel_rooming_lists/{token}".replace("{token}", encodeURIComponent(String(e.token))),
|
|
2571
2593
|
method: "GET",
|
|
2572
2594
|
headers: n,
|
|
2573
|
-
query: w(t,
|
|
2595
|
+
query: w(t, v.Snake)
|
|
2574
2596
|
}, r);
|
|
2575
|
-
return new $(s, (u) => w(u,
|
|
2597
|
+
return new $(s, (u) => w(u, v.Camel)).value();
|
|
2576
2598
|
}
|
|
2577
2599
|
/**
|
|
2578
2600
|
* Get Hotel Rooming Lists of a booking. This endpoint is public and does not require a secret API key.
|
|
@@ -2607,9 +2629,9 @@ class $r extends W {
|
|
|
2607
2629
|
path: "/v1/hotels/{id}".replace("{id}", encodeURIComponent(String(e.id))),
|
|
2608
2630
|
method: "GET",
|
|
2609
2631
|
headers: n,
|
|
2610
|
-
query: w(t,
|
|
2632
|
+
query: w(t, v.Snake)
|
|
2611
2633
|
}, r);
|
|
2612
|
-
return await new $(s, (u) => w(u,
|
|
2634
|
+
return await new $(s, (u) => w(u, v.Camel)).value();
|
|
2613
2635
|
}
|
|
2614
2636
|
/**
|
|
2615
2637
|
* Returns a single Hotel by id with their content localize into the requested **lang**.
|
|
@@ -2653,7 +2675,7 @@ function Ur() {
|
|
|
2653
2675
|
formData: "FormData" in c,
|
|
2654
2676
|
arrayBuffer: "ArrayBuffer" in c
|
|
2655
2677
|
};
|
|
2656
|
-
function
|
|
2678
|
+
function S(o) {
|
|
2657
2679
|
return o && DataView.prototype.isPrototypeOf(o);
|
|
2658
2680
|
}
|
|
2659
2681
|
if (h.arrayBuffer)
|
|
@@ -2768,7 +2790,7 @@ function Ur() {
|
|
|
2768
2790
|
}
|
|
2769
2791
|
function B() {
|
|
2770
2792
|
return this.bodyUsed = !1, this._initBody = function(o) {
|
|
2771
|
-
this.bodyUsed = this.bodyUsed, this._bodyInit = o, o ? typeof o == "string" ? this._bodyText = o : h.blob && Blob.prototype.isPrototypeOf(o) ? this._bodyBlob = o : h.formData && FormData.prototype.isPrototypeOf(o) ? this._bodyFormData = o : h.searchParams && URLSearchParams.prototype.isPrototypeOf(o) ? this._bodyText = o.toString() : h.arrayBuffer && h.blob &&
|
|
2793
|
+
this.bodyUsed = this.bodyUsed, this._bodyInit = o, o ? typeof o == "string" ? this._bodyText = o : h.blob && Blob.prototype.isPrototypeOf(o) ? this._bodyBlob = o : h.formData && FormData.prototype.isPrototypeOf(o) ? this._bodyFormData = o : h.searchParams && URLSearchParams.prototype.isPrototypeOf(o) ? this._bodyText = o.toString() : h.arrayBuffer && h.blob && S(o) ? (this._bodyArrayBuffer = E(o.buffer), this._bodyInit = new Blob([this._bodyArrayBuffer])) : h.arrayBuffer && (ArrayBuffer.prototype.isPrototypeOf(o) || y(o)) ? this._bodyArrayBuffer = E(o) : this._bodyText = o = Object.prototype.toString.call(o) : (this._noBody = !0, this._bodyText = ""), this.headers.get("content-type") || (typeof o == "string" ? this.headers.set("content-type", "text/plain;charset=UTF-8") : this._bodyBlob && this._bodyBlob.type ? this.headers.set("content-type", this._bodyBlob.type) : h.searchParams && URLSearchParams.prototype.isPrototypeOf(o) && this.headers.set("content-type", "application/x-www-form-urlencoded;charset=UTF-8"));
|
|
2772
2794
|
}, h.blob && (this.blob = function() {
|
|
2773
2795
|
var o = M(this);
|
|
2774
2796
|
if (o)
|
|
@@ -2811,10 +2833,10 @@ function Ur() {
|
|
|
2811
2833
|
return this.text().then(JSON.parse);
|
|
2812
2834
|
}, this;
|
|
2813
2835
|
}
|
|
2814
|
-
var
|
|
2815
|
-
function
|
|
2836
|
+
var K = ["CONNECT", "DELETE", "GET", "HEAD", "OPTIONS", "PATCH", "POST", "PUT", "TRACE"];
|
|
2837
|
+
function F(o) {
|
|
2816
2838
|
var a = o.toUpperCase();
|
|
2817
|
-
return
|
|
2839
|
+
return K.indexOf(a) > -1 ? a : o;
|
|
2818
2840
|
}
|
|
2819
2841
|
function N(o, a) {
|
|
2820
2842
|
if (!(this instanceof N))
|
|
@@ -2827,7 +2849,7 @@ function Ur() {
|
|
|
2827
2849
|
this.url = o.url, this.credentials = o.credentials, a.headers || (this.headers = new d(o.headers)), this.method = o.method, this.mode = o.mode, this.signal = o.signal, !f && o._bodyInit != null && (f = o._bodyInit, o.bodyUsed = !0);
|
|
2828
2850
|
} else
|
|
2829
2851
|
this.url = String(o);
|
|
2830
|
-
if (this.credentials = a.credentials || this.credentials || "same-origin", (a.headers || !this.headers) && (this.headers = new d(a.headers)), this.method =
|
|
2852
|
+
if (this.credentials = a.credentials || this.credentials || "same-origin", (a.headers || !this.headers) && (this.headers = new d(a.headers)), this.method = F(a.method || this.method || "GET"), this.mode = a.mode || this.mode || null, this.signal = a.signal || this.signal || (function() {
|
|
2831
2853
|
if ("AbortController" in c) {
|
|
2832
2854
|
var p = new AbortController();
|
|
2833
2855
|
return p.signal;
|
|
@@ -2982,7 +3004,7 @@ const Gr = /* @__PURE__ */ j(Nr), Hr = (i) => ({
|
|
|
2982
3004
|
hotelRoomingLists: new Pr(i),
|
|
2983
3005
|
hotels: new $r(i)
|
|
2984
3006
|
});
|
|
2985
|
-
function
|
|
3007
|
+
function Kr(i) {
|
|
2986
3008
|
switch (i) {
|
|
2987
3009
|
case ee.Production:
|
|
2988
3010
|
return "AUTH_TOKEN";
|
|
@@ -3001,10 +3023,10 @@ function Fr(i) {
|
|
|
3001
3023
|
}
|
|
3002
3024
|
function at(i) {
|
|
3003
3025
|
return !!(typeof document < "u" && document?.cookie && document.cookie.split(";").find(
|
|
3004
|
-
(t) => t.includes(
|
|
3026
|
+
(t) => t.includes(Kr(i))
|
|
3005
3027
|
));
|
|
3006
3028
|
}
|
|
3007
|
-
class
|
|
3029
|
+
class Fr {
|
|
3008
3030
|
constructor(e) {
|
|
3009
3031
|
this.config = e;
|
|
3010
3032
|
}
|
|
@@ -3048,7 +3070,7 @@ class _n {
|
|
|
3048
3070
|
fetchApi: Gr,
|
|
3049
3071
|
headers: r,
|
|
3050
3072
|
middleware: [
|
|
3051
|
-
new
|
|
3073
|
+
new Fr(this.config),
|
|
3052
3074
|
new Yr(this.config)
|
|
3053
3075
|
]
|
|
3054
3076
|
});
|