@sygna/bridge-util 2.0.1 → 2.0.2
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 +1 -1
- package/src/api/index.js +2 -1
package/package.json
CHANGED
package/src/api/index.js
CHANGED
|
@@ -101,6 +101,7 @@ class API {
|
|
|
101
101
|
const headers = {
|
|
102
102
|
'Content-Type': 'application/json',
|
|
103
103
|
'x-api-key': this.api_key,
|
|
104
|
+
'User-Agent': 'util-js/2.0.2"'
|
|
104
105
|
};
|
|
105
106
|
const response = await fetch(url, {
|
|
106
107
|
method: 'POST',
|
|
@@ -115,7 +116,7 @@ class API {
|
|
|
115
116
|
* @param {string} url
|
|
116
117
|
*/
|
|
117
118
|
async getSB(url) {
|
|
118
|
-
const headers = { 'x-api-key': this.api_key };
|
|
119
|
+
const headers = { 'x-api-key': this.api_key, 'User-Agent': 'util-js/2.0.2"' };
|
|
119
120
|
const response = await fetch(url, { headers: headers });
|
|
120
121
|
return await response.json();
|
|
121
122
|
}
|