sdk-triggerx 0.1.7 → 0.1.8
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/client.js +2 -3
- package/dist/config.js +2 -5
- package/package.json +1 -1
package/dist/client.js
CHANGED
|
@@ -5,13 +5,12 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.TriggerXClient = void 0;
|
|
7
7
|
const axios_1 = __importDefault(require("axios"));
|
|
8
|
-
const config_1 = require("./config");
|
|
9
8
|
class TriggerXClient {
|
|
10
9
|
constructor(apiKey, config) {
|
|
11
10
|
this.apiKey = apiKey; // Initialize the apiKey
|
|
12
|
-
const baseConfig =
|
|
11
|
+
// const baseConfig = getConfig();
|
|
13
12
|
this.client = axios_1.default.create({
|
|
14
|
-
baseURL:
|
|
13
|
+
baseURL: 'https://data.triggerx.network',
|
|
15
14
|
headers: { 'Authorization': `Bearer ${this.apiKey}` }, // Set the API key here
|
|
16
15
|
...config,
|
|
17
16
|
});
|
package/dist/config.js
CHANGED
|
@@ -1,11 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
// import dotenv from 'dotenv';
|
|
3
|
+
// dotenv.config();
|
|
5
4
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
5
|
exports.getConfig = getConfig;
|
|
7
|
-
const dotenv_1 = __importDefault(require("dotenv"));
|
|
8
|
-
dotenv_1.default.config();
|
|
9
6
|
function getConfig() {
|
|
10
7
|
return {
|
|
11
8
|
apiKey: process.env.API_KEY || '',
|