@withgateway/sdk 0.2.1 → 0.2.3
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/cli.js +438 -81
- package/dist/cli.js.map +1 -1
- package/dist/cli.mjs +439 -82
- package/dist/cli.mjs.map +1 -1
- package/dist/files/index.js +9 -5
- package/dist/files/index.js.map +1 -1
- package/dist/files/index.mjs +9 -5
- package/dist/files/index.mjs.map +1 -1
- package/dist/index.d.mts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +21 -10
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +20 -10
- package/dist/index.mjs.map +1 -1
- package/dist/traces/index.js +9 -5
- package/dist/traces/index.js.map +1 -1
- package/dist/traces/index.mjs +9 -5
- package/dist/traces/index.mjs.map +1 -1
- package/dist/tracing/index.js +1 -1
- package/dist/tracing/index.js.map +1 -1
- package/dist/tracing/index.mjs +1 -1
- package/dist/tracing/index.mjs.map +1 -1
- package/dist/worlds/index.d.mts +7 -1
- package/dist/worlds/index.d.ts +7 -1
- package/dist/worlds/index.js +19 -9
- package/dist/worlds/index.js.map +1 -1
- package/dist/worlds/index.mjs +19 -9
- package/dist/worlds/index.mjs.map +1 -1
- package/package.json +1 -1
- package/runtime/gatewaysdk/environment/schema/api.py +61 -3
- package/runtime/gatewaysdk/environment/schema/batch.py +5 -1
- package/runtime/gatewaysdk/environment/schema/connector.py +11 -0
- package/runtime/gatewaysdk/environment/schema/data.py +76 -2
- package/runtime/gatewaysdk/environment/schema/dependencies.py +11 -1
- package/runtime/gatewaysdk/environment/schema/host.py +8 -17
- package/runtime/gatewaysdk/environment/schema/local.py +105 -19
- package/runtime/gatewaysdk/environment/schema/mapping.py +13 -1
- package/runtime/gatewaysdk/environment/schema/platform.py +32 -5
- package/runtime/gatewaysdk/environment/schema/skills/benchmarks-getting-started/SKILL.md +4 -1
- package/runtime/gatewaysdk/environment/schema/skills/worlds-getting-started/SKILL.md +5 -5
- package/runtime/gatewaysdk/environment/schema/tools_world.py +5 -1
- package/runtime/gatewaysdk/environment/schema/validation.py +4 -3
- package/skills/benchmarks-getting-started/SKILL.md +4 -1
- package/skills/worlds-getting-started/SKILL.md +5 -5
package/dist/traces/index.mjs
CHANGED
|
@@ -172,13 +172,10 @@ async function apiRequest(options, method, path3, body) {
|
|
|
172
172
|
...body === void 0 ? {} : { body: JSON.stringify(body) }
|
|
173
173
|
});
|
|
174
174
|
const text = await res.text();
|
|
175
|
-
if (!res.ok)
|
|
176
|
-
throw new Error(
|
|
177
|
-
`${method} ${path3} -> ${res.status}: ${text.slice(0, 400)}`
|
|
178
|
-
);
|
|
179
|
-
}
|
|
175
|
+
if (!res.ok) throw new ApiError(res.status, method, path3, text.slice(0, 400));
|
|
180
176
|
return JSON.parse(text);
|
|
181
177
|
}
|
|
178
|
+
var ApiError;
|
|
182
179
|
var init_worlds = __esm({
|
|
183
180
|
"src/worlds/index.ts"() {
|
|
184
181
|
"use strict";
|
|
@@ -193,6 +190,13 @@ var init_worlds = __esm({
|
|
|
193
190
|
init_query();
|
|
194
191
|
init_migrate();
|
|
195
192
|
init_ingest();
|
|
193
|
+
ApiError = class extends Error {
|
|
194
|
+
constructor(status, method, path3, body) {
|
|
195
|
+
super(`${method} ${path3} -> ${status}: ${body}`);
|
|
196
|
+
this.status = status;
|
|
197
|
+
this.name = "ApiError";
|
|
198
|
+
}
|
|
199
|
+
};
|
|
196
200
|
}
|
|
197
201
|
});
|
|
198
202
|
|