@fias/create-fias-plugin 1.10.0 → 1.11.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fias/create-fias-plugin",
3
- "version": "1.10.0",
3
+ "version": "1.11.0",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -1,4 +1,4 @@
1
- <!-- fias-sdk-guide-version: 2.17.0 -->
1
+ <!-- fias-sdk-guide-version: 2.18.0 -->
2
2
 
3
3
  # FIAS Plugin Development Guide
4
4
 
@@ -665,7 +665,7 @@ await invoke({ query: 'latest EU AI Act enforcement dates' });
665
665
 
666
666
  ### `useVaultDocuments()` — User-owned Vault documents
667
667
 
668
- **Permissions:** `vault:documents:read` (list / read / readBytes / getDownloadUrl / search), `vault:documents:write` (write / update / delete / attach / detach / upload)
668
+ **Permissions:** `vault:documents:read` (list / read / readBytes / getDownloadUrl / search), `vault:documents:write` (write / saveContent / update / delete / attach / detach / upload)
669
669
  **Returns:** `VaultDocumentsApi`
670
670
 
671
671
  The Vault is the platform's persistent document store for the signed-in user. Distinct from `useFiasStorage` (per-plugin sandbox): Vault docs live in the user's My Data, survive plugin uninstall, and can be cross-referenced from other arches. Documents this arche creates are scoped to it (`source_arche_id`) and surfaced to the user under `/My-Fias/Arches/<archeId>/`.
@@ -709,6 +709,15 @@ const result = await vault.upload(bytes, {
709
709
  // but still appears in list() — don't assume every listed doc has bytes.
710
710
  const { bytes: saved } = await vault.readBytes(documentId);
711
711
 
712
+ // Overwrite a document THIS arche created IN PLACE — same documentId, bytes
713
+ // replaced, no version history. The autosave path (a spreadsheet saving as
714
+ // the user works); to publish a distinct new version use write({
715
+ // replacesDocumentId }) instead. UTF-8 text, ≤ 200 KB (OWN_DOCUMENT_SAVE_TOO_LARGE
716
+ // names the cap). Debounce: a few seconds of idle plus blur/close — never per
717
+ // keystroke — and surface RATE_LIMIT verbatim rather than retrying. A save
718
+ // drops the document's search index and does not re-run extraction.
719
+ await vault.saveContent({ documentId, content: JSON.stringify(sheet) });
720
+
712
721
  // Semantic search across documents this arche owns
713
722
  // (burns user credits per the AI Markup Invariant — call sparingly)
714
723
  const { matches } = await vault.search('quarterly revenue', { topK: 5 });
@@ -1,4 +1,4 @@
1
- <!-- fias-sdk-guide-version: 2.17.0 -->
1
+ <!-- fias-sdk-guide-version: 2.18.0 -->
2
2
 
3
3
  # FIAS Plugin Development Guide
4
4
 
@@ -665,7 +665,7 @@ await invoke({ query: 'latest EU AI Act enforcement dates' });
665
665
 
666
666
  ### `useVaultDocuments()` — User-owned Vault documents
667
667
 
668
- **Permissions:** `vault:documents:read` (list / read / readBytes / getDownloadUrl / search), `vault:documents:write` (write / update / delete / attach / detach / upload)
668
+ **Permissions:** `vault:documents:read` (list / read / readBytes / getDownloadUrl / search), `vault:documents:write` (write / saveContent / update / delete / attach / detach / upload)
669
669
  **Returns:** `VaultDocumentsApi`
670
670
 
671
671
  The Vault is the platform's persistent document store for the signed-in user. Distinct from `useFiasStorage` (per-plugin sandbox): Vault docs live in the user's My Data, survive plugin uninstall, and can be cross-referenced from other arches. Documents this arche creates are scoped to it (`source_arche_id`) and surfaced to the user under `/My-Fias/Arches/<archeId>/`.
@@ -709,6 +709,15 @@ const result = await vault.upload(bytes, {
709
709
  // but still appears in list() — don't assume every listed doc has bytes.
710
710
  const { bytes: saved } = await vault.readBytes(documentId);
711
711
 
712
+ // Overwrite a document THIS arche created IN PLACE — same documentId, bytes
713
+ // replaced, no version history. The autosave path (a spreadsheet saving as
714
+ // the user works); to publish a distinct new version use write({
715
+ // replacesDocumentId }) instead. UTF-8 text, ≤ 200 KB (OWN_DOCUMENT_SAVE_TOO_LARGE
716
+ // names the cap). Debounce: a few seconds of idle plus blur/close — never per
717
+ // keystroke — and surface RATE_LIMIT verbatim rather than retrying. A save
718
+ // drops the document's search index and does not re-run extraction.
719
+ await vault.saveContent({ documentId, content: JSON.stringify(sheet) });
720
+
712
721
  // Semantic search across documents this arche owns
713
722
  // (burns user credits per the AI Markup Invariant — call sparingly)
714
723
  const { matches } = await vault.search('quarterly revenue', { topK: 5 });