@gojinko/plugin 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.
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "jinko",
3
3
  "description": "Search flights, book trips, and manage bookings with the Jinko Travel API. Connects to the Jinko MCP server for live flight pricing, trip management, and payment.",
4
- "version": "2.14.0",
4
+ "version": "2.16.0",
5
5
  "author": {
6
6
  "name": "Jinko",
7
7
  "url": "https://gojinko.com"
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "jinko",
3
3
  "description": "Search flights, book trips, and manage bookings with the Jinko Travel API. Connects to the Jinko MCP server for live flight pricing, trip management, and payment.",
4
- "version": "2.14.0",
4
+ "version": "2.16.0",
5
5
  "author": {
6
6
  "name": "Jinko",
7
7
  "url": "https://gojinko.com"
package/README.md CHANGED
@@ -4,7 +4,7 @@ Plugin for **Claude Code** and **OpenAI Codex** that enables flight search, trip
4
4
 
5
5
  ## What's included
6
6
 
7
- - **4 skills**: search-flights, book-trip, manage-booking, account
7
+ - **6 skills**: search-flights, search-hotels, book-trip, manage-booking, account, cli
8
8
  - **MCP server config**: connects to `mcp.builders.gojinko.com`
9
9
  - **Dual-platform support**: works with both Claude Code and Codex CLI
10
10
 
@@ -39,9 +39,11 @@ codex plugin install @gojinko/plugin
39
39
  | Skill | Description | Example prompt |
40
40
  |-------|-------------|---------------|
41
41
  | `jinko:search-flights` | Find flights, explore destinations, compare prices | "Find flights from Paris to Tokyo in June" |
42
- | `jinko:book-trip` | Book a flight with travelers and payment | "Book the cheapest flight and pay" |
42
+ | `jinko:search-hotels` | Search live hotel inventory and rates by destination, dates, and occupancy — or look up a hotel by name | "Find hotels in Tokyo for 2 nights in June" |
43
+ | `jinko:book-trip` | Book flights, hotels, or both — travelers, ancillaries, and payment | "Book the cheapest flight and pay" |
43
44
  | `jinko:manage-booking` | Check refund eligibility and process refunds | "Can I get a refund on booking ORD-123?" |
44
45
  | `jinko:account` | Account setup guide — API keys, quotas, dashboard | "How do I set up my Jinko API key?" |
46
+ | `jinko:cli` | Run travel ops from the terminal — search flights/hotels, build trips, book, refund, look up bookings via the `jinko` CLI | "Search flights from the terminal with the jinko CLI" |
45
47
 
46
48
  ## Authentication
47
49
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gojinko/plugin",
3
- "version": "2.14.0",
3
+ "version": "2.16.0",
4
4
  "description": "Jinko Travel plugin for Claude Code and OpenAI Codex — flight search, booking, and trip management via MCP",
5
5
  "private": false,
6
6
  "license": "MIT",
@@ -50,7 +50,8 @@ Prod and sandbox keys are stored separately in `~/.jinko/config.yaml`. Precedenc
50
50
  | `hotel-details` | Rich metadata (gallery, facilities, policies, per-room details) for a single hotel |
51
51
  | `trip` | Create / update a trip: add items, remove items, set travelers + contact |
52
52
  | `select-ancillaries` | Add baggage / seats / meals to a trip item |
53
- | `book` | Schedule checkout → returns Stripe payment URL |
53
+ | `checkout` | Finalize a trip → returns `checkout_url` (human pays in browser) + `agent_spt_params` (agent pays programmatically). `book` is a deprecated alias. |
54
+ | `agent-pay submit` | Pay programmatically with a Shared Payment Token (`--trip-id` + `--token`); 3DS step-up falls back to `checkout_url` |
54
55
  | `trip-status` | Full status: cart, quote, fulfillment, bookings |
55
56
  | `get-booking` | Retrieve a booking by `JNK-*` ref + last name (guest access). |
56
57
  | `refund check / commit / status` | Voluntary refund flow |
@@ -74,14 +75,21 @@ jinko trip --trip-id tr_ABC \
74
75
  --travelers '[{"type":"ADT","first_name":"John","last_name":"Doe","date_of_birth":"1990-01-15"}]' \
75
76
  --contact '{"email":"john@example.com","phone":"+33612345678"}'
76
77
 
77
- # 4. Schedule checkout — returns canonical Jinko-hosted URL
78
- jinko book --trip-id tr_ABC
79
- # → { checkout_url: "https://app.gojinko.com/checkout?sid=12345" }
78
+ # 4. Checkout — returns canonical Jinko-hosted URL + agent payment params
79
+ jinko checkout --trip-id tr_ABC
80
+ # → { checkout_url: "https://app.gojinko.com/checkout?sid=12345",
81
+ # agent_spt_params: { max_amount: 259449, currency: "EUR", ... } }
80
82
  # The /checkout page renders the cart, collects any remaining info,
81
83
  # and triggers the right Stripe flow (embedded Elements or Hosted
82
84
  # Checkout) on Pay-button click.
83
85
 
84
- # 5. User pays in browser (or open the URL programmatically)
86
+ # 5a. Human path: user pays in browser (or open the URL programmatically)
87
+ # 5b. Agent path: mint a Shared Payment Token scoped to agent_spt_params,
88
+ # then pay programmatically (no browser):
89
+ jinko agent-pay submit --trip-id tr_ABC --token spt_xxx
90
+ # → { status: "processing", payment_verified: true }
91
+ # On a 3DS step-up / decline, the response carries a checkout_url fallback.
92
+
85
93
  # 6. Poll status
86
94
  jinko trip-status --trip-id tr_ABC
87
95
  ```
@@ -141,7 +149,7 @@ jinko refund status --ref JNK-A7B3X9 --last-name Doe
141
149
  - **Two auth systems.** CLI OAuth tokens (WorkOS device flow, stored in `~/.jinko/config.yaml`) are NOT interchangeable with MCP OAuth tokens (DCR, different issuer). Don't paste a CLI token into an MCP Bearer header — it will fail with issuer mismatch. Use an API key (`jnk_*`) for cross-surface programmatic access.
142
150
  - **IATA codes**: `--from PAR` uses a CITY code (matches CDG + ORY + BVA); `--from CDG` uses an airport. `flight-search` has `--origin-type city|airport` to disambiguate.
143
151
  - **trip_item_token format**: `offer_xxx:fare_yyy` (flight) or `htl_xxx:rate_yyy` (hotel). Always the offer ID + fare/rate ID joined by colon.
144
- - **Token expiry**: offers cached ~30 min. If `book` returns a quote failure, re-run `flight-search`/`hotel-search` to get a fresh token.
152
+ - **Token expiry**: offers cached ~30 min. If `checkout` returns a quote failure, re-run `flight-search`/`hotel-search` to get a fresh token.
145
153
  - **Script use**: set `JINKO_API_KEY` env var and use `--format json` so output parses cleanly.
146
154
 
147
155
  ## See also