@plugable-io/js 0.0.2 → 0.0.3

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.
Files changed (2) hide show
  1. package/README.md +6 -3
  2. package/package.json +12 -2
package/README.md CHANGED
@@ -66,7 +66,9 @@ const file = fileInput.files[0];
66
66
  try {
67
67
  const uploadedFile = await client.upload(file, {
68
68
  metadata: {
69
- custom_key: 'custom_value'
69
+ type: 'invoice',
70
+ order_id: 'ord_12345',
71
+ purchased: ['product_1', 'product_2']
70
72
  },
71
73
  onProgress: (percent) => {
72
74
  console.log(`Upload progress: ${percent}%`);
@@ -85,17 +87,18 @@ The results depend on your bucket's usage pattern:
85
87
  - **Organization**: Returns files matching the user's `org_id`.
86
88
  - **Personal**: Returns files matching the user's `owner_id`.
87
89
 
90
+
88
91
  ```typescript
89
92
  // Example: Find all invoices for a specific order
90
93
  const response = await client.list({
91
94
  metadata: {
92
95
  type: 'invoice',
93
- order_id: 'ord_12345'
96
+ purchased: ['product_1']
94
97
  }
95
98
  });
96
- ```
97
99
 
98
100
  console.log('Files:', response.files);
101
+
99
102
  ```
100
103
 
101
104
  ### Getting a File
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@plugable-io/js",
3
- "version": "0.0.2",
3
+ "version": "0.0.3",
4
4
  "description": "JavaScript client for Plugable File Management API",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",
@@ -13,7 +13,17 @@
13
13
  "dev": "tsup src/index.ts --format cjs,esm --dts --watch",
14
14
  "lint": "tsc --noEmit"
15
15
  },
16
- "keywords": [],
16
+ "keywords": [
17
+ "file-upload",
18
+ "storage",
19
+ "file-management",
20
+ "cloud-storage",
21
+ "typescript",
22
+ "client",
23
+ "sdk",
24
+ "plugable",
25
+ "buckets"
26
+ ],
17
27
  "author": "",
18
28
  "license": "MIT",
19
29
  "dependencies": {