wontopos 2.2.31 → 2.2.32
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/wontopos.d.ts +24 -7
- package/dist/wontopos.js +7 -3
- package/package.json +1 -1
package/dist/wontopos.d.ts
CHANGED
|
@@ -148,9 +148,17 @@ export interface StatusResult {
|
|
|
148
148
|
/**
|
|
149
149
|
* An image attached to a memory, passed to `add`/`store` via `opts.image`.
|
|
150
150
|
*
|
|
151
|
-
*
|
|
152
|
-
*
|
|
153
|
-
*
|
|
151
|
+
* What the service keeps is NOT your original. An image whose long edge is over
|
|
152
|
+
* 1568px is downscaled to 1568 before anything else happens, and that smaller
|
|
153
|
+
* picture is what gets embedded, stored, and handed back by `getImage`. Nothing in
|
|
154
|
+
* the retrieval path ever looks above 1568 — the embedder and the reader both
|
|
155
|
+
* shrink to it — so the extra pixels would be bytes nobody reads. This is a memory
|
|
156
|
+
* service, not a photo host: the picture it holds has the resolution of a memory.
|
|
157
|
+
*
|
|
158
|
+
* Keep your own copy if you need the full-resolution file. Either archive it
|
|
159
|
+
* yourself, or put its URL in `reference` — we store that string and never open it.
|
|
160
|
+
*
|
|
161
|
+
* You are billed for the picture we keep, so downscaling never costs you more.
|
|
154
162
|
*/
|
|
155
163
|
export interface ImageInput {
|
|
156
164
|
/** base64 of the image. A `data:image/...;base64,` prefix is accepted and stripped. */
|
|
@@ -166,9 +174,14 @@ export interface ImageInput {
|
|
|
166
174
|
*/
|
|
167
175
|
taken_at?: string;
|
|
168
176
|
}
|
|
169
|
-
/** `getImage` → the
|
|
177
|
+
/** `getImage` → the picture the service holds, plus what it actually is. */
|
|
170
178
|
export interface ImageBytes {
|
|
171
|
-
/**
|
|
179
|
+
/**
|
|
180
|
+
* The image as stored. Write it to a file, or wrap it in a Blob to show it.
|
|
181
|
+
*
|
|
182
|
+
* This is the service's copy, not necessarily your upload: anything over 1568px
|
|
183
|
+
* on its long edge was downscaled on the way in (see `ImageInput`).
|
|
184
|
+
*/
|
|
172
185
|
bytes: Uint8Array;
|
|
173
186
|
/** Sniffed from the BYTES, not from whatever the upload was named — e.g. `image/jpeg`. */
|
|
174
187
|
contentType: string;
|
|
@@ -650,9 +663,13 @@ export declare class Client {
|
|
|
650
663
|
/** Collect ALL of a store's memories into an array (original text + metadata, no vectors). */
|
|
651
664
|
exportMemories(userId?: string): Promise<Memory[]>;
|
|
652
665
|
/**
|
|
653
|
-
* Fetch the
|
|
666
|
+
* Fetch the bytes of an image memory — the picture the SERVICE holds.
|
|
654
667
|
*
|
|
655
|
-
*
|
|
668
|
+
* Not necessarily your upload: an image whose long edge was over 1568px was
|
|
669
|
+
* downscaled to 1568 on the way in, and that is what was embedded, stored and
|
|
670
|
+
* comes back here. Nothing in the retrieval path looks above 1568, so the extra
|
|
671
|
+
* pixels would be bytes nobody reads. Keep your own copy for the full-resolution
|
|
672
|
+
* file. The type is sniffed from the bytes themselves rather
|
|
656
673
|
* than from whatever the file was called. Rejects with `NotFoundError` when this
|
|
657
674
|
* memory has no image, or when the service was not configured to keep originals —
|
|
658
675
|
* it says "no" instead of handing back something empty, so "a memory with no image"
|
package/dist/wontopos.js
CHANGED
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
* runtime's (never disabled by this SDK; Node 18+ floors TLS at 1.2). Prefer
|
|
38
38
|
* `Client.fromEnv()` over keys in source code.
|
|
39
39
|
*/
|
|
40
|
-
const VERSION = "2.2.
|
|
40
|
+
const VERSION = "2.2.32";
|
|
41
41
|
/** Runtime info helps support debug a report ("node 18 on Windows...") —
|
|
42
42
|
* platform only, never anything identifying. Browsers have no `process` (and
|
|
43
43
|
* silently drop the UA header anyway). */
|
|
@@ -689,9 +689,13 @@ export class Client {
|
|
|
689
689
|
}
|
|
690
690
|
// ----- images (Tablet 2 and newer) -----
|
|
691
691
|
/**
|
|
692
|
-
* Fetch the
|
|
692
|
+
* Fetch the bytes of an image memory — the picture the SERVICE holds.
|
|
693
693
|
*
|
|
694
|
-
*
|
|
694
|
+
* Not necessarily your upload: an image whose long edge was over 1568px was
|
|
695
|
+
* downscaled to 1568 on the way in, and that is what was embedded, stored and
|
|
696
|
+
* comes back here. Nothing in the retrieval path looks above 1568, so the extra
|
|
697
|
+
* pixels would be bytes nobody reads. Keep your own copy for the full-resolution
|
|
698
|
+
* file. The type is sniffed from the bytes themselves rather
|
|
695
699
|
* than from whatever the file was called. Rejects with `NotFoundError` when this
|
|
696
700
|
* memory has no image, or when the service was not configured to keep originals —
|
|
697
701
|
* it says "no" instead of handing back something empty, so "a memory with no image"
|
package/package.json
CHANGED