gemini-reverse 1.0.11 → 1.0.12

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-EN.md CHANGED
@@ -6,6 +6,20 @@ All notable changes to this project will be documented in this file.
6
6
 
7
7
  ---
8
8
 
9
+ ## [1.0.12]
10
+
11
+ ### Fixed
12
+ - Fixed `image.save()` returning 403 — removed stale two-hop redirect chain (`=d-I?alr=yes`); `_getFullSizeImage` already returns the final URL directly.
13
+
14
+ ---
15
+
16
+ ## [1.0.8]
17
+
18
+ ### Fixed
19
+ - Fixed quota key format — null entries in quota ID list are now filtered before joining, producing clean numeric keys (e.g. `11`, `4`) instead of `-11`, `-4`.
20
+
21
+ ---
22
+
9
23
  ## [1.0.7]
10
24
 
11
25
  ### Added
@@ -20,7 +34,7 @@ All notable changes to this project will be documented in this file.
20
34
  - **`model_number` in `AvailableModel`** — New field mirrored from model header into request payload (`inner[79]`).
21
35
  - **`buildModelIdNumberMapping()`** — Static method on `AvailableModel` returning a `modelId → modelNumber` mapping.
22
36
  - **New models** — `BASIC_LITE` (`gemini-3-lite`), `PLUS_LITE` (`gemini-3-lite-plus`), `ADVANCED_LITE` (`gemini-3-lite-advanced`).
23
- - **New GRPC keys** — Added from `pr`: `GET_CONVERSATION_TURN`, `UPDATE_CONVERSATION`, `MARK_LAST_CONVERSATION_TURN`, `GENERATE_HEADLINE`, `GET_GEM`, `DELETE_GEM_AND_CONVERSATIONS`, `CREATE_TASK`, `GET_TASK`, `GET_ALL_TASKS`, `GET_TASKS_IN_CONVERSATION`, `GET_CANDIDATES`, `LIST_DISCOVERY_CARDS`, `GET_DISCOVERY_CARD`, `LIST_DISCOVERY_BANNERS`, `LIST_GEMINI_APP_ARTIFACTS`, `DELETE_GEMINI_APP_ARTIFACTS`, `LIST_MEMORIES`, `CREATE_MEMORY`, `UPDATE_MEMORY`, `DELETE_MEMORY`, `DELETE_ALL_MEMORIES`, `CHECK_GEMINI_QUOTA`, `CHECK_QUOTA`, `GET_ABUSE_STATUS`, `UPDATE_USER_PREFERENCES`, `READ_USER_PREFERENCES`, `CONTINUE_SHARED_CONVERSATION`, `GET_USAGE_INFO`.
37
+ - **New GRPC keys** — `GET_CONVERSATION_TURN`, `UPDATE_CONVERSATION`, `MARK_LAST_CONVERSATION_TURN`, `GENERATE_HEADLINE`, `GET_GEM`, `DELETE_GEM_AND_CONVERSATIONS`, `CREATE_TASK`, `GET_TASK`, `GET_ALL_TASKS`, `GET_TASKS_IN_CONVERSATION`, `GET_CANDIDATES`, `LIST_DISCOVERY_CARDS`, `GET_DISCOVERY_CARD`, `LIST_DISCOVERY_BANNERS`, `LIST_GEMINI_APP_ARTIFACTS`, `DELETE_GEMINI_APP_ARTIFACTS`, `LIST_MEMORIES`, `CREATE_MEMORY`, `UPDATE_MEMORY`, `DELETE_MEMORY`, `DELETE_ALL_MEMORIES`, `CHECK_GEMINI_QUOTA`, `CHECK_QUOTA`, `GET_ABUSE_STATUS`, `UPDATE_USER_PREFERENCES`, `READ_USER_PREFERENCES`, `CONTINUE_SHARED_CONVERSATION`, `GET_USAGE_INFO`.
24
38
  - **Auto-refresh jitter** — Cookie refresh interval now applies ±15 seconds of random jitter to prevent synchronized background requests.
25
39
  - **`_fetchPreferences()` / `_syncActivity()`** — Replaced monolithic `_sendBardSettings` / `_sendBardActivity` with dedicated methods that cleanly separate preference sync from activity heartbeat.
26
40
  - **Case-insensitive model resolution** — `_resolveModelByName` now matches model names and display names case-insensitively.
@@ -40,14 +54,6 @@ All notable changes to this project will be documented in this file.
40
54
 
41
55
  ### Fixed
42
56
  - **Upload failure** — Fixed missing `Push-ID` header, content-type, and REFERER headers in `uploadFile`.
43
- - **Quota key format** — Null entries in quota ID list are now filtered before joining, producing clean numeric keys (e.g. `11`, `4`) instead of `-11`, `-4`.
44
-
45
- ---
46
-
47
- ## [1.0.8]
48
-
49
- ### Fixed
50
- - Fixed quota key format — null entries in quota ID list are now filtered before joining, producing clean numeric keys (e.g. `11`, `4`) instead of `-11`, `-4`.
51
57
 
52
58
  ---
53
59
 
package/CHANGELOG-IDN.md CHANGED
@@ -6,6 +6,20 @@ Semua perubahan penting pada proyek ini dicatat di sini.
6
6
 
7
7
  ---
8
8
 
9
+ ## [1.0.12]
10
+
11
+ ### Diperbaiki
12
+ - `image.save()` yang gagal dengan 403 — rantai redirect dua langkah (`=d-I?alr=yes`) yang sudah tidak berlaku dihapus; `_getFullSizeImage` sudah mengembalikan URL final secara langsung.
13
+
14
+ ---
15
+
16
+ ## [1.0.8]
17
+
18
+ ### Diperbaiki
19
+ - Format kunci quota — entry null pada daftar ID quota sekarang difilter sebelum digabung, menghasilkan kunci numerik yang benar (mis. `11`, `4`) bukan `-11`, `-4`.
20
+
21
+ ---
22
+
9
23
  ## [1.0.7]
10
24
 
11
25
  ### Ditambahkan
@@ -40,14 +54,6 @@ Semua perubahan penting pada proyek ini dicatat di sini.
40
54
 
41
55
  ### Diperbaiki
42
56
  - **Upload gagal** — Header `Push-ID`, content-type, dan REFERER yang hilang di `uploadFile` sudah diperbaiki.
43
- - **Format kunci quota** — Entry null pada daftar ID quota sekarang difilter sebelum digabung, menghasilkan kunci numerik yang benar (mis. `11`, `4`) bukan `-11`, `-4`.
44
-
45
- ---
46
-
47
- ## [1.0.8]
48
-
49
- ### Diperbaiki
50
- - Format kunci quota — entry null difilter sebelum digabung sehingga menghasilkan kunci numerik yang bersih (mis. `11`, `4`) bukan `-11`, `-4`.
51
57
 
52
58
  ---
53
59
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gemini-reverse",
3
- "version": "1.0.11",
3
+ "version": "1.0.12",
4
4
  "description": "Unofficial Node.js client for gemini.google.com — inspired by Gemini-API (Python). Supports streaming, chat sessions, gems, file uploads, and TypeScript.",
5
5
  "main": "index.js",
6
6
  "types": "index.d.ts",
package/types/image.js CHANGED
@@ -107,21 +107,7 @@ class GeneratedImage extends Image {
107
107
  this.cid, this.rid, this.rcid, this.image_id,
108
108
  );
109
109
  if (originalUrl) {
110
- const proxyConfig = this._parseProxy(this.proxy);
111
- const cookies = this.client_ref ? this.client_ref.cookies : null;
112
- const headers = {
113
- 'Origin': 'https://gemini.google.com',
114
- 'Referer': 'https://gemini.google.com/',
115
- ...(cookies ? { 'Cookie': Object.entries(cookies).map(([k, v]) => `${k}=${v}`).join('; ') } : {}),
116
- };
117
-
118
- const r1 = await axios.get(`${originalUrl}=d-I?alr=yes`, {
119
- headers, maxRedirects: 5, ...(proxyConfig ? { proxy: proxyConfig } : {}),
120
- });
121
- const r2 = await axios.get(r1.data.trim(), {
122
- headers, maxRedirects: 5, ...(proxyConfig ? { proxy: proxyConfig } : {}),
123
- });
124
- this.url = r2.data.trim();
110
+ this.url = originalUrl;
125
111
  return await super._performSave(savePath, filename, verbose);
126
112
  }
127
113
  } catch (e) {