@gojinko/api-client 2.14.0 → 2.16.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/README.md +31 -7
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/tools.d.ts +23 -4
- package/dist/tools.d.ts.map +1 -1
- package/dist/tools.js +26 -0
- package/dist/tools.js.map +1 -1
- package/dist/types/devplatform.d.ts +43 -7
- package/dist/types/devplatform.d.ts.map +1 -1
- package/dist/types/devplatform.js +1 -1
- package/dist/types/generated.d.ts +651 -20
- package/dist/types/generated.d.ts.map +1 -1
- package/package.json +1 -1
- package/public-api.yaml +544 -38
|
@@ -3,6 +3,232 @@
|
|
|
3
3
|
* Do not make direct changes to the file.
|
|
4
4
|
*/
|
|
5
5
|
export interface paths {
|
|
6
|
+
"/v1/destination": {
|
|
7
|
+
parameters: {
|
|
8
|
+
query?: never;
|
|
9
|
+
header?: never;
|
|
10
|
+
path?: never;
|
|
11
|
+
cookie?: never;
|
|
12
|
+
};
|
|
13
|
+
/**
|
|
14
|
+
* Top destinations by search demand
|
|
15
|
+
* @description Most-searched destinations by de-sampled request share. `destination` is optional (omit to rank all destinations); set `origin_market` to scope to one source market.
|
|
16
|
+
*/
|
|
17
|
+
get: {
|
|
18
|
+
parameters: {
|
|
19
|
+
query: {
|
|
20
|
+
/** @description Analysis mode. `trend` is accepted but currently returns snapshot-shaped data. */
|
|
21
|
+
analysis: components["parameters"]["analysis"];
|
|
22
|
+
/** @description Origin market filter as <Level>:<Code>, e.g. Country:US or City:NYC. */
|
|
23
|
+
origin_market?: components["parameters"]["originMarket"];
|
|
24
|
+
/** @description Optional destination filter as <Level>:<Code>, e.g. Country:TH. */
|
|
25
|
+
destination?: components["parameters"]["destinationFilter"];
|
|
26
|
+
/** @description Named departure window (defaults to Next90Days server-side). */
|
|
27
|
+
travel_period?: components["parameters"]["travelPeriod"];
|
|
28
|
+
/** @description Start of departure window (YYYY-MM-DD). Required when travel_period=Custom. */
|
|
29
|
+
departure_date_from?: components["parameters"]["departureDateFrom"];
|
|
30
|
+
/** @description End of departure window (YYYY-MM-DD). Required when travel_period=Custom. */
|
|
31
|
+
departure_date_to?: components["parameters"]["departureDateTo"];
|
|
32
|
+
/** @description Optional traveler-type filter. */
|
|
33
|
+
traveler_type?: components["parameters"]["travelerType"];
|
|
34
|
+
/** @description Optional trip-type filter. */
|
|
35
|
+
trip_type?: components["parameters"]["tripType"];
|
|
36
|
+
/** @description Max rows (1-200, default 20). */
|
|
37
|
+
limit?: components["parameters"]["limit"];
|
|
38
|
+
};
|
|
39
|
+
header?: never;
|
|
40
|
+
path?: never;
|
|
41
|
+
cookie?: never;
|
|
42
|
+
};
|
|
43
|
+
requestBody?: never;
|
|
44
|
+
responses: {
|
|
45
|
+
/** @description OK */
|
|
46
|
+
200: {
|
|
47
|
+
headers: {
|
|
48
|
+
[name: string]: unknown;
|
|
49
|
+
};
|
|
50
|
+
content: {
|
|
51
|
+
"application/json": components["schemas"]["DestinationResponse"];
|
|
52
|
+
};
|
|
53
|
+
};
|
|
54
|
+
/** @description Authentication required */
|
|
55
|
+
401: {
|
|
56
|
+
headers: {
|
|
57
|
+
[name: string]: unknown;
|
|
58
|
+
};
|
|
59
|
+
content: {
|
|
60
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
61
|
+
};
|
|
62
|
+
};
|
|
63
|
+
/** @description Validation error */
|
|
64
|
+
422: {
|
|
65
|
+
headers: {
|
|
66
|
+
[name: string]: unknown;
|
|
67
|
+
};
|
|
68
|
+
content: {
|
|
69
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
70
|
+
};
|
|
71
|
+
};
|
|
72
|
+
};
|
|
73
|
+
};
|
|
74
|
+
put?: never;
|
|
75
|
+
post?: never;
|
|
76
|
+
delete?: never;
|
|
77
|
+
options?: never;
|
|
78
|
+
head?: never;
|
|
79
|
+
patch?: never;
|
|
80
|
+
trace?: never;
|
|
81
|
+
};
|
|
82
|
+
"/v1/market": {
|
|
83
|
+
parameters: {
|
|
84
|
+
query?: never;
|
|
85
|
+
header?: never;
|
|
86
|
+
path?: never;
|
|
87
|
+
cookie?: never;
|
|
88
|
+
};
|
|
89
|
+
/**
|
|
90
|
+
* Top source markets for a destination
|
|
91
|
+
* @description Which source markets generate the most demand for a given destination.
|
|
92
|
+
*/
|
|
93
|
+
get: {
|
|
94
|
+
parameters: {
|
|
95
|
+
query: {
|
|
96
|
+
/** @description Analysis mode. `trend` is accepted but currently returns snapshot-shaped data. */
|
|
97
|
+
analysis: components["parameters"]["analysis"];
|
|
98
|
+
/** @description Destination as <Level>:<Code>, e.g. Country:TH. Required for this endpoint. */
|
|
99
|
+
destination: components["parameters"]["destinationRequired"];
|
|
100
|
+
/** @description Origin market filter as <Level>:<Code>, e.g. Country:US or City:NYC. */
|
|
101
|
+
origin_market?: components["parameters"]["originMarket"];
|
|
102
|
+
/** @description Named departure window (defaults to Next90Days server-side). */
|
|
103
|
+
travel_period?: components["parameters"]["travelPeriod"];
|
|
104
|
+
/** @description Start of departure window (YYYY-MM-DD). Required when travel_period=Custom. */
|
|
105
|
+
departure_date_from?: components["parameters"]["departureDateFrom"];
|
|
106
|
+
/** @description End of departure window (YYYY-MM-DD). Required when travel_period=Custom. */
|
|
107
|
+
departure_date_to?: components["parameters"]["departureDateTo"];
|
|
108
|
+
/** @description Optional traveler-type filter. */
|
|
109
|
+
traveler_type?: components["parameters"]["travelerType"];
|
|
110
|
+
/** @description Optional trip-type filter. */
|
|
111
|
+
trip_type?: components["parameters"]["tripType"];
|
|
112
|
+
/** @description Max rows (1-200, default 20). */
|
|
113
|
+
limit?: components["parameters"]["limit"];
|
|
114
|
+
};
|
|
115
|
+
header?: never;
|
|
116
|
+
path?: never;
|
|
117
|
+
cookie?: never;
|
|
118
|
+
};
|
|
119
|
+
requestBody?: never;
|
|
120
|
+
responses: {
|
|
121
|
+
/** @description OK */
|
|
122
|
+
200: {
|
|
123
|
+
headers: {
|
|
124
|
+
[name: string]: unknown;
|
|
125
|
+
};
|
|
126
|
+
content: {
|
|
127
|
+
"application/json": components["schemas"]["MarketResponse"];
|
|
128
|
+
};
|
|
129
|
+
};
|
|
130
|
+
/** @description Authentication required */
|
|
131
|
+
401: {
|
|
132
|
+
headers: {
|
|
133
|
+
[name: string]: unknown;
|
|
134
|
+
};
|
|
135
|
+
content: {
|
|
136
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
137
|
+
};
|
|
138
|
+
};
|
|
139
|
+
/** @description Validation error */
|
|
140
|
+
422: {
|
|
141
|
+
headers: {
|
|
142
|
+
[name: string]: unknown;
|
|
143
|
+
};
|
|
144
|
+
content: {
|
|
145
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
146
|
+
};
|
|
147
|
+
};
|
|
148
|
+
};
|
|
149
|
+
};
|
|
150
|
+
put?: never;
|
|
151
|
+
post?: never;
|
|
152
|
+
delete?: never;
|
|
153
|
+
options?: never;
|
|
154
|
+
head?: never;
|
|
155
|
+
patch?: never;
|
|
156
|
+
trace?: never;
|
|
157
|
+
};
|
|
158
|
+
"/v1/audience": {
|
|
159
|
+
parameters: {
|
|
160
|
+
query?: never;
|
|
161
|
+
header?: never;
|
|
162
|
+
path?: never;
|
|
163
|
+
cookie?: never;
|
|
164
|
+
};
|
|
165
|
+
/**
|
|
166
|
+
* Traveler-type mix for a destination
|
|
167
|
+
* @description Traveler-type composition (Solo / Couple / Family / Group) of demand for a destination. `traveler_type` is not a valid filter here — this endpoint buckets by it.
|
|
168
|
+
*/
|
|
169
|
+
get: {
|
|
170
|
+
parameters: {
|
|
171
|
+
query: {
|
|
172
|
+
/** @description Analysis mode. `trend` is accepted but currently returns snapshot-shaped data. */
|
|
173
|
+
analysis: components["parameters"]["analysis"];
|
|
174
|
+
/** @description Destination as <Level>:<Code>, e.g. Country:TH. Required for this endpoint. */
|
|
175
|
+
destination: components["parameters"]["destinationRequired"];
|
|
176
|
+
/** @description Origin market filter as <Level>:<Code>, e.g. Country:US or City:NYC. */
|
|
177
|
+
origin_market?: components["parameters"]["originMarket"];
|
|
178
|
+
/** @description Named departure window (defaults to Next90Days server-side). */
|
|
179
|
+
travel_period?: components["parameters"]["travelPeriod"];
|
|
180
|
+
/** @description Start of departure window (YYYY-MM-DD). Required when travel_period=Custom. */
|
|
181
|
+
departure_date_from?: components["parameters"]["departureDateFrom"];
|
|
182
|
+
/** @description End of departure window (YYYY-MM-DD). Required when travel_period=Custom. */
|
|
183
|
+
departure_date_to?: components["parameters"]["departureDateTo"];
|
|
184
|
+
/** @description Optional trip-type filter. */
|
|
185
|
+
trip_type?: components["parameters"]["tripType"];
|
|
186
|
+
/** @description Max rows (1-200, default 20). */
|
|
187
|
+
limit?: components["parameters"]["limit"];
|
|
188
|
+
};
|
|
189
|
+
header?: never;
|
|
190
|
+
path?: never;
|
|
191
|
+
cookie?: never;
|
|
192
|
+
};
|
|
193
|
+
requestBody?: never;
|
|
194
|
+
responses: {
|
|
195
|
+
/** @description OK */
|
|
196
|
+
200: {
|
|
197
|
+
headers: {
|
|
198
|
+
[name: string]: unknown;
|
|
199
|
+
};
|
|
200
|
+
content: {
|
|
201
|
+
"application/json": components["schemas"]["AudienceResponse"];
|
|
202
|
+
};
|
|
203
|
+
};
|
|
204
|
+
/** @description Authentication required */
|
|
205
|
+
401: {
|
|
206
|
+
headers: {
|
|
207
|
+
[name: string]: unknown;
|
|
208
|
+
};
|
|
209
|
+
content: {
|
|
210
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
211
|
+
};
|
|
212
|
+
};
|
|
213
|
+
/** @description Validation error */
|
|
214
|
+
422: {
|
|
215
|
+
headers: {
|
|
216
|
+
[name: string]: unknown;
|
|
217
|
+
};
|
|
218
|
+
content: {
|
|
219
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
220
|
+
};
|
|
221
|
+
};
|
|
222
|
+
};
|
|
223
|
+
};
|
|
224
|
+
put?: never;
|
|
225
|
+
post?: never;
|
|
226
|
+
delete?: never;
|
|
227
|
+
options?: never;
|
|
228
|
+
head?: never;
|
|
229
|
+
patch?: never;
|
|
230
|
+
trace?: never;
|
|
231
|
+
};
|
|
6
232
|
"/health": {
|
|
7
233
|
parameters: {
|
|
8
234
|
query?: never;
|
|
@@ -39,6 +265,266 @@ export interface paths {
|
|
|
39
265
|
patch?: never;
|
|
40
266
|
trace?: never;
|
|
41
267
|
};
|
|
268
|
+
"/v1/agent_payment/submit": {
|
|
269
|
+
parameters: {
|
|
270
|
+
query?: never;
|
|
271
|
+
header?: never;
|
|
272
|
+
path?: never;
|
|
273
|
+
cookie?: never;
|
|
274
|
+
};
|
|
275
|
+
get?: never;
|
|
276
|
+
put?: never;
|
|
277
|
+
/** Submit an agent payment — present trip_id + a Shared Payment Token to schedule + authorize the booking; returns a checkout_url fallback if customer action (3DS) is required */
|
|
278
|
+
post: {
|
|
279
|
+
parameters: {
|
|
280
|
+
query?: never;
|
|
281
|
+
header?: never;
|
|
282
|
+
path?: never;
|
|
283
|
+
cookie?: never;
|
|
284
|
+
};
|
|
285
|
+
requestBody?: {
|
|
286
|
+
content: {
|
|
287
|
+
"application/json": components["schemas"]["AgentPaymentSubmitRequest"];
|
|
288
|
+
};
|
|
289
|
+
};
|
|
290
|
+
responses: {
|
|
291
|
+
/** @description Authorization result */
|
|
292
|
+
200: {
|
|
293
|
+
headers: {
|
|
294
|
+
[name: string]: unknown;
|
|
295
|
+
};
|
|
296
|
+
content: {
|
|
297
|
+
"application/json": components["schemas"]["AgentPaymentSubmitResponse"];
|
|
298
|
+
};
|
|
299
|
+
};
|
|
300
|
+
/** @description Bad request */
|
|
301
|
+
400: {
|
|
302
|
+
headers: {
|
|
303
|
+
[name: string]: unknown;
|
|
304
|
+
};
|
|
305
|
+
content: {
|
|
306
|
+
/**
|
|
307
|
+
* @example {
|
|
308
|
+
* "error": {
|
|
309
|
+
* "code": "BAD_REQUEST",
|
|
310
|
+
* "message": "Malformed JSON in request body.",
|
|
311
|
+
* "doc_url": "https://docs.gojinko.com/concepts/errors"
|
|
312
|
+
* }
|
|
313
|
+
* }
|
|
314
|
+
*/
|
|
315
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
316
|
+
};
|
|
317
|
+
};
|
|
318
|
+
/** @description Authentication required */
|
|
319
|
+
401: {
|
|
320
|
+
headers: {
|
|
321
|
+
[name: string]: unknown;
|
|
322
|
+
};
|
|
323
|
+
content: {
|
|
324
|
+
/**
|
|
325
|
+
* @example {
|
|
326
|
+
* "error": {
|
|
327
|
+
* "code": "AUTH_REQUIRED",
|
|
328
|
+
* "message": "Invalid or expired API key.",
|
|
329
|
+
* "doc_url": "https://docs.gojinko.com/api-reference/authentication"
|
|
330
|
+
* }
|
|
331
|
+
* }
|
|
332
|
+
*/
|
|
333
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
334
|
+
};
|
|
335
|
+
};
|
|
336
|
+
/** @description Validation error */
|
|
337
|
+
422: {
|
|
338
|
+
headers: {
|
|
339
|
+
[name: string]: unknown;
|
|
340
|
+
};
|
|
341
|
+
content: {
|
|
342
|
+
/**
|
|
343
|
+
* @example {
|
|
344
|
+
* "error": {
|
|
345
|
+
* "code": "BAD_REQUEST",
|
|
346
|
+
* "message": "origins: origins is required; trip_type: trip_type is required",
|
|
347
|
+
* "doc_url": "https://docs.gojinko.com/concepts/errors"
|
|
348
|
+
* }
|
|
349
|
+
* }
|
|
350
|
+
*/
|
|
351
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
352
|
+
};
|
|
353
|
+
};
|
|
354
|
+
/** @description Rate limit or quota exceeded */
|
|
355
|
+
429: {
|
|
356
|
+
headers: {
|
|
357
|
+
[name: string]: unknown;
|
|
358
|
+
};
|
|
359
|
+
content: {
|
|
360
|
+
/**
|
|
361
|
+
* @example {
|
|
362
|
+
* "error": {
|
|
363
|
+
* "code": "RATE_LIMITED",
|
|
364
|
+
* "message": "Rate limit or quota exceeded.",
|
|
365
|
+
* "doc_url": "https://docs.gojinko.com/concepts/errors"
|
|
366
|
+
* }
|
|
367
|
+
* }
|
|
368
|
+
*/
|
|
369
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
370
|
+
};
|
|
371
|
+
};
|
|
372
|
+
/** @description Upstream service error */
|
|
373
|
+
502: {
|
|
374
|
+
headers: {
|
|
375
|
+
[name: string]: unknown;
|
|
376
|
+
};
|
|
377
|
+
content: {
|
|
378
|
+
/**
|
|
379
|
+
* @example {
|
|
380
|
+
* "error": {
|
|
381
|
+
* "code": "UPSTREAM_ERROR",
|
|
382
|
+
* "message": "Upstream travel provider returned an error. Please retry.",
|
|
383
|
+
* "doc_url": "https://docs.gojinko.com/concepts/errors"
|
|
384
|
+
* }
|
|
385
|
+
* }
|
|
386
|
+
*/
|
|
387
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
388
|
+
};
|
|
389
|
+
};
|
|
390
|
+
};
|
|
391
|
+
};
|
|
392
|
+
delete?: never;
|
|
393
|
+
options?: never;
|
|
394
|
+
head?: never;
|
|
395
|
+
patch?: never;
|
|
396
|
+
trace?: never;
|
|
397
|
+
};
|
|
398
|
+
"/v1/checkout": {
|
|
399
|
+
parameters: {
|
|
400
|
+
query?: never;
|
|
401
|
+
header?: never;
|
|
402
|
+
path?: never;
|
|
403
|
+
cookie?: never;
|
|
404
|
+
};
|
|
405
|
+
get?: never;
|
|
406
|
+
put?: never;
|
|
407
|
+
/** Checkout a trip — returns a checkout URL the user opens to pay, plus the Shared Payment Token params an agent can use to pay programmatically */
|
|
408
|
+
post: {
|
|
409
|
+
parameters: {
|
|
410
|
+
query?: never;
|
|
411
|
+
header?: never;
|
|
412
|
+
path?: never;
|
|
413
|
+
cookie?: never;
|
|
414
|
+
};
|
|
415
|
+
requestBody?: {
|
|
416
|
+
content: {
|
|
417
|
+
"application/json": components["schemas"]["CheckoutRequest"];
|
|
418
|
+
};
|
|
419
|
+
};
|
|
420
|
+
responses: {
|
|
421
|
+
/** @description Checkout session */
|
|
422
|
+
200: {
|
|
423
|
+
headers: {
|
|
424
|
+
[name: string]: unknown;
|
|
425
|
+
};
|
|
426
|
+
content: {
|
|
427
|
+
"application/json": components["schemas"]["CheckoutResponse"];
|
|
428
|
+
};
|
|
429
|
+
};
|
|
430
|
+
/** @description Bad request */
|
|
431
|
+
400: {
|
|
432
|
+
headers: {
|
|
433
|
+
[name: string]: unknown;
|
|
434
|
+
};
|
|
435
|
+
content: {
|
|
436
|
+
/**
|
|
437
|
+
* @example {
|
|
438
|
+
* "error": {
|
|
439
|
+
* "code": "BAD_REQUEST",
|
|
440
|
+
* "message": "Malformed JSON in request body.",
|
|
441
|
+
* "doc_url": "https://docs.gojinko.com/concepts/errors"
|
|
442
|
+
* }
|
|
443
|
+
* }
|
|
444
|
+
*/
|
|
445
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
446
|
+
};
|
|
447
|
+
};
|
|
448
|
+
/** @description Authentication required */
|
|
449
|
+
401: {
|
|
450
|
+
headers: {
|
|
451
|
+
[name: string]: unknown;
|
|
452
|
+
};
|
|
453
|
+
content: {
|
|
454
|
+
/**
|
|
455
|
+
* @example {
|
|
456
|
+
* "error": {
|
|
457
|
+
* "code": "AUTH_REQUIRED",
|
|
458
|
+
* "message": "Invalid or expired API key.",
|
|
459
|
+
* "doc_url": "https://docs.gojinko.com/api-reference/authentication"
|
|
460
|
+
* }
|
|
461
|
+
* }
|
|
462
|
+
*/
|
|
463
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
464
|
+
};
|
|
465
|
+
};
|
|
466
|
+
/** @description Validation error */
|
|
467
|
+
422: {
|
|
468
|
+
headers: {
|
|
469
|
+
[name: string]: unknown;
|
|
470
|
+
};
|
|
471
|
+
content: {
|
|
472
|
+
/**
|
|
473
|
+
* @example {
|
|
474
|
+
* "error": {
|
|
475
|
+
* "code": "BAD_REQUEST",
|
|
476
|
+
* "message": "origins: origins is required; trip_type: trip_type is required",
|
|
477
|
+
* "doc_url": "https://docs.gojinko.com/concepts/errors"
|
|
478
|
+
* }
|
|
479
|
+
* }
|
|
480
|
+
*/
|
|
481
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
482
|
+
};
|
|
483
|
+
};
|
|
484
|
+
/** @description Rate limit or quota exceeded */
|
|
485
|
+
429: {
|
|
486
|
+
headers: {
|
|
487
|
+
[name: string]: unknown;
|
|
488
|
+
};
|
|
489
|
+
content: {
|
|
490
|
+
/**
|
|
491
|
+
* @example {
|
|
492
|
+
* "error": {
|
|
493
|
+
* "code": "RATE_LIMITED",
|
|
494
|
+
* "message": "Rate limit or quota exceeded.",
|
|
495
|
+
* "doc_url": "https://docs.gojinko.com/concepts/errors"
|
|
496
|
+
* }
|
|
497
|
+
* }
|
|
498
|
+
*/
|
|
499
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
500
|
+
};
|
|
501
|
+
};
|
|
502
|
+
/** @description Upstream service error */
|
|
503
|
+
502: {
|
|
504
|
+
headers: {
|
|
505
|
+
[name: string]: unknown;
|
|
506
|
+
};
|
|
507
|
+
content: {
|
|
508
|
+
/**
|
|
509
|
+
* @example {
|
|
510
|
+
* "error": {
|
|
511
|
+
* "code": "UPSTREAM_ERROR",
|
|
512
|
+
* "message": "Upstream travel provider returned an error. Please retry.",
|
|
513
|
+
* "doc_url": "https://docs.gojinko.com/concepts/errors"
|
|
514
|
+
* }
|
|
515
|
+
* }
|
|
516
|
+
*/
|
|
517
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
518
|
+
};
|
|
519
|
+
};
|
|
520
|
+
};
|
|
521
|
+
};
|
|
522
|
+
delete?: never;
|
|
523
|
+
options?: never;
|
|
524
|
+
head?: never;
|
|
525
|
+
patch?: never;
|
|
526
|
+
trace?: never;
|
|
527
|
+
};
|
|
42
528
|
"/v1/find_destination": {
|
|
43
529
|
parameters: {
|
|
44
530
|
query?: never;
|
|
@@ -903,7 +1389,10 @@ export interface paths {
|
|
|
903
1389
|
};
|
|
904
1390
|
get?: never;
|
|
905
1391
|
put?: never;
|
|
906
|
-
/**
|
|
1392
|
+
/**
|
|
1393
|
+
* DEPRECATED — use /checkout. Alias retained for backward compatibility.
|
|
1394
|
+
* @deprecated
|
|
1395
|
+
*/
|
|
907
1396
|
post: {
|
|
908
1397
|
parameters: {
|
|
909
1398
|
query?: never;
|
|
@@ -913,7 +1402,7 @@ export interface paths {
|
|
|
913
1402
|
};
|
|
914
1403
|
requestBody?: {
|
|
915
1404
|
content: {
|
|
916
|
-
"application/json": components["schemas"]["
|
|
1405
|
+
"application/json": components["schemas"]["CheckoutRequest"];
|
|
917
1406
|
};
|
|
918
1407
|
};
|
|
919
1408
|
responses: {
|
|
@@ -923,7 +1412,7 @@ export interface paths {
|
|
|
923
1412
|
[name: string]: unknown;
|
|
924
1413
|
};
|
|
925
1414
|
content: {
|
|
926
|
-
"application/json": components["schemas"]["
|
|
1415
|
+
"application/json": components["schemas"]["CheckoutResponse"];
|
|
927
1416
|
};
|
|
928
1417
|
};
|
|
929
1418
|
/** @description Bad request */
|
|
@@ -932,6 +1421,15 @@ export interface paths {
|
|
|
932
1421
|
[name: string]: unknown;
|
|
933
1422
|
};
|
|
934
1423
|
content: {
|
|
1424
|
+
/**
|
|
1425
|
+
* @example {
|
|
1426
|
+
* "error": {
|
|
1427
|
+
* "code": "BAD_REQUEST",
|
|
1428
|
+
* "message": "Malformed JSON in request body.",
|
|
1429
|
+
* "doc_url": "https://docs.gojinko.com/concepts/errors"
|
|
1430
|
+
* }
|
|
1431
|
+
* }
|
|
1432
|
+
*/
|
|
935
1433
|
"application/json": components["schemas"]["ErrorResponse"];
|
|
936
1434
|
};
|
|
937
1435
|
};
|
|
@@ -941,6 +1439,15 @@ export interface paths {
|
|
|
941
1439
|
[name: string]: unknown;
|
|
942
1440
|
};
|
|
943
1441
|
content: {
|
|
1442
|
+
/**
|
|
1443
|
+
* @example {
|
|
1444
|
+
* "error": {
|
|
1445
|
+
* "code": "AUTH_REQUIRED",
|
|
1446
|
+
* "message": "Invalid or expired API key.",
|
|
1447
|
+
* "doc_url": "https://docs.gojinko.com/api-reference/authentication"
|
|
1448
|
+
* }
|
|
1449
|
+
* }
|
|
1450
|
+
*/
|
|
944
1451
|
"application/json": components["schemas"]["ErrorResponse"];
|
|
945
1452
|
};
|
|
946
1453
|
};
|
|
@@ -950,6 +1457,15 @@ export interface paths {
|
|
|
950
1457
|
[name: string]: unknown;
|
|
951
1458
|
};
|
|
952
1459
|
content: {
|
|
1460
|
+
/**
|
|
1461
|
+
* @example {
|
|
1462
|
+
* "error": {
|
|
1463
|
+
* "code": "BAD_REQUEST",
|
|
1464
|
+
* "message": "origins: origins is required; trip_type: trip_type is required",
|
|
1465
|
+
* "doc_url": "https://docs.gojinko.com/concepts/errors"
|
|
1466
|
+
* }
|
|
1467
|
+
* }
|
|
1468
|
+
*/
|
|
953
1469
|
"application/json": components["schemas"]["ErrorResponse"];
|
|
954
1470
|
};
|
|
955
1471
|
};
|
|
@@ -959,6 +1475,15 @@ export interface paths {
|
|
|
959
1475
|
[name: string]: unknown;
|
|
960
1476
|
};
|
|
961
1477
|
content: {
|
|
1478
|
+
/**
|
|
1479
|
+
* @example {
|
|
1480
|
+
* "error": {
|
|
1481
|
+
* "code": "RATE_LIMITED",
|
|
1482
|
+
* "message": "Rate limit or quota exceeded.",
|
|
1483
|
+
* "doc_url": "https://docs.gojinko.com/concepts/errors"
|
|
1484
|
+
* }
|
|
1485
|
+
* }
|
|
1486
|
+
*/
|
|
962
1487
|
"application/json": components["schemas"]["ErrorResponse"];
|
|
963
1488
|
};
|
|
964
1489
|
};
|
|
@@ -968,6 +1493,15 @@ export interface paths {
|
|
|
968
1493
|
[name: string]: unknown;
|
|
969
1494
|
};
|
|
970
1495
|
content: {
|
|
1496
|
+
/**
|
|
1497
|
+
* @example {
|
|
1498
|
+
* "error": {
|
|
1499
|
+
* "code": "UPSTREAM_ERROR",
|
|
1500
|
+
* "message": "Upstream travel provider returned an error. Please retry.",
|
|
1501
|
+
* "doc_url": "https://docs.gojinko.com/concepts/errors"
|
|
1502
|
+
* }
|
|
1503
|
+
* }
|
|
1504
|
+
*/
|
|
971
1505
|
"application/json": components["schemas"]["ErrorResponse"];
|
|
972
1506
|
};
|
|
973
1507
|
};
|
|
@@ -1919,6 +2453,35 @@ export interface paths {
|
|
|
1919
2453
|
export type webhooks = Record<string, never>;
|
|
1920
2454
|
export interface components {
|
|
1921
2455
|
schemas: {
|
|
2456
|
+
AgentPaymentSubmitRequest: {
|
|
2457
|
+
/** @example trip_1048576 */
|
|
2458
|
+
trip_id: string;
|
|
2459
|
+
/** @example spt_1Nq8L2eZvKYlo2C0 */
|
|
2460
|
+
shared_payment_token: string;
|
|
2461
|
+
};
|
|
2462
|
+
AgentPaymentSubmitResponse: {
|
|
2463
|
+
fulfillment_cart_id?: number;
|
|
2464
|
+
/** @example processing */
|
|
2465
|
+
status?: string;
|
|
2466
|
+
payment_verified?: boolean;
|
|
2467
|
+
message?: string;
|
|
2468
|
+
/** @description Hosted-checkout fallback, present only on a 3DS step-up / decline. */
|
|
2469
|
+
checkout_url?: string;
|
|
2470
|
+
recap_token?: string;
|
|
2471
|
+
};
|
|
2472
|
+
AgentSPTParams: {
|
|
2473
|
+
/**
|
|
2474
|
+
* @description Locked cart total in the smallest currency unit — scope the Shared Payment Token to at most this.
|
|
2475
|
+
* @example 259449
|
|
2476
|
+
*/
|
|
2477
|
+
max_amount: number;
|
|
2478
|
+
/** @example EUR */
|
|
2479
|
+
currency: string;
|
|
2480
|
+
/** @description Stripe Agentic Commerce network_business_profile id the SPT is granted against. Empty until the preview account is provisioned. */
|
|
2481
|
+
stripe_profile?: string;
|
|
2482
|
+
/** @example 2026-06-10T13:04:56Z */
|
|
2483
|
+
expires_at?: string;
|
|
2484
|
+
};
|
|
1922
2485
|
/** @description A purchasable ancillary (bag, seat, bundle, ...) offered on a trip item. */
|
|
1923
2486
|
AncillaryOffer: {
|
|
1924
2487
|
/** @description Stable id used to select this ancillary. */
|
|
@@ -1939,6 +2502,31 @@ export interface components {
|
|
|
1939
2502
|
per_pax?: boolean;
|
|
1940
2503
|
max_quantity?: number;
|
|
1941
2504
|
};
|
|
2505
|
+
CheckoutRequest: {
|
|
2506
|
+
/** @example trip_1048576 */
|
|
2507
|
+
trip_id: string;
|
|
2508
|
+
};
|
|
2509
|
+
CheckoutResponse: {
|
|
2510
|
+
/** @example cs_1048576 */
|
|
2511
|
+
session_id?: string;
|
|
2512
|
+
/** @example https://book.gojinko.com/checkout?sid=1048576 */
|
|
2513
|
+
checkout_url?: string;
|
|
2514
|
+
/** @example pending_payment */
|
|
2515
|
+
status?: string;
|
|
2516
|
+
/** @example 2026-06-01T13:04:56Z */
|
|
2517
|
+
expires_at?: string;
|
|
2518
|
+
total_amount?: {
|
|
2519
|
+
/** @example 318.4 */
|
|
2520
|
+
amount?: number;
|
|
2521
|
+
value?: number;
|
|
2522
|
+
/** @example USD */
|
|
2523
|
+
currency?: string;
|
|
2524
|
+
/** @example 2 */
|
|
2525
|
+
decimal_places?: number;
|
|
2526
|
+
};
|
|
2527
|
+
items?: unknown[];
|
|
2528
|
+
agent_spt_params?: components["schemas"]["AgentSPTParams"];
|
|
2529
|
+
};
|
|
1942
2530
|
HealthResponse: {
|
|
1943
2531
|
/** @enum {string} */
|
|
1944
2532
|
status: "ok";
|
|
@@ -2325,22 +2913,6 @@ export interface components {
|
|
|
2325
2913
|
};
|
|
2326
2914
|
}[];
|
|
2327
2915
|
};
|
|
2328
|
-
BookResponse: {
|
|
2329
|
-
session_id?: string;
|
|
2330
|
-
checkout_url?: string;
|
|
2331
|
-
status?: string;
|
|
2332
|
-
expires_at?: string;
|
|
2333
|
-
total_amount?: {
|
|
2334
|
-
amount?: number;
|
|
2335
|
-
value?: number;
|
|
2336
|
-
currency?: string;
|
|
2337
|
-
decimal_places?: number;
|
|
2338
|
-
};
|
|
2339
|
-
items?: unknown[];
|
|
2340
|
-
};
|
|
2341
|
-
BookRequest: {
|
|
2342
|
-
trip_id: string;
|
|
2343
|
-
};
|
|
2344
2916
|
HotelSearchResponse: {
|
|
2345
2917
|
hotels?: {
|
|
2346
2918
|
hotel_id?: string;
|
|
@@ -2595,9 +3167,68 @@ export interface components {
|
|
|
2595
3167
|
booking_ref?: string;
|
|
2596
3168
|
last_name?: string;
|
|
2597
3169
|
};
|
|
3170
|
+
/** @enum {string} */
|
|
3171
|
+
AnalysisType: "snapshot" | "trend";
|
|
3172
|
+
/** @enum {string} */
|
|
3173
|
+
TravelPeriod: "Summer" | "Winter" | "Christmas" | "Easter" | "Next30Days" | "Next90Days" | "Custom";
|
|
3174
|
+
/** @enum {string} */
|
|
3175
|
+
TravelerType: "Solo" | "Couple" | "Group" | "Family";
|
|
3176
|
+
/** @enum {string} */
|
|
3177
|
+
TripType: "One-Way" | "Round-Trip";
|
|
3178
|
+
DestinationRow: {
|
|
3179
|
+
rank?: number;
|
|
3180
|
+
destination: string;
|
|
3181
|
+
/** Format: double */
|
|
3182
|
+
share?: number;
|
|
3183
|
+
};
|
|
3184
|
+
MarketRow: {
|
|
3185
|
+
rank?: number;
|
|
3186
|
+
market: string;
|
|
3187
|
+
/** Format: double */
|
|
3188
|
+
share?: number;
|
|
3189
|
+
};
|
|
3190
|
+
AudienceRow: {
|
|
3191
|
+
rank?: number;
|
|
3192
|
+
audience: string;
|
|
3193
|
+
/** Format: double */
|
|
3194
|
+
share?: number;
|
|
3195
|
+
};
|
|
3196
|
+
DestinationResponse: {
|
|
3197
|
+
analysis_type: components["schemas"]["AnalysisType"];
|
|
3198
|
+
rows: components["schemas"]["DestinationRow"][];
|
|
3199
|
+
};
|
|
3200
|
+
MarketResponse: {
|
|
3201
|
+
analysis_type: components["schemas"]["AnalysisType"];
|
|
3202
|
+
rows: components["schemas"]["MarketRow"][];
|
|
3203
|
+
};
|
|
3204
|
+
AudienceResponse: {
|
|
3205
|
+
analysis_type: components["schemas"]["AnalysisType"];
|
|
3206
|
+
rows: components["schemas"]["AudienceRow"][];
|
|
3207
|
+
};
|
|
2598
3208
|
};
|
|
2599
3209
|
responses: never;
|
|
2600
|
-
parameters:
|
|
3210
|
+
parameters: {
|
|
3211
|
+
/** @description Analysis mode. `trend` is accepted but currently returns snapshot-shaped data. */
|
|
3212
|
+
analysis: components["schemas"]["AnalysisType"];
|
|
3213
|
+
/** @description Origin market filter as <Level>:<Code>, e.g. Country:US or City:NYC. */
|
|
3214
|
+
originMarket: string;
|
|
3215
|
+
/** @description Optional destination filter as <Level>:<Code>, e.g. Country:TH. */
|
|
3216
|
+
destinationFilter: string;
|
|
3217
|
+
/** @description Destination as <Level>:<Code>, e.g. Country:TH. Required for this endpoint. */
|
|
3218
|
+
destinationRequired: string;
|
|
3219
|
+
/** @description Named departure window (defaults to Next90Days server-side). */
|
|
3220
|
+
travelPeriod: components["schemas"]["TravelPeriod"];
|
|
3221
|
+
/** @description Start of departure window (YYYY-MM-DD). Required when travel_period=Custom. */
|
|
3222
|
+
departureDateFrom: string;
|
|
3223
|
+
/** @description End of departure window (YYYY-MM-DD). Required when travel_period=Custom. */
|
|
3224
|
+
departureDateTo: string;
|
|
3225
|
+
/** @description Optional traveler-type filter. */
|
|
3226
|
+
travelerType: components["schemas"]["TravelerType"];
|
|
3227
|
+
/** @description Optional trip-type filter. */
|
|
3228
|
+
tripType: components["schemas"]["TripType"];
|
|
3229
|
+
/** @description Max rows (1-200, default 20). */
|
|
3230
|
+
limit: number;
|
|
3231
|
+
};
|
|
2601
3232
|
requestBodies: never;
|
|
2602
3233
|
headers: never;
|
|
2603
3234
|
pathItems: never;
|