@edirect/storage-gateway 11.0.39 → 11.0.40
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/README.md +18 -3
- package/dist/README.md +18 -3
- package/dist/package.json +1 -1
- package/package.json +1 -2
package/README.md
CHANGED
|
@@ -42,10 +42,12 @@ new StorageGatewayClient(baseUrl: string, headers?: StorageGatewayHeaders)
|
|
|
42
42
|
```
|
|
43
43
|
|
|
44
44
|
**Parameters:**
|
|
45
|
+
|
|
45
46
|
- `baseUrl` - The base URL of the Storage Gateway API
|
|
46
47
|
- `headers` (optional) - Headers to include in all requests
|
|
47
48
|
|
|
48
49
|
**Types:**
|
|
50
|
+
|
|
49
51
|
```typescript
|
|
50
52
|
interface StorageGatewayHeaders {
|
|
51
53
|
authorization: string;
|
|
@@ -72,6 +74,7 @@ const configs = await client.listStorageConfigurations({
|
|
|
72
74
|
```
|
|
73
75
|
|
|
74
76
|
**Parameters:**
|
|
77
|
+
|
|
75
78
|
- `params.skip` (optional) - Number of records to skip
|
|
76
79
|
- `params.take` (optional) - Number of records to return
|
|
77
80
|
|
|
@@ -95,6 +98,7 @@ const config = await client.createStorageConfiguration({
|
|
|
95
98
|
```
|
|
96
99
|
|
|
97
100
|
**Parameters:**
|
|
101
|
+
|
|
98
102
|
- `data` - Configuration data object
|
|
99
103
|
|
|
100
104
|
---
|
|
@@ -108,6 +112,7 @@ const config = await client.getStorageConfiguration('my-storage');
|
|
|
108
112
|
```
|
|
109
113
|
|
|
110
114
|
**Parameters:**
|
|
115
|
+
|
|
111
116
|
- `key` - The storage configuration key
|
|
112
117
|
|
|
113
118
|
---
|
|
@@ -129,6 +134,7 @@ const updated = await client.updateStorageConfiguration({
|
|
|
129
134
|
```
|
|
130
135
|
|
|
131
136
|
**Parameters:**
|
|
137
|
+
|
|
132
138
|
- `params.key` - The storage configuration key
|
|
133
139
|
- `params.data` - Updated configuration data
|
|
134
140
|
|
|
@@ -143,6 +149,7 @@ await client.deleteStorageConfiguration('my-storage');
|
|
|
143
149
|
```
|
|
144
150
|
|
|
145
151
|
**Parameters:**
|
|
152
|
+
|
|
146
153
|
- `key` - The storage configuration key to delete
|
|
147
154
|
|
|
148
155
|
---
|
|
@@ -166,6 +173,7 @@ const files = await client.listFiles({
|
|
|
166
173
|
```
|
|
167
174
|
|
|
168
175
|
**Parameters:**
|
|
176
|
+
|
|
169
177
|
- `params.storageKey` - The storage configuration key
|
|
170
178
|
- `params.path` (optional) - Path to list files from
|
|
171
179
|
|
|
@@ -186,6 +194,7 @@ const result = await client.uploadFile({
|
|
|
186
194
|
```
|
|
187
195
|
|
|
188
196
|
**Parameters:**
|
|
197
|
+
|
|
189
198
|
- `params.storageKey` - The storage configuration key
|
|
190
199
|
- `params.file` - The file to upload (File or Blob)
|
|
191
200
|
- `params.path` (optional) - Destination path for the file
|
|
@@ -211,6 +220,7 @@ const url = URL.createObjectURL(blob);
|
|
|
211
220
|
```
|
|
212
221
|
|
|
213
222
|
**Parameters:**
|
|
223
|
+
|
|
214
224
|
- `params.storageKey` - The storage configuration key
|
|
215
225
|
- `params.path` - Path to the file to download
|
|
216
226
|
|
|
@@ -233,6 +243,7 @@ console.log(info);
|
|
|
233
243
|
```
|
|
234
244
|
|
|
235
245
|
**Parameters:**
|
|
246
|
+
|
|
236
247
|
- `params.storageKey` - The storage configuration key
|
|
237
248
|
- `params.path` - Path to the file
|
|
238
249
|
|
|
@@ -250,6 +261,7 @@ await client.deleteFile({
|
|
|
250
261
|
```
|
|
251
262
|
|
|
252
263
|
**Parameters:**
|
|
264
|
+
|
|
253
265
|
- `params.storageKey` - The storage configuration key
|
|
254
266
|
- `params.path` - Path to the file to delete
|
|
255
267
|
|
|
@@ -277,9 +289,12 @@ import { StorageGatewayClient } from '@edirect/storage-gateway';
|
|
|
277
289
|
|
|
278
290
|
async function main() {
|
|
279
291
|
// Initialize client
|
|
280
|
-
const client = new StorageGatewayClient(
|
|
281
|
-
|
|
282
|
-
|
|
292
|
+
const client = new StorageGatewayClient(
|
|
293
|
+
'https://storage-gateway.example.com',
|
|
294
|
+
{
|
|
295
|
+
authorization: 'Bearer your-jwt-token',
|
|
296
|
+
}
|
|
297
|
+
);
|
|
283
298
|
|
|
284
299
|
// List available providers
|
|
285
300
|
const providers = await client.listStorageProviders();
|
package/dist/README.md
CHANGED
|
@@ -42,10 +42,12 @@ new StorageGatewayClient(baseUrl: string, headers?: StorageGatewayHeaders)
|
|
|
42
42
|
```
|
|
43
43
|
|
|
44
44
|
**Parameters:**
|
|
45
|
+
|
|
45
46
|
- `baseUrl` - The base URL of the Storage Gateway API
|
|
46
47
|
- `headers` (optional) - Headers to include in all requests
|
|
47
48
|
|
|
48
49
|
**Types:**
|
|
50
|
+
|
|
49
51
|
```typescript
|
|
50
52
|
interface StorageGatewayHeaders {
|
|
51
53
|
authorization: string;
|
|
@@ -72,6 +74,7 @@ const configs = await client.listStorageConfigurations({
|
|
|
72
74
|
```
|
|
73
75
|
|
|
74
76
|
**Parameters:**
|
|
77
|
+
|
|
75
78
|
- `params.skip` (optional) - Number of records to skip
|
|
76
79
|
- `params.take` (optional) - Number of records to return
|
|
77
80
|
|
|
@@ -95,6 +98,7 @@ const config = await client.createStorageConfiguration({
|
|
|
95
98
|
```
|
|
96
99
|
|
|
97
100
|
**Parameters:**
|
|
101
|
+
|
|
98
102
|
- `data` - Configuration data object
|
|
99
103
|
|
|
100
104
|
---
|
|
@@ -108,6 +112,7 @@ const config = await client.getStorageConfiguration('my-storage');
|
|
|
108
112
|
```
|
|
109
113
|
|
|
110
114
|
**Parameters:**
|
|
115
|
+
|
|
111
116
|
- `key` - The storage configuration key
|
|
112
117
|
|
|
113
118
|
---
|
|
@@ -129,6 +134,7 @@ const updated = await client.updateStorageConfiguration({
|
|
|
129
134
|
```
|
|
130
135
|
|
|
131
136
|
**Parameters:**
|
|
137
|
+
|
|
132
138
|
- `params.key` - The storage configuration key
|
|
133
139
|
- `params.data` - Updated configuration data
|
|
134
140
|
|
|
@@ -143,6 +149,7 @@ await client.deleteStorageConfiguration('my-storage');
|
|
|
143
149
|
```
|
|
144
150
|
|
|
145
151
|
**Parameters:**
|
|
152
|
+
|
|
146
153
|
- `key` - The storage configuration key to delete
|
|
147
154
|
|
|
148
155
|
---
|
|
@@ -166,6 +173,7 @@ const files = await client.listFiles({
|
|
|
166
173
|
```
|
|
167
174
|
|
|
168
175
|
**Parameters:**
|
|
176
|
+
|
|
169
177
|
- `params.storageKey` - The storage configuration key
|
|
170
178
|
- `params.path` (optional) - Path to list files from
|
|
171
179
|
|
|
@@ -186,6 +194,7 @@ const result = await client.uploadFile({
|
|
|
186
194
|
```
|
|
187
195
|
|
|
188
196
|
**Parameters:**
|
|
197
|
+
|
|
189
198
|
- `params.storageKey` - The storage configuration key
|
|
190
199
|
- `params.file` - The file to upload (File or Blob)
|
|
191
200
|
- `params.path` (optional) - Destination path for the file
|
|
@@ -211,6 +220,7 @@ const url = URL.createObjectURL(blob);
|
|
|
211
220
|
```
|
|
212
221
|
|
|
213
222
|
**Parameters:**
|
|
223
|
+
|
|
214
224
|
- `params.storageKey` - The storage configuration key
|
|
215
225
|
- `params.path` - Path to the file to download
|
|
216
226
|
|
|
@@ -233,6 +243,7 @@ console.log(info);
|
|
|
233
243
|
```
|
|
234
244
|
|
|
235
245
|
**Parameters:**
|
|
246
|
+
|
|
236
247
|
- `params.storageKey` - The storage configuration key
|
|
237
248
|
- `params.path` - Path to the file
|
|
238
249
|
|
|
@@ -250,6 +261,7 @@ await client.deleteFile({
|
|
|
250
261
|
```
|
|
251
262
|
|
|
252
263
|
**Parameters:**
|
|
264
|
+
|
|
253
265
|
- `params.storageKey` - The storage configuration key
|
|
254
266
|
- `params.path` - Path to the file to delete
|
|
255
267
|
|
|
@@ -277,9 +289,12 @@ import { StorageGatewayClient } from '@edirect/storage-gateway';
|
|
|
277
289
|
|
|
278
290
|
async function main() {
|
|
279
291
|
// Initialize client
|
|
280
|
-
const client = new StorageGatewayClient(
|
|
281
|
-
|
|
282
|
-
|
|
292
|
+
const client = new StorageGatewayClient(
|
|
293
|
+
'https://storage-gateway.example.com',
|
|
294
|
+
{
|
|
295
|
+
authorization: 'Bearer your-jwt-token',
|
|
296
|
+
}
|
|
297
|
+
);
|
|
283
298
|
|
|
284
299
|
// List available providers
|
|
285
300
|
const providers = await client.listStorageProviders();
|
package/dist/package.json
CHANGED
package/package.json
CHANGED
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@edirect/storage-gateway",
|
|
3
|
-
"version": "11.0.
|
|
3
|
+
"version": "11.0.40",
|
|
4
4
|
"packageScope": "@edirect",
|
|
5
5
|
"main": "./dist/src/index.js",
|
|
6
6
|
"types": "./dist/src/index.d.ts",
|
|
7
7
|
"exports": {
|
|
8
8
|
".": {
|
|
9
|
-
"development": "./src/index.ts",
|
|
10
9
|
"import": "./dist/src/index.js",
|
|
11
10
|
"default": "./dist/src/index.js",
|
|
12
11
|
"require": "./dist/src/index.js",
|