pinata 1.0.4 → 1.0.6

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/index.d.mts CHANGED
@@ -14,9 +14,11 @@ type UploadResponse = {
14
14
  name: string;
15
15
  cid: string;
16
16
  size: number;
17
+ created_at: string;
17
18
  number_of_files: number;
18
19
  mime_type: string;
19
20
  user_id: string;
21
+ group_id: string | null;
20
22
  };
21
23
  type FileObject = {
22
24
  name: string;
@@ -49,7 +51,7 @@ type FileListItem = {
49
51
  size: number;
50
52
  number_of_files: number;
51
53
  mime_type: string;
52
- group_id: string;
54
+ group_id: string | null;
53
55
  created_at: string;
54
56
  };
55
57
  type FileListResponse = {
package/dist/index.d.ts CHANGED
@@ -14,9 +14,11 @@ type UploadResponse = {
14
14
  name: string;
15
15
  cid: string;
16
16
  size: number;
17
+ created_at: string;
17
18
  number_of_files: number;
18
19
  mime_type: string;
19
20
  user_id: string;
21
+ group_id: string | null;
20
22
  };
21
23
  type FileObject = {
22
24
  name: string;
@@ -49,7 +51,7 @@ type FileListItem = {
49
51
  size: number;
50
52
  number_of_files: number;
51
53
  mime_type: string;
52
- group_id: string;
54
+ group_id: string | null;
53
55
  created_at: string;
54
56
  };
55
57
  type FileListResponse = {
package/dist/index.js CHANGED
@@ -154,7 +154,8 @@ var uploadFile = async (config, file, options) => {
154
154
  );
155
155
  }
156
156
  const res = await request.json();
157
- return res;
157
+ const resData = res.data;
158
+ return resData;
158
159
  } catch (error) {
159
160
  if (error instanceof PinataError) {
160
161
  throw error;
@@ -216,7 +217,8 @@ var uploadBase64 = async (config, base64String, options) => {
216
217
  );
217
218
  }
218
219
  const res = await request.json();
219
- return res;
220
+ const resData = res.data;
221
+ return resData;
220
222
  } catch (error) {
221
223
  if (error instanceof PinataError) {
222
224
  throw error;
@@ -290,7 +292,8 @@ var uploadUrl = async (config, url, options) => {
290
292
  );
291
293
  }
292
294
  const res = await request.json();
293
- return res;
295
+ const resData = res.data;
296
+ return resData;
294
297
  } catch (error) {
295
298
  if (error instanceof PinataError) {
296
299
  throw error;
@@ -352,7 +355,8 @@ var uploadJson = async (config, jsonData, options) => {
352
355
  );
353
356
  }
354
357
  const res = await request.json();
355
- return res;
358
+ const resData = res.data;
359
+ return resData;
356
360
  } catch (error) {
357
361
  if (error instanceof PinataError) {
358
362
  throw error;