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 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 = (0, config_1.getConfig)();
11
+ // const baseConfig = getConfig();
13
12
  this.client = axios_1.default.create({
14
- baseURL: config?.baseURL || baseConfig.apiUrl || 'https://data.triggerx.network', //http://localhost:9002 , https://data.triggerx.network
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
- var __importDefault = (this && this.__importDefault) || function (mod) {
3
- return (mod && mod.__esModule) ? mod : { "default": mod };
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 || '',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sdk-triggerx",
3
- "version": "0.1.7",
3
+ "version": "0.1.8",
4
4
  "description": "SDK for interacting with the TriggerX backend and smart contracts.",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",