opensteer 0.9.4 → 0.9.6
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/{chunk-ZRF7WMS3.js → chunk-3I3A5OLB.js} +3 -3
- package/dist/{chunk-ZRF7WMS3.js.map → chunk-3I3A5OLB.js.map} +1 -1
- package/dist/{chunk-GSCQQKZZ.js → chunk-3XBQRZZC.js} +221 -6
- package/dist/chunk-3XBQRZZC.js.map +1 -0
- package/dist/{chunk-GEUHKPC2.js → chunk-BVRIPCWA.js} +878 -572
- package/dist/chunk-BVRIPCWA.js.map +1 -0
- package/dist/chunk-L4NF74KI.js +458 -0
- package/dist/chunk-L4NF74KI.js.map +1 -0
- package/dist/cli/bin.cjs +1313 -494
- package/dist/cli/bin.cjs.map +1 -1
- package/dist/cli/bin.js +235 -108
- package/dist/cli/bin.js.map +1 -1
- package/dist/index.cjs +1152 -647
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +37 -460
- package/dist/index.d.ts +37 -460
- package/dist/index.js +3 -4
- package/dist/local-view/serve-entry.cjs +5354 -4
- package/dist/local-view/serve-entry.cjs.map +1 -1
- package/dist/local-view/serve-entry.js +1 -1
- package/dist/opensteer-UGA6YBRN.js +6 -0
- package/dist/{opensteer-PJI7VUIT.js.map → opensteer-UGA6YBRN.js.map} +1 -1
- package/dist/{session-control-M3JD7ZKA.js → session-control-U3L5H2ZI.js} +3 -3
- package/dist/{session-control-M3JD7ZKA.js.map → session-control-U3L5H2ZI.js.map} +1 -1
- package/package.json +7 -7
- package/skills/opensteer/SKILL.md +134 -94
- package/dist/chunk-GEUHKPC2.js.map +0 -1
- package/dist/chunk-GSCQQKZZ.js.map +0 -1
- package/dist/chunk-HQCMXRBE.js +0 -335
- package/dist/chunk-HQCMXRBE.js.map +0 -1
- package/dist/chunk-KCINASQC.js +0 -3
- package/dist/chunk-KCINASQC.js.map +0 -1
- package/dist/opensteer-PJI7VUIT.js +0 -6
|
@@ -295,6 +295,218 @@ function mediaTypeExtension(mediaType) {
|
|
|
295
295
|
}
|
|
296
296
|
}
|
|
297
297
|
|
|
298
|
+
// ../protocol/src/json.ts
|
|
299
|
+
var JSON_SCHEMA_DRAFT_2020_12 = "https://json-schema.org/draft/2020-12/schema";
|
|
300
|
+
function defineSchema(schema) {
|
|
301
|
+
return schema;
|
|
302
|
+
}
|
|
303
|
+
function stringSchema(options = {}) {
|
|
304
|
+
return defineSchema({
|
|
305
|
+
type: "string",
|
|
306
|
+
...options
|
|
307
|
+
});
|
|
308
|
+
}
|
|
309
|
+
function numberSchema(options = {}) {
|
|
310
|
+
return defineSchema({
|
|
311
|
+
type: "number",
|
|
312
|
+
...options
|
|
313
|
+
});
|
|
314
|
+
}
|
|
315
|
+
function integerSchema(options = {}) {
|
|
316
|
+
return defineSchema({
|
|
317
|
+
type: "integer",
|
|
318
|
+
...options
|
|
319
|
+
});
|
|
320
|
+
}
|
|
321
|
+
function literalSchema(value, options = {}) {
|
|
322
|
+
return defineSchema({
|
|
323
|
+
const: value,
|
|
324
|
+
...options
|
|
325
|
+
});
|
|
326
|
+
}
|
|
327
|
+
function enumSchema(values, options = {}) {
|
|
328
|
+
return defineSchema({
|
|
329
|
+
enum: values,
|
|
330
|
+
...options
|
|
331
|
+
});
|
|
332
|
+
}
|
|
333
|
+
function arraySchema(items, options = {}) {
|
|
334
|
+
return defineSchema({
|
|
335
|
+
type: "array",
|
|
336
|
+
items,
|
|
337
|
+
...options
|
|
338
|
+
});
|
|
339
|
+
}
|
|
340
|
+
function objectSchema(properties, options = {}) {
|
|
341
|
+
const { required, additionalProperties, ...rest } = options;
|
|
342
|
+
return defineSchema({
|
|
343
|
+
type: "object",
|
|
344
|
+
properties,
|
|
345
|
+
...rest,
|
|
346
|
+
...required === void 0 ? {} : { required },
|
|
347
|
+
...additionalProperties === void 0 ? { additionalProperties: false } : { additionalProperties }
|
|
348
|
+
});
|
|
349
|
+
}
|
|
350
|
+
function recordSchema(valueSchema, options = {}) {
|
|
351
|
+
return defineSchema({
|
|
352
|
+
type: "object",
|
|
353
|
+
additionalProperties: valueSchema,
|
|
354
|
+
...options
|
|
355
|
+
});
|
|
356
|
+
}
|
|
357
|
+
function oneOfSchema(members, options = {}) {
|
|
358
|
+
return defineSchema({
|
|
359
|
+
oneOf: members,
|
|
360
|
+
...options
|
|
361
|
+
});
|
|
362
|
+
}
|
|
363
|
+
|
|
364
|
+
// ../protocol/src/capabilities.ts
|
|
365
|
+
var opensteerCapabilities = [
|
|
366
|
+
"sessions.manage",
|
|
367
|
+
"pages.manage",
|
|
368
|
+
"pages.navigate",
|
|
369
|
+
"input.pointer",
|
|
370
|
+
"input.keyboard",
|
|
371
|
+
"input.touch",
|
|
372
|
+
"artifacts.screenshot",
|
|
373
|
+
"execution.pause",
|
|
374
|
+
"execution.resume",
|
|
375
|
+
"execution.freeze",
|
|
376
|
+
"inspect.pages",
|
|
377
|
+
"inspect.frames",
|
|
378
|
+
"inspect.html",
|
|
379
|
+
"inspect.domSnapshot",
|
|
380
|
+
"inspect.text",
|
|
381
|
+
"inspect.attributes",
|
|
382
|
+
"inspect.hitTest",
|
|
383
|
+
"inspect.viewportMetrics",
|
|
384
|
+
"inspect.network",
|
|
385
|
+
"inspect.networkBodies",
|
|
386
|
+
"inspect.cookies",
|
|
387
|
+
"inspect.localStorage",
|
|
388
|
+
"inspect.sessionStorage",
|
|
389
|
+
"inspect.indexedDb",
|
|
390
|
+
"transport.sessionHttp",
|
|
391
|
+
"instrumentation.initScripts",
|
|
392
|
+
"instrumentation.routing",
|
|
393
|
+
"events.pageLifecycle",
|
|
394
|
+
"events.dialog",
|
|
395
|
+
"events.download",
|
|
396
|
+
"events.chooser",
|
|
397
|
+
"events.worker",
|
|
398
|
+
"events.console",
|
|
399
|
+
"events.pageError",
|
|
400
|
+
"events.websocket",
|
|
401
|
+
"events.eventStream",
|
|
402
|
+
"events.executionState",
|
|
403
|
+
"surface.rest",
|
|
404
|
+
"surface.mcp"
|
|
405
|
+
];
|
|
406
|
+
var opensteerCapabilitySchema = enumSchema(opensteerCapabilities, {
|
|
407
|
+
title: "OpensteerCapability"
|
|
408
|
+
});
|
|
409
|
+
var opensteerCapabilitySetSchema = arraySchema(opensteerCapabilitySchema, {
|
|
410
|
+
title: "OpensteerCapabilitySet",
|
|
411
|
+
uniqueItems: true
|
|
412
|
+
});
|
|
413
|
+
var opensteerCapabilityDescriptorSchema = objectSchema(
|
|
414
|
+
{
|
|
415
|
+
key: opensteerCapabilitySchema,
|
|
416
|
+
description: stringSchema(),
|
|
417
|
+
stability: enumSchema(["stable", "experimental"])
|
|
418
|
+
},
|
|
419
|
+
{
|
|
420
|
+
title: "OpensteerCapabilityDescriptor",
|
|
421
|
+
required: ["key", "description", "stability"]
|
|
422
|
+
}
|
|
423
|
+
);
|
|
424
|
+
arraySchema(
|
|
425
|
+
opensteerCapabilityDescriptorSchema,
|
|
426
|
+
{
|
|
427
|
+
title: "OpensteerCapabilityDescriptorList",
|
|
428
|
+
uniqueItems: true
|
|
429
|
+
}
|
|
430
|
+
);
|
|
431
|
+
|
|
432
|
+
// ../protocol/src/errors.ts
|
|
433
|
+
var opensteerErrorCodes = [
|
|
434
|
+
"invalid-request",
|
|
435
|
+
"invalid-argument",
|
|
436
|
+
"invalid-ref",
|
|
437
|
+
"unsupported-version",
|
|
438
|
+
"unsupported-operation",
|
|
439
|
+
"unsupported-capability",
|
|
440
|
+
"not-found",
|
|
441
|
+
"stale-node-ref",
|
|
442
|
+
"session-closed",
|
|
443
|
+
"page-closed",
|
|
444
|
+
"frame-detached",
|
|
445
|
+
"timeout",
|
|
446
|
+
"navigation-failed",
|
|
447
|
+
"permission-denied",
|
|
448
|
+
"conflict",
|
|
449
|
+
"profile-unavailable",
|
|
450
|
+
"auth-failure",
|
|
451
|
+
"auth-recovery-failed",
|
|
452
|
+
"browser-required",
|
|
453
|
+
"rate-limited",
|
|
454
|
+
"operation-failed",
|
|
455
|
+
"internal"
|
|
456
|
+
];
|
|
457
|
+
var OpensteerProtocolError = class extends Error {
|
|
458
|
+
code;
|
|
459
|
+
retriable;
|
|
460
|
+
capability;
|
|
461
|
+
details;
|
|
462
|
+
constructor(code, message, options = {}) {
|
|
463
|
+
super(message, { cause: options.cause });
|
|
464
|
+
this.name = "OpensteerProtocolError";
|
|
465
|
+
this.code = code;
|
|
466
|
+
this.retriable = options.retriable ?? false;
|
|
467
|
+
this.capability = options.capability;
|
|
468
|
+
this.details = options.details;
|
|
469
|
+
}
|
|
470
|
+
};
|
|
471
|
+
function createOpensteerError(code, message, options = {}) {
|
|
472
|
+
return {
|
|
473
|
+
code,
|
|
474
|
+
message,
|
|
475
|
+
retriable: options.retriable ?? false,
|
|
476
|
+
...options.capability === void 0 ? {} : { capability: options.capability },
|
|
477
|
+
...options.details === void 0 ? {} : { details: options.details }
|
|
478
|
+
};
|
|
479
|
+
}
|
|
480
|
+
function isOpensteerProtocolError(value) {
|
|
481
|
+
return value instanceof OpensteerProtocolError;
|
|
482
|
+
}
|
|
483
|
+
function toOpensteerError(error) {
|
|
484
|
+
return createOpensteerError(error.code, error.message, {
|
|
485
|
+
retriable: error.retriable,
|
|
486
|
+
...error.capability === void 0 ? {} : { capability: error.capability },
|
|
487
|
+
...error.details === void 0 ? {} : { details: error.details }
|
|
488
|
+
});
|
|
489
|
+
}
|
|
490
|
+
var opensteerErrorCodeSchema = {
|
|
491
|
+
title: "OpensteerErrorCode",
|
|
492
|
+
enum: opensteerErrorCodes
|
|
493
|
+
};
|
|
494
|
+
var opensteerErrorSchema = objectSchema(
|
|
495
|
+
{
|
|
496
|
+
code: opensteerErrorCodeSchema,
|
|
497
|
+
message: stringSchema(),
|
|
498
|
+
retriable: {
|
|
499
|
+
type: "boolean"
|
|
500
|
+
},
|
|
501
|
+
capability: opensteerCapabilitySchema,
|
|
502
|
+
details: recordSchema({})
|
|
503
|
+
},
|
|
504
|
+
{
|
|
505
|
+
title: "OpensteerError",
|
|
506
|
+
required: ["code", "message", "retriable"]
|
|
507
|
+
}
|
|
508
|
+
);
|
|
509
|
+
|
|
298
510
|
// ../runtime-core/src/observation-utils.ts
|
|
299
511
|
var REDACTED = "[REDACTED]";
|
|
300
512
|
var SENSITIVE_KEY_PATTERN = /(authorization|proxy[_-]?authorization|cookie|set-cookie|api[_-]?key|access[_-]?token|refresh[_-]?token|auth[_-]?token|token|secret|password|passwd|private[_-]?key|database[_-]?url|db[_-]?url|session(?:id)?|csrf(?:token)?)/i;
|
|
@@ -2092,7 +2304,8 @@ function normalizeOpensteerEngineName(value, source = "engine") {
|
|
|
2092
2304
|
if (normalized === "playwright" || normalized === "abp") {
|
|
2093
2305
|
return normalized;
|
|
2094
2306
|
}
|
|
2095
|
-
throw new
|
|
2307
|
+
throw new OpensteerProtocolError(
|
|
2308
|
+
"invalid-argument",
|
|
2096
2309
|
`${source} must be one of ${OPENSTEER_ENGINE_NAMES.join(", ")}; received "${value}".`
|
|
2097
2310
|
);
|
|
2098
2311
|
}
|
|
@@ -2101,7 +2314,8 @@ function assertSupportedEngineOptions(input) {
|
|
|
2101
2314
|
return;
|
|
2102
2315
|
}
|
|
2103
2316
|
if (typeof input.browser === "object" && input.browser !== null && input.browser.mode === "attach") {
|
|
2104
|
-
throw new
|
|
2317
|
+
throw new OpensteerProtocolError(
|
|
2318
|
+
"invalid-argument",
|
|
2105
2319
|
'ABP engine does not support browser.mode="attach". Use the Playwright engine for attach flows.'
|
|
2106
2320
|
);
|
|
2107
2321
|
}
|
|
@@ -2109,7 +2323,8 @@ function assertSupportedEngineOptions(input) {
|
|
|
2109
2323
|
if (unsupportedContextOptionNames.length === 0) {
|
|
2110
2324
|
return;
|
|
2111
2325
|
}
|
|
2112
|
-
throw new
|
|
2326
|
+
throw new OpensteerProtocolError(
|
|
2327
|
+
"invalid-argument",
|
|
2113
2328
|
`ABP engine does not support ${unsupportedContextOptionNames.join(", ")}. Supported ABP context options: context.viewport.`
|
|
2114
2329
|
);
|
|
2115
2330
|
}
|
|
@@ -4142,6 +4357,6 @@ async function sleep2(ms) {
|
|
|
4142
4357
|
await new Promise((resolve2) => setTimeout(resolve2, ms));
|
|
4143
4358
|
}
|
|
4144
4359
|
|
|
4145
|
-
export { DEFAULT_OPENSTEER_ENGINE, OPENSTEER_ENGINE_NAMES, OPENSTEER_FILESYSTEM_WORKSPACE_LAYOUT, OPENSTEER_FILESYSTEM_WORKSPACE_VERSION, OpensteerBrowserManager, assertSupportedEngineOptions, buildLocalViewSessionUrl, createArtifactStore, createFilesystemOpensteerWorkspace, createObservationStore, ensureLocalViewServiceRunning, manifestToExternalBinaryLocation, normalizeObservabilityConfig, normalizeObservationContext, normalizeOpensteerEngineName, normalizeWorkspaceId, resolveFilesystemWorkspacePath, resolveOpensteerEngineName, setLocalViewMode, stopLocalViewService };
|
|
4146
|
-
//# sourceMappingURL=chunk-
|
|
4147
|
-
//# sourceMappingURL=chunk-
|
|
4360
|
+
export { DEFAULT_OPENSTEER_ENGINE, JSON_SCHEMA_DRAFT_2020_12, OPENSTEER_ENGINE_NAMES, OPENSTEER_FILESYSTEM_WORKSPACE_LAYOUT, OPENSTEER_FILESYSTEM_WORKSPACE_VERSION, OpensteerBrowserManager, OpensteerProtocolError, arraySchema, assertSupportedEngineOptions, buildLocalViewSessionUrl, createArtifactStore, createFilesystemOpensteerWorkspace, createObservationStore, createOpensteerError, defineSchema, ensureLocalViewServiceRunning, enumSchema, integerSchema, isOpensteerProtocolError, literalSchema, manifestToExternalBinaryLocation, normalizeObservabilityConfig, normalizeObservationContext, normalizeOpensteerEngineName, normalizeWorkspaceId, numberSchema, objectSchema, oneOfSchema, opensteerCapabilitySetSchema, opensteerErrorCodes, opensteerErrorSchema, recordSchema, resolveFilesystemWorkspacePath, resolveOpensteerEngineName, setLocalViewMode, stopLocalViewService, stringSchema, toOpensteerError };
|
|
4361
|
+
//# sourceMappingURL=chunk-3XBQRZZC.js.map
|
|
4362
|
+
//# sourceMappingURL=chunk-3XBQRZZC.js.map
|