@gpt-platform/admin 0.1.5 → 0.2.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.
package/dist/index.js CHANGED
@@ -852,13 +852,8 @@ var createClient = (config = {}) => {
852
852
  };
853
853
  };
854
854
 
855
- // src/_internal/client.gen.ts
856
- var client = createClient(
857
- createConfig({ baseUrl: "http://localhost:33333" })
858
- );
859
-
860
855
  // src/version.ts
861
- var SDK_VERSION = "0.1.4";
856
+ var SDK_VERSION = "0.2.0";
862
857
  var DEFAULT_API_VERSION = "2026-02-25";
863
858
 
864
859
  // src/base-client.ts
@@ -875,8 +870,6 @@ function isSecureUrl(url) {
875
870
  }
876
871
  var BaseClient = class {
877
872
  constructor(config = {}) {
878
- /** The underlying HTTP client instance, exposed for namespace factories */
879
- this.clientInstance = client;
880
873
  this.config = config;
881
874
  this.apiVersion = config.apiVersion ?? DEFAULT_API_VERSION;
882
875
  if (config.baseUrl && !isSecureUrl(config.baseUrl)) {
@@ -884,10 +877,10 @@ var BaseClient = class {
884
877
  "[GPT Core SDK] Warning: Using non-HTTPS URL. Credentials may be transmitted insecurely. Use HTTPS in production environments."
885
878
  );
886
879
  }
887
- if (config.baseUrl) {
888
- client.setConfig({ baseUrl: config.baseUrl });
889
- }
890
- client.interceptors.request.use((req) => {
880
+ const clientConfig = {};
881
+ if (config.baseUrl) clientConfig["baseUrl"] = config.baseUrl;
882
+ this.clientInstance = createClient(createConfig(clientConfig));
883
+ this.clientInstance.interceptors.request.use((req) => {
891
884
  const requestUrl = req.url || config.baseUrl || "";
892
885
  if ((config.apiKey || config.token) && !isSecureUrl(requestUrl)) {
893
886
  console.warn(
@@ -1369,6 +1362,11 @@ var RequestBuilder = class {
1369
1362
  }
1370
1363
  };
1371
1364
 
1365
+ // src/_internal/client.gen.ts
1366
+ var client = createClient(
1367
+ createConfig({ baseUrl: "http://localhost:33333" })
1368
+ );
1369
+
1372
1370
  // src/_internal/sdk.gen.ts
1373
1371
  var patchAdminAccountsByIdCredit = (options) => (options.client ?? client).patch({
1374
1372
  security: [{ scheme: "bearer", type: "http" }],