@bitbar/cloud-api-client 1.4.0 → 1.4.1
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.
|
@@ -3,7 +3,6 @@ import { APIEntity } from './APIEntity';
|
|
|
3
3
|
import { APIList } from './APIList';
|
|
4
4
|
import { FilesQueryParams } from './class/FilesQueryParams';
|
|
5
5
|
import { FileData, UploadObj, UserFile } from './models/UserFile';
|
|
6
|
-
import FormData from 'form-data';
|
|
7
6
|
export declare class APIListFiles extends APIList<UserFile, FilesQueryParams, FileData | FormData> {
|
|
8
7
|
constructor(parent: APIEntity | API);
|
|
9
8
|
upload(obj: UploadObj): this;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
/* @bitbar/cloud-api-client v1.4.
|
|
1
|
+
/* @bitbar/cloud-api-client v1.4.1 | Copyright 2025 (c) SmartBear Software and contributors | .git/blob/master/LICENSE */
|
|
2
2
|
(function (global, factory) {
|
|
3
|
-
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('
|
|
4
|
-
typeof define === 'function' && define.amd ? define(['exports', '
|
|
5
|
-
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global["bitbar-cloud-api-client"] = {}, global
|
|
6
|
-
})(this, (function (exports,
|
|
3
|
+
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@bitbar/finka'), require('qs'), require('node-abort-controller')) :
|
|
4
|
+
typeof define === 'function' && define.amd ? define(['exports', '@bitbar/finka', 'qs', 'node-abort-controller'], factory) :
|
|
5
|
+
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global["bitbar-cloud-api-client"] = {}, global["@bitbar/finka"], global.qs, global["node-abort-controller"]));
|
|
6
|
+
})(this, (function (exports, finka, qs, nodeAbortController) { 'use strict';
|
|
7
7
|
|
|
8
|
-
var version = "1.4.
|
|
8
|
+
var version = "1.4.1";
|
|
9
9
|
|
|
10
10
|
/******************************************************************************
|
|
11
11
|
Copyright (c) Microsoft Corporation.
|
|
@@ -1599,6 +1599,7 @@
|
|
|
1599
1599
|
}
|
|
1600
1600
|
nodeUpload(file) {
|
|
1601
1601
|
const fs = require('fs');
|
|
1602
|
+
const FormData = require('form-data');
|
|
1602
1603
|
const form = new FormData();
|
|
1603
1604
|
form.append('file', fs.createReadStream(file.dir + '/' + file.filename), {
|
|
1604
1605
|
filename: file.filename
|
|
@@ -1791,6 +1792,7 @@
|
|
|
1791
1792
|
}
|
|
1792
1793
|
}
|
|
1793
1794
|
|
|
1795
|
+
const axios = require('axios').default;
|
|
1794
1796
|
if (globalThis.isNodeJs) {
|
|
1795
1797
|
axios.defaults.headers.common['User-Agent'] = `Bitbar Cloud API Client for JavaScript v${version}`;
|
|
1796
1798
|
}
|