opensteer 0.9.1 → 0.9.2

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.cjs CHANGED
@@ -1489,55 +1489,6 @@ arraySchema(headerEntrySchema, {
1489
1489
  title: "OrderedHeaders"
1490
1490
  });
1491
1491
 
1492
- // ../protocol/src/captcha.ts
1493
- var captchaTypeSchema = enumSchema(
1494
- ["recaptcha-v2", "hcaptcha", "turnstile"],
1495
- {
1496
- title: "CaptchaType"
1497
- }
1498
- );
1499
- var captchaProviderSchema = enumSchema(["2captcha", "capsolver"], {
1500
- title: "CaptchaProvider"
1501
- });
1502
- var captchaDetectionResultSchema = objectSchema(
1503
- {
1504
- type: captchaTypeSchema,
1505
- siteKey: stringSchema({ minLength: 1 }),
1506
- pageUrl: stringSchema({ minLength: 1 })
1507
- },
1508
- {
1509
- title: "CaptchaDetectionResult",
1510
- required: ["type", "siteKey", "pageUrl"]
1511
- }
1512
- );
1513
- var opensteerCaptchaSolveInputSchema = objectSchema(
1514
- {
1515
- provider: captchaProviderSchema,
1516
- apiKey: stringSchema({ minLength: 1 }),
1517
- pageRef: pageRefSchema,
1518
- timeoutMs: integerSchema({ minimum: 1 }),
1519
- type: captchaTypeSchema,
1520
- siteKey: stringSchema({ minLength: 1 }),
1521
- pageUrl: stringSchema({ minLength: 1 })
1522
- },
1523
- {
1524
- title: "OpensteerCaptchaSolveInput",
1525
- required: ["provider", "apiKey"]
1526
- }
1527
- );
1528
- var opensteerCaptchaSolveOutputSchema = objectSchema(
1529
- {
1530
- captcha: captchaDetectionResultSchema,
1531
- token: stringSchema({ minLength: 1 }),
1532
- injected: { type: "boolean" },
1533
- provider: captchaProviderSchema
1534
- },
1535
- {
1536
- title: "OpensteerCaptchaSolveOutput",
1537
- required: ["captcha", "token", "injected", "provider"]
1538
- }
1539
- );
1540
-
1541
1492
  // ../protocol/src/storage.ts
1542
1493
  var jsonUnknownSchema = {};
1543
1494
  var cookieSameSiteSchema = enumSchema(["strict", "lax", "none"], {
@@ -1790,16 +1741,6 @@ var opensteerRequestPlanResponseExpectationSchema = objectSchema(
1790
1741
  required: ["status"]
1791
1742
  }
1792
1743
  );
1793
- var opensteerRecipeRefSchema = objectSchema(
1794
- {
1795
- key: stringSchema({ minLength: 1 }),
1796
- version: stringSchema({ minLength: 1 })
1797
- },
1798
- {
1799
- title: "OpensteerRecipeRef",
1800
- required: ["key"]
1801
- }
1802
- );
1803
1744
  var opensteerRequestFailurePolicyHeaderMatchSchema = objectSchema(
1804
1745
  {
1805
1746
  name: stringSchema({ minLength: 1 }),
@@ -1855,46 +1796,9 @@ var opensteerRequestRetryPolicySchema = objectSchema(
1855
1796
  required: ["maxRetries"]
1856
1797
  }
1857
1798
  );
1858
- var opensteerRecipeCachePolicySchema = enumSchema(
1859
- ["none", "untilFailure"],
1860
- {
1861
- title: "OpensteerRecipeCachePolicy"
1862
- }
1863
- );
1864
- var opensteerRequestPlanRecipeBindingSchema = objectSchema(
1865
- {
1866
- recipe: opensteerRecipeRefSchema,
1867
- cachePolicy: opensteerRecipeCachePolicySchema
1868
- },
1869
- {
1870
- title: "OpensteerRequestPlanRecipeBinding",
1871
- required: ["recipe"]
1872
- }
1873
- );
1874
- var opensteerRequestPlanRecoverBindingSchema = objectSchema(
1875
- {
1876
- recipe: opensteerRecipeRefSchema,
1877
- cachePolicy: opensteerRecipeCachePolicySchema,
1878
- failurePolicy: opensteerRequestFailurePolicySchema
1879
- },
1880
- {
1881
- title: "OpensteerRequestPlanRecoverBinding",
1882
- required: ["recipe", "failurePolicy"]
1883
- }
1884
- );
1885
- var opensteerRequestPlanRecipesSchema = objectSchema(
1886
- {
1887
- prepare: opensteerRequestPlanRecipeBindingSchema,
1888
- recover: opensteerRequestPlanRecoverBindingSchema
1889
- },
1890
- {
1891
- title: "OpensteerRequestPlanRecipes"
1892
- }
1893
- );
1894
1799
  var opensteerRequestPlanAuthSchema = objectSchema(
1895
1800
  {
1896
1801
  strategy: enumSchema(["session-cookie", "bearer-token", "api-key", "custom"]),
1897
- recipe: opensteerRecipeRefSchema,
1898
1802
  failurePolicy: opensteerRequestFailurePolicySchema,
1899
1803
  description: stringSchema({ minLength: 1 })
1900
1804
  },
@@ -1910,7 +1814,6 @@ var opensteerRequestPlanPayloadSchema = objectSchema(
1910
1814
  parameters: arraySchema(opensteerRequestPlanParameterSchema),
1911
1815
  body: opensteerRequestPlanBodySchema,
1912
1816
  response: opensteerRequestPlanResponseExpectationSchema,
1913
- recipes: opensteerRequestPlanRecipesSchema,
1914
1817
  retryPolicy: opensteerRequestRetryPolicySchema,
1915
1818
  auth: opensteerRequestPlanAuthSchema
1916
1819
  },
@@ -2001,317 +1904,6 @@ var opensteerRequestBodyInputSchema = oneOfSchema(
2001
1904
  title: "OpensteerRequestBodyInput"
2002
1905
  }
2003
1906
  );
2004
- var opensteerRecipeRetryOverridesSchema = objectSchema(
2005
- {
2006
- params: recordSchema(stringSchema(), {
2007
- title: "OpensteerRecipeParams"
2008
- }),
2009
- headers: recordSchema(stringSchema(), {
2010
- title: "OpensteerRecipeHeaders"
2011
- }),
2012
- query: recordSchema(stringSchema(), {
2013
- title: "OpensteerRecipeQuery"
2014
- }),
2015
- body: recordSchema(stringSchema(), {
2016
- title: "OpensteerRecipeBodyVariables"
2017
- })
2018
- },
2019
- {
2020
- title: "OpensteerRecipeRetryOverrides"
2021
- }
2022
- );
2023
- var opensteerRecipeStepResponseCaptureSchema = objectSchema(
2024
- {
2025
- header: objectSchema(
2026
- {
2027
- name: stringSchema({ minLength: 1 }),
2028
- saveAs: stringSchema({ minLength: 1 })
2029
- },
2030
- {
2031
- title: "OpensteerAuthRecipeHeaderCapture",
2032
- required: ["name", "saveAs"]
2033
- }
2034
- ),
2035
- bodyJsonPointer: objectSchema(
2036
- {
2037
- pointer: stringSchema({ minLength: 1 }),
2038
- saveAs: stringSchema({ minLength: 1 })
2039
- },
2040
- {
2041
- title: "OpensteerAuthRecipeBodyJsonPointerCapture",
2042
- required: ["pointer", "saveAs"]
2043
- }
2044
- ),
2045
- bodyText: objectSchema(
2046
- {
2047
- saveAs: stringSchema({ minLength: 1 })
2048
- },
2049
- {
2050
- title: "OpensteerAuthRecipeBodyTextCapture",
2051
- required: ["saveAs"]
2052
- }
2053
- )
2054
- },
2055
- {
2056
- title: "OpensteerRecipeStepResponseCapture"
2057
- }
2058
- );
2059
- var opensteerRecipeRequestStepInputSchema = objectSchema(
2060
- {
2061
- url: stringSchema({ minLength: 1 }),
2062
- transport: transportKindSchema,
2063
- pageRef: pageRefSchema,
2064
- cookieJar: stringSchema({ minLength: 1 }),
2065
- method: stringSchema({ minLength: 1 }),
2066
- headers: recordSchema(stringSchema(), {
2067
- title: "OpensteerRecipeRequestHeaders"
2068
- }),
2069
- query: recordSchema(stringSchema(), {
2070
- title: "OpensteerRecipeRequestQuery"
2071
- }),
2072
- body: opensteerRequestBodyInputSchema,
2073
- followRedirects: { type: "boolean" }
2074
- },
2075
- {
2076
- title: "OpensteerRecipeRequestStepInput",
2077
- required: ["url"]
2078
- }
2079
- );
2080
- var opensteerRecipeHookRefSchema = objectSchema(
2081
- {
2082
- specifier: stringSchema({ minLength: 1 }),
2083
- export: stringSchema({ minLength: 1 })
2084
- },
2085
- {
2086
- title: "OpensteerRecipeHookRef",
2087
- required: ["specifier", "export"]
2088
- }
2089
- );
2090
- var opensteerRecipeStepSchema = oneOfSchema(
2091
- [
2092
- objectSchema(
2093
- {
2094
- kind: enumSchema(["goto"]),
2095
- url: stringSchema({ minLength: 1 })
2096
- },
2097
- {
2098
- title: "OpensteerAuthRecipeGotoStep",
2099
- required: ["kind", "url"]
2100
- }
2101
- ),
2102
- objectSchema(
2103
- {
2104
- kind: enumSchema(["reload"])
2105
- },
2106
- {
2107
- title: "OpensteerAuthRecipeReloadStep",
2108
- required: ["kind"]
2109
- }
2110
- ),
2111
- objectSchema(
2112
- {
2113
- kind: enumSchema(["waitForUrl"]),
2114
- includes: stringSchema({ minLength: 1 }),
2115
- timeoutMs: integerSchema({ minimum: 0 })
2116
- },
2117
- {
2118
- title: "OpensteerAuthRecipeWaitForUrlStep",
2119
- required: ["kind", "includes"]
2120
- }
2121
- ),
2122
- objectSchema(
2123
- {
2124
- kind: enumSchema(["waitForNetwork"]),
2125
- url: stringSchema({ minLength: 1 }),
2126
- hostname: stringSchema({ minLength: 1 }),
2127
- path: stringSchema({ minLength: 1 }),
2128
- method: stringSchema({ minLength: 1 }),
2129
- status: stringSchema({ minLength: 1 }),
2130
- includeBodies: { type: "boolean" },
2131
- timeoutMs: integerSchema({ minimum: 0 }),
2132
- saveAs: stringSchema({ minLength: 1 })
2133
- },
2134
- {
2135
- title: "OpensteerRecipeWaitForNetworkStep",
2136
- required: ["kind"]
2137
- }
2138
- ),
2139
- objectSchema(
2140
- {
2141
- kind: enumSchema(["waitForCookie"]),
2142
- name: stringSchema({ minLength: 1 }),
2143
- url: stringSchema({ minLength: 1 }),
2144
- timeoutMs: integerSchema({ minimum: 0 }),
2145
- saveAs: stringSchema({ minLength: 1 })
2146
- },
2147
- {
2148
- title: "OpensteerAuthRecipeWaitForCookieStep",
2149
- required: ["kind", "name"]
2150
- }
2151
- ),
2152
- objectSchema(
2153
- {
2154
- kind: enumSchema(["waitForStorage"]),
2155
- area: enumSchema(["local", "session"]),
2156
- origin: stringSchema({ minLength: 1 }),
2157
- key: stringSchema({ minLength: 1 }),
2158
- timeoutMs: integerSchema({ minimum: 0 }),
2159
- saveAs: stringSchema({ minLength: 1 })
2160
- },
2161
- {
2162
- title: "OpensteerAuthRecipeWaitForStorageStep",
2163
- required: ["kind", "area", "origin", "key"]
2164
- }
2165
- ),
2166
- objectSchema(
2167
- {
2168
- kind: enumSchema(["readCookie"]),
2169
- name: stringSchema({ minLength: 1 }),
2170
- url: stringSchema({ minLength: 1 }),
2171
- saveAs: stringSchema({ minLength: 1 })
2172
- },
2173
- {
2174
- title: "OpensteerAuthRecipeReadCookieStep",
2175
- required: ["kind", "name", "saveAs"]
2176
- }
2177
- ),
2178
- objectSchema(
2179
- {
2180
- kind: enumSchema(["readStorage"]),
2181
- area: enumSchema(["local", "session"]),
2182
- origin: stringSchema({ minLength: 1 }),
2183
- key: stringSchema({ minLength: 1 }),
2184
- pageUrl: stringSchema({ minLength: 1 }),
2185
- saveAs: stringSchema({ minLength: 1 })
2186
- },
2187
- {
2188
- title: "OpensteerRecipeReadStorageStep",
2189
- required: ["kind", "area", "origin", "key", "saveAs"]
2190
- }
2191
- ),
2192
- objectSchema(
2193
- {
2194
- kind: enumSchema(["evaluate"]),
2195
- script: stringSchema({ minLength: 1 }),
2196
- args: arraySchema(jsonValueSchema),
2197
- pageRef: pageRefSchema,
2198
- saveAs: stringSchema({ minLength: 1 })
2199
- },
2200
- {
2201
- title: "OpensteerRecipeEvaluateStep",
2202
- required: ["kind", "script"]
2203
- }
2204
- ),
2205
- objectSchema(
2206
- {
2207
- kind: enumSchema(["syncCookiesToJar"]),
2208
- jar: stringSchema({ minLength: 1 }),
2209
- urls: arraySchema(stringSchema({ minLength: 1 }), {
2210
- minItems: 1
2211
- })
2212
- },
2213
- {
2214
- title: "OpensteerRecipeSyncCookiesToJarStep",
2215
- required: ["kind", "jar"]
2216
- }
2217
- ),
2218
- objectSchema(
2219
- {
2220
- kind: enumSchema(["request"]),
2221
- request: opensteerRecipeRequestStepInputSchema,
2222
- capture: opensteerRecipeStepResponseCaptureSchema
2223
- },
2224
- {
2225
- title: "OpensteerRecipeRequestStep",
2226
- required: ["kind", "request"]
2227
- }
2228
- ),
2229
- objectSchema(
2230
- {
2231
- kind: enumSchema(["sessionRequest"]),
2232
- request: opensteerRecipeRequestStepInputSchema,
2233
- capture: opensteerRecipeStepResponseCaptureSchema
2234
- },
2235
- {
2236
- title: "OpensteerAuthRecipeSessionRequestStep",
2237
- required: ["kind", "request"]
2238
- }
2239
- ),
2240
- objectSchema(
2241
- {
2242
- kind: enumSchema(["directRequest"]),
2243
- request: opensteerRecipeRequestStepInputSchema,
2244
- capture: opensteerRecipeStepResponseCaptureSchema
2245
- },
2246
- {
2247
- title: "OpensteerAuthRecipeDirectRequestStep",
2248
- required: ["kind", "request"]
2249
- }
2250
- ),
2251
- objectSchema(
2252
- {
2253
- kind: enumSchema(["solveCaptcha"]),
2254
- provider: captchaProviderSchema,
2255
- apiKey: stringSchema({ minLength: 1 }),
2256
- pageRef: pageRefSchema,
2257
- timeoutMs: integerSchema({ minimum: 1 }),
2258
- type: captchaTypeSchema,
2259
- siteKey: stringSchema({ minLength: 1 }),
2260
- pageUrl: stringSchema({ minLength: 1 }),
2261
- saveAs: stringSchema({ minLength: 1 })
2262
- },
2263
- {
2264
- title: "OpensteerRecipeSolveCaptchaStep",
2265
- required: ["kind", "provider", "apiKey"]
2266
- }
2267
- ),
2268
- objectSchema(
2269
- {
2270
- kind: enumSchema(["hook"]),
2271
- hook: opensteerRecipeHookRefSchema
2272
- },
2273
- {
2274
- title: "OpensteerRecipeHookStep",
2275
- required: ["kind", "hook"]
2276
- }
2277
- )
2278
- ],
2279
- {
2280
- title: "OpensteerRecipeStep"
2281
- }
2282
- );
2283
- var opensteerRecipePayloadSchema = objectSchema(
2284
- {
2285
- description: stringSchema({ minLength: 1 }),
2286
- steps: arraySchema(opensteerRecipeStepSchema, {
2287
- minItems: 1
2288
- }),
2289
- outputs: opensteerRecipeRetryOverridesSchema
2290
- },
2291
- {
2292
- title: "OpensteerRecipePayload",
2293
- required: ["steps"]
2294
- }
2295
- );
2296
- var opensteerRecipeRecordSchema = objectSchema(
2297
- {
2298
- id: stringSchema({ minLength: 1 }),
2299
- key: stringSchema({ minLength: 1 }),
2300
- version: stringSchema({ minLength: 1 }),
2301
- createdAt: integerSchema({ minimum: 0 }),
2302
- updatedAt: integerSchema({ minimum: 0 }),
2303
- contentHash: stringSchema({ minLength: 1 }),
2304
- tags: arraySchema(stringSchema({ minLength: 1 }), {
2305
- uniqueItems: true
2306
- }),
2307
- provenance: opensteerRegistryProvenanceSchema,
2308
- payload: opensteerRecipePayloadSchema
2309
- },
2310
- {
2311
- title: "OpensteerRecipeRecord",
2312
- required: ["id", "key", "version", "createdAt", "updatedAt", "contentHash", "tags", "payload"]
2313
- }
2314
- );
2315
1907
  var opensteerNetworkQueryInputSchema = objectSchema(
2316
1908
  {
2317
1909
  pageRef: pageRefSchema,
@@ -2710,85 +2302,6 @@ objectSchema(
2710
2302
  required: ["plans"]
2711
2303
  }
2712
2304
  );
2713
- objectSchema(
2714
- {
2715
- id: stringSchema({ minLength: 1 }),
2716
- key: stringSchema({ minLength: 1 }),
2717
- version: stringSchema({ minLength: 1 }),
2718
- tags: arraySchema(stringSchema({ minLength: 1 }), {
2719
- uniqueItems: true
2720
- }),
2721
- provenance: opensteerRegistryProvenanceSchema,
2722
- payload: opensteerRecipePayloadSchema
2723
- },
2724
- {
2725
- title: "OpensteerWriteRecipeInput",
2726
- required: ["key", "version", "payload"]
2727
- }
2728
- );
2729
- objectSchema(
2730
- {
2731
- key: stringSchema({ minLength: 1 }),
2732
- version: stringSchema({ minLength: 1 })
2733
- },
2734
- {
2735
- title: "OpensteerGetRecipeInput",
2736
- required: ["key"]
2737
- }
2738
- );
2739
- objectSchema(
2740
- {
2741
- key: stringSchema({ minLength: 1 })
2742
- },
2743
- {
2744
- title: "OpensteerListRecipesInput"
2745
- }
2746
- );
2747
- objectSchema(
2748
- {
2749
- recipes: arraySchema(opensteerRecipeRecordSchema)
2750
- },
2751
- {
2752
- title: "OpensteerListRecipesOutput",
2753
- required: ["recipes"]
2754
- }
2755
- );
2756
- objectSchema(
2757
- {
2758
- key: stringSchema({ minLength: 1 }),
2759
- version: stringSchema({ minLength: 1 }),
2760
- variables: recordSchema(stringSchema(), {
2761
- title: "OpensteerRecipeVariables"
2762
- })
2763
- },
2764
- {
2765
- title: "OpensteerRunRecipeInput",
2766
- required: ["key"]
2767
- }
2768
- );
2769
- objectSchema(
2770
- {
2771
- recipe: objectSchema(
2772
- {
2773
- id: stringSchema({ minLength: 1 }),
2774
- key: stringSchema({ minLength: 1 }),
2775
- version: stringSchema({ minLength: 1 })
2776
- },
2777
- {
2778
- title: "OpensteerResolvedRecipeRef",
2779
- required: ["id", "key", "version"]
2780
- }
2781
- ),
2782
- variables: recordSchema(stringSchema(), {
2783
- title: "OpensteerResolvedRecipeVariables"
2784
- }),
2785
- overrides: opensteerRecipeRetryOverridesSchema
2786
- },
2787
- {
2788
- title: "OpensteerRunRecipeOutput",
2789
- required: ["recipe", "variables"]
2790
- }
2791
- );
2792
2305
  objectSchema(
2793
2306
  {
2794
2307
  key: stringSchema({ minLength: 1 }),
@@ -2895,17 +2408,7 @@ objectSchema(
2895
2408
  {
2896
2409
  attempted: { type: "boolean" },
2897
2410
  succeeded: { type: "boolean" },
2898
- matchedFailurePolicy: { type: "boolean" },
2899
- recipe: objectSchema(
2900
- {
2901
- key: stringSchema({ minLength: 1 }),
2902
- version: stringSchema({ minLength: 1 })
2903
- },
2904
- {
2905
- title: "OpensteerResolvedRecoveryRecipeRef",
2906
- required: ["key", "version"]
2907
- }
2908
- )
2411
+ matchedFailurePolicy: { type: "boolean" }
2909
2412
  },
2910
2413
  {
2911
2414
  title: "OpensteerRequestRecoveryMetadata",
@@ -2944,6 +2447,69 @@ objectSchema(
2944
2447
  }
2945
2448
  );
2946
2449
 
2450
+ // ../protocol/src/state.ts
2451
+ var opensteerStateSnapshotCookieSchema = objectSchema(
2452
+ {
2453
+ name: stringSchema({ minLength: 1 }),
2454
+ value: stringSchema(),
2455
+ domain: stringSchema({ minLength: 1 }),
2456
+ path: stringSchema({ minLength: 1 }),
2457
+ secure: { type: "boolean" },
2458
+ httpOnly: { type: "boolean" },
2459
+ sameSite: enumSchema(["strict", "lax", "none"]),
2460
+ priority: enumSchema(["low", "medium", "high"]),
2461
+ partitionKey: stringSchema({ minLength: 1 }),
2462
+ session: { type: "boolean" },
2463
+ expiresAt: oneOfSchema([integerSchema({ minimum: 0 }), { type: "null" }])
2464
+ },
2465
+ {
2466
+ title: "OpensteerStateSnapshotCookie",
2467
+ required: ["name", "value", "domain", "path", "secure", "httpOnly", "session"]
2468
+ }
2469
+ );
2470
+ var opensteerStateSnapshotSchema = objectSchema(
2471
+ {
2472
+ id: stringSchema({ minLength: 1 }),
2473
+ capturedAt: integerSchema({ minimum: 0 }),
2474
+ pageRef: pageRefSchema,
2475
+ url: stringSchema({ minLength: 1 }),
2476
+ cookies: arraySchema(opensteerStateSnapshotCookieSchema),
2477
+ storage: storageSnapshotSchema,
2478
+ hiddenFields: arraySchema(
2479
+ objectSchema(
2480
+ {
2481
+ path: stringSchema({ minLength: 1 }),
2482
+ name: stringSchema({ minLength: 1 }),
2483
+ value: stringSchema()
2484
+ },
2485
+ {
2486
+ title: "OpensteerStateSnapshotHiddenField",
2487
+ required: ["path", "name", "value"]
2488
+ }
2489
+ )
2490
+ ),
2491
+ globals: recordSchema({}, { title: "OpensteerStateSnapshotGlobals" })
2492
+ },
2493
+ {
2494
+ title: "OpensteerStateSnapshot",
2495
+ required: ["id", "capturedAt"]
2496
+ }
2497
+ );
2498
+ var opensteerStateDeltaSchema = objectSchema(
2499
+ {
2500
+ beforeStateId: stringSchema({ minLength: 1 }),
2501
+ afterStateId: stringSchema({ minLength: 1 }),
2502
+ cookiesChanged: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
2503
+ storageChanged: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
2504
+ hiddenFieldsChanged: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
2505
+ globalsChanged: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true })
2506
+ },
2507
+ {
2508
+ title: "OpensteerStateDelta",
2509
+ required: ["cookiesChanged", "storageChanged", "hiddenFieldsChanged", "globalsChanged"]
2510
+ }
2511
+ );
2512
+
2947
2513
  // ../protocol/src/snapshots.ts
2948
2514
  var screenshotFormatSchema = enumSchema(["png", "jpeg", "webp"], {
2949
2515
  title: "ScreenshotFormat"
@@ -3717,6 +3283,55 @@ var opensteerArtifactReadOutputSchema = objectSchema(
3717
3283
  }
3718
3284
  );
3719
3285
 
3286
+ // ../protocol/src/captcha.ts
3287
+ var captchaTypeSchema = enumSchema(
3288
+ ["recaptcha-v2", "hcaptcha", "turnstile"],
3289
+ {
3290
+ title: "CaptchaType"
3291
+ }
3292
+ );
3293
+ var captchaProviderSchema = enumSchema(["2captcha", "capsolver"], {
3294
+ title: "CaptchaProvider"
3295
+ });
3296
+ var captchaDetectionResultSchema = objectSchema(
3297
+ {
3298
+ type: captchaTypeSchema,
3299
+ siteKey: stringSchema({ minLength: 1 }),
3300
+ pageUrl: stringSchema({ minLength: 1 })
3301
+ },
3302
+ {
3303
+ title: "CaptchaDetectionResult",
3304
+ required: ["type", "siteKey", "pageUrl"]
3305
+ }
3306
+ );
3307
+ var opensteerCaptchaSolveInputSchema = objectSchema(
3308
+ {
3309
+ provider: captchaProviderSchema,
3310
+ apiKey: stringSchema({ minLength: 1 }),
3311
+ pageRef: pageRefSchema,
3312
+ timeoutMs: integerSchema({ minimum: 1 }),
3313
+ type: captchaTypeSchema,
3314
+ siteKey: stringSchema({ minLength: 1 }),
3315
+ pageUrl: stringSchema({ minLength: 1 })
3316
+ },
3317
+ {
3318
+ title: "OpensteerCaptchaSolveInput",
3319
+ required: ["provider", "apiKey"]
3320
+ }
3321
+ );
3322
+ var opensteerCaptchaSolveOutputSchema = objectSchema(
3323
+ {
3324
+ captcha: captchaDetectionResultSchema,
3325
+ token: stringSchema({ minLength: 1 }),
3326
+ injected: { type: "boolean" },
3327
+ provider: captchaProviderSchema
3328
+ },
3329
+ {
3330
+ title: "OpensteerCaptchaSolveOutput",
3331
+ required: ["captcha", "token", "injected", "provider"]
3332
+ }
3333
+ );
3334
+
3720
3335
  // ../protocol/src/traces.ts
3721
3336
  var traceContextSchema = objectSchema(
3722
3337
  {
@@ -3913,1616 +3528,74 @@ var sandboxAjaxRouteSchema = objectSchema(
3913
3528
  },
3914
3529
  {
3915
3530
  title: "SandboxAjaxMockResponse",
3916
- required: ["status"]
3917
- }
3918
- )
3919
- },
3920
- {
3921
- title: "SandboxAjaxRoute",
3922
- required: ["urlPattern", "mode"]
3923
- }
3924
- );
3925
- var opensteerScriptSandboxInputSchema = objectSchema(
3926
- {
3927
- artifactId: stringSchema({ minLength: 1 }),
3928
- content: stringSchema(),
3929
- fidelity: sandboxFidelitySchema,
3930
- ajaxRoutes: arraySchema(sandboxAjaxRouteSchema),
3931
- cookies: recordSchema(stringSchema(), {
3932
- title: "SandboxCookies"
3933
- }),
3934
- globals: objectSchema(
3935
- {},
3936
- {
3937
- title: "SandboxGlobals",
3938
- additionalProperties: true
3939
- }
3940
- ),
3941
- timeoutMs: integerSchema({ minimum: 1 }),
3942
- clockMode: enumSchema(["real", "manual"])
3943
- },
3944
- {
3945
- title: "OpensteerScriptSandboxInput"
3946
- }
3947
- );
3948
- var sandboxCapturedAjaxCallSchema = objectSchema(
3949
- {
3950
- method: stringSchema({ minLength: 1 }),
3951
- url: stringSchema({ minLength: 1 }),
3952
- headers: recordSchema(stringSchema(), {
3953
- title: "SandboxCapturedAjaxHeaders"
3954
- }),
3955
- body: stringSchema(),
3956
- timestamp: integerSchema({ minimum: 0 })
3957
- },
3958
- {
3959
- title: "SandboxCapturedAjaxCall",
3960
- required: ["method", "url", "headers", "timestamp"]
3961
- }
3962
- );
3963
- var opensteerScriptSandboxOutputSchema = objectSchema(
3964
- {
3965
- result: oneOfSchema(
3966
- [
3967
- objectSchema({}, { additionalProperties: true }),
3968
- arraySchema({}),
3969
- stringSchema(),
3970
- { type: "number" },
3971
- enumSchema([true, false, null])
3972
- ],
3973
- {
3974
- title: "SandboxResult"
3975
- }
3976
- ),
3977
- capturedAjax: arraySchema(sandboxCapturedAjaxCallSchema),
3978
- errors: arraySchema(stringSchema({ minLength: 1 })),
3979
- durationMs: integerSchema({ minimum: 0 })
3980
- },
3981
- {
3982
- title: "OpensteerScriptSandboxOutput",
3983
- required: ["capturedAjax", "errors", "durationMs"]
3984
- }
3985
- );
3986
-
3987
- // ../protocol/src/reverse.ts
3988
- var opensteerStateSourceKindSchema = enumSchema(
3989
- ["temporary", "persistent", "attach"],
3990
- { title: "OpensteerStateSourceKind" }
3991
- );
3992
- var opensteerReverseCaseStatusSchema = enumSchema(
3993
- ["capturing", "analyzing", "ready", "attention"],
3994
- { title: "OpensteerReverseCaseStatus" }
3995
- );
3996
- var opensteerReverseChannelKindSchema = enumSchema(
3997
- ["http", "event-stream", "websocket"],
3998
- { title: "OpensteerReverseChannelKind" }
3999
- );
4000
- var opensteerReverseManualCalibrationModeSchema = enumSchema(
4001
- ["allow", "avoid", "require"],
4002
- { title: "OpensteerReverseManualCalibrationMode" }
4003
- );
4004
- var opensteerReverseCandidateBoundarySchema = enumSchema(
4005
- ["first-party", "same-site", "third-party"],
4006
- { title: "OpensteerReverseCandidateBoundary" }
4007
- );
4008
- var opensteerReverseAdvisoryTagSchema = enumSchema(
4009
- [
4010
- "data",
4011
- "facet",
4012
- "telemetry",
4013
- "subscription",
4014
- "navigation",
4015
- "document",
4016
- "route-data",
4017
- "search",
4018
- "tracking",
4019
- "unknown"
4020
- ],
4021
- { title: "OpensteerReverseAdvisoryTag" }
4022
- );
4023
- var opensteerReverseConstraintKindSchema = enumSchema(
4024
- [
4025
- "requires-browser",
4026
- "requires-cookie",
4027
- "requires-storage",
4028
- "requires-script",
4029
- "requires-guard",
4030
- "requires-live-state",
4031
- "opaque-body",
4032
- "unsupported"
4033
- ],
4034
- { title: "OpensteerReverseConstraintKind" }
4035
- );
4036
- var opensteerRequestInputLocationSchema = enumSchema(
4037
- ["path", "query", "header", "cookie", "body-field"],
4038
- { title: "OpensteerRequestInputLocation" }
4039
- );
4040
- var opensteerRequestInputRequirednessSchema = enumSchema(
4041
- ["required", "optional", "unknown"],
4042
- { title: "OpensteerRequestInputRequiredness" }
4043
- );
4044
- var opensteerRequestInputClassificationSchema = enumSchema(
4045
- ["managed", "static", "contextual", "volatile"],
4046
- { title: "OpensteerRequestInputClassification" }
4047
- );
4048
- var opensteerRequestInputSourceSchema = enumSchema(
4049
- [
4050
- "literal",
4051
- "cookie",
4052
- "storage",
4053
- "prior-response",
4054
- "page",
4055
- "script",
4056
- "guard-output",
4057
- "runtime-managed",
4058
- "unknown"
4059
- ],
4060
- { title: "OpensteerRequestInputSource" }
4061
- );
4062
- var opensteerRequestInputMaterializationPolicySchema = enumSchema(
4063
- ["copy", "omit", "recompute", "resolve"],
4064
- { title: "OpensteerRequestInputMaterializationPolicy" }
4065
- );
4066
- var opensteerRequestInputExportPolicySchema = enumSchema(
4067
- ["portable", "browser-bound", "blocked"],
4068
- { title: "OpensteerRequestInputExportPolicy" }
4069
- );
4070
- var opensteerReverseQueryViewSchema = enumSchema(
4071
- ["records", "clusters", "candidates"],
4072
- { title: "OpensteerReverseQueryView" }
4073
- );
4074
- var opensteerReverseSortKeySchema = enumSchema(
4075
- [
4076
- "observed-at",
4077
- "advisory-rank",
4078
- "target-hint-matches",
4079
- "response-richness",
4080
- "portability",
4081
- "boundary",
4082
- "success"
4083
- ],
4084
- { title: "OpensteerReverseSortKey" }
4085
- );
4086
- var opensteerReverseSortPresetSchema = enumSchema(
4087
- [
4088
- "advisory-rank",
4089
- "observed-at",
4090
- "portability",
4091
- "first-party",
4092
- "hint-match",
4093
- "response-richness"
4094
- ],
4095
- { title: "OpensteerReverseSortPreset" }
4096
- );
4097
- var opensteerReverseSortDirectionSchema = enumSchema(
4098
- ["asc", "desc"],
4099
- {
4100
- title: "OpensteerReverseSortDirection"
4101
- }
4102
- );
4103
- var opensteerObservationClusterRelationshipKindSchema = enumSchema(
4104
- ["seed", "preflight", "redirect", "retry", "duplicate", "follow-on"],
4105
- { title: "OpensteerObservationClusterRelationshipKind" }
4106
- );
4107
- var opensteerReverseReportKindSchema = enumSchema(
4108
- ["discovery", "package"],
4109
- { title: "OpensteerReverseReportKind" }
4110
- );
4111
- var opensteerReversePackageKindSchema = enumSchema(
4112
- ["portable-http", "browser-workflow"],
4113
- { title: "OpensteerReversePackageKind" }
4114
- );
4115
- var opensteerReversePackageReadinessSchema = enumSchema(
4116
- ["runnable", "draft", "unsupported"],
4117
- { title: "OpensteerReversePackageReadiness" }
4118
- );
4119
- var opensteerBodyCodecKindSchema = enumSchema(
4120
- [
4121
- "json",
4122
- "form-urlencoded",
4123
- "multipart",
4124
- "graphql",
4125
- "persisted-graphql",
4126
- "text",
4127
- "opaque-binary",
4128
- "sse",
4129
- "websocket-json",
4130
- "websocket-text",
4131
- "unknown"
4132
- ],
4133
- { title: "OpensteerBodyCodecKind" }
4134
- );
4135
- var opensteerExecutableResolverKindSchema = enumSchema(
4136
- [
4137
- "literal",
4138
- "cookie",
4139
- "storage",
4140
- "prior-record",
4141
- "binding",
4142
- "candidate",
4143
- "case",
4144
- "state-snapshot",
4145
- "artifact",
4146
- "manual",
4147
- "runtime-managed"
4148
- ],
4149
- { title: "OpensteerExecutableResolverKind" }
4150
- );
4151
- var opensteerValueReferenceKindSchema = enumSchema(
4152
- [
4153
- "literal",
4154
- "resolver",
4155
- "binding",
4156
- "candidate",
4157
- "case",
4158
- "record",
4159
- "artifact",
4160
- "state-snapshot",
4161
- "runtime",
4162
- "manual"
4163
- ],
4164
- { title: "OpensteerValueReferenceKind" }
4165
- );
4166
- var opensteerRuntimeValueKeySchema = enumSchema(
4167
- ["pageRef", "packageId", "caseId", "candidateId", "objective"],
4168
- { title: "OpensteerRuntimeValueKey" }
4169
- );
4170
- var opensteerValidationRuleKindSchema = enumSchema(
4171
- [
4172
- "status",
4173
- "json-structure",
4174
- "text-includes",
4175
- "stream-first-chunk",
4176
- "websocket-open",
4177
- "message-count-at-least"
4178
- ],
4179
- { title: "OpensteerValidationRuleKind" }
4180
- );
4181
- enumSchema(
4182
- ["operation", "await-record", "assert"],
4183
- { title: "OpensteerReverseWorkflowStepKind" }
4184
- );
4185
- var opensteerReverseRequirementKindSchema = enumSchema(
4186
- ["resolver", "guard", "workflow-step", "state", "channel", "unsupported"],
4187
- { title: "OpensteerReverseRequirementKind" }
4188
- );
4189
- var opensteerReverseRequirementStatusSchema = enumSchema(
4190
- ["required", "recommended"],
4191
- { title: "OpensteerReverseRequirementStatus" }
4192
- );
4193
- var opensteerReverseSuggestedEditKindSchema = enumSchema(
4194
- [
4195
- "set-resolver",
4196
- "attach-trace",
4197
- "replace-workflow",
4198
- "patch-step-input",
4199
- "switch-state-source",
4200
- "inspect-evidence",
4201
- "mark-unsupported"
4202
- ],
4203
- { title: "OpensteerReverseSuggestedEditKind" }
4204
- );
4205
- var jsonValueSchema2 = defineSchema({
4206
- title: "JsonValue"
4207
- });
4208
- var opensteerValueReferenceSchema = objectSchema(
4209
- {
4210
- kind: opensteerValueReferenceKindSchema,
4211
- pointer: stringSchema({ minLength: 1 }),
4212
- resolverId: stringSchema({ minLength: 1 }),
4213
- binding: stringSchema({ minLength: 1 }),
4214
- recordId: stringSchema({ minLength: 1 }),
4215
- artifactId: stringSchema({ minLength: 1 }),
4216
- stateSnapshotId: stringSchema({ minLength: 1 }),
4217
- runtimeKey: opensteerRuntimeValueKeySchema,
4218
- value: jsonValueSchema2,
4219
- placeholder: stringSchema({ minLength: 1 })
4220
- },
4221
- {
4222
- title: "OpensteerValueReference",
4223
- required: ["kind"]
4224
- }
4225
- );
4226
- var opensteerValueTemplateSchema = defineSchema({
4227
- title: "OpensteerValueTemplate"
4228
- });
4229
- var opensteerReverseTargetHintsSchema = objectSchema(
4230
- {
4231
- hosts: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4232
- paths: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4233
- operationNames: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4234
- channels: arraySchema(opensteerReverseChannelKindSchema, { uniqueItems: true })
4235
- },
4236
- {
4237
- title: "OpensteerReverseTargetHints"
4238
- }
4239
- );
4240
- var opensteerBodyCodecDescriptorSchema = objectSchema(
4241
- {
4242
- kind: opensteerBodyCodecKindSchema,
4243
- contentType: stringSchema({ minLength: 1 }),
4244
- operationName: stringSchema({ minLength: 1 }),
4245
- fieldPaths: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true })
4246
- },
4247
- {
4248
- title: "OpensteerBodyCodecDescriptor",
4249
- required: ["kind", "fieldPaths"]
4250
- }
4251
- );
4252
- var opensteerObservationClusterSchema = objectSchema(
4253
- {
4254
- id: stringSchema({ minLength: 1 }),
4255
- observationId: stringSchema({ minLength: 1 }),
4256
- label: stringSchema({ minLength: 1 }),
4257
- channel: opensteerReverseChannelKindSchema,
4258
- method: stringSchema({ minLength: 1 }),
4259
- url: stringSchema({ minLength: 1 }),
4260
- matchedTargetHints: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4261
- members: arraySchema(
4262
- objectSchema(
4263
- {
4264
- recordId: stringSchema({ minLength: 1 }),
4265
- observedAt: integerSchema({ minimum: 0 }),
4266
- resourceType: stringSchema({ minLength: 1 }),
4267
- status: integerSchema({ minimum: 0 }),
4268
- relation: opensteerObservationClusterRelationshipKindSchema,
4269
- relatedRecordId: stringSchema({ minLength: 1 }),
4270
- matchedTargetHints: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true })
4271
- },
4272
- {
4273
- title: "OpensteerObservationClusterMember",
4274
- required: ["recordId", "relation", "matchedTargetHints"]
4275
- }
4276
- )
4277
- )
4278
- },
4279
- {
4280
- title: "OpensteerObservationCluster",
4281
- required: ["id", "observationId", "label", "channel", "url", "matchedTargetHints", "members"]
4282
- }
4283
- );
4284
- var opensteerStateSnapshotCookieSchema = objectSchema(
4285
- {
4286
- name: stringSchema({ minLength: 1 }),
4287
- value: stringSchema(),
4288
- domain: stringSchema({ minLength: 1 }),
4289
- path: stringSchema({ minLength: 1 }),
4290
- secure: { type: "boolean" },
4291
- httpOnly: { type: "boolean" },
4292
- sameSite: enumSchema(["strict", "lax", "none"]),
4293
- priority: enumSchema(["low", "medium", "high"]),
4294
- partitionKey: stringSchema({ minLength: 1 }),
4295
- session: { type: "boolean" },
4296
- expiresAt: oneOfSchema([integerSchema({ minimum: 0 }), { type: "null" }])
4297
- },
4298
- {
4299
- title: "OpensteerStateSnapshotCookie",
4300
- required: ["name", "value", "domain", "path", "secure", "httpOnly", "session"]
4301
- }
4302
- );
4303
- var opensteerStateSnapshotSchema = objectSchema(
4304
- {
4305
- id: stringSchema({ minLength: 1 }),
4306
- capturedAt: integerSchema({ minimum: 0 }),
4307
- pageRef: pageRefSchema,
4308
- url: stringSchema({ minLength: 1 }),
4309
- cookies: arraySchema(opensteerStateSnapshotCookieSchema),
4310
- storage: storageSnapshotSchema,
4311
- hiddenFields: arraySchema(
4312
- objectSchema(
4313
- {
4314
- path: stringSchema({ minLength: 1 }),
4315
- name: stringSchema({ minLength: 1 }),
4316
- value: stringSchema()
4317
- },
4318
- {
4319
- title: "OpensteerStateSnapshotHiddenField",
4320
- required: ["path", "name", "value"]
4321
- }
4322
- )
4323
- ),
4324
- globals: recordSchema({}, { title: "OpensteerStateSnapshotGlobals" })
4325
- },
4326
- {
4327
- title: "OpensteerStateSnapshot",
4328
- required: ["id", "capturedAt"]
4329
- }
4330
- );
4331
- var opensteerStateDeltaSchema = objectSchema(
4332
- {
4333
- beforeStateId: stringSchema({ minLength: 1 }),
4334
- afterStateId: stringSchema({ minLength: 1 }),
4335
- cookiesChanged: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4336
- storageChanged: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4337
- hiddenFieldsChanged: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4338
- globalsChanged: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true })
4339
- },
4340
- {
4341
- title: "OpensteerStateDelta",
4342
- required: ["cookiesChanged", "storageChanged", "hiddenFieldsChanged", "globalsChanged"]
4343
- }
4344
- );
4345
- var opensteerRequestInputDescriptorSchema = objectSchema(
4346
- {
4347
- name: stringSchema({ minLength: 1 }),
4348
- location: opensteerRequestInputLocationSchema,
4349
- path: stringSchema({ minLength: 1 }),
4350
- wireName: stringSchema({ minLength: 1 }),
4351
- requiredness: opensteerRequestInputRequirednessSchema,
4352
- classification: opensteerRequestInputClassificationSchema,
4353
- source: opensteerRequestInputSourceSchema,
4354
- materializationPolicy: opensteerRequestInputMaterializationPolicySchema,
4355
- exportPolicy: opensteerRequestInputExportPolicySchema,
4356
- originalValue: stringSchema(),
4357
- provenance: objectSchema(
4358
- {
4359
- recordId: stringSchema({ minLength: 1 }),
4360
- observationId: stringSchema({ minLength: 1 }),
4361
- sourcePointer: stringSchema({ minLength: 1 }),
4362
- notes: stringSchema({ minLength: 1 })
4363
- },
4364
- {
4365
- title: "OpensteerRequestInputDescriptorProvenance"
4366
- }
4367
- ),
4368
- unlockedByGuardIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true })
4369
- },
4370
- {
4371
- title: "OpensteerRequestInputDescriptor",
4372
- required: [
4373
- "name",
4374
- "location",
4375
- "requiredness",
4376
- "classification",
4377
- "source",
4378
- "materializationPolicy",
4379
- "exportPolicy"
4380
- ]
4381
- }
4382
- );
4383
- var opensteerExecutableResolverSchema = objectSchema(
4384
- {
4385
- id: stringSchema({ minLength: 1 }),
4386
- kind: opensteerExecutableResolverKindSchema,
4387
- label: stringSchema({ minLength: 1 }),
4388
- status: enumSchema(["ready", "missing"]),
4389
- requiresBrowser: { type: "boolean" },
4390
- requiresLiveState: { type: "boolean" },
4391
- description: stringSchema({ minLength: 1 }),
4392
- inputNames: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4393
- guardId: stringSchema({ minLength: 1 }),
4394
- traceId: stringSchema({ minLength: 1 }),
4395
- valueRef: opensteerValueReferenceSchema
4396
- },
4397
- {
4398
- title: "OpensteerExecutableResolver",
4399
- required: ["id", "kind", "label", "status", "requiresBrowser", "requiresLiveState"]
4400
- }
4401
- );
4402
- var opensteerReverseAdvisorySignalsSchema = objectSchema(
4403
- {
4404
- advisoryRank: numberSchema(),
4405
- observedAt: integerSchema({ minimum: 0 }),
4406
- targetHintMatches: integerSchema({ minimum: 0 }),
4407
- responseRichness: integerSchema({ minimum: 0 }),
4408
- portabilityWeight: integerSchema({ minimum: 0 }),
4409
- boundaryWeight: integerSchema({ minimum: 0 }),
4410
- successfulStatus: { type: "boolean" },
4411
- fetchLike: { type: "boolean" },
4412
- hasResponseBody: { type: "boolean" },
4413
- dataPathMatch: { type: "boolean" },
4414
- cookieInputCount: integerSchema({ minimum: 0 }),
4415
- storageInputCount: integerSchema({ minimum: 0 }),
4416
- volatileInputCount: integerSchema({ minimum: 0 }),
4417
- guardCount: integerSchema({ minimum: 0 })
4418
- },
4419
- {
4420
- title: "OpensteerReverseAdvisorySignals",
4421
- required: [
4422
- "advisoryRank",
4423
- "targetHintMatches",
4424
- "responseRichness",
4425
- "portabilityWeight",
4426
- "boundaryWeight",
4427
- "successfulStatus",
4428
- "fetchLike",
4429
- "hasResponseBody",
4430
- "dataPathMatch",
4431
- "cookieInputCount",
4432
- "storageInputCount",
4433
- "volatileInputCount",
4434
- "guardCount"
4435
- ]
4436
- }
4437
- );
4438
- var opensteerValidationRuleSchema = objectSchema(
4439
- {
4440
- id: stringSchema({ minLength: 1 }),
4441
- kind: opensteerValidationRuleKindSchema,
4442
- label: stringSchema({ minLength: 1 }),
4443
- required: { type: "boolean" },
4444
- expectedStatus: integerSchema({ minimum: 0 }),
4445
- structureHash: stringSchema({ minLength: 1 }),
4446
- textIncludes: stringSchema({ minLength: 1 }),
4447
- minimumCount: integerSchema({ minimum: 0 })
4448
- },
4449
- {
4450
- title: "OpensteerValidationRule",
4451
- required: ["id", "kind", "label", "required"]
4452
- }
4453
- );
4454
- var opensteerChannelDescriptorSchema = objectSchema(
4455
- {
4456
- kind: opensteerReverseChannelKindSchema,
4457
- recordKind: networkRecordKindSchema,
4458
- method: stringSchema({ minLength: 1 }),
4459
- url: stringSchema({ minLength: 1 }),
4460
- subprotocol: stringSchema({ minLength: 1 })
4461
- },
4462
- {
4463
- title: "OpensteerChannelDescriptor",
4464
- required: ["kind", "recordKind", "url"]
4465
- }
4466
- );
4467
- var opensteerReverseOperationWorkflowStepSchema = objectSchema(
4468
- {
4469
- id: stringSchema({ minLength: 1 }),
4470
- kind: enumSchema(["operation"]),
4471
- label: stringSchema({ minLength: 1 }),
4472
- operation: stringSchema({ minLength: 1 }),
4473
- input: opensteerValueTemplateSchema,
4474
- bindAs: stringSchema({ minLength: 1 })
4475
- },
4476
- {
4477
- title: "OpensteerReverseOperationWorkflowStep",
4478
- required: ["id", "kind", "label", "operation", "input"]
4479
- }
4480
- );
4481
- var opensteerReverseAwaitRecordWorkflowStepSchema = objectSchema(
4482
- {
4483
- id: stringSchema({ minLength: 1 }),
4484
- kind: enumSchema(["await-record"]),
4485
- label: stringSchema({ minLength: 1 }),
4486
- channel: opensteerChannelDescriptorSchema,
4487
- recordId: stringSchema({ minLength: 1 }),
4488
- match: objectSchema(
4489
- {
4490
- recordId: stringSchema({ minLength: 1 }),
4491
- host: stringSchema({ minLength: 1 }),
4492
- path: stringSchema({ minLength: 1 }),
4493
- method: stringSchema({ minLength: 1 }),
4494
- channel: opensteerReverseChannelKindSchema,
4495
- status: integerSchema({ minimum: 0 }),
4496
- text: stringSchema({ minLength: 1 })
4497
- },
4498
- {
4499
- title: "OpensteerReverseAwaitRecordMatch"
4500
- }
4501
- ),
4502
- validationRuleIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4503
- timeoutMs: integerSchema({ minimum: 0 }),
4504
- bindAs: stringSchema({ minLength: 1 })
4505
- },
4506
- {
4507
- title: "OpensteerReverseAwaitRecordWorkflowStep",
4508
- required: ["id", "kind", "label", "channel"]
4509
- }
4510
- );
4511
- var opensteerReverseAssertWorkflowStepSchema = objectSchema(
4512
- {
4513
- id: stringSchema({ minLength: 1 }),
4514
- kind: enumSchema(["assert"]),
4515
- label: stringSchema({ minLength: 1 }),
4516
- validationRuleIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4517
- binding: stringSchema({ minLength: 1 })
4518
- },
4519
- {
4520
- title: "OpensteerReverseAssertWorkflowStep",
4521
- required: ["id", "kind", "label", "validationRuleIds"]
4522
- }
4523
- );
4524
- var opensteerReverseWorkflowStepSchema = oneOfSchema(
4525
- [
4526
- opensteerReverseOperationWorkflowStepSchema,
4527
- opensteerReverseAwaitRecordWorkflowStepSchema,
4528
- opensteerReverseAssertWorkflowStepSchema
4529
- ],
4530
- {
4531
- title: "OpensteerReverseWorkflowStep"
4532
- }
4533
- );
4534
- var opensteerReversePackageRequirementsSchema = objectSchema(
4535
- {
4536
- requiresBrowser: { type: "boolean" },
4537
- requiresLiveState: { type: "boolean" },
4538
- manualCalibration: enumSchema(["not-needed", "recommended", "required"]),
4539
- stateSources: arraySchema(opensteerStateSourceKindSchema, { uniqueItems: true })
4540
- },
4541
- {
4542
- title: "OpensteerReversePackageRequirements",
4543
- required: ["requiresBrowser", "requiresLiveState", "manualCalibration", "stateSources"]
4544
- }
4545
- );
4546
- var opensteerReverseAdvisoryTemplateSchema = objectSchema(
4547
- {
4548
- id: stringSchema({ minLength: 1 }),
4549
- label: stringSchema({ minLength: 1 }),
4550
- channel: opensteerReverseChannelKindSchema,
4551
- execution: enumSchema(["transport", "page-observation"]),
4552
- stateSource: opensteerStateSourceKindSchema,
4553
- observationId: stringSchema({ minLength: 1 }),
4554
- transport: transportKindSchema,
4555
- guardIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4556
- resolverIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4557
- requiresBrowser: { type: "boolean" },
4558
- requiresLiveState: { type: "boolean" },
4559
- viability: enumSchema(["ready", "draft", "unsupported"]),
4560
- notes: stringSchema({ minLength: 1 })
4561
- },
4562
- {
4563
- title: "OpensteerReverseAdvisoryTemplate",
4564
- required: [
4565
- "id",
4566
- "label",
4567
- "channel",
4568
- "execution",
4569
- "stateSource",
4570
- "guardIds",
4571
- "resolverIds",
4572
- "requiresBrowser",
4573
- "requiresLiveState",
4574
- "viability"
4575
- ]
4576
- }
4577
- );
4578
- var opensteerReverseGuardRecordSchema = objectSchema(
4579
- {
4580
- id: stringSchema({ minLength: 1 }),
4581
- kind: enumSchema(["interaction", "state", "script", "manual"]),
4582
- label: stringSchema({ minLength: 1 }),
4583
- status: enumSchema(["required", "satisfied", "unresolved"]),
4584
- interactionTraceId: stringSchema({ minLength: 1 }),
4585
- notes: stringSchema({ minLength: 1 })
4586
- },
4587
- {
4588
- title: "OpensteerReverseGuardRecord",
4589
- required: ["id", "kind", "label", "status"]
4590
- }
4591
- );
4592
- var opensteerReverseObservationRecordSchema = objectSchema(
4593
- {
4594
- id: stringSchema({ minLength: 1 }),
4595
- capturedAt: integerSchema({ minimum: 0 }),
4596
- pageRef: pageRefSchema,
4597
- url: stringSchema({ minLength: 1 }),
4598
- stateSource: opensteerStateSourceKindSchema,
4599
- networkRecordIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4600
- scriptArtifactIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4601
- interactionTraceIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4602
- stateSnapshotIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4603
- notes: stringSchema({ minLength: 1 })
4604
- },
4605
- {
4606
- title: "OpensteerReverseObservationRecord",
4607
- required: [
4608
- "id",
4609
- "capturedAt",
4610
- "stateSource",
4611
- "networkRecordIds",
4612
- "scriptArtifactIds",
4613
- "interactionTraceIds",
4614
- "stateSnapshotIds"
4615
- ]
4616
- }
4617
- );
4618
- var opensteerReverseObservedRecordSchema = objectSchema(
4619
- {
4620
- recordId: stringSchema({ minLength: 1 }),
4621
- observationId: stringSchema({ minLength: 1 }),
4622
- clusterId: stringSchema({ minLength: 1 }),
4623
- observedAt: integerSchema({ minimum: 0 }),
4624
- channel: opensteerChannelDescriptorSchema,
4625
- bodyCodec: opensteerBodyCodecDescriptorSchema,
4626
- resourceType: stringSchema({ minLength: 1 }),
4627
- status: integerSchema({ minimum: 0 }),
4628
- matchedTargetHints: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4629
- relationKinds: arraySchema(opensteerObservationClusterRelationshipKindSchema, {
4630
- uniqueItems: true
4631
- })
4632
- },
4633
- {
4634
- title: "OpensteerReverseObservedRecord",
4635
- required: [
4636
- "recordId",
4637
- "observationId",
4638
- "clusterId",
4639
- "channel",
4640
- "bodyCodec",
4641
- "matchedTargetHints",
4642
- "relationKinds"
4643
- ]
4644
- }
4645
- );
4646
- var opensteerReverseCandidateRecordSchema = objectSchema(
4647
- {
4648
- id: stringSchema({ minLength: 1 }),
4649
- observationId: stringSchema({ minLength: 1 }),
4650
- clusterId: stringSchema({ minLength: 1 }),
4651
- recordId: stringSchema({ minLength: 1 }),
4652
- channel: opensteerChannelDescriptorSchema,
4653
- bodyCodec: opensteerBodyCodecDescriptorSchema,
4654
- boundary: opensteerReverseCandidateBoundarySchema,
4655
- summary: stringSchema({ minLength: 1 }),
4656
- matchedTargetHints: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4657
- advisoryTags: arraySchema(opensteerReverseAdvisoryTagSchema, { uniqueItems: true }),
4658
- constraints: arraySchema(opensteerReverseConstraintKindSchema, { uniqueItems: true }),
4659
- signals: opensteerReverseAdvisorySignalsSchema,
4660
- inputs: arraySchema(opensteerRequestInputDescriptorSchema),
4661
- resolvers: arraySchema(opensteerExecutableResolverSchema),
4662
- guardIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4663
- scriptArtifactIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4664
- advisoryTemplates: arraySchema(opensteerReverseAdvisoryTemplateSchema)
4665
- },
4666
- {
4667
- title: "OpensteerReverseCandidateRecord",
4668
- required: [
4669
- "id",
4670
- "observationId",
4671
- "clusterId",
4672
- "recordId",
4673
- "channel",
4674
- "bodyCodec",
4675
- "boundary",
4676
- "summary",
4677
- "matchedTargetHints",
4678
- "advisoryTags",
4679
- "constraints",
4680
- "signals",
4681
- "inputs",
4682
- "resolvers",
4683
- "guardIds",
4684
- "scriptArtifactIds",
4685
- "advisoryTemplates"
4686
- ]
4687
- }
4688
- );
4689
- var opensteerReverseReplayValidationSchema = objectSchema(
4690
- {
4691
- statusMatches: { type: "boolean" },
4692
- structureMatches: { type: "boolean" },
4693
- opened: { type: "boolean" },
4694
- firstChunkObserved: { type: "boolean" },
4695
- firstChunkMatches: { type: "boolean" },
4696
- messageObserved: { type: "boolean" },
4697
- messageCount: integerSchema({ minimum: 0 })
4698
- },
4699
- {
4700
- title: "OpensteerReverseReplayValidation"
4701
- }
4702
- );
4703
- var opensteerReverseReplayRunRecordSchema = objectSchema(
4704
- {
4705
- id: stringSchema({ minLength: 1 }),
4706
- createdAt: integerSchema({ minimum: 0 }),
4707
- candidateId: stringSchema({ minLength: 1 }),
4708
- templateId: stringSchema({ minLength: 1 }),
4709
- packageId: stringSchema({ minLength: 1 }),
4710
- success: { type: "boolean" },
4711
- channel: opensteerReverseChannelKindSchema,
4712
- kind: opensteerReversePackageKindSchema,
4713
- readiness: opensteerReversePackageReadinessSchema,
4714
- transport: transportKindSchema,
4715
- stateSource: opensteerStateSourceKindSchema,
4716
- executedStepIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4717
- failedStepId: stringSchema({ minLength: 1 }),
4718
- bindings: recordSchema({}, { title: "OpensteerReverseReplayRunBindings" }),
4719
- recordId: stringSchema({ minLength: 1 }),
4720
- status: integerSchema({ minimum: 0 }),
4721
- validation: opensteerReverseReplayValidationSchema,
4722
- error: stringSchema({ minLength: 1 })
4723
- },
4724
- {
4725
- title: "OpensteerReverseReplayRunRecord",
4726
- required: [
4727
- "id",
4728
- "createdAt",
4729
- "packageId",
4730
- "success",
4731
- "kind",
4732
- "readiness",
4733
- "executedStepIds",
4734
- "validation"
4735
- ]
4736
- }
4737
- );
4738
- var opensteerReverseExperimentRecordSchema = objectSchema(
4739
- {
4740
- id: stringSchema({ minLength: 1 }),
4741
- createdAt: integerSchema({ minimum: 0 }),
4742
- candidateId: stringSchema({ minLength: 1 }),
4743
- templateId: stringSchema({ minLength: 1 }),
4744
- kind: enumSchema(["replay-attempt", "field-variation"]),
4745
- hypothesis: stringSchema({ minLength: 1 }),
4746
- success: { type: "boolean" },
4747
- status: integerSchema({ minimum: 0 }),
4748
- notes: stringSchema({ minLength: 1 }),
4749
- validation: opensteerReverseReplayValidationSchema
4750
- },
4751
- {
4752
- title: "OpensteerReverseExperimentRecord",
4753
- required: ["id", "createdAt", "kind", "hypothesis", "success"]
4754
- }
4755
- );
4756
- var opensteerReverseRequirementSchema = objectSchema(
4757
- {
4758
- id: stringSchema({ minLength: 1 }),
4759
- kind: opensteerReverseRequirementKindSchema,
4760
- status: opensteerReverseRequirementStatusSchema,
4761
- label: stringSchema({ minLength: 1 }),
4762
- description: stringSchema({ minLength: 1 }),
4763
- blocking: { type: "boolean" },
4764
- resolverId: stringSchema({ minLength: 1 }),
4765
- guardId: stringSchema({ minLength: 1 }),
4766
- stepId: stringSchema({ minLength: 1 }),
4767
- inputNames: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4768
- traceId: stringSchema({ minLength: 1 }),
4769
- artifactId: stringSchema({ minLength: 1 }),
4770
- recordId: stringSchema({ minLength: 1 })
4771
- },
4772
- {
4773
- title: "OpensteerReverseRequirement",
4774
- required: ["id", "kind", "status", "label", "blocking"]
4775
- }
4776
- );
4777
- var opensteerReverseSuggestedEditSchema = objectSchema(
4778
- {
4779
- id: stringSchema({ minLength: 1 }),
4780
- kind: opensteerReverseSuggestedEditKindSchema,
4781
- label: stringSchema({ minLength: 1 }),
4782
- description: stringSchema({ minLength: 1 }),
4783
- resolverId: stringSchema({ minLength: 1 }),
4784
- guardId: stringSchema({ minLength: 1 }),
4785
- stepId: stringSchema({ minLength: 1 }),
4786
- traceId: stringSchema({ minLength: 1 }),
4787
- artifactId: stringSchema({ minLength: 1 }),
4788
- recordId: stringSchema({ minLength: 1 }),
4789
- payload: jsonValueSchema2
4790
- },
4791
- {
4792
- title: "OpensteerReverseSuggestedEdit",
4793
- required: ["id", "kind", "label"]
4794
- }
4795
- );
4796
- var opensteerReverseExportRecordSchema = objectSchema(
4797
- {
4798
- id: stringSchema({ minLength: 1 }),
4799
- createdAt: integerSchema({ minimum: 0 }),
4800
- candidateId: stringSchema({ minLength: 1 }),
4801
- templateId: stringSchema({ minLength: 1 }),
4802
- packageId: stringSchema({ minLength: 1 }),
4803
- kind: opensteerReversePackageKindSchema,
4804
- readiness: opensteerReversePackageReadinessSchema,
4805
- requestPlanId: stringSchema({ minLength: 1 })
4806
- },
4807
- {
4808
- title: "OpensteerReverseExportRecord",
4809
- required: ["id", "createdAt", "packageId", "kind", "readiness"]
4810
- }
4811
- );
4812
- var opensteerReverseCasePayloadSchema = objectSchema(
4813
- {
4814
- objective: stringSchema({ minLength: 1 }),
4815
- notes: stringSchema({ minLength: 1 }),
4816
- status: opensteerReverseCaseStatusSchema,
4817
- stateSource: opensteerStateSourceKindSchema,
4818
- observations: arraySchema(opensteerReverseObservationRecordSchema),
4819
- observationClusters: arraySchema(opensteerObservationClusterSchema),
4820
- observedRecords: arraySchema(opensteerReverseObservedRecordSchema),
4821
- candidates: arraySchema(opensteerReverseCandidateRecordSchema),
4822
- guards: arraySchema(opensteerReverseGuardRecordSchema),
4823
- stateSnapshots: arraySchema(opensteerStateSnapshotSchema),
4824
- stateDeltas: arraySchema(opensteerStateDeltaSchema),
4825
- experiments: arraySchema(opensteerReverseExperimentRecordSchema),
4826
- replayRuns: arraySchema(opensteerReverseReplayRunRecordSchema),
4827
- exports: arraySchema(opensteerReverseExportRecordSchema)
4828
- },
4829
- {
4830
- title: "OpensteerReverseCasePayload",
4831
- required: [
4832
- "objective",
4833
- "status",
4834
- "stateSource",
4835
- "observations",
4836
- "observationClusters",
4837
- "observedRecords",
4838
- "candidates",
4839
- "guards",
4840
- "stateSnapshots",
4841
- "stateDeltas",
4842
- "experiments",
4843
- "replayRuns",
4844
- "exports"
4845
- ]
4846
- }
4847
- );
4848
- objectSchema(
4849
- {
4850
- id: stringSchema({ minLength: 1 }),
4851
- key: stringSchema({ minLength: 1 }),
4852
- version: stringSchema({ minLength: 1 }),
4853
- createdAt: integerSchema({ minimum: 0 }),
4854
- updatedAt: integerSchema({ minimum: 0 }),
4855
- contentHash: stringSchema({ minLength: 1 }),
4856
- tags: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4857
- provenance: opensteerRegistryProvenanceSchema,
4858
- payload: opensteerReverseCasePayloadSchema
4859
- },
4860
- {
4861
- title: "OpensteerReverseCaseRecord",
4862
- required: ["id", "key", "version", "createdAt", "updatedAt", "contentHash", "tags", "payload"]
4863
- }
4864
- );
4865
- var opensteerReversePackagePayloadSchema = objectSchema(
4866
- {
4867
- kind: opensteerReversePackageKindSchema,
4868
- readiness: opensteerReversePackageReadinessSchema,
4869
- caseId: stringSchema({ minLength: 1 }),
4870
- objective: stringSchema({ minLength: 1 }),
4871
- source: objectSchema(
4872
- {
4873
- kind: enumSchema(["record", "candidate"]),
4874
- id: stringSchema({ minLength: 1 })
4875
- },
4876
- {
4877
- title: "OpensteerReversePackageSource",
4878
- required: ["kind", "id"]
4879
- }
4880
- ),
4881
- sourceRecordId: stringSchema({ minLength: 1 }),
4882
- candidateId: stringSchema({ minLength: 1 }),
4883
- candidate: opensteerReverseCandidateRecordSchema,
4884
- templateId: stringSchema({ minLength: 1 }),
4885
- template: opensteerReverseAdvisoryTemplateSchema,
4886
- channel: opensteerChannelDescriptorSchema,
4887
- stateSource: opensteerStateSourceKindSchema,
4888
- observationId: stringSchema({ minLength: 1 }),
4889
- transport: transportKindSchema,
4890
- guardIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4891
- workflow: arraySchema(opensteerReverseWorkflowStepSchema),
4892
- resolvers: arraySchema(opensteerExecutableResolverSchema),
4893
- validators: arraySchema(opensteerValidationRuleSchema),
4894
- stateSnapshots: arraySchema(opensteerStateSnapshotSchema),
4895
- requirements: opensteerReversePackageRequirementsSchema,
4896
- requestPlanId: stringSchema({ minLength: 1 }),
4897
- unresolvedRequirements: arraySchema(opensteerReverseRequirementSchema),
4898
- suggestedEdits: arraySchema(opensteerReverseSuggestedEditSchema),
4899
- attachedTraceIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4900
- attachedArtifactIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4901
- attachedRecordIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4902
- notes: stringSchema({ minLength: 1 }),
4903
- parentPackageId: stringSchema({ minLength: 1 })
4904
- },
4905
- {
4906
- title: "OpensteerReversePackagePayload",
4907
- required: [
4908
- "kind",
4909
- "readiness",
4910
- "caseId",
4911
- "objective",
4912
- "source",
4913
- "sourceRecordId",
4914
- "guardIds",
4915
- "workflow",
4916
- "resolvers",
4917
- "validators",
4918
- "stateSnapshots",
4919
- "requirements",
4920
- "unresolvedRequirements",
4921
- "suggestedEdits",
4922
- "attachedTraceIds",
4923
- "attachedArtifactIds",
4924
- "attachedRecordIds"
4925
- ]
4926
- }
4927
- );
4928
- var opensteerReversePackageRecordSchema = objectSchema(
4929
- {
4930
- id: stringSchema({ minLength: 1 }),
4931
- key: stringSchema({ minLength: 1 }),
4932
- version: stringSchema({ minLength: 1 }),
4933
- createdAt: integerSchema({ minimum: 0 }),
4934
- updatedAt: integerSchema({ minimum: 0 }),
4935
- contentHash: stringSchema({ minLength: 1 }),
4936
- tags: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4937
- provenance: opensteerRegistryProvenanceSchema,
4938
- payload: opensteerReversePackagePayloadSchema
4939
- },
4940
- {
4941
- title: "OpensteerReversePackageRecord",
4942
- required: ["id", "key", "version", "createdAt", "updatedAt", "contentHash", "tags", "payload"]
4943
- }
4944
- );
4945
- var opensteerReverseCandidateReportItemSchema = objectSchema(
4946
- {
4947
- candidateId: stringSchema({ minLength: 1 }),
4948
- clusterId: stringSchema({ minLength: 1 }),
4949
- advisoryRank: numberSchema(),
4950
- bodyCodec: opensteerBodyCodecDescriptorSchema,
4951
- summary: stringSchema({ minLength: 1 }),
4952
- advisoryTags: arraySchema(opensteerReverseAdvisoryTagSchema, { uniqueItems: true }),
4953
- constraints: arraySchema(opensteerReverseConstraintKindSchema, { uniqueItems: true }),
4954
- signals: opensteerReverseAdvisorySignalsSchema,
4955
- reasons: arraySchema(stringSchema({ minLength: 1 }))
4956
- },
4957
- {
4958
- title: "OpensteerReverseCandidateAdvisoryItem",
4959
- required: [
4960
- "candidateId",
4961
- "clusterId",
4962
- "advisoryRank",
4963
- "bodyCodec",
4964
- "summary",
4965
- "advisoryTags",
4966
- "constraints",
4967
- "signals",
4968
- "reasons"
4969
- ]
4970
- }
4971
- );
4972
- var opensteerReverseDiscoverySummaryCountsSchema = objectSchema(
4973
- {
4974
- hosts: recordSchema(integerSchema({ minimum: 0 }), { title: "OpensteerReverseSummaryHosts" }),
4975
- channels: recordSchema(integerSchema({ minimum: 0 }), {
4976
- title: "OpensteerReverseSummaryChannels"
4977
- }),
4978
- resourceTypes: recordSchema(integerSchema({ minimum: 0 }), {
4979
- title: "OpensteerReverseSummaryResourceTypes"
4980
- }),
4981
- advisoryTags: recordSchema(integerSchema({ minimum: 0 }), {
4982
- title: "OpensteerReverseSummaryAdvisoryTags"
4983
- }),
4984
- constraints: recordSchema(integerSchema({ minimum: 0 }), {
4985
- title: "OpensteerReverseSummaryConstraints"
4986
- }),
4987
- relationKinds: recordSchema(integerSchema({ minimum: 0 }), {
4988
- title: "OpensteerReverseSummaryRelationKinds"
4989
- })
4990
- },
4991
- {
4992
- title: "OpensteerReverseDiscoverySummaryCounts",
4993
- required: [
4994
- "hosts",
4995
- "channels",
4996
- "resourceTypes",
4997
- "advisoryTags",
4998
- "constraints",
4999
- "relationKinds"
5000
- ]
5001
- }
5002
- );
5003
- var opensteerReverseReportPayloadSchema = objectSchema(
5004
- {
5005
- kind: opensteerReverseReportKindSchema,
5006
- caseId: stringSchema({ minLength: 1 }),
5007
- objective: stringSchema({ minLength: 1 }),
5008
- packageId: stringSchema({ minLength: 1 }),
5009
- packageKind: opensteerReversePackageKindSchema,
5010
- packageReadiness: opensteerReversePackageReadinessSchema,
5011
- observations: arraySchema(opensteerReverseObservationRecordSchema),
5012
- observationClusters: arraySchema(opensteerObservationClusterSchema),
5013
- observedRecords: arraySchema(opensteerReverseObservedRecordSchema),
5014
- guards: arraySchema(opensteerReverseGuardRecordSchema),
5015
- stateDeltas: arraySchema(opensteerStateDeltaSchema),
5016
- summaryCounts: opensteerReverseDiscoverySummaryCountsSchema,
5017
- candidateAdvisories: arraySchema(opensteerReverseCandidateReportItemSchema),
5018
- query: objectSchema(
5019
- {
5020
- view: opensteerReverseQueryViewSchema,
5021
- filters: objectSchema(
5022
- {
5023
- recordId: stringSchema({ minLength: 1 }),
5024
- clusterId: stringSchema({ minLength: 1 }),
5025
- candidateId: stringSchema({ minLength: 1 }),
5026
- host: stringSchema({ minLength: 1 }),
5027
- path: stringSchema({ minLength: 1 }),
5028
- method: stringSchema({ minLength: 1 }),
5029
- status: stringSchema({ minLength: 1 }),
5030
- resourceType: stringSchema({ minLength: 1 }),
5031
- channel: opensteerReverseChannelKindSchema,
5032
- boundary: opensteerReverseCandidateBoundarySchema,
5033
- advisoryTag: opensteerReverseAdvisoryTagSchema,
5034
- constraint: opensteerReverseConstraintKindSchema,
5035
- bodyCodec: opensteerBodyCodecKindSchema,
5036
- relationKind: opensteerObservationClusterRelationshipKindSchema,
5037
- hasGuards: { type: "boolean" },
5038
- hasResolvers: { type: "boolean" },
5039
- artifactId: stringSchema({ minLength: 1 }),
5040
- stateSnapshotId: stringSchema({ minLength: 1 }),
5041
- traceId: stringSchema({ minLength: 1 }),
5042
- evidenceRef: stringSchema({ minLength: 1 }),
5043
- text: stringSchema({ minLength: 1 })
5044
- },
5045
- {
5046
- title: "OpensteerReverseReportQueryFilters"
5047
- }
5048
- ),
5049
- sort: objectSchema(
5050
- {
5051
- preset: opensteerReverseSortPresetSchema,
5052
- keys: arraySchema(
5053
- objectSchema(
5054
- {
5055
- key: opensteerReverseSortKeySchema,
5056
- direction: opensteerReverseSortDirectionSchema
5057
- },
5058
- {
5059
- title: "OpensteerReverseReportQuerySortTerm",
5060
- required: ["key"]
5061
- }
5062
- ),
5063
- { minItems: 1 }
5064
- )
5065
- },
5066
- {
5067
- title: "OpensteerReverseReportQuerySort"
5068
- }
5069
- ),
5070
- limit: integerSchema({ minimum: 1 }),
5071
- totalCount: integerSchema({ minimum: 0 }),
5072
- nextCursor: stringSchema({ minLength: 1 }),
5073
- resultIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true })
5074
- },
5075
- {
5076
- title: "OpensteerReverseQuerySnapshot",
5077
- required: ["view", "sort", "limit", "totalCount", "resultIds"]
5078
- }
5079
- ),
5080
- experiments: arraySchema(opensteerReverseExperimentRecordSchema),
5081
- replayRuns: arraySchema(opensteerReverseReplayRunRecordSchema),
5082
- unresolvedRequirements: arraySchema(opensteerReverseRequirementSchema),
5083
- suggestedEdits: arraySchema(opensteerReverseSuggestedEditSchema),
5084
- linkedNetworkRecordIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5085
- linkedInteractionTraceIds: arraySchema(stringSchema({ minLength: 1 }), {
5086
- uniqueItems: true
5087
- }),
5088
- linkedArtifactIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5089
- linkedStateSnapshotIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5090
- package: opensteerReversePackageRecordSchema
5091
- },
5092
- {
5093
- title: "OpensteerReverseReportPayload",
5094
- required: [
5095
- "kind",
5096
- "caseId",
5097
- "objective",
5098
- "observations",
5099
- "observationClusters",
5100
- "observedRecords",
5101
- "guards",
5102
- "stateDeltas",
5103
- "summaryCounts",
5104
- "candidateAdvisories",
5105
- "experiments",
5106
- "replayRuns",
5107
- "linkedNetworkRecordIds",
5108
- "linkedInteractionTraceIds",
5109
- "linkedArtifactIds",
5110
- "linkedStateSnapshotIds"
5111
- ]
5112
- }
5113
- );
5114
- var opensteerReverseReportRecordSchema = objectSchema(
5115
- {
5116
- id: stringSchema({ minLength: 1 }),
5117
- key: stringSchema({ minLength: 1 }),
5118
- version: stringSchema({ minLength: 1 }),
5119
- createdAt: integerSchema({ minimum: 0 }),
5120
- updatedAt: integerSchema({ minimum: 0 }),
5121
- contentHash: stringSchema({ minLength: 1 }),
5122
- tags: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5123
- provenance: opensteerRegistryProvenanceSchema,
5124
- payload: opensteerReverseReportPayloadSchema
5125
- },
5126
- {
5127
- title: "OpensteerReverseReportRecord",
5128
- required: ["id", "key", "version", "createdAt", "updatedAt", "contentHash", "tags", "payload"]
5129
- }
5130
- );
5131
- var opensteerReverseNetworkFilterSchema = objectSchema(
5132
- {
5133
- url: stringSchema({ minLength: 1 }),
5134
- hostname: stringSchema({ minLength: 1 }),
5135
- path: stringSchema({ minLength: 1 }),
5136
- method: stringSchema({ minLength: 1 }),
5137
- resourceType: stringSchema({ minLength: 1 }),
5138
- includeBodies: { type: "boolean" }
5139
- },
5140
- {
5141
- title: "OpensteerReverseCaptureNetworkFilter"
5142
- }
5143
- );
5144
- var opensteerReverseQueryFiltersSchema = objectSchema(
5145
- {
5146
- recordId: stringSchema({ minLength: 1 }),
5147
- clusterId: stringSchema({ minLength: 1 }),
5148
- candidateId: stringSchema({ minLength: 1 }),
5149
- host: stringSchema({ minLength: 1 }),
5150
- path: stringSchema({ minLength: 1 }),
5151
- method: stringSchema({ minLength: 1 }),
5152
- status: stringSchema({ minLength: 1 }),
5153
- resourceType: stringSchema({ minLength: 1 }),
5154
- channel: opensteerReverseChannelKindSchema,
5155
- boundary: opensteerReverseCandidateBoundarySchema,
5156
- advisoryTag: opensteerReverseAdvisoryTagSchema,
5157
- constraint: opensteerReverseConstraintKindSchema,
5158
- bodyCodec: opensteerBodyCodecKindSchema,
5159
- relationKind: opensteerObservationClusterRelationshipKindSchema,
5160
- hasGuards: { type: "boolean" },
5161
- hasResolvers: { type: "boolean" },
5162
- artifactId: stringSchema({ minLength: 1 }),
5163
- stateSnapshotId: stringSchema({ minLength: 1 }),
5164
- traceId: stringSchema({ minLength: 1 }),
5165
- evidenceRef: stringSchema({ minLength: 1 }),
5166
- text: stringSchema({ minLength: 1 })
5167
- },
5168
- {
5169
- title: "OpensteerReverseQueryFilters"
5170
- }
5171
- );
5172
- var opensteerReverseQuerySortSchema = objectSchema(
5173
- {
5174
- preset: opensteerReverseSortPresetSchema,
5175
- keys: arraySchema(
5176
- objectSchema(
5177
- {
5178
- key: opensteerReverseSortKeySchema,
5179
- direction: opensteerReverseSortDirectionSchema
5180
- },
5181
- {
5182
- title: "OpensteerReverseSortTerm",
5183
- required: ["key"]
5184
- }
5185
- ),
5186
- { minItems: 1 }
5187
- )
5188
- },
5189
- {
5190
- title: "OpensteerReverseQuerySort"
5191
- }
5192
- );
5193
- var opensteerReverseQuerySnapshotSchema = objectSchema(
5194
- {
5195
- view: opensteerReverseQueryViewSchema,
5196
- filters: opensteerReverseQueryFiltersSchema,
5197
- sort: opensteerReverseQuerySortSchema,
5198
- limit: integerSchema({ minimum: 1, maximum: 200 }),
5199
- totalCount: integerSchema({ minimum: 0 }),
5200
- nextCursor: stringSchema({ minLength: 1 }),
5201
- resultIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true })
5202
- },
5203
- {
5204
- title: "OpensteerReverseQuerySnapshot",
5205
- required: ["view", "sort", "limit", "totalCount", "resultIds"]
5206
- }
5207
- );
5208
- var opensteerReverseQueryRecordItemSchema = objectSchema(
5209
- {
5210
- record: opensteerReverseObservedRecordSchema,
5211
- candidateIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true })
5212
- },
5213
- {
5214
- title: "OpensteerReverseQueryRecordItem",
5215
- required: ["record", "candidateIds"]
5216
- }
5217
- );
5218
- var opensteerReverseQueryClusterItemSchema = objectSchema(
5219
- {
5220
- cluster: opensteerObservationClusterSchema,
5221
- candidateIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true })
5222
- },
5223
- {
5224
- title: "OpensteerReverseQueryClusterItem",
5225
- required: ["cluster", "candidateIds"]
5226
- }
5227
- );
5228
- var opensteerReverseQueryCandidateItemSchema = objectSchema(
5229
- {
5230
- candidate: opensteerReverseCandidateRecordSchema,
5231
- reasons: arraySchema(stringSchema({ minLength: 1 }))
5232
- },
5233
- {
5234
- title: "OpensteerReverseQueryCandidateItem",
5235
- required: ["candidate", "reasons"]
5236
- }
5237
- );
5238
- objectSchema(
5239
- {
5240
- caseId: stringSchema({ minLength: 1 }),
5241
- key: stringSchema({ minLength: 1 }),
5242
- objective: stringSchema({ minLength: 1 }),
5243
- notes: stringSchema({ minLength: 1 }),
5244
- tags: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5245
- pageRef: pageRefSchema,
5246
- stateSource: opensteerStateSourceKindSchema,
5247
- network: opensteerReverseNetworkFilterSchema,
5248
- includeScripts: { type: "boolean" },
5249
- includeStorage: { type: "boolean" },
5250
- includeSessionStorage: { type: "boolean" },
5251
- includeIndexedDb: { type: "boolean" },
5252
- interactionTraceIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5253
- targetHints: opensteerReverseTargetHintsSchema,
5254
- captureWindowMs: integerSchema({ minimum: 0 }),
5255
- manualCalibration: opensteerReverseManualCalibrationModeSchema
5256
- },
5257
- {
5258
- title: "OpensteerReverseDiscoverInput"
5259
- }
5260
- );
5261
- objectSchema(
5262
- {
5263
- caseId: stringSchema({ minLength: 1 }),
5264
- reportId: stringSchema({ minLength: 1 }),
5265
- summary: objectSchema(
5266
- {
5267
- observationIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5268
- recordCount: integerSchema({ minimum: 0 }),
5269
- clusterCount: integerSchema({ minimum: 0 }),
5270
- candidateCount: integerSchema({ minimum: 0 })
5271
- },
5272
- {
5273
- title: "OpensteerReverseDiscoverSummary",
5274
- required: ["observationIds", "recordCount", "clusterCount", "candidateCount"]
5275
- }
5276
- ),
5277
- index: objectSchema(
5278
- {
5279
- views: arraySchema(opensteerReverseQueryViewSchema, { uniqueItems: true }),
5280
- sortableKeys: arraySchema(opensteerReverseSortKeySchema, { uniqueItems: true }),
5281
- channels: arraySchema(opensteerReverseChannelKindSchema, { uniqueItems: true }),
5282
- hosts: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5283
- relationKinds: arraySchema(opensteerObservationClusterRelationshipKindSchema, {
5284
- uniqueItems: true
5285
- })
5286
- },
5287
- {
5288
- title: "OpensteerReverseDiscoverIndex",
5289
- required: ["views", "sortableKeys", "channels", "hosts", "relationKinds"]
5290
- }
5291
- )
5292
- },
5293
- {
5294
- title: "OpensteerReverseDiscoverOutput",
5295
- required: ["caseId", "reportId", "summary", "index"]
5296
- }
5297
- );
5298
- objectSchema(
5299
- {
5300
- caseId: stringSchema({ minLength: 1 }),
5301
- view: opensteerReverseQueryViewSchema,
5302
- filters: opensteerReverseQueryFiltersSchema,
5303
- sort: opensteerReverseQuerySortSchema,
5304
- limit: integerSchema({ minimum: 1, maximum: 200 }),
5305
- cursor: stringSchema({ minLength: 1 })
5306
- },
5307
- {
5308
- title: "OpensteerReverseQueryInput",
5309
- required: ["caseId"]
5310
- }
5311
- );
5312
- objectSchema(
5313
- {
5314
- caseId: stringSchema({ minLength: 1 }),
5315
- view: opensteerReverseQueryViewSchema,
5316
- query: opensteerReverseQuerySnapshotSchema,
5317
- totalCount: integerSchema({ minimum: 0 }),
5318
- nextCursor: stringSchema({ minLength: 1 }),
5319
- records: arraySchema(opensteerReverseQueryRecordItemSchema),
5320
- clusters: arraySchema(opensteerReverseQueryClusterItemSchema),
5321
- candidates: arraySchema(opensteerReverseQueryCandidateItemSchema)
5322
- },
5323
- {
5324
- title: "OpensteerReverseQueryOutput",
5325
- required: ["caseId", "view", "query", "totalCount"]
5326
- }
5327
- );
5328
- objectSchema(
5329
- {
5330
- caseId: stringSchema({ minLength: 1 }),
5331
- source: objectSchema(
5332
- {
5333
- kind: enumSchema(["record", "candidate"]),
5334
- id: stringSchema({ minLength: 1 })
5335
- },
5336
- {
5337
- title: "OpensteerReversePackageCreateSource",
5338
- required: ["kind", "id"]
5339
- }
5340
- ),
5341
- templateId: stringSchema({ minLength: 1 }),
5342
- key: stringSchema({ minLength: 1 }),
5343
- version: stringSchema({ minLength: 1 }),
5344
- notes: stringSchema({ minLength: 1 })
5345
- },
5346
- {
5347
- title: "OpensteerReversePackageCreateInput",
5348
- required: ["caseId", "source"]
5349
- }
5350
- );
5351
- objectSchema(
5352
- {
5353
- package: opensteerReversePackageRecordSchema,
5354
- report: opensteerReverseReportRecordSchema
5355
- },
5356
- {
5357
- title: "OpensteerReversePackageCreateOutput",
5358
- required: ["package", "report"]
5359
- }
5360
- );
5361
- objectSchema(
5362
- {
5363
- packageId: stringSchema({ minLength: 1 }),
5364
- pageRef: pageRefSchema
5365
- },
5366
- {
5367
- title: "OpensteerReversePackageRunInput",
5368
- required: ["packageId"]
5369
- }
5370
- );
5371
- objectSchema(
5372
- {
5373
- packageId: stringSchema({ minLength: 1 }),
5374
- caseId: stringSchema({ minLength: 1 }),
5375
- source: objectSchema(
5376
- {
5377
- kind: enumSchema(["record", "candidate"]),
5378
- id: stringSchema({ minLength: 1 })
5379
- },
5380
- {
5381
- title: "OpensteerReversePackageRunSource",
5382
- required: ["kind", "id"]
5383
- }
5384
- ),
5385
- candidateId: stringSchema({ minLength: 1 }),
5386
- templateId: stringSchema({ minLength: 1 }),
5387
- success: { type: "boolean" },
5388
- kind: opensteerReversePackageKindSchema,
5389
- readiness: opensteerReversePackageReadinessSchema,
5390
- channel: opensteerReverseChannelKindSchema,
5391
- transport: transportKindSchema,
5392
- stateSource: opensteerStateSourceKindSchema,
5393
- recordId: stringSchema({ minLength: 1 }),
5394
- status: integerSchema({ minimum: 0 }),
5395
- validation: opensteerReverseReplayValidationSchema,
5396
- executedStepIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5397
- failedStepId: stringSchema({ minLength: 1 }),
5398
- bindings: recordSchema({}, { title: "OpensteerReversePackageRunBindings" }),
5399
- replayRunId: stringSchema({ minLength: 1 }),
5400
- unresolvedRequirements: arraySchema(opensteerReverseRequirementSchema),
5401
- suggestedEdits: arraySchema(opensteerReverseSuggestedEditSchema),
5402
- error: stringSchema({ minLength: 1 })
5403
- },
5404
- {
5405
- title: "OpensteerReversePackageRunOutput",
5406
- required: [
5407
- "packageId",
5408
- "source",
5409
- "success",
5410
- "kind",
5411
- "readiness",
5412
- "validation",
5413
- "executedStepIds",
5414
- "bindings",
5415
- "unresolvedRequirements",
5416
- "suggestedEdits"
5417
- ]
5418
- }
5419
- );
5420
- objectSchema(
5421
- {
5422
- packageId: stringSchema({ minLength: 1 }),
5423
- key: stringSchema({ minLength: 1 }),
5424
- version: stringSchema({ minLength: 1 })
5425
- },
5426
- {
5427
- title: "OpensteerReverseExportInput",
5428
- required: ["packageId"]
5429
- }
5430
- );
5431
- objectSchema(
5432
- {
5433
- package: opensteerReversePackageRecordSchema,
5434
- requestPlan: opensteerRequestPlanRecordSchema
5435
- },
5436
- {
5437
- title: "OpensteerReverseExportOutput",
5438
- required: ["package"]
5439
- }
5440
- );
5441
- objectSchema(
5442
- {
5443
- caseId: stringSchema({ minLength: 1 }),
5444
- packageId: stringSchema({ minLength: 1 }),
5445
- reportId: stringSchema({ minLength: 1 }),
5446
- kind: opensteerReverseReportKindSchema
5447
- },
5448
- {
5449
- title: "OpensteerReverseReportInput"
5450
- }
5451
- );
5452
- objectSchema(
5453
- {
5454
- report: opensteerReverseReportRecordSchema
5455
- },
5456
- {
5457
- title: "OpensteerReverseReportOutput",
5458
- required: ["report"]
5459
- }
5460
- );
5461
- objectSchema(
5462
- {
5463
- packageId: stringSchema({ minLength: 1 })
5464
- },
5465
- {
5466
- title: "OpensteerReversePackageGetInput",
5467
- required: ["packageId"]
5468
- }
5469
- );
5470
- objectSchema(
5471
- {
5472
- package: opensteerReversePackageRecordSchema
5473
- },
5474
- {
5475
- title: "OpensteerReversePackageGetOutput",
5476
- required: ["package"]
5477
- }
5478
- );
5479
- objectSchema(
5480
- {
5481
- caseId: stringSchema({ minLength: 1 }),
5482
- key: stringSchema({ minLength: 1 }),
5483
- kind: opensteerReversePackageKindSchema,
5484
- readiness: opensteerReversePackageReadinessSchema
3531
+ required: ["status"]
3532
+ }
3533
+ )
5485
3534
  },
5486
3535
  {
5487
- title: "OpensteerReversePackageListInput"
3536
+ title: "SandboxAjaxRoute",
3537
+ required: ["urlPattern", "mode"]
5488
3538
  }
5489
3539
  );
5490
- objectSchema(
3540
+ var opensteerScriptSandboxInputSchema = objectSchema(
5491
3541
  {
5492
- packages: arraySchema(opensteerReversePackageRecordSchema)
3542
+ artifactId: stringSchema({ minLength: 1 }),
3543
+ content: stringSchema(),
3544
+ fidelity: sandboxFidelitySchema,
3545
+ ajaxRoutes: arraySchema(sandboxAjaxRouteSchema),
3546
+ cookies: recordSchema(stringSchema(), {
3547
+ title: "SandboxCookies"
3548
+ }),
3549
+ globals: objectSchema(
3550
+ {},
3551
+ {
3552
+ title: "SandboxGlobals",
3553
+ additionalProperties: true
3554
+ }
3555
+ ),
3556
+ timeoutMs: integerSchema({ minimum: 1 }),
3557
+ clockMode: enumSchema(["real", "manual"])
5493
3558
  },
5494
3559
  {
5495
- title: "OpensteerReversePackageListOutput",
5496
- required: ["packages"]
3560
+ title: "OpensteerScriptSandboxInput"
5497
3561
  }
5498
3562
  );
5499
- objectSchema(
3563
+ var sandboxCapturedAjaxCallSchema = objectSchema(
5500
3564
  {
5501
- packageId: stringSchema({ minLength: 1 }),
5502
- key: stringSchema({ minLength: 1 }),
5503
- version: stringSchema({ minLength: 1 }),
5504
- notes: stringSchema({ minLength: 1 }),
5505
- workflow: arraySchema(opensteerReverseWorkflowStepSchema),
5506
- resolvers: arraySchema(opensteerExecutableResolverSchema),
5507
- validators: arraySchema(opensteerValidationRuleSchema),
5508
- attachedTraceIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5509
- attachedArtifactIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5510
- attachedRecordIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5511
- stateSnapshotIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true })
3565
+ method: stringSchema({ minLength: 1 }),
3566
+ url: stringSchema({ minLength: 1 }),
3567
+ headers: recordSchema(stringSchema(), {
3568
+ title: "SandboxCapturedAjaxHeaders"
3569
+ }),
3570
+ body: stringSchema(),
3571
+ timestamp: integerSchema({ minimum: 0 })
5512
3572
  },
5513
3573
  {
5514
- title: "OpensteerReversePackagePatchInput",
5515
- required: ["packageId"]
3574
+ title: "SandboxCapturedAjaxCall",
3575
+ required: ["method", "url", "headers", "timestamp"]
5516
3576
  }
5517
3577
  );
5518
- objectSchema(
3578
+ var opensteerScriptSandboxOutputSchema = objectSchema(
5519
3579
  {
5520
- package: opensteerReversePackageRecordSchema,
5521
- report: opensteerReverseReportRecordSchema
3580
+ result: oneOfSchema(
3581
+ [
3582
+ objectSchema({}, { additionalProperties: true }),
3583
+ arraySchema({}),
3584
+ stringSchema(),
3585
+ { type: "number" },
3586
+ enumSchema([true, false, null])
3587
+ ],
3588
+ {
3589
+ title: "SandboxResult"
3590
+ }
3591
+ ),
3592
+ capturedAjax: arraySchema(sandboxCapturedAjaxCallSchema),
3593
+ errors: arraySchema(stringSchema({ minLength: 1 })),
3594
+ durationMs: integerSchema({ minimum: 0 })
5522
3595
  },
5523
3596
  {
5524
- title: "OpensteerReversePackagePatchOutput",
5525
- required: ["package", "report"]
3597
+ title: "OpensteerScriptSandboxOutput",
3598
+ required: ["capturedAjax", "errors", "durationMs"]
5526
3599
  }
5527
3600
  );
5528
3601
 
@@ -6377,12 +4450,12 @@ var opensteerDomExtractInputSchema = defineSchema({
6377
4450
  ),
6378
4451
  anyOf: [defineSchema({ required: ["persist"] }), defineSchema({ required: ["schema"] })]
6379
4452
  });
6380
- var jsonValueSchema3 = recordSchema({}, { title: "JsonValueRecord" });
4453
+ var jsonValueSchema2 = recordSchema({}, { title: "JsonValueRecord" });
6381
4454
  var opensteerDomExtractOutputSchema = objectSchema(
6382
4455
  {
6383
4456
  data: oneOfSchema(
6384
4457
  [
6385
- jsonValueSchema3,
4458
+ jsonValueSchema2,
6386
4459
  arraySchema({}),
6387
4460
  stringSchema(),
6388
4461
  numberSchema(),
@@ -6785,7 +4858,7 @@ var opensteerSemanticOperationSpecificationsBase = [
6785
4858
  }),
6786
4859
  defineSemanticOperationSpec({
6787
4860
  name: "artifact.read",
6788
- description: "Read a persisted artifact by ID so agents can inspect captured scripts, storage, cookies, or snapshots linked from reverse packages and reports.",
4861
+ description: "Read a persisted artifact by ID so agents can inspect captured scripts, storage, cookies, or snapshots linked from recorded workflows.",
6789
4862
  inputSchema: opensteerArtifactReadInputSchema,
6790
4863
  outputSchema: opensteerArtifactReadOutputSchema,
6791
4864
  requiredCapabilities: []
@@ -7206,76 +5279,6 @@ var FilesystemRequestPlanRegistry = class extends FilesystemRegistryStore {
7206
5279
  });
7207
5280
  }
7208
5281
  };
7209
- var FilesystemAuthRecipeRegistry = class extends FilesystemRegistryStore {
7210
- constructor(rootPath) {
7211
- super(rootPath, ["registry", "auth-recipes"]);
7212
- }
7213
- async write(input) {
7214
- const id = normalizeNonEmptyString("id", input.id ?? `auth-recipe:${crypto.randomUUID()}`);
7215
- const key = normalizeNonEmptyString("key", input.key);
7216
- const version = normalizeNonEmptyString("version", input.version);
7217
- const createdAt = normalizeTimestamp("createdAt", input.createdAt ?? Date.now());
7218
- const updatedAt = normalizeTimestamp("updatedAt", input.updatedAt ?? createdAt);
7219
- if (updatedAt < createdAt) {
7220
- throw new RangeError("updatedAt must be greater than or equal to createdAt");
7221
- }
7222
- const payload = input.payload;
7223
- const contentHash = sha256Hex(Buffer.from(canonicalJsonString(payload), "utf8"));
7224
- const provenance = normalizeProvenance2(input.provenance);
7225
- const record = {
7226
- id,
7227
- key,
7228
- version,
7229
- createdAt,
7230
- updatedAt,
7231
- contentHash,
7232
- tags: normalizeTags(input.tags),
7233
- ...provenance === void 0 ? {} : { provenance },
7234
- payload
7235
- };
7236
- return this.writeRecord(record);
7237
- }
7238
- async list(input = {}) {
7239
- const key = input.key === void 0 ? void 0 : normalizeNonEmptyString("key", input.key);
7240
- const records = await this.readAllRecords();
7241
- return key === void 0 ? records : records.filter((record) => record.key === key);
7242
- }
7243
- };
7244
- var FilesystemRecipeRegistry = class extends FilesystemRegistryStore {
7245
- constructor(rootPath) {
7246
- super(rootPath, ["registry", "recipes"]);
7247
- }
7248
- async write(input) {
7249
- const id = normalizeNonEmptyString("id", input.id ?? `recipe:${crypto.randomUUID()}`);
7250
- const key = normalizeNonEmptyString("key", input.key);
7251
- const version = normalizeNonEmptyString("version", input.version);
7252
- const createdAt = normalizeTimestamp("createdAt", input.createdAt ?? Date.now());
7253
- const updatedAt = normalizeTimestamp("updatedAt", input.updatedAt ?? createdAt);
7254
- if (updatedAt < createdAt) {
7255
- throw new RangeError("updatedAt must be greater than or equal to createdAt");
7256
- }
7257
- const payload = input.payload;
7258
- const contentHash = sha256Hex(Buffer.from(canonicalJsonString(payload), "utf8"));
7259
- const provenance = normalizeProvenance2(input.provenance);
7260
- const record = {
7261
- id,
7262
- key,
7263
- version,
7264
- createdAt,
7265
- updatedAt,
7266
- contentHash,
7267
- tags: normalizeTags(input.tags),
7268
- ...provenance === void 0 ? {} : { provenance },
7269
- payload
7270
- };
7271
- return this.writeRecord(record);
7272
- }
7273
- async list(input = {}) {
7274
- const key = input.key === void 0 ? void 0 : normalizeNonEmptyString("key", input.key);
7275
- const records = await this.readAllRecords();
7276
- return key === void 0 ? records : records.filter((record) => record.key === key);
7277
- }
7278
- };
7279
5282
  var FilesystemInteractionTraceRegistry = class extends FilesystemRegistryStore {
7280
5283
  constructor(rootPath) {
7281
5284
  super(rootPath, ["registry", "interaction-traces"]);
@@ -7311,163 +5314,15 @@ var FilesystemInteractionTraceRegistry = class extends FilesystemRegistryStore {
7311
5314
  return key === void 0 ? records : records.filter((record) => record.key === key);
7312
5315
  }
7313
5316
  };
7314
- var FilesystemReverseCaseRegistry = class extends FilesystemRegistryStore {
7315
- constructor(rootPath) {
7316
- super(rootPath, ["registry", "reverse-cases"]);
7317
- }
7318
- async write(input) {
7319
- const id = normalizeNonEmptyString("id", input.id ?? `reverse-case:${crypto.randomUUID()}`);
7320
- const key = normalizeNonEmptyString("key", input.key);
7321
- const version = normalizeNonEmptyString("version", input.version);
7322
- const createdAt = normalizeTimestamp("createdAt", input.createdAt ?? Date.now());
7323
- const updatedAt = normalizeTimestamp("updatedAt", input.updatedAt ?? createdAt);
7324
- if (updatedAt < createdAt) {
7325
- throw new RangeError("updatedAt must be greater than or equal to createdAt");
7326
- }
7327
- const payload = input.payload;
7328
- const contentHash = sha256Hex(Buffer.from(canonicalJsonString(payload), "utf8"));
7329
- const provenance = normalizeProvenance2(input.provenance);
7330
- const record = {
7331
- id,
7332
- key,
7333
- version,
7334
- createdAt,
7335
- updatedAt,
7336
- contentHash,
7337
- tags: normalizeTags(input.tags),
7338
- ...provenance === void 0 ? {} : { provenance },
7339
- payload
7340
- };
7341
- return this.writeRecord(record);
7342
- }
7343
- async list(input = {}) {
7344
- const key = input.key === void 0 ? void 0 : normalizeNonEmptyString("key", input.key);
7345
- const records = await this.readAllRecords();
7346
- return key === void 0 ? records : records.filter((record) => record.key === key);
7347
- }
7348
- async update(input) {
7349
- const id = normalizeNonEmptyString("id", input.id);
7350
- return withFilesystemLock(this.writeLockPath(), async () => {
7351
- const existing = await this.getById(id);
7352
- if (existing === void 0) {
7353
- throw new Error(`registry record ${id} was not found`);
7354
- }
7355
- const nextUpdatedAt = normalizeTimestamp(
7356
- "updatedAt",
7357
- input.updatedAt ?? Math.max(Date.now(), existing.updatedAt)
7358
- );
7359
- if (nextUpdatedAt < existing.createdAt) {
7360
- throw new RangeError("updatedAt must be greater than or equal to createdAt");
7361
- }
7362
- const nextPayload = input.payload;
7363
- const nextProvenance = normalizeProvenance2(input.provenance ?? existing.provenance);
7364
- const nextRecord = {
7365
- ...existing,
7366
- updatedAt: nextUpdatedAt,
7367
- contentHash: sha256Hex(Buffer.from(canonicalJsonString(nextPayload), "utf8")),
7368
- tags: normalizeTags(input.tags ?? existing.tags),
7369
- ...nextProvenance === void 0 ? {} : { provenance: nextProvenance },
7370
- payload: nextPayload
7371
- };
7372
- await writeJsonFileAtomic(this.recordPath(id), nextRecord);
7373
- return nextRecord;
7374
- });
7375
- }
7376
- };
7377
- var FilesystemReversePackageRegistry = class extends FilesystemRegistryStore {
7378
- constructor(rootPath) {
7379
- super(rootPath, ["registry", "reverse-packages"]);
7380
- }
7381
- async write(input) {
7382
- const id = normalizeNonEmptyString("id", input.id ?? `reverse-package:${crypto.randomUUID()}`);
7383
- const key = normalizeNonEmptyString("key", input.key);
7384
- const version = normalizeNonEmptyString("version", input.version);
7385
- const createdAt = normalizeTimestamp("createdAt", input.createdAt ?? Date.now());
7386
- const updatedAt = normalizeTimestamp("updatedAt", input.updatedAt ?? createdAt);
7387
- if (updatedAt < createdAt) {
7388
- throw new RangeError("updatedAt must be greater than or equal to createdAt");
7389
- }
7390
- const payload = input.payload;
7391
- const contentHash = sha256Hex(Buffer.from(canonicalJsonString(payload), "utf8"));
7392
- const provenance = normalizeProvenance2(input.provenance);
7393
- const record = {
7394
- id,
7395
- key,
7396
- version,
7397
- createdAt,
7398
- updatedAt,
7399
- contentHash,
7400
- tags: normalizeTags(input.tags),
7401
- ...provenance === void 0 ? {} : { provenance },
7402
- payload
7403
- };
7404
- return this.writeRecord(record);
7405
- }
7406
- async list(input = {}) {
7407
- const key = input.key === void 0 ? void 0 : normalizeNonEmptyString("key", input.key);
7408
- const records = await this.readAllRecords();
7409
- return key === void 0 ? records : records.filter((record) => record.key === key);
7410
- }
7411
- };
7412
- var FilesystemReverseReportRegistry = class extends FilesystemRegistryStore {
7413
- constructor(rootPath) {
7414
- super(rootPath, ["registry", "reverse-reports"]);
7415
- }
7416
- async write(input) {
7417
- const id = normalizeNonEmptyString("id", input.id ?? `reverse-report:${crypto.randomUUID()}`);
7418
- const key = normalizeNonEmptyString("key", input.key);
7419
- const version = normalizeNonEmptyString("version", input.version);
7420
- const createdAt = normalizeTimestamp("createdAt", input.createdAt ?? Date.now());
7421
- const updatedAt = normalizeTimestamp("updatedAt", input.updatedAt ?? createdAt);
7422
- if (updatedAt < createdAt) {
7423
- throw new RangeError("updatedAt must be greater than or equal to createdAt");
7424
- }
7425
- const payload = input.payload;
7426
- const contentHash = sha256Hex(Buffer.from(canonicalJsonString(payload), "utf8"));
7427
- const provenance = normalizeProvenance2(input.provenance);
7428
- const record = {
7429
- id,
7430
- key,
7431
- version,
7432
- createdAt,
7433
- updatedAt,
7434
- contentHash,
7435
- tags: normalizeTags(input.tags),
7436
- ...provenance === void 0 ? {} : { provenance },
7437
- payload
7438
- };
7439
- return this.writeRecord(record);
7440
- }
7441
- async list(input = {}) {
7442
- const key = input.key === void 0 ? void 0 : normalizeNonEmptyString("key", input.key);
7443
- const records = await this.readAllRecords();
7444
- return key === void 0 ? records : records.filter((record) => record.key === key);
7445
- }
7446
- };
7447
5317
  function createDescriptorRegistry(rootPath) {
7448
5318
  return new FilesystemDescriptorRegistry(rootPath);
7449
5319
  }
7450
5320
  function createRequestPlanRegistry(rootPath) {
7451
5321
  return new FilesystemRequestPlanRegistry(rootPath);
7452
5322
  }
7453
- function createAuthRecipeRegistry(rootPath) {
7454
- return new FilesystemAuthRecipeRegistry(rootPath);
7455
- }
7456
- function createRecipeRegistry(rootPath) {
7457
- return new FilesystemRecipeRegistry(rootPath);
7458
- }
7459
5323
  function createInteractionTraceRegistry(rootPath) {
7460
5324
  return new FilesystemInteractionTraceRegistry(rootPath);
7461
5325
  }
7462
- function createReverseCaseRegistry(rootPath) {
7463
- return new FilesystemReverseCaseRegistry(rootPath);
7464
- }
7465
- function createReversePackageRegistry(rootPath) {
7466
- return new FilesystemReversePackageRegistry(rootPath);
7467
- }
7468
- function createReverseReportRegistry(rootPath) {
7469
- return new FilesystemReverseReportRegistry(rootPath);
7470
- }
7471
5326
  var TAG_DELIMITER = "";
7472
5327
  var NODE_SQLITE_SPECIFIER = `node:${"sqlite"}`;
7473
5328
  var SAVED_NETWORK_SQLITE_SUPPORT_ERROR = "Saved-network operations require Node's built-in SQLite support. Use a Node runtime with node:sqlite enabled.";
@@ -8912,20 +6767,10 @@ async function createFilesystemOpensteerWorkspace(options) {
8912
6767
  await descriptors.initialize();
8913
6768
  const requestPlans = createRequestPlanRegistry(options.rootPath);
8914
6769
  await requestPlans.initialize();
8915
- const authRecipes = createAuthRecipeRegistry(options.rootPath);
8916
- await authRecipes.initialize();
8917
- const recipes = createRecipeRegistry(options.rootPath);
8918
- await recipes.initialize();
8919
6770
  const savedNetwork = createSavedNetworkStore(options.rootPath);
8920
6771
  await savedNetwork.initialize();
8921
- const reverseCases = createReverseCaseRegistry(options.rootPath);
8922
- await reverseCases.initialize();
8923
6772
  const interactionTraces = createInteractionTraceRegistry(options.rootPath);
8924
6773
  await interactionTraces.initialize();
8925
- const reversePackages = createReversePackageRegistry(options.rootPath);
8926
- await reversePackages.initialize();
8927
- const reverseReports = createReverseReportRegistry(options.rootPath);
8928
- await reverseReports.initialize();
8929
6774
  const traces = createTraceStore(options.rootPath, artifacts);
8930
6775
  await traces.initialize();
8931
6776
  const observations = createObservationStore(options.rootPath, artifacts);
@@ -8951,13 +6796,8 @@ async function createFilesystemOpensteerWorkspace(options) {
8951
6796
  registry: {
8952
6797
  descriptors,
8953
6798
  requestPlans,
8954
- authRecipes,
8955
- recipes,
8956
6799
  savedNetwork,
8957
- reverseCases,
8958
- interactionTraces,
8959
- reversePackages,
8960
- reverseReports
6800
+ interactionTraces
8961
6801
  },
8962
6802
  lock(task) {
8963
6803
  return withFilesystemLock(lockPath, task);
@@ -17788,7 +15628,7 @@ function resolveCloudConfig(input = {}) {
17788
15628
 
17789
15629
  // ../runtime-core/package.json
17790
15630
  var package_default = {
17791
- version: "0.2.1"};
15631
+ version: "0.2.2"};
17792
15632
 
17793
15633
  // ../runtime-core/src/version.ts
17794
15634
  var OPENSTEER_RUNTIME_CORE_VERSION = package_default.version;
@@ -28082,7 +25922,7 @@ var Opensteer = class {
28082
25922
  scroll: (input) => this.scroll(input)
28083
25923
  };
28084
25924
  this.network = {
28085
- query: (input = {}) => this.queryNetwork(input),
25925
+ query: (input = {}) => this.runtime.queryNetwork(input),
28086
25926
  detail: (recordId, options2) => this.runtime.getNetworkDetail({ recordId, ...options2 })
28087
25927
  };
28088
25928
  }
@@ -28116,9 +25956,6 @@ var Opensteer = class {
28116
25956
  } : input;
28117
25957
  return (await this.runtime.evaluate(normalized)).value;
28118
25958
  }
28119
- async evaluateJson(input) {
28120
- return this.evaluate(input);
28121
- }
28122
25959
  async addInitScript(input) {
28123
25960
  return this.runtime.addInitScript(
28124
25961
  typeof input === "string" ? {
@@ -28155,34 +25992,6 @@ var Opensteer = class {
28155
25992
  async extract(input) {
28156
25993
  return (await this.runtime.extract(input)).data;
28157
25994
  }
28158
- async queryNetwork(input = {}) {
28159
- return this.runtime.queryNetwork(input);
28160
- }
28161
- async waitForNetwork(input) {
28162
- const { timeoutMs, pollIntervalMs, ...query } = input;
28163
- const timeoutAt = Date.now() + (timeoutMs ?? 3e4);
28164
- const pollInterval = pollIntervalMs ?? 100;
28165
- const baseline = new Set(
28166
- (await this.runtime.queryNetwork({ ...query, limit: 200 })).records.map(
28167
- (record) => record.recordId
28168
- )
28169
- );
28170
- while (true) {
28171
- const next = (await this.runtime.queryNetwork({ ...query, limit: 200 })).records.find(
28172
- (record) => !baseline.has(record.recordId)
28173
- );
28174
- if (next !== void 0) {
28175
- return next;
28176
- }
28177
- if (Date.now() >= timeoutAt) {
28178
- throw new Error("waitForNetwork timed out");
28179
- }
28180
- await delay3(pollInterval);
28181
- }
28182
- }
28183
- async waitForResponse(input) {
28184
- return this.waitForNetwork(input);
28185
- }
28186
25995
  async waitForPage(input = {}) {
28187
25996
  const baseline = new Set((await this.runtime.listPages()).pages.map((page) => page.pageRef));
28188
25997
  const timeoutAt = Date.now() + (input.timeoutMs ?? 3e4);