@opensteer/runtime-core 0.2.1 → 0.2.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -13,7 +13,7 @@ import vm from 'vm';
13
13
 
14
14
  // package.json
15
15
  var package_default = {
16
- version: "0.2.1"};
16
+ version: "0.2.3"};
17
17
 
18
18
  // src/version.ts
19
19
  var OPENSTEER_RUNTIME_CORE_VERSION = package_default.version;
@@ -1453,55 +1453,6 @@ arraySchema(headerEntrySchema, {
1453
1453
  title: "OrderedHeaders"
1454
1454
  });
1455
1455
 
1456
- // ../protocol/src/captcha.ts
1457
- var captchaTypeSchema = enumSchema(
1458
- ["recaptcha-v2", "hcaptcha", "turnstile"],
1459
- {
1460
- title: "CaptchaType"
1461
- }
1462
- );
1463
- var captchaProviderSchema = enumSchema(["2captcha", "capsolver"], {
1464
- title: "CaptchaProvider"
1465
- });
1466
- var captchaDetectionResultSchema = objectSchema(
1467
- {
1468
- type: captchaTypeSchema,
1469
- siteKey: stringSchema({ minLength: 1 }),
1470
- pageUrl: stringSchema({ minLength: 1 })
1471
- },
1472
- {
1473
- title: "CaptchaDetectionResult",
1474
- required: ["type", "siteKey", "pageUrl"]
1475
- }
1476
- );
1477
- var opensteerCaptchaSolveInputSchema = objectSchema(
1478
- {
1479
- provider: captchaProviderSchema,
1480
- apiKey: stringSchema({ minLength: 1 }),
1481
- pageRef: pageRefSchema,
1482
- timeoutMs: integerSchema({ minimum: 1 }),
1483
- type: captchaTypeSchema,
1484
- siteKey: stringSchema({ minLength: 1 }),
1485
- pageUrl: stringSchema({ minLength: 1 })
1486
- },
1487
- {
1488
- title: "OpensteerCaptchaSolveInput",
1489
- required: ["provider", "apiKey"]
1490
- }
1491
- );
1492
- var opensteerCaptchaSolveOutputSchema = objectSchema(
1493
- {
1494
- captcha: captchaDetectionResultSchema,
1495
- token: stringSchema({ minLength: 1 }),
1496
- injected: { type: "boolean" },
1497
- provider: captchaProviderSchema
1498
- },
1499
- {
1500
- title: "OpensteerCaptchaSolveOutput",
1501
- required: ["captcha", "token", "injected", "provider"]
1502
- }
1503
- );
1504
-
1505
1456
  // ../protocol/src/storage.ts
1506
1457
  var jsonUnknownSchema = {};
1507
1458
  var cookieSameSiteSchema = enumSchema(["strict", "lax", "none"], {
@@ -1754,16 +1705,6 @@ var opensteerRequestPlanResponseExpectationSchema = objectSchema(
1754
1705
  required: ["status"]
1755
1706
  }
1756
1707
  );
1757
- var opensteerRecipeRefSchema = objectSchema(
1758
- {
1759
- key: stringSchema({ minLength: 1 }),
1760
- version: stringSchema({ minLength: 1 })
1761
- },
1762
- {
1763
- title: "OpensteerRecipeRef",
1764
- required: ["key"]
1765
- }
1766
- );
1767
1708
  var opensteerRequestFailurePolicyHeaderMatchSchema = objectSchema(
1768
1709
  {
1769
1710
  name: stringSchema({ minLength: 1 }),
@@ -1819,46 +1760,9 @@ var opensteerRequestRetryPolicySchema = objectSchema(
1819
1760
  required: ["maxRetries"]
1820
1761
  }
1821
1762
  );
1822
- var opensteerRecipeCachePolicySchema = enumSchema(
1823
- ["none", "untilFailure"],
1824
- {
1825
- title: "OpensteerRecipeCachePolicy"
1826
- }
1827
- );
1828
- var opensteerRequestPlanRecipeBindingSchema = objectSchema(
1829
- {
1830
- recipe: opensteerRecipeRefSchema,
1831
- cachePolicy: opensteerRecipeCachePolicySchema
1832
- },
1833
- {
1834
- title: "OpensteerRequestPlanRecipeBinding",
1835
- required: ["recipe"]
1836
- }
1837
- );
1838
- var opensteerRequestPlanRecoverBindingSchema = objectSchema(
1839
- {
1840
- recipe: opensteerRecipeRefSchema,
1841
- cachePolicy: opensteerRecipeCachePolicySchema,
1842
- failurePolicy: opensteerRequestFailurePolicySchema
1843
- },
1844
- {
1845
- title: "OpensteerRequestPlanRecoverBinding",
1846
- required: ["recipe", "failurePolicy"]
1847
- }
1848
- );
1849
- var opensteerRequestPlanRecipesSchema = objectSchema(
1850
- {
1851
- prepare: opensteerRequestPlanRecipeBindingSchema,
1852
- recover: opensteerRequestPlanRecoverBindingSchema
1853
- },
1854
- {
1855
- title: "OpensteerRequestPlanRecipes"
1856
- }
1857
- );
1858
1763
  var opensteerRequestPlanAuthSchema = objectSchema(
1859
1764
  {
1860
1765
  strategy: enumSchema(["session-cookie", "bearer-token", "api-key", "custom"]),
1861
- recipe: opensteerRecipeRefSchema,
1862
1766
  failurePolicy: opensteerRequestFailurePolicySchema,
1863
1767
  description: stringSchema({ minLength: 1 })
1864
1768
  },
@@ -1874,7 +1778,6 @@ var opensteerRequestPlanPayloadSchema = objectSchema(
1874
1778
  parameters: arraySchema(opensteerRequestPlanParameterSchema),
1875
1779
  body: opensteerRequestPlanBodySchema,
1876
1780
  response: opensteerRequestPlanResponseExpectationSchema,
1877
- recipes: opensteerRequestPlanRecipesSchema,
1878
1781
  retryPolicy: opensteerRequestRetryPolicySchema,
1879
1782
  auth: opensteerRequestPlanAuthSchema
1880
1783
  },
@@ -1965,317 +1868,6 @@ var opensteerRequestBodyInputSchema = oneOfSchema(
1965
1868
  title: "OpensteerRequestBodyInput"
1966
1869
  }
1967
1870
  );
1968
- var opensteerRecipeRetryOverridesSchema = objectSchema(
1969
- {
1970
- params: recordSchema(stringSchema(), {
1971
- title: "OpensteerRecipeParams"
1972
- }),
1973
- headers: recordSchema(stringSchema(), {
1974
- title: "OpensteerRecipeHeaders"
1975
- }),
1976
- query: recordSchema(stringSchema(), {
1977
- title: "OpensteerRecipeQuery"
1978
- }),
1979
- body: recordSchema(stringSchema(), {
1980
- title: "OpensteerRecipeBodyVariables"
1981
- })
1982
- },
1983
- {
1984
- title: "OpensteerRecipeRetryOverrides"
1985
- }
1986
- );
1987
- var opensteerRecipeStepResponseCaptureSchema = objectSchema(
1988
- {
1989
- header: objectSchema(
1990
- {
1991
- name: stringSchema({ minLength: 1 }),
1992
- saveAs: stringSchema({ minLength: 1 })
1993
- },
1994
- {
1995
- title: "OpensteerAuthRecipeHeaderCapture",
1996
- required: ["name", "saveAs"]
1997
- }
1998
- ),
1999
- bodyJsonPointer: objectSchema(
2000
- {
2001
- pointer: stringSchema({ minLength: 1 }),
2002
- saveAs: stringSchema({ minLength: 1 })
2003
- },
2004
- {
2005
- title: "OpensteerAuthRecipeBodyJsonPointerCapture",
2006
- required: ["pointer", "saveAs"]
2007
- }
2008
- ),
2009
- bodyText: objectSchema(
2010
- {
2011
- saveAs: stringSchema({ minLength: 1 })
2012
- },
2013
- {
2014
- title: "OpensteerAuthRecipeBodyTextCapture",
2015
- required: ["saveAs"]
2016
- }
2017
- )
2018
- },
2019
- {
2020
- title: "OpensteerRecipeStepResponseCapture"
2021
- }
2022
- );
2023
- var opensteerRecipeRequestStepInputSchema = objectSchema(
2024
- {
2025
- url: stringSchema({ minLength: 1 }),
2026
- transport: transportKindSchema,
2027
- pageRef: pageRefSchema,
2028
- cookieJar: stringSchema({ minLength: 1 }),
2029
- method: stringSchema({ minLength: 1 }),
2030
- headers: recordSchema(stringSchema(), {
2031
- title: "OpensteerRecipeRequestHeaders"
2032
- }),
2033
- query: recordSchema(stringSchema(), {
2034
- title: "OpensteerRecipeRequestQuery"
2035
- }),
2036
- body: opensteerRequestBodyInputSchema,
2037
- followRedirects: { type: "boolean" }
2038
- },
2039
- {
2040
- title: "OpensteerRecipeRequestStepInput",
2041
- required: ["url"]
2042
- }
2043
- );
2044
- var opensteerRecipeHookRefSchema = objectSchema(
2045
- {
2046
- specifier: stringSchema({ minLength: 1 }),
2047
- export: stringSchema({ minLength: 1 })
2048
- },
2049
- {
2050
- title: "OpensteerRecipeHookRef",
2051
- required: ["specifier", "export"]
2052
- }
2053
- );
2054
- var opensteerRecipeStepSchema = oneOfSchema(
2055
- [
2056
- objectSchema(
2057
- {
2058
- kind: enumSchema(["goto"]),
2059
- url: stringSchema({ minLength: 1 })
2060
- },
2061
- {
2062
- title: "OpensteerAuthRecipeGotoStep",
2063
- required: ["kind", "url"]
2064
- }
2065
- ),
2066
- objectSchema(
2067
- {
2068
- kind: enumSchema(["reload"])
2069
- },
2070
- {
2071
- title: "OpensteerAuthRecipeReloadStep",
2072
- required: ["kind"]
2073
- }
2074
- ),
2075
- objectSchema(
2076
- {
2077
- kind: enumSchema(["waitForUrl"]),
2078
- includes: stringSchema({ minLength: 1 }),
2079
- timeoutMs: integerSchema({ minimum: 0 })
2080
- },
2081
- {
2082
- title: "OpensteerAuthRecipeWaitForUrlStep",
2083
- required: ["kind", "includes"]
2084
- }
2085
- ),
2086
- objectSchema(
2087
- {
2088
- kind: enumSchema(["waitForNetwork"]),
2089
- url: stringSchema({ minLength: 1 }),
2090
- hostname: stringSchema({ minLength: 1 }),
2091
- path: stringSchema({ minLength: 1 }),
2092
- method: stringSchema({ minLength: 1 }),
2093
- status: stringSchema({ minLength: 1 }),
2094
- includeBodies: { type: "boolean" },
2095
- timeoutMs: integerSchema({ minimum: 0 }),
2096
- saveAs: stringSchema({ minLength: 1 })
2097
- },
2098
- {
2099
- title: "OpensteerRecipeWaitForNetworkStep",
2100
- required: ["kind"]
2101
- }
2102
- ),
2103
- objectSchema(
2104
- {
2105
- kind: enumSchema(["waitForCookie"]),
2106
- name: stringSchema({ minLength: 1 }),
2107
- url: stringSchema({ minLength: 1 }),
2108
- timeoutMs: integerSchema({ minimum: 0 }),
2109
- saveAs: stringSchema({ minLength: 1 })
2110
- },
2111
- {
2112
- title: "OpensteerAuthRecipeWaitForCookieStep",
2113
- required: ["kind", "name"]
2114
- }
2115
- ),
2116
- objectSchema(
2117
- {
2118
- kind: enumSchema(["waitForStorage"]),
2119
- area: enumSchema(["local", "session"]),
2120
- origin: stringSchema({ minLength: 1 }),
2121
- key: stringSchema({ minLength: 1 }),
2122
- timeoutMs: integerSchema({ minimum: 0 }),
2123
- saveAs: stringSchema({ minLength: 1 })
2124
- },
2125
- {
2126
- title: "OpensteerAuthRecipeWaitForStorageStep",
2127
- required: ["kind", "area", "origin", "key"]
2128
- }
2129
- ),
2130
- objectSchema(
2131
- {
2132
- kind: enumSchema(["readCookie"]),
2133
- name: stringSchema({ minLength: 1 }),
2134
- url: stringSchema({ minLength: 1 }),
2135
- saveAs: stringSchema({ minLength: 1 })
2136
- },
2137
- {
2138
- title: "OpensteerAuthRecipeReadCookieStep",
2139
- required: ["kind", "name", "saveAs"]
2140
- }
2141
- ),
2142
- objectSchema(
2143
- {
2144
- kind: enumSchema(["readStorage"]),
2145
- area: enumSchema(["local", "session"]),
2146
- origin: stringSchema({ minLength: 1 }),
2147
- key: stringSchema({ minLength: 1 }),
2148
- pageUrl: stringSchema({ minLength: 1 }),
2149
- saveAs: stringSchema({ minLength: 1 })
2150
- },
2151
- {
2152
- title: "OpensteerRecipeReadStorageStep",
2153
- required: ["kind", "area", "origin", "key", "saveAs"]
2154
- }
2155
- ),
2156
- objectSchema(
2157
- {
2158
- kind: enumSchema(["evaluate"]),
2159
- script: stringSchema({ minLength: 1 }),
2160
- args: arraySchema(jsonValueSchema),
2161
- pageRef: pageRefSchema,
2162
- saveAs: stringSchema({ minLength: 1 })
2163
- },
2164
- {
2165
- title: "OpensteerRecipeEvaluateStep",
2166
- required: ["kind", "script"]
2167
- }
2168
- ),
2169
- objectSchema(
2170
- {
2171
- kind: enumSchema(["syncCookiesToJar"]),
2172
- jar: stringSchema({ minLength: 1 }),
2173
- urls: arraySchema(stringSchema({ minLength: 1 }), {
2174
- minItems: 1
2175
- })
2176
- },
2177
- {
2178
- title: "OpensteerRecipeSyncCookiesToJarStep",
2179
- required: ["kind", "jar"]
2180
- }
2181
- ),
2182
- objectSchema(
2183
- {
2184
- kind: enumSchema(["request"]),
2185
- request: opensteerRecipeRequestStepInputSchema,
2186
- capture: opensteerRecipeStepResponseCaptureSchema
2187
- },
2188
- {
2189
- title: "OpensteerRecipeRequestStep",
2190
- required: ["kind", "request"]
2191
- }
2192
- ),
2193
- objectSchema(
2194
- {
2195
- kind: enumSchema(["sessionRequest"]),
2196
- request: opensteerRecipeRequestStepInputSchema,
2197
- capture: opensteerRecipeStepResponseCaptureSchema
2198
- },
2199
- {
2200
- title: "OpensteerAuthRecipeSessionRequestStep",
2201
- required: ["kind", "request"]
2202
- }
2203
- ),
2204
- objectSchema(
2205
- {
2206
- kind: enumSchema(["directRequest"]),
2207
- request: opensteerRecipeRequestStepInputSchema,
2208
- capture: opensteerRecipeStepResponseCaptureSchema
2209
- },
2210
- {
2211
- title: "OpensteerAuthRecipeDirectRequestStep",
2212
- required: ["kind", "request"]
2213
- }
2214
- ),
2215
- objectSchema(
2216
- {
2217
- kind: enumSchema(["solveCaptcha"]),
2218
- provider: captchaProviderSchema,
2219
- apiKey: stringSchema({ minLength: 1 }),
2220
- pageRef: pageRefSchema,
2221
- timeoutMs: integerSchema({ minimum: 1 }),
2222
- type: captchaTypeSchema,
2223
- siteKey: stringSchema({ minLength: 1 }),
2224
- pageUrl: stringSchema({ minLength: 1 }),
2225
- saveAs: stringSchema({ minLength: 1 })
2226
- },
2227
- {
2228
- title: "OpensteerRecipeSolveCaptchaStep",
2229
- required: ["kind", "provider", "apiKey"]
2230
- }
2231
- ),
2232
- objectSchema(
2233
- {
2234
- kind: enumSchema(["hook"]),
2235
- hook: opensteerRecipeHookRefSchema
2236
- },
2237
- {
2238
- title: "OpensteerRecipeHookStep",
2239
- required: ["kind", "hook"]
2240
- }
2241
- )
2242
- ],
2243
- {
2244
- title: "OpensteerRecipeStep"
2245
- }
2246
- );
2247
- var opensteerRecipePayloadSchema = objectSchema(
2248
- {
2249
- description: stringSchema({ minLength: 1 }),
2250
- steps: arraySchema(opensteerRecipeStepSchema, {
2251
- minItems: 1
2252
- }),
2253
- outputs: opensteerRecipeRetryOverridesSchema
2254
- },
2255
- {
2256
- title: "OpensteerRecipePayload",
2257
- required: ["steps"]
2258
- }
2259
- );
2260
- var opensteerRecipeRecordSchema = objectSchema(
2261
- {
2262
- id: stringSchema({ minLength: 1 }),
2263
- key: stringSchema({ minLength: 1 }),
2264
- version: stringSchema({ minLength: 1 }),
2265
- createdAt: integerSchema({ minimum: 0 }),
2266
- updatedAt: integerSchema({ minimum: 0 }),
2267
- contentHash: stringSchema({ minLength: 1 }),
2268
- tags: arraySchema(stringSchema({ minLength: 1 }), {
2269
- uniqueItems: true
2270
- }),
2271
- provenance: opensteerRegistryProvenanceSchema,
2272
- payload: opensteerRecipePayloadSchema
2273
- },
2274
- {
2275
- title: "OpensteerRecipeRecord",
2276
- required: ["id", "key", "version", "createdAt", "updatedAt", "contentHash", "tags", "payload"]
2277
- }
2278
- );
2279
1871
  var opensteerNetworkQueryInputSchema = objectSchema(
2280
1872
  {
2281
1873
  pageRef: pageRefSchema,
@@ -2674,85 +2266,6 @@ objectSchema(
2674
2266
  required: ["plans"]
2675
2267
  }
2676
2268
  );
2677
- objectSchema(
2678
- {
2679
- id: stringSchema({ minLength: 1 }),
2680
- key: stringSchema({ minLength: 1 }),
2681
- version: stringSchema({ minLength: 1 }),
2682
- tags: arraySchema(stringSchema({ minLength: 1 }), {
2683
- uniqueItems: true
2684
- }),
2685
- provenance: opensteerRegistryProvenanceSchema,
2686
- payload: opensteerRecipePayloadSchema
2687
- },
2688
- {
2689
- title: "OpensteerWriteRecipeInput",
2690
- required: ["key", "version", "payload"]
2691
- }
2692
- );
2693
- objectSchema(
2694
- {
2695
- key: stringSchema({ minLength: 1 }),
2696
- version: stringSchema({ minLength: 1 })
2697
- },
2698
- {
2699
- title: "OpensteerGetRecipeInput",
2700
- required: ["key"]
2701
- }
2702
- );
2703
- objectSchema(
2704
- {
2705
- key: stringSchema({ minLength: 1 })
2706
- },
2707
- {
2708
- title: "OpensteerListRecipesInput"
2709
- }
2710
- );
2711
- objectSchema(
2712
- {
2713
- recipes: arraySchema(opensteerRecipeRecordSchema)
2714
- },
2715
- {
2716
- title: "OpensteerListRecipesOutput",
2717
- required: ["recipes"]
2718
- }
2719
- );
2720
- objectSchema(
2721
- {
2722
- key: stringSchema({ minLength: 1 }),
2723
- version: stringSchema({ minLength: 1 }),
2724
- variables: recordSchema(stringSchema(), {
2725
- title: "OpensteerRecipeVariables"
2726
- })
2727
- },
2728
- {
2729
- title: "OpensteerRunRecipeInput",
2730
- required: ["key"]
2731
- }
2732
- );
2733
- objectSchema(
2734
- {
2735
- recipe: objectSchema(
2736
- {
2737
- id: stringSchema({ minLength: 1 }),
2738
- key: stringSchema({ minLength: 1 }),
2739
- version: stringSchema({ minLength: 1 })
2740
- },
2741
- {
2742
- title: "OpensteerResolvedRecipeRef",
2743
- required: ["id", "key", "version"]
2744
- }
2745
- ),
2746
- variables: recordSchema(stringSchema(), {
2747
- title: "OpensteerResolvedRecipeVariables"
2748
- }),
2749
- overrides: opensteerRecipeRetryOverridesSchema
2750
- },
2751
- {
2752
- title: "OpensteerRunRecipeOutput",
2753
- required: ["recipe", "variables"]
2754
- }
2755
- );
2756
2269
  objectSchema(
2757
2270
  {
2758
2271
  key: stringSchema({ minLength: 1 }),
@@ -2859,17 +2372,7 @@ objectSchema(
2859
2372
  {
2860
2373
  attempted: { type: "boolean" },
2861
2374
  succeeded: { type: "boolean" },
2862
- matchedFailurePolicy: { type: "boolean" },
2863
- recipe: objectSchema(
2864
- {
2865
- key: stringSchema({ minLength: 1 }),
2866
- version: stringSchema({ minLength: 1 })
2867
- },
2868
- {
2869
- title: "OpensteerResolvedRecoveryRecipeRef",
2870
- required: ["key", "version"]
2871
- }
2872
- )
2375
+ matchedFailurePolicy: { type: "boolean" }
2873
2376
  },
2874
2377
  {
2875
2378
  title: "OpensteerRequestRecoveryMetadata",
@@ -2908,6 +2411,69 @@ objectSchema(
2908
2411
  }
2909
2412
  );
2910
2413
 
2414
+ // ../protocol/src/state.ts
2415
+ var opensteerStateSnapshotCookieSchema = objectSchema(
2416
+ {
2417
+ name: stringSchema({ minLength: 1 }),
2418
+ value: stringSchema(),
2419
+ domain: stringSchema({ minLength: 1 }),
2420
+ path: stringSchema({ minLength: 1 }),
2421
+ secure: { type: "boolean" },
2422
+ httpOnly: { type: "boolean" },
2423
+ sameSite: enumSchema(["strict", "lax", "none"]),
2424
+ priority: enumSchema(["low", "medium", "high"]),
2425
+ partitionKey: stringSchema({ minLength: 1 }),
2426
+ session: { type: "boolean" },
2427
+ expiresAt: oneOfSchema([integerSchema({ minimum: 0 }), { type: "null" }])
2428
+ },
2429
+ {
2430
+ title: "OpensteerStateSnapshotCookie",
2431
+ required: ["name", "value", "domain", "path", "secure", "httpOnly", "session"]
2432
+ }
2433
+ );
2434
+ var opensteerStateSnapshotSchema = objectSchema(
2435
+ {
2436
+ id: stringSchema({ minLength: 1 }),
2437
+ capturedAt: integerSchema({ minimum: 0 }),
2438
+ pageRef: pageRefSchema,
2439
+ url: stringSchema({ minLength: 1 }),
2440
+ cookies: arraySchema(opensteerStateSnapshotCookieSchema),
2441
+ storage: storageSnapshotSchema,
2442
+ hiddenFields: arraySchema(
2443
+ objectSchema(
2444
+ {
2445
+ path: stringSchema({ minLength: 1 }),
2446
+ name: stringSchema({ minLength: 1 }),
2447
+ value: stringSchema()
2448
+ },
2449
+ {
2450
+ title: "OpensteerStateSnapshotHiddenField",
2451
+ required: ["path", "name", "value"]
2452
+ }
2453
+ )
2454
+ ),
2455
+ globals: recordSchema({}, { title: "OpensteerStateSnapshotGlobals" })
2456
+ },
2457
+ {
2458
+ title: "OpensteerStateSnapshot",
2459
+ required: ["id", "capturedAt"]
2460
+ }
2461
+ );
2462
+ var opensteerStateDeltaSchema = objectSchema(
2463
+ {
2464
+ beforeStateId: stringSchema({ minLength: 1 }),
2465
+ afterStateId: stringSchema({ minLength: 1 }),
2466
+ cookiesChanged: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
2467
+ storageChanged: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
2468
+ hiddenFieldsChanged: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
2469
+ globalsChanged: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true })
2470
+ },
2471
+ {
2472
+ title: "OpensteerStateDelta",
2473
+ required: ["cookiesChanged", "storageChanged", "hiddenFieldsChanged", "globalsChanged"]
2474
+ }
2475
+ );
2476
+
2911
2477
  // ../protocol/src/snapshots.ts
2912
2478
  var screenshotFormatSchema = enumSchema(["png", "jpeg", "webp"], {
2913
2479
  title: "ScreenshotFormat"
@@ -3681,6 +3247,55 @@ var opensteerArtifactReadOutputSchema = objectSchema(
3681
3247
  }
3682
3248
  );
3683
3249
 
3250
+ // ../protocol/src/captcha.ts
3251
+ var captchaTypeSchema = enumSchema(
3252
+ ["recaptcha-v2", "hcaptcha", "turnstile"],
3253
+ {
3254
+ title: "CaptchaType"
3255
+ }
3256
+ );
3257
+ var captchaProviderSchema = enumSchema(["2captcha", "capsolver"], {
3258
+ title: "CaptchaProvider"
3259
+ });
3260
+ var captchaDetectionResultSchema = objectSchema(
3261
+ {
3262
+ type: captchaTypeSchema,
3263
+ siteKey: stringSchema({ minLength: 1 }),
3264
+ pageUrl: stringSchema({ minLength: 1 })
3265
+ },
3266
+ {
3267
+ title: "CaptchaDetectionResult",
3268
+ required: ["type", "siteKey", "pageUrl"]
3269
+ }
3270
+ );
3271
+ var opensteerCaptchaSolveInputSchema = objectSchema(
3272
+ {
3273
+ provider: captchaProviderSchema,
3274
+ apiKey: stringSchema({ minLength: 1 }),
3275
+ pageRef: pageRefSchema,
3276
+ timeoutMs: integerSchema({ minimum: 1 }),
3277
+ type: captchaTypeSchema,
3278
+ siteKey: stringSchema({ minLength: 1 }),
3279
+ pageUrl: stringSchema({ minLength: 1 })
3280
+ },
3281
+ {
3282
+ title: "OpensteerCaptchaSolveInput",
3283
+ required: ["provider", "apiKey"]
3284
+ }
3285
+ );
3286
+ var opensteerCaptchaSolveOutputSchema = objectSchema(
3287
+ {
3288
+ captcha: captchaDetectionResultSchema,
3289
+ token: stringSchema({ minLength: 1 }),
3290
+ injected: { type: "boolean" },
3291
+ provider: captchaProviderSchema
3292
+ },
3293
+ {
3294
+ title: "OpensteerCaptchaSolveOutput",
3295
+ required: ["captcha", "token", "injected", "provider"]
3296
+ }
3297
+ );
3298
+
3684
3299
  // ../protocol/src/traces.ts
3685
3300
  var traceContextSchema = objectSchema(
3686
3301
  {
@@ -3851,1629 +3466,87 @@ var sandboxAjaxModeSchema = enumSchema(
3851
3466
  }
3852
3467
  );
3853
3468
  var sandboxAjaxRouteSchema = objectSchema(
3854
- {
3855
- urlPattern: stringSchema({ minLength: 1 }),
3856
- mode: sandboxAjaxModeSchema,
3857
- mockResponse: objectSchema(
3858
- {
3859
- status: integerSchema({ minimum: 100, maximum: 599 }),
3860
- headers: recordSchema(stringSchema(), {
3861
- title: "SandboxAjaxMockHeaders"
3862
- }),
3863
- body: stringSchema()
3864
- },
3865
- {
3866
- title: "SandboxAjaxMockResponse",
3867
- required: ["status"]
3868
- }
3869
- )
3870
- },
3871
- {
3872
- title: "SandboxAjaxRoute",
3873
- required: ["urlPattern", "mode"]
3874
- }
3875
- );
3876
- var opensteerScriptSandboxInputSchema = objectSchema(
3877
- {
3878
- artifactId: stringSchema({ minLength: 1 }),
3879
- content: stringSchema(),
3880
- fidelity: sandboxFidelitySchema,
3881
- ajaxRoutes: arraySchema(sandboxAjaxRouteSchema),
3882
- cookies: recordSchema(stringSchema(), {
3883
- title: "SandboxCookies"
3884
- }),
3885
- globals: objectSchema(
3886
- {},
3887
- {
3888
- title: "SandboxGlobals",
3889
- additionalProperties: true
3890
- }
3891
- ),
3892
- timeoutMs: integerSchema({ minimum: 1 }),
3893
- clockMode: enumSchema(["real", "manual"])
3894
- },
3895
- {
3896
- title: "OpensteerScriptSandboxInput"
3897
- }
3898
- );
3899
- var sandboxCapturedAjaxCallSchema = objectSchema(
3900
- {
3901
- method: stringSchema({ minLength: 1 }),
3902
- url: stringSchema({ minLength: 1 }),
3903
- headers: recordSchema(stringSchema(), {
3904
- title: "SandboxCapturedAjaxHeaders"
3905
- }),
3906
- body: stringSchema(),
3907
- timestamp: integerSchema({ minimum: 0 })
3908
- },
3909
- {
3910
- title: "SandboxCapturedAjaxCall",
3911
- required: ["method", "url", "headers", "timestamp"]
3912
- }
3913
- );
3914
- var opensteerScriptSandboxOutputSchema = objectSchema(
3915
- {
3916
- result: oneOfSchema(
3917
- [
3918
- objectSchema({}, { additionalProperties: true }),
3919
- arraySchema({}),
3920
- stringSchema(),
3921
- { type: "number" },
3922
- enumSchema([true, false, null])
3923
- ],
3924
- {
3925
- title: "SandboxResult"
3926
- }
3927
- ),
3928
- capturedAjax: arraySchema(sandboxCapturedAjaxCallSchema),
3929
- errors: arraySchema(stringSchema({ minLength: 1 })),
3930
- durationMs: integerSchema({ minimum: 0 })
3931
- },
3932
- {
3933
- title: "OpensteerScriptSandboxOutput",
3934
- required: ["capturedAjax", "errors", "durationMs"]
3935
- }
3936
- );
3937
-
3938
- // ../protocol/src/reverse.ts
3939
- var opensteerStateSourceKindSchema = enumSchema(
3940
- ["temporary", "persistent", "attach"],
3941
- { title: "OpensteerStateSourceKind" }
3942
- );
3943
- var opensteerReverseCaseStatusSchema = enumSchema(
3944
- ["capturing", "analyzing", "ready", "attention"],
3945
- { title: "OpensteerReverseCaseStatus" }
3946
- );
3947
- var opensteerReverseChannelKindSchema = enumSchema(
3948
- ["http", "event-stream", "websocket"],
3949
- { title: "OpensteerReverseChannelKind" }
3950
- );
3951
- var opensteerReverseManualCalibrationModeSchema = enumSchema(
3952
- ["allow", "avoid", "require"],
3953
- { title: "OpensteerReverseManualCalibrationMode" }
3954
- );
3955
- var opensteerReverseCandidateBoundarySchema = enumSchema(
3956
- ["first-party", "same-site", "third-party"],
3957
- { title: "OpensteerReverseCandidateBoundary" }
3958
- );
3959
- var opensteerReverseAdvisoryTagSchema = enumSchema(
3960
- [
3961
- "data",
3962
- "facet",
3963
- "telemetry",
3964
- "subscription",
3965
- "navigation",
3966
- "document",
3967
- "route-data",
3968
- "search",
3969
- "tracking",
3970
- "unknown"
3971
- ],
3972
- { title: "OpensteerReverseAdvisoryTag" }
3973
- );
3974
- var opensteerReverseConstraintKindSchema = enumSchema(
3975
- [
3976
- "requires-browser",
3977
- "requires-cookie",
3978
- "requires-storage",
3979
- "requires-script",
3980
- "requires-guard",
3981
- "requires-live-state",
3982
- "opaque-body",
3983
- "unsupported"
3984
- ],
3985
- { title: "OpensteerReverseConstraintKind" }
3986
- );
3987
- var opensteerRequestInputLocationSchema = enumSchema(
3988
- ["path", "query", "header", "cookie", "body-field"],
3989
- { title: "OpensteerRequestInputLocation" }
3990
- );
3991
- var opensteerRequestInputRequirednessSchema = enumSchema(
3992
- ["required", "optional", "unknown"],
3993
- { title: "OpensteerRequestInputRequiredness" }
3994
- );
3995
- var opensteerRequestInputClassificationSchema = enumSchema(
3996
- ["managed", "static", "contextual", "volatile"],
3997
- { title: "OpensteerRequestInputClassification" }
3998
- );
3999
- var opensteerRequestInputSourceSchema = enumSchema(
4000
- [
4001
- "literal",
4002
- "cookie",
4003
- "storage",
4004
- "prior-response",
4005
- "page",
4006
- "script",
4007
- "guard-output",
4008
- "runtime-managed",
4009
- "unknown"
4010
- ],
4011
- { title: "OpensteerRequestInputSource" }
4012
- );
4013
- var opensteerRequestInputMaterializationPolicySchema = enumSchema(
4014
- ["copy", "omit", "recompute", "resolve"],
4015
- { title: "OpensteerRequestInputMaterializationPolicy" }
4016
- );
4017
- var opensteerRequestInputExportPolicySchema = enumSchema(
4018
- ["portable", "browser-bound", "blocked"],
4019
- { title: "OpensteerRequestInputExportPolicy" }
4020
- );
4021
- var opensteerReverseQueryViewSchema = enumSchema(
4022
- ["records", "clusters", "candidates"],
4023
- { title: "OpensteerReverseQueryView" }
4024
- );
4025
- var opensteerReverseSortKeySchema = enumSchema(
4026
- [
4027
- "observed-at",
4028
- "advisory-rank",
4029
- "target-hint-matches",
4030
- "response-richness",
4031
- "portability",
4032
- "boundary",
4033
- "success"
4034
- ],
4035
- { title: "OpensteerReverseSortKey" }
4036
- );
4037
- var opensteerReverseSortPresetSchema = enumSchema(
4038
- [
4039
- "advisory-rank",
4040
- "observed-at",
4041
- "portability",
4042
- "first-party",
4043
- "hint-match",
4044
- "response-richness"
4045
- ],
4046
- { title: "OpensteerReverseSortPreset" }
4047
- );
4048
- var opensteerReverseSortDirectionSchema = enumSchema(
4049
- ["asc", "desc"],
4050
- {
4051
- title: "OpensteerReverseSortDirection"
4052
- }
4053
- );
4054
- var opensteerObservationClusterRelationshipKindSchema = enumSchema(
4055
- ["seed", "preflight", "redirect", "retry", "duplicate", "follow-on"],
4056
- { title: "OpensteerObservationClusterRelationshipKind" }
4057
- );
4058
- var opensteerReverseReportKindSchema = enumSchema(
4059
- ["discovery", "package"],
4060
- { title: "OpensteerReverseReportKind" }
4061
- );
4062
- var opensteerReversePackageKindSchema = enumSchema(
4063
- ["portable-http", "browser-workflow"],
4064
- { title: "OpensteerReversePackageKind" }
4065
- );
4066
- var opensteerReversePackageReadinessSchema = enumSchema(
4067
- ["runnable", "draft", "unsupported"],
4068
- { title: "OpensteerReversePackageReadiness" }
4069
- );
4070
- var opensteerBodyCodecKindSchema = enumSchema(
4071
- [
4072
- "json",
4073
- "form-urlencoded",
4074
- "multipart",
4075
- "graphql",
4076
- "persisted-graphql",
4077
- "text",
4078
- "opaque-binary",
4079
- "sse",
4080
- "websocket-json",
4081
- "websocket-text",
4082
- "unknown"
4083
- ],
4084
- { title: "OpensteerBodyCodecKind" }
4085
- );
4086
- var opensteerExecutableResolverKindSchema = enumSchema(
4087
- [
4088
- "literal",
4089
- "cookie",
4090
- "storage",
4091
- "prior-record",
4092
- "binding",
4093
- "candidate",
4094
- "case",
4095
- "state-snapshot",
4096
- "artifact",
4097
- "manual",
4098
- "runtime-managed"
4099
- ],
4100
- { title: "OpensteerExecutableResolverKind" }
4101
- );
4102
- var opensteerValueReferenceKindSchema = enumSchema(
4103
- [
4104
- "literal",
4105
- "resolver",
4106
- "binding",
4107
- "candidate",
4108
- "case",
4109
- "record",
4110
- "artifact",
4111
- "state-snapshot",
4112
- "runtime",
4113
- "manual"
4114
- ],
4115
- { title: "OpensteerValueReferenceKind" }
4116
- );
4117
- var opensteerRuntimeValueKeySchema = enumSchema(
4118
- ["pageRef", "packageId", "caseId", "candidateId", "objective"],
4119
- { title: "OpensteerRuntimeValueKey" }
4120
- );
4121
- var opensteerValidationRuleKindSchema = enumSchema(
4122
- [
4123
- "status",
4124
- "json-structure",
4125
- "text-includes",
4126
- "stream-first-chunk",
4127
- "websocket-open",
4128
- "message-count-at-least"
4129
- ],
4130
- { title: "OpensteerValidationRuleKind" }
4131
- );
4132
- enumSchema(
4133
- ["operation", "await-record", "assert"],
4134
- { title: "OpensteerReverseWorkflowStepKind" }
4135
- );
4136
- var opensteerReverseRequirementKindSchema = enumSchema(
4137
- ["resolver", "guard", "workflow-step", "state", "channel", "unsupported"],
4138
- { title: "OpensteerReverseRequirementKind" }
4139
- );
4140
- var opensteerReverseRequirementStatusSchema = enumSchema(
4141
- ["required", "recommended"],
4142
- { title: "OpensteerReverseRequirementStatus" }
4143
- );
4144
- var opensteerReverseSuggestedEditKindSchema = enumSchema(
4145
- [
4146
- "set-resolver",
4147
- "attach-trace",
4148
- "replace-workflow",
4149
- "patch-step-input",
4150
- "switch-state-source",
4151
- "inspect-evidence",
4152
- "mark-unsupported"
4153
- ],
4154
- { title: "OpensteerReverseSuggestedEditKind" }
4155
- );
4156
- var jsonValueSchema2 = defineSchema({
4157
- title: "JsonValue"
4158
- });
4159
- var opensteerValueReferenceSchema = objectSchema(
4160
- {
4161
- kind: opensteerValueReferenceKindSchema,
4162
- pointer: stringSchema({ minLength: 1 }),
4163
- resolverId: stringSchema({ minLength: 1 }),
4164
- binding: stringSchema({ minLength: 1 }),
4165
- recordId: stringSchema({ minLength: 1 }),
4166
- artifactId: stringSchema({ minLength: 1 }),
4167
- stateSnapshotId: stringSchema({ minLength: 1 }),
4168
- runtimeKey: opensteerRuntimeValueKeySchema,
4169
- value: jsonValueSchema2,
4170
- placeholder: stringSchema({ minLength: 1 })
4171
- },
4172
- {
4173
- title: "OpensteerValueReference",
4174
- required: ["kind"]
4175
- }
4176
- );
4177
- var opensteerValueTemplateSchema = defineSchema({
4178
- title: "OpensteerValueTemplate"
4179
- });
4180
- var opensteerReverseTargetHintsSchema = objectSchema(
4181
- {
4182
- hosts: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4183
- paths: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4184
- operationNames: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4185
- channels: arraySchema(opensteerReverseChannelKindSchema, { uniqueItems: true })
4186
- },
4187
- {
4188
- title: "OpensteerReverseTargetHints"
4189
- }
4190
- );
4191
- var opensteerBodyCodecDescriptorSchema = objectSchema(
4192
- {
4193
- kind: opensteerBodyCodecKindSchema,
4194
- contentType: stringSchema({ minLength: 1 }),
4195
- operationName: stringSchema({ minLength: 1 }),
4196
- fieldPaths: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true })
4197
- },
4198
- {
4199
- title: "OpensteerBodyCodecDescriptor",
4200
- required: ["kind", "fieldPaths"]
4201
- }
4202
- );
4203
- var opensteerObservationClusterSchema = objectSchema(
4204
- {
4205
- id: stringSchema({ minLength: 1 }),
4206
- observationId: stringSchema({ minLength: 1 }),
4207
- label: stringSchema({ minLength: 1 }),
4208
- channel: opensteerReverseChannelKindSchema,
4209
- method: stringSchema({ minLength: 1 }),
4210
- url: stringSchema({ minLength: 1 }),
4211
- matchedTargetHints: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4212
- members: arraySchema(
4213
- objectSchema(
4214
- {
4215
- recordId: stringSchema({ minLength: 1 }),
4216
- observedAt: integerSchema({ minimum: 0 }),
4217
- resourceType: stringSchema({ minLength: 1 }),
4218
- status: integerSchema({ minimum: 0 }),
4219
- relation: opensteerObservationClusterRelationshipKindSchema,
4220
- relatedRecordId: stringSchema({ minLength: 1 }),
4221
- matchedTargetHints: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true })
4222
- },
4223
- {
4224
- title: "OpensteerObservationClusterMember",
4225
- required: ["recordId", "relation", "matchedTargetHints"]
4226
- }
4227
- )
4228
- )
4229
- },
4230
- {
4231
- title: "OpensteerObservationCluster",
4232
- required: ["id", "observationId", "label", "channel", "url", "matchedTargetHints", "members"]
4233
- }
4234
- );
4235
- var opensteerStateSnapshotCookieSchema = objectSchema(
4236
- {
4237
- name: stringSchema({ minLength: 1 }),
4238
- value: stringSchema(),
4239
- domain: stringSchema({ minLength: 1 }),
4240
- path: stringSchema({ minLength: 1 }),
4241
- secure: { type: "boolean" },
4242
- httpOnly: { type: "boolean" },
4243
- sameSite: enumSchema(["strict", "lax", "none"]),
4244
- priority: enumSchema(["low", "medium", "high"]),
4245
- partitionKey: stringSchema({ minLength: 1 }),
4246
- session: { type: "boolean" },
4247
- expiresAt: oneOfSchema([integerSchema({ minimum: 0 }), { type: "null" }])
4248
- },
4249
- {
4250
- title: "OpensteerStateSnapshotCookie",
4251
- required: ["name", "value", "domain", "path", "secure", "httpOnly", "session"]
4252
- }
4253
- );
4254
- var opensteerStateSnapshotSchema = objectSchema(
4255
- {
4256
- id: stringSchema({ minLength: 1 }),
4257
- capturedAt: integerSchema({ minimum: 0 }),
4258
- pageRef: pageRefSchema,
4259
- url: stringSchema({ minLength: 1 }),
4260
- cookies: arraySchema(opensteerStateSnapshotCookieSchema),
4261
- storage: storageSnapshotSchema,
4262
- hiddenFields: arraySchema(
4263
- objectSchema(
4264
- {
4265
- path: stringSchema({ minLength: 1 }),
4266
- name: stringSchema({ minLength: 1 }),
4267
- value: stringSchema()
4268
- },
4269
- {
4270
- title: "OpensteerStateSnapshotHiddenField",
4271
- required: ["path", "name", "value"]
4272
- }
4273
- )
4274
- ),
4275
- globals: recordSchema({}, { title: "OpensteerStateSnapshotGlobals" })
4276
- },
4277
- {
4278
- title: "OpensteerStateSnapshot",
4279
- required: ["id", "capturedAt"]
4280
- }
4281
- );
4282
- var opensteerStateDeltaSchema = objectSchema(
4283
- {
4284
- beforeStateId: stringSchema({ minLength: 1 }),
4285
- afterStateId: stringSchema({ minLength: 1 }),
4286
- cookiesChanged: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4287
- storageChanged: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4288
- hiddenFieldsChanged: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4289
- globalsChanged: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true })
4290
- },
4291
- {
4292
- title: "OpensteerStateDelta",
4293
- required: ["cookiesChanged", "storageChanged", "hiddenFieldsChanged", "globalsChanged"]
4294
- }
4295
- );
4296
- var opensteerRequestInputDescriptorSchema = objectSchema(
4297
- {
4298
- name: stringSchema({ minLength: 1 }),
4299
- location: opensteerRequestInputLocationSchema,
4300
- path: stringSchema({ minLength: 1 }),
4301
- wireName: stringSchema({ minLength: 1 }),
4302
- requiredness: opensteerRequestInputRequirednessSchema,
4303
- classification: opensteerRequestInputClassificationSchema,
4304
- source: opensteerRequestInputSourceSchema,
4305
- materializationPolicy: opensteerRequestInputMaterializationPolicySchema,
4306
- exportPolicy: opensteerRequestInputExportPolicySchema,
4307
- originalValue: stringSchema(),
4308
- provenance: objectSchema(
4309
- {
4310
- recordId: stringSchema({ minLength: 1 }),
4311
- observationId: stringSchema({ minLength: 1 }),
4312
- sourcePointer: stringSchema({ minLength: 1 }),
4313
- notes: stringSchema({ minLength: 1 })
4314
- },
4315
- {
4316
- title: "OpensteerRequestInputDescriptorProvenance"
4317
- }
4318
- ),
4319
- unlockedByGuardIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true })
4320
- },
4321
- {
4322
- title: "OpensteerRequestInputDescriptor",
4323
- required: [
4324
- "name",
4325
- "location",
4326
- "requiredness",
4327
- "classification",
4328
- "source",
4329
- "materializationPolicy",
4330
- "exportPolicy"
4331
- ]
4332
- }
4333
- );
4334
- var opensteerExecutableResolverSchema = objectSchema(
4335
- {
4336
- id: stringSchema({ minLength: 1 }),
4337
- kind: opensteerExecutableResolverKindSchema,
4338
- label: stringSchema({ minLength: 1 }),
4339
- status: enumSchema(["ready", "missing"]),
4340
- requiresBrowser: { type: "boolean" },
4341
- requiresLiveState: { type: "boolean" },
4342
- description: stringSchema({ minLength: 1 }),
4343
- inputNames: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4344
- guardId: stringSchema({ minLength: 1 }),
4345
- traceId: stringSchema({ minLength: 1 }),
4346
- valueRef: opensteerValueReferenceSchema
4347
- },
4348
- {
4349
- title: "OpensteerExecutableResolver",
4350
- required: ["id", "kind", "label", "status", "requiresBrowser", "requiresLiveState"]
4351
- }
4352
- );
4353
- var opensteerReverseAdvisorySignalsSchema = objectSchema(
4354
- {
4355
- advisoryRank: numberSchema(),
4356
- observedAt: integerSchema({ minimum: 0 }),
4357
- targetHintMatches: integerSchema({ minimum: 0 }),
4358
- responseRichness: integerSchema({ minimum: 0 }),
4359
- portabilityWeight: integerSchema({ minimum: 0 }),
4360
- boundaryWeight: integerSchema({ minimum: 0 }),
4361
- successfulStatus: { type: "boolean" },
4362
- fetchLike: { type: "boolean" },
4363
- hasResponseBody: { type: "boolean" },
4364
- dataPathMatch: { type: "boolean" },
4365
- cookieInputCount: integerSchema({ minimum: 0 }),
4366
- storageInputCount: integerSchema({ minimum: 0 }),
4367
- volatileInputCount: integerSchema({ minimum: 0 }),
4368
- guardCount: integerSchema({ minimum: 0 })
4369
- },
4370
- {
4371
- title: "OpensteerReverseAdvisorySignals",
4372
- required: [
4373
- "advisoryRank",
4374
- "targetHintMatches",
4375
- "responseRichness",
4376
- "portabilityWeight",
4377
- "boundaryWeight",
4378
- "successfulStatus",
4379
- "fetchLike",
4380
- "hasResponseBody",
4381
- "dataPathMatch",
4382
- "cookieInputCount",
4383
- "storageInputCount",
4384
- "volatileInputCount",
4385
- "guardCount"
4386
- ]
4387
- }
4388
- );
4389
- var opensteerValidationRuleSchema = objectSchema(
4390
- {
4391
- id: stringSchema({ minLength: 1 }),
4392
- kind: opensteerValidationRuleKindSchema,
4393
- label: stringSchema({ minLength: 1 }),
4394
- required: { type: "boolean" },
4395
- expectedStatus: integerSchema({ minimum: 0 }),
4396
- structureHash: stringSchema({ minLength: 1 }),
4397
- textIncludes: stringSchema({ minLength: 1 }),
4398
- minimumCount: integerSchema({ minimum: 0 })
4399
- },
4400
- {
4401
- title: "OpensteerValidationRule",
4402
- required: ["id", "kind", "label", "required"]
4403
- }
4404
- );
4405
- var opensteerChannelDescriptorSchema = objectSchema(
4406
- {
4407
- kind: opensteerReverseChannelKindSchema,
4408
- recordKind: networkRecordKindSchema,
4409
- method: stringSchema({ minLength: 1 }),
4410
- url: stringSchema({ minLength: 1 }),
4411
- subprotocol: stringSchema({ minLength: 1 })
4412
- },
4413
- {
4414
- title: "OpensteerChannelDescriptor",
4415
- required: ["kind", "recordKind", "url"]
4416
- }
4417
- );
4418
- var opensteerReverseOperationWorkflowStepSchema = objectSchema(
4419
- {
4420
- id: stringSchema({ minLength: 1 }),
4421
- kind: enumSchema(["operation"]),
4422
- label: stringSchema({ minLength: 1 }),
4423
- operation: stringSchema({ minLength: 1 }),
4424
- input: opensteerValueTemplateSchema,
4425
- bindAs: stringSchema({ minLength: 1 })
4426
- },
4427
- {
4428
- title: "OpensteerReverseOperationWorkflowStep",
4429
- required: ["id", "kind", "label", "operation", "input"]
4430
- }
4431
- );
4432
- var opensteerReverseAwaitRecordWorkflowStepSchema = objectSchema(
4433
- {
4434
- id: stringSchema({ minLength: 1 }),
4435
- kind: enumSchema(["await-record"]),
4436
- label: stringSchema({ minLength: 1 }),
4437
- channel: opensteerChannelDescriptorSchema,
4438
- recordId: stringSchema({ minLength: 1 }),
4439
- match: objectSchema(
4440
- {
4441
- recordId: stringSchema({ minLength: 1 }),
4442
- host: stringSchema({ minLength: 1 }),
4443
- path: stringSchema({ minLength: 1 }),
4444
- method: stringSchema({ minLength: 1 }),
4445
- channel: opensteerReverseChannelKindSchema,
4446
- status: integerSchema({ minimum: 0 }),
4447
- text: stringSchema({ minLength: 1 })
4448
- },
4449
- {
4450
- title: "OpensteerReverseAwaitRecordMatch"
4451
- }
4452
- ),
4453
- validationRuleIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4454
- timeoutMs: integerSchema({ minimum: 0 }),
4455
- bindAs: stringSchema({ minLength: 1 })
4456
- },
4457
- {
4458
- title: "OpensteerReverseAwaitRecordWorkflowStep",
4459
- required: ["id", "kind", "label", "channel"]
4460
- }
4461
- );
4462
- var opensteerReverseAssertWorkflowStepSchema = objectSchema(
4463
- {
4464
- id: stringSchema({ minLength: 1 }),
4465
- kind: enumSchema(["assert"]),
4466
- label: stringSchema({ minLength: 1 }),
4467
- validationRuleIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4468
- binding: stringSchema({ minLength: 1 })
4469
- },
4470
- {
4471
- title: "OpensteerReverseAssertWorkflowStep",
4472
- required: ["id", "kind", "label", "validationRuleIds"]
4473
- }
4474
- );
4475
- var opensteerReverseWorkflowStepSchema = oneOfSchema(
4476
- [
4477
- opensteerReverseOperationWorkflowStepSchema,
4478
- opensteerReverseAwaitRecordWorkflowStepSchema,
4479
- opensteerReverseAssertWorkflowStepSchema
4480
- ],
4481
- {
4482
- title: "OpensteerReverseWorkflowStep"
4483
- }
4484
- );
4485
- var opensteerReversePackageRequirementsSchema = objectSchema(
4486
- {
4487
- requiresBrowser: { type: "boolean" },
4488
- requiresLiveState: { type: "boolean" },
4489
- manualCalibration: enumSchema(["not-needed", "recommended", "required"]),
4490
- stateSources: arraySchema(opensteerStateSourceKindSchema, { uniqueItems: true })
4491
- },
4492
- {
4493
- title: "OpensteerReversePackageRequirements",
4494
- required: ["requiresBrowser", "requiresLiveState", "manualCalibration", "stateSources"]
4495
- }
4496
- );
4497
- var opensteerReverseAdvisoryTemplateSchema = objectSchema(
4498
- {
4499
- id: stringSchema({ minLength: 1 }),
4500
- label: stringSchema({ minLength: 1 }),
4501
- channel: opensteerReverseChannelKindSchema,
4502
- execution: enumSchema(["transport", "page-observation"]),
4503
- stateSource: opensteerStateSourceKindSchema,
4504
- observationId: stringSchema({ minLength: 1 }),
4505
- transport: transportKindSchema,
4506
- guardIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4507
- resolverIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4508
- requiresBrowser: { type: "boolean" },
4509
- requiresLiveState: { type: "boolean" },
4510
- viability: enumSchema(["ready", "draft", "unsupported"]),
4511
- notes: stringSchema({ minLength: 1 })
4512
- },
4513
- {
4514
- title: "OpensteerReverseAdvisoryTemplate",
4515
- required: [
4516
- "id",
4517
- "label",
4518
- "channel",
4519
- "execution",
4520
- "stateSource",
4521
- "guardIds",
4522
- "resolverIds",
4523
- "requiresBrowser",
4524
- "requiresLiveState",
4525
- "viability"
4526
- ]
4527
- }
4528
- );
4529
- var opensteerReverseGuardRecordSchema = objectSchema(
4530
- {
4531
- id: stringSchema({ minLength: 1 }),
4532
- kind: enumSchema(["interaction", "state", "script", "manual"]),
4533
- label: stringSchema({ minLength: 1 }),
4534
- status: enumSchema(["required", "satisfied", "unresolved"]),
4535
- interactionTraceId: stringSchema({ minLength: 1 }),
4536
- notes: stringSchema({ minLength: 1 })
4537
- },
4538
- {
4539
- title: "OpensteerReverseGuardRecord",
4540
- required: ["id", "kind", "label", "status"]
4541
- }
4542
- );
4543
- var opensteerReverseObservationRecordSchema = objectSchema(
4544
- {
4545
- id: stringSchema({ minLength: 1 }),
4546
- capturedAt: integerSchema({ minimum: 0 }),
4547
- pageRef: pageRefSchema,
4548
- url: stringSchema({ minLength: 1 }),
4549
- stateSource: opensteerStateSourceKindSchema,
4550
- networkRecordIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4551
- scriptArtifactIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4552
- interactionTraceIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4553
- stateSnapshotIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4554
- notes: stringSchema({ minLength: 1 })
4555
- },
4556
- {
4557
- title: "OpensteerReverseObservationRecord",
4558
- required: [
4559
- "id",
4560
- "capturedAt",
4561
- "stateSource",
4562
- "networkRecordIds",
4563
- "scriptArtifactIds",
4564
- "interactionTraceIds",
4565
- "stateSnapshotIds"
4566
- ]
4567
- }
4568
- );
4569
- var opensteerReverseObservedRecordSchema = objectSchema(
4570
- {
4571
- recordId: stringSchema({ minLength: 1 }),
4572
- observationId: stringSchema({ minLength: 1 }),
4573
- clusterId: stringSchema({ minLength: 1 }),
4574
- observedAt: integerSchema({ minimum: 0 }),
4575
- channel: opensteerChannelDescriptorSchema,
4576
- bodyCodec: opensteerBodyCodecDescriptorSchema,
4577
- resourceType: stringSchema({ minLength: 1 }),
4578
- status: integerSchema({ minimum: 0 }),
4579
- matchedTargetHints: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4580
- relationKinds: arraySchema(opensteerObservationClusterRelationshipKindSchema, {
4581
- uniqueItems: true
4582
- })
4583
- },
4584
- {
4585
- title: "OpensteerReverseObservedRecord",
4586
- required: [
4587
- "recordId",
4588
- "observationId",
4589
- "clusterId",
4590
- "channel",
4591
- "bodyCodec",
4592
- "matchedTargetHints",
4593
- "relationKinds"
4594
- ]
4595
- }
4596
- );
4597
- var opensteerReverseCandidateRecordSchema = objectSchema(
4598
- {
4599
- id: stringSchema({ minLength: 1 }),
4600
- observationId: stringSchema({ minLength: 1 }),
4601
- clusterId: stringSchema({ minLength: 1 }),
4602
- recordId: stringSchema({ minLength: 1 }),
4603
- channel: opensteerChannelDescriptorSchema,
4604
- bodyCodec: opensteerBodyCodecDescriptorSchema,
4605
- boundary: opensteerReverseCandidateBoundarySchema,
4606
- summary: stringSchema({ minLength: 1 }),
4607
- matchedTargetHints: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4608
- advisoryTags: arraySchema(opensteerReverseAdvisoryTagSchema, { uniqueItems: true }),
4609
- constraints: arraySchema(opensteerReverseConstraintKindSchema, { uniqueItems: true }),
4610
- signals: opensteerReverseAdvisorySignalsSchema,
4611
- inputs: arraySchema(opensteerRequestInputDescriptorSchema),
4612
- resolvers: arraySchema(opensteerExecutableResolverSchema),
4613
- guardIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4614
- scriptArtifactIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4615
- advisoryTemplates: arraySchema(opensteerReverseAdvisoryTemplateSchema)
4616
- },
4617
- {
4618
- title: "OpensteerReverseCandidateRecord",
4619
- required: [
4620
- "id",
4621
- "observationId",
4622
- "clusterId",
4623
- "recordId",
4624
- "channel",
4625
- "bodyCodec",
4626
- "boundary",
4627
- "summary",
4628
- "matchedTargetHints",
4629
- "advisoryTags",
4630
- "constraints",
4631
- "signals",
4632
- "inputs",
4633
- "resolvers",
4634
- "guardIds",
4635
- "scriptArtifactIds",
4636
- "advisoryTemplates"
4637
- ]
4638
- }
4639
- );
4640
- var opensteerReverseReplayValidationSchema = objectSchema(
4641
- {
4642
- statusMatches: { type: "boolean" },
4643
- structureMatches: { type: "boolean" },
4644
- opened: { type: "boolean" },
4645
- firstChunkObserved: { type: "boolean" },
4646
- firstChunkMatches: { type: "boolean" },
4647
- messageObserved: { type: "boolean" },
4648
- messageCount: integerSchema({ minimum: 0 })
4649
- },
4650
- {
4651
- title: "OpensteerReverseReplayValidation"
4652
- }
4653
- );
4654
- var opensteerReverseReplayRunRecordSchema = objectSchema(
4655
- {
4656
- id: stringSchema({ minLength: 1 }),
4657
- createdAt: integerSchema({ minimum: 0 }),
4658
- candidateId: stringSchema({ minLength: 1 }),
4659
- templateId: stringSchema({ minLength: 1 }),
4660
- packageId: stringSchema({ minLength: 1 }),
4661
- success: { type: "boolean" },
4662
- channel: opensteerReverseChannelKindSchema,
4663
- kind: opensteerReversePackageKindSchema,
4664
- readiness: opensteerReversePackageReadinessSchema,
4665
- transport: transportKindSchema,
4666
- stateSource: opensteerStateSourceKindSchema,
4667
- executedStepIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4668
- failedStepId: stringSchema({ minLength: 1 }),
4669
- bindings: recordSchema({}, { title: "OpensteerReverseReplayRunBindings" }),
4670
- recordId: stringSchema({ minLength: 1 }),
4671
- status: integerSchema({ minimum: 0 }),
4672
- validation: opensteerReverseReplayValidationSchema,
4673
- error: stringSchema({ minLength: 1 })
4674
- },
4675
- {
4676
- title: "OpensteerReverseReplayRunRecord",
4677
- required: [
4678
- "id",
4679
- "createdAt",
4680
- "packageId",
4681
- "success",
4682
- "kind",
4683
- "readiness",
4684
- "executedStepIds",
4685
- "validation"
4686
- ]
4687
- }
4688
- );
4689
- var opensteerReverseExperimentRecordSchema = objectSchema(
4690
- {
4691
- id: stringSchema({ minLength: 1 }),
4692
- createdAt: integerSchema({ minimum: 0 }),
4693
- candidateId: stringSchema({ minLength: 1 }),
4694
- templateId: stringSchema({ minLength: 1 }),
4695
- kind: enumSchema(["replay-attempt", "field-variation"]),
4696
- hypothesis: stringSchema({ minLength: 1 }),
4697
- success: { type: "boolean" },
4698
- status: integerSchema({ minimum: 0 }),
4699
- notes: stringSchema({ minLength: 1 }),
4700
- validation: opensteerReverseReplayValidationSchema
4701
- },
4702
- {
4703
- title: "OpensteerReverseExperimentRecord",
4704
- required: ["id", "createdAt", "kind", "hypothesis", "success"]
4705
- }
4706
- );
4707
- var opensteerReverseRequirementSchema = objectSchema(
4708
- {
4709
- id: stringSchema({ minLength: 1 }),
4710
- kind: opensteerReverseRequirementKindSchema,
4711
- status: opensteerReverseRequirementStatusSchema,
4712
- label: stringSchema({ minLength: 1 }),
4713
- description: stringSchema({ minLength: 1 }),
4714
- blocking: { type: "boolean" },
4715
- resolverId: stringSchema({ minLength: 1 }),
4716
- guardId: stringSchema({ minLength: 1 }),
4717
- stepId: stringSchema({ minLength: 1 }),
4718
- inputNames: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4719
- traceId: stringSchema({ minLength: 1 }),
4720
- artifactId: stringSchema({ minLength: 1 }),
4721
- recordId: stringSchema({ minLength: 1 })
4722
- },
4723
- {
4724
- title: "OpensteerReverseRequirement",
4725
- required: ["id", "kind", "status", "label", "blocking"]
4726
- }
4727
- );
4728
- var opensteerReverseSuggestedEditSchema = objectSchema(
4729
- {
4730
- id: stringSchema({ minLength: 1 }),
4731
- kind: opensteerReverseSuggestedEditKindSchema,
4732
- label: stringSchema({ minLength: 1 }),
4733
- description: stringSchema({ minLength: 1 }),
4734
- resolverId: stringSchema({ minLength: 1 }),
4735
- guardId: stringSchema({ minLength: 1 }),
4736
- stepId: stringSchema({ minLength: 1 }),
4737
- traceId: stringSchema({ minLength: 1 }),
4738
- artifactId: stringSchema({ minLength: 1 }),
4739
- recordId: stringSchema({ minLength: 1 }),
4740
- payload: jsonValueSchema2
4741
- },
4742
- {
4743
- title: "OpensteerReverseSuggestedEdit",
4744
- required: ["id", "kind", "label"]
4745
- }
4746
- );
4747
- var opensteerReverseExportRecordSchema = objectSchema(
4748
- {
4749
- id: stringSchema({ minLength: 1 }),
4750
- createdAt: integerSchema({ minimum: 0 }),
4751
- candidateId: stringSchema({ minLength: 1 }),
4752
- templateId: stringSchema({ minLength: 1 }),
4753
- packageId: stringSchema({ minLength: 1 }),
4754
- kind: opensteerReversePackageKindSchema,
4755
- readiness: opensteerReversePackageReadinessSchema,
4756
- requestPlanId: stringSchema({ minLength: 1 })
4757
- },
4758
- {
4759
- title: "OpensteerReverseExportRecord",
4760
- required: ["id", "createdAt", "packageId", "kind", "readiness"]
4761
- }
4762
- );
4763
- var opensteerReverseCasePayloadSchema = objectSchema(
4764
- {
4765
- objective: stringSchema({ minLength: 1 }),
4766
- notes: stringSchema({ minLength: 1 }),
4767
- status: opensteerReverseCaseStatusSchema,
4768
- stateSource: opensteerStateSourceKindSchema,
4769
- observations: arraySchema(opensteerReverseObservationRecordSchema),
4770
- observationClusters: arraySchema(opensteerObservationClusterSchema),
4771
- observedRecords: arraySchema(opensteerReverseObservedRecordSchema),
4772
- candidates: arraySchema(opensteerReverseCandidateRecordSchema),
4773
- guards: arraySchema(opensteerReverseGuardRecordSchema),
4774
- stateSnapshots: arraySchema(opensteerStateSnapshotSchema),
4775
- stateDeltas: arraySchema(opensteerStateDeltaSchema),
4776
- experiments: arraySchema(opensteerReverseExperimentRecordSchema),
4777
- replayRuns: arraySchema(opensteerReverseReplayRunRecordSchema),
4778
- exports: arraySchema(opensteerReverseExportRecordSchema)
4779
- },
4780
- {
4781
- title: "OpensteerReverseCasePayload",
4782
- required: [
4783
- "objective",
4784
- "status",
4785
- "stateSource",
4786
- "observations",
4787
- "observationClusters",
4788
- "observedRecords",
4789
- "candidates",
4790
- "guards",
4791
- "stateSnapshots",
4792
- "stateDeltas",
4793
- "experiments",
4794
- "replayRuns",
4795
- "exports"
4796
- ]
4797
- }
4798
- );
4799
- objectSchema(
4800
- {
4801
- id: stringSchema({ minLength: 1 }),
4802
- key: stringSchema({ minLength: 1 }),
4803
- version: stringSchema({ minLength: 1 }),
4804
- createdAt: integerSchema({ minimum: 0 }),
4805
- updatedAt: integerSchema({ minimum: 0 }),
4806
- contentHash: stringSchema({ minLength: 1 }),
4807
- tags: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4808
- provenance: opensteerRegistryProvenanceSchema,
4809
- payload: opensteerReverseCasePayloadSchema
4810
- },
4811
- {
4812
- title: "OpensteerReverseCaseRecord",
4813
- required: ["id", "key", "version", "createdAt", "updatedAt", "contentHash", "tags", "payload"]
4814
- }
4815
- );
4816
- var opensteerReversePackagePayloadSchema = objectSchema(
4817
- {
4818
- kind: opensteerReversePackageKindSchema,
4819
- readiness: opensteerReversePackageReadinessSchema,
4820
- caseId: stringSchema({ minLength: 1 }),
4821
- objective: stringSchema({ minLength: 1 }),
4822
- source: objectSchema(
4823
- {
4824
- kind: enumSchema(["record", "candidate"]),
4825
- id: stringSchema({ minLength: 1 })
4826
- },
4827
- {
4828
- title: "OpensteerReversePackageSource",
4829
- required: ["kind", "id"]
4830
- }
4831
- ),
4832
- sourceRecordId: stringSchema({ minLength: 1 }),
4833
- candidateId: stringSchema({ minLength: 1 }),
4834
- candidate: opensteerReverseCandidateRecordSchema,
4835
- templateId: stringSchema({ minLength: 1 }),
4836
- template: opensteerReverseAdvisoryTemplateSchema,
4837
- channel: opensteerChannelDescriptorSchema,
4838
- stateSource: opensteerStateSourceKindSchema,
4839
- observationId: stringSchema({ minLength: 1 }),
4840
- transport: transportKindSchema,
4841
- guardIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4842
- workflow: arraySchema(opensteerReverseWorkflowStepSchema),
4843
- resolvers: arraySchema(opensteerExecutableResolverSchema),
4844
- validators: arraySchema(opensteerValidationRuleSchema),
4845
- stateSnapshots: arraySchema(opensteerStateSnapshotSchema),
4846
- requirements: opensteerReversePackageRequirementsSchema,
4847
- requestPlanId: stringSchema({ minLength: 1 }),
4848
- unresolvedRequirements: arraySchema(opensteerReverseRequirementSchema),
4849
- suggestedEdits: arraySchema(opensteerReverseSuggestedEditSchema),
4850
- attachedTraceIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4851
- attachedArtifactIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4852
- attachedRecordIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4853
- notes: stringSchema({ minLength: 1 }),
4854
- parentPackageId: stringSchema({ minLength: 1 })
4855
- },
4856
- {
4857
- title: "OpensteerReversePackagePayload",
4858
- required: [
4859
- "kind",
4860
- "readiness",
4861
- "caseId",
4862
- "objective",
4863
- "source",
4864
- "sourceRecordId",
4865
- "guardIds",
4866
- "workflow",
4867
- "resolvers",
4868
- "validators",
4869
- "stateSnapshots",
4870
- "requirements",
4871
- "unresolvedRequirements",
4872
- "suggestedEdits",
4873
- "attachedTraceIds",
4874
- "attachedArtifactIds",
4875
- "attachedRecordIds"
4876
- ]
4877
- }
4878
- );
4879
- var opensteerReversePackageRecordSchema = objectSchema(
4880
- {
4881
- id: stringSchema({ minLength: 1 }),
4882
- key: stringSchema({ minLength: 1 }),
4883
- version: stringSchema({ minLength: 1 }),
4884
- createdAt: integerSchema({ minimum: 0 }),
4885
- updatedAt: integerSchema({ minimum: 0 }),
4886
- contentHash: stringSchema({ minLength: 1 }),
4887
- tags: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
4888
- provenance: opensteerRegistryProvenanceSchema,
4889
- payload: opensteerReversePackagePayloadSchema
4890
- },
4891
- {
4892
- title: "OpensteerReversePackageRecord",
4893
- required: ["id", "key", "version", "createdAt", "updatedAt", "contentHash", "tags", "payload"]
4894
- }
4895
- );
4896
- var opensteerReverseCandidateReportItemSchema = objectSchema(
4897
- {
4898
- candidateId: stringSchema({ minLength: 1 }),
4899
- clusterId: stringSchema({ minLength: 1 }),
4900
- advisoryRank: numberSchema(),
4901
- bodyCodec: opensteerBodyCodecDescriptorSchema,
4902
- summary: stringSchema({ minLength: 1 }),
4903
- advisoryTags: arraySchema(opensteerReverseAdvisoryTagSchema, { uniqueItems: true }),
4904
- constraints: arraySchema(opensteerReverseConstraintKindSchema, { uniqueItems: true }),
4905
- signals: opensteerReverseAdvisorySignalsSchema,
4906
- reasons: arraySchema(stringSchema({ minLength: 1 }))
4907
- },
4908
- {
4909
- title: "OpensteerReverseCandidateAdvisoryItem",
4910
- required: [
4911
- "candidateId",
4912
- "clusterId",
4913
- "advisoryRank",
4914
- "bodyCodec",
4915
- "summary",
4916
- "advisoryTags",
4917
- "constraints",
4918
- "signals",
4919
- "reasons"
4920
- ]
4921
- }
4922
- );
4923
- var opensteerReverseDiscoverySummaryCountsSchema = objectSchema(
4924
- {
4925
- hosts: recordSchema(integerSchema({ minimum: 0 }), { title: "OpensteerReverseSummaryHosts" }),
4926
- channels: recordSchema(integerSchema({ minimum: 0 }), {
4927
- title: "OpensteerReverseSummaryChannels"
4928
- }),
4929
- resourceTypes: recordSchema(integerSchema({ minimum: 0 }), {
4930
- title: "OpensteerReverseSummaryResourceTypes"
4931
- }),
4932
- advisoryTags: recordSchema(integerSchema({ minimum: 0 }), {
4933
- title: "OpensteerReverseSummaryAdvisoryTags"
4934
- }),
4935
- constraints: recordSchema(integerSchema({ minimum: 0 }), {
4936
- title: "OpensteerReverseSummaryConstraints"
4937
- }),
4938
- relationKinds: recordSchema(integerSchema({ minimum: 0 }), {
4939
- title: "OpensteerReverseSummaryRelationKinds"
4940
- })
4941
- },
4942
- {
4943
- title: "OpensteerReverseDiscoverySummaryCounts",
4944
- required: [
4945
- "hosts",
4946
- "channels",
4947
- "resourceTypes",
4948
- "advisoryTags",
4949
- "constraints",
4950
- "relationKinds"
4951
- ]
4952
- }
4953
- );
4954
- var opensteerReverseReportPayloadSchema = objectSchema(
4955
- {
4956
- kind: opensteerReverseReportKindSchema,
4957
- caseId: stringSchema({ minLength: 1 }),
4958
- objective: stringSchema({ minLength: 1 }),
4959
- packageId: stringSchema({ minLength: 1 }),
4960
- packageKind: opensteerReversePackageKindSchema,
4961
- packageReadiness: opensteerReversePackageReadinessSchema,
4962
- observations: arraySchema(opensteerReverseObservationRecordSchema),
4963
- observationClusters: arraySchema(opensteerObservationClusterSchema),
4964
- observedRecords: arraySchema(opensteerReverseObservedRecordSchema),
4965
- guards: arraySchema(opensteerReverseGuardRecordSchema),
4966
- stateDeltas: arraySchema(opensteerStateDeltaSchema),
4967
- summaryCounts: opensteerReverseDiscoverySummaryCountsSchema,
4968
- candidateAdvisories: arraySchema(opensteerReverseCandidateReportItemSchema),
4969
- query: objectSchema(
4970
- {
4971
- view: opensteerReverseQueryViewSchema,
4972
- filters: objectSchema(
4973
- {
4974
- recordId: stringSchema({ minLength: 1 }),
4975
- clusterId: stringSchema({ minLength: 1 }),
4976
- candidateId: stringSchema({ minLength: 1 }),
4977
- host: stringSchema({ minLength: 1 }),
4978
- path: stringSchema({ minLength: 1 }),
4979
- method: stringSchema({ minLength: 1 }),
4980
- status: stringSchema({ minLength: 1 }),
4981
- resourceType: stringSchema({ minLength: 1 }),
4982
- channel: opensteerReverseChannelKindSchema,
4983
- boundary: opensteerReverseCandidateBoundarySchema,
4984
- advisoryTag: opensteerReverseAdvisoryTagSchema,
4985
- constraint: opensteerReverseConstraintKindSchema,
4986
- bodyCodec: opensteerBodyCodecKindSchema,
4987
- relationKind: opensteerObservationClusterRelationshipKindSchema,
4988
- hasGuards: { type: "boolean" },
4989
- hasResolvers: { type: "boolean" },
4990
- artifactId: stringSchema({ minLength: 1 }),
4991
- stateSnapshotId: stringSchema({ minLength: 1 }),
4992
- traceId: stringSchema({ minLength: 1 }),
4993
- evidenceRef: stringSchema({ minLength: 1 }),
4994
- text: stringSchema({ minLength: 1 })
4995
- },
4996
- {
4997
- title: "OpensteerReverseReportQueryFilters"
4998
- }
4999
- ),
5000
- sort: objectSchema(
5001
- {
5002
- preset: opensteerReverseSortPresetSchema,
5003
- keys: arraySchema(
5004
- objectSchema(
5005
- {
5006
- key: opensteerReverseSortKeySchema,
5007
- direction: opensteerReverseSortDirectionSchema
5008
- },
5009
- {
5010
- title: "OpensteerReverseReportQuerySortTerm",
5011
- required: ["key"]
5012
- }
5013
- ),
5014
- { minItems: 1 }
5015
- )
5016
- },
5017
- {
5018
- title: "OpensteerReverseReportQuerySort"
5019
- }
5020
- ),
5021
- limit: integerSchema({ minimum: 1 }),
5022
- totalCount: integerSchema({ minimum: 0 }),
5023
- nextCursor: stringSchema({ minLength: 1 }),
5024
- resultIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true })
5025
- },
5026
- {
5027
- title: "OpensteerReverseQuerySnapshot",
5028
- required: ["view", "sort", "limit", "totalCount", "resultIds"]
5029
- }
5030
- ),
5031
- experiments: arraySchema(opensteerReverseExperimentRecordSchema),
5032
- replayRuns: arraySchema(opensteerReverseReplayRunRecordSchema),
5033
- unresolvedRequirements: arraySchema(opensteerReverseRequirementSchema),
5034
- suggestedEdits: arraySchema(opensteerReverseSuggestedEditSchema),
5035
- linkedNetworkRecordIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5036
- linkedInteractionTraceIds: arraySchema(stringSchema({ minLength: 1 }), {
5037
- uniqueItems: true
5038
- }),
5039
- linkedArtifactIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5040
- linkedStateSnapshotIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5041
- package: opensteerReversePackageRecordSchema
5042
- },
5043
- {
5044
- title: "OpensteerReverseReportPayload",
5045
- required: [
5046
- "kind",
5047
- "caseId",
5048
- "objective",
5049
- "observations",
5050
- "observationClusters",
5051
- "observedRecords",
5052
- "guards",
5053
- "stateDeltas",
5054
- "summaryCounts",
5055
- "candidateAdvisories",
5056
- "experiments",
5057
- "replayRuns",
5058
- "linkedNetworkRecordIds",
5059
- "linkedInteractionTraceIds",
5060
- "linkedArtifactIds",
5061
- "linkedStateSnapshotIds"
5062
- ]
5063
- }
5064
- );
5065
- var opensteerReverseReportRecordSchema = objectSchema(
5066
- {
5067
- id: stringSchema({ minLength: 1 }),
5068
- key: stringSchema({ minLength: 1 }),
5069
- version: stringSchema({ minLength: 1 }),
5070
- createdAt: integerSchema({ minimum: 0 }),
5071
- updatedAt: integerSchema({ minimum: 0 }),
5072
- contentHash: stringSchema({ minLength: 1 }),
5073
- tags: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5074
- provenance: opensteerRegistryProvenanceSchema,
5075
- payload: opensteerReverseReportPayloadSchema
5076
- },
5077
- {
5078
- title: "OpensteerReverseReportRecord",
5079
- required: ["id", "key", "version", "createdAt", "updatedAt", "contentHash", "tags", "payload"]
5080
- }
5081
- );
5082
- var opensteerReverseNetworkFilterSchema = objectSchema(
5083
- {
5084
- url: stringSchema({ minLength: 1 }),
5085
- hostname: stringSchema({ minLength: 1 }),
5086
- path: stringSchema({ minLength: 1 }),
5087
- method: stringSchema({ minLength: 1 }),
5088
- resourceType: stringSchema({ minLength: 1 }),
5089
- includeBodies: { type: "boolean" }
5090
- },
5091
- {
5092
- title: "OpensteerReverseCaptureNetworkFilter"
5093
- }
5094
- );
5095
- var opensteerReverseQueryFiltersSchema = objectSchema(
5096
- {
5097
- recordId: stringSchema({ minLength: 1 }),
5098
- clusterId: stringSchema({ minLength: 1 }),
5099
- candidateId: stringSchema({ minLength: 1 }),
5100
- host: stringSchema({ minLength: 1 }),
5101
- path: stringSchema({ minLength: 1 }),
5102
- method: stringSchema({ minLength: 1 }),
5103
- status: stringSchema({ minLength: 1 }),
5104
- resourceType: stringSchema({ minLength: 1 }),
5105
- channel: opensteerReverseChannelKindSchema,
5106
- boundary: opensteerReverseCandidateBoundarySchema,
5107
- advisoryTag: opensteerReverseAdvisoryTagSchema,
5108
- constraint: opensteerReverseConstraintKindSchema,
5109
- bodyCodec: opensteerBodyCodecKindSchema,
5110
- relationKind: opensteerObservationClusterRelationshipKindSchema,
5111
- hasGuards: { type: "boolean" },
5112
- hasResolvers: { type: "boolean" },
5113
- artifactId: stringSchema({ minLength: 1 }),
5114
- stateSnapshotId: stringSchema({ minLength: 1 }),
5115
- traceId: stringSchema({ minLength: 1 }),
5116
- evidenceRef: stringSchema({ minLength: 1 }),
5117
- text: stringSchema({ minLength: 1 })
5118
- },
5119
- {
5120
- title: "OpensteerReverseQueryFilters"
5121
- }
5122
- );
5123
- var opensteerReverseQuerySortSchema = objectSchema(
5124
- {
5125
- preset: opensteerReverseSortPresetSchema,
5126
- keys: arraySchema(
5127
- objectSchema(
5128
- {
5129
- key: opensteerReverseSortKeySchema,
5130
- direction: opensteerReverseSortDirectionSchema
5131
- },
5132
- {
5133
- title: "OpensteerReverseSortTerm",
5134
- required: ["key"]
5135
- }
5136
- ),
5137
- { minItems: 1 }
5138
- )
5139
- },
5140
- {
5141
- title: "OpensteerReverseQuerySort"
5142
- }
5143
- );
5144
- var opensteerReverseQuerySnapshotSchema = objectSchema(
5145
- {
5146
- view: opensteerReverseQueryViewSchema,
5147
- filters: opensteerReverseQueryFiltersSchema,
5148
- sort: opensteerReverseQuerySortSchema,
5149
- limit: integerSchema({ minimum: 1, maximum: 200 }),
5150
- totalCount: integerSchema({ minimum: 0 }),
5151
- nextCursor: stringSchema({ minLength: 1 }),
5152
- resultIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true })
5153
- },
5154
- {
5155
- title: "OpensteerReverseQuerySnapshot",
5156
- required: ["view", "sort", "limit", "totalCount", "resultIds"]
5157
- }
5158
- );
5159
- var opensteerReverseQueryRecordItemSchema = objectSchema(
5160
- {
5161
- record: opensteerReverseObservedRecordSchema,
5162
- candidateIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true })
5163
- },
5164
- {
5165
- title: "OpensteerReverseQueryRecordItem",
5166
- required: ["record", "candidateIds"]
5167
- }
5168
- );
5169
- var opensteerReverseQueryClusterItemSchema = objectSchema(
5170
- {
5171
- cluster: opensteerObservationClusterSchema,
5172
- candidateIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true })
5173
- },
5174
- {
5175
- title: "OpensteerReverseQueryClusterItem",
5176
- required: ["cluster", "candidateIds"]
5177
- }
5178
- );
5179
- var opensteerReverseQueryCandidateItemSchema = objectSchema(
5180
- {
5181
- candidate: opensteerReverseCandidateRecordSchema,
5182
- reasons: arraySchema(stringSchema({ minLength: 1 }))
5183
- },
5184
- {
5185
- title: "OpensteerReverseQueryCandidateItem",
5186
- required: ["candidate", "reasons"]
5187
- }
5188
- );
5189
- objectSchema(
5190
- {
5191
- caseId: stringSchema({ minLength: 1 }),
5192
- key: stringSchema({ minLength: 1 }),
5193
- objective: stringSchema({ minLength: 1 }),
5194
- notes: stringSchema({ minLength: 1 }),
5195
- tags: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5196
- pageRef: pageRefSchema,
5197
- stateSource: opensteerStateSourceKindSchema,
5198
- network: opensteerReverseNetworkFilterSchema,
5199
- includeScripts: { type: "boolean" },
5200
- includeStorage: { type: "boolean" },
5201
- includeSessionStorage: { type: "boolean" },
5202
- includeIndexedDb: { type: "boolean" },
5203
- interactionTraceIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5204
- targetHints: opensteerReverseTargetHintsSchema,
5205
- captureWindowMs: integerSchema({ minimum: 0 }),
5206
- manualCalibration: opensteerReverseManualCalibrationModeSchema
5207
- },
5208
- {
5209
- title: "OpensteerReverseDiscoverInput"
5210
- }
5211
- );
5212
- objectSchema(
5213
- {
5214
- caseId: stringSchema({ minLength: 1 }),
5215
- reportId: stringSchema({ minLength: 1 }),
5216
- summary: objectSchema(
5217
- {
5218
- observationIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5219
- recordCount: integerSchema({ minimum: 0 }),
5220
- clusterCount: integerSchema({ minimum: 0 }),
5221
- candidateCount: integerSchema({ minimum: 0 })
5222
- },
5223
- {
5224
- title: "OpensteerReverseDiscoverSummary",
5225
- required: ["observationIds", "recordCount", "clusterCount", "candidateCount"]
5226
- }
5227
- ),
5228
- index: objectSchema(
5229
- {
5230
- views: arraySchema(opensteerReverseQueryViewSchema, { uniqueItems: true }),
5231
- sortableKeys: arraySchema(opensteerReverseSortKeySchema, { uniqueItems: true }),
5232
- channels: arraySchema(opensteerReverseChannelKindSchema, { uniqueItems: true }),
5233
- hosts: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5234
- relationKinds: arraySchema(opensteerObservationClusterRelationshipKindSchema, {
5235
- uniqueItems: true
5236
- })
5237
- },
5238
- {
5239
- title: "OpensteerReverseDiscoverIndex",
5240
- required: ["views", "sortableKeys", "channels", "hosts", "relationKinds"]
5241
- }
5242
- )
5243
- },
5244
- {
5245
- title: "OpensteerReverseDiscoverOutput",
5246
- required: ["caseId", "reportId", "summary", "index"]
5247
- }
5248
- );
5249
- objectSchema(
5250
- {
5251
- caseId: stringSchema({ minLength: 1 }),
5252
- view: opensteerReverseQueryViewSchema,
5253
- filters: opensteerReverseQueryFiltersSchema,
5254
- sort: opensteerReverseQuerySortSchema,
5255
- limit: integerSchema({ minimum: 1, maximum: 200 }),
5256
- cursor: stringSchema({ minLength: 1 })
5257
- },
5258
- {
5259
- title: "OpensteerReverseQueryInput",
5260
- required: ["caseId"]
5261
- }
5262
- );
5263
- objectSchema(
5264
- {
5265
- caseId: stringSchema({ minLength: 1 }),
5266
- view: opensteerReverseQueryViewSchema,
5267
- query: opensteerReverseQuerySnapshotSchema,
5268
- totalCount: integerSchema({ minimum: 0 }),
5269
- nextCursor: stringSchema({ minLength: 1 }),
5270
- records: arraySchema(opensteerReverseQueryRecordItemSchema),
5271
- clusters: arraySchema(opensteerReverseQueryClusterItemSchema),
5272
- candidates: arraySchema(opensteerReverseQueryCandidateItemSchema)
5273
- },
5274
- {
5275
- title: "OpensteerReverseQueryOutput",
5276
- required: ["caseId", "view", "query", "totalCount"]
5277
- }
5278
- );
5279
- objectSchema(
5280
- {
5281
- caseId: stringSchema({ minLength: 1 }),
5282
- source: objectSchema(
5283
- {
5284
- kind: enumSchema(["record", "candidate"]),
5285
- id: stringSchema({ minLength: 1 })
5286
- },
5287
- {
5288
- title: "OpensteerReversePackageCreateSource",
5289
- required: ["kind", "id"]
5290
- }
5291
- ),
5292
- templateId: stringSchema({ minLength: 1 }),
5293
- key: stringSchema({ minLength: 1 }),
5294
- version: stringSchema({ minLength: 1 }),
5295
- notes: stringSchema({ minLength: 1 })
5296
- },
5297
- {
5298
- title: "OpensteerReversePackageCreateInput",
5299
- required: ["caseId", "source"]
5300
- }
5301
- );
5302
- objectSchema(
5303
- {
5304
- package: opensteerReversePackageRecordSchema,
5305
- report: opensteerReverseReportRecordSchema
5306
- },
5307
- {
5308
- title: "OpensteerReversePackageCreateOutput",
5309
- required: ["package", "report"]
5310
- }
5311
- );
5312
- objectSchema(
5313
- {
5314
- packageId: stringSchema({ minLength: 1 }),
5315
- pageRef: pageRefSchema
5316
- },
5317
- {
5318
- title: "OpensteerReversePackageRunInput",
5319
- required: ["packageId"]
5320
- }
5321
- );
5322
- objectSchema(
5323
- {
5324
- packageId: stringSchema({ minLength: 1 }),
5325
- caseId: stringSchema({ minLength: 1 }),
5326
- source: objectSchema(
5327
- {
5328
- kind: enumSchema(["record", "candidate"]),
5329
- id: stringSchema({ minLength: 1 })
5330
- },
5331
- {
5332
- title: "OpensteerReversePackageRunSource",
5333
- required: ["kind", "id"]
5334
- }
5335
- ),
5336
- candidateId: stringSchema({ minLength: 1 }),
5337
- templateId: stringSchema({ minLength: 1 }),
5338
- success: { type: "boolean" },
5339
- kind: opensteerReversePackageKindSchema,
5340
- readiness: opensteerReversePackageReadinessSchema,
5341
- channel: opensteerReverseChannelKindSchema,
5342
- transport: transportKindSchema,
5343
- stateSource: opensteerStateSourceKindSchema,
5344
- recordId: stringSchema({ minLength: 1 }),
5345
- status: integerSchema({ minimum: 0 }),
5346
- validation: opensteerReverseReplayValidationSchema,
5347
- executedStepIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5348
- failedStepId: stringSchema({ minLength: 1 }),
5349
- bindings: recordSchema({}, { title: "OpensteerReversePackageRunBindings" }),
5350
- replayRunId: stringSchema({ minLength: 1 }),
5351
- unresolvedRequirements: arraySchema(opensteerReverseRequirementSchema),
5352
- suggestedEdits: arraySchema(opensteerReverseSuggestedEditSchema),
5353
- error: stringSchema({ minLength: 1 })
5354
- },
5355
- {
5356
- title: "OpensteerReversePackageRunOutput",
5357
- required: [
5358
- "packageId",
5359
- "source",
5360
- "success",
5361
- "kind",
5362
- "readiness",
5363
- "validation",
5364
- "executedStepIds",
5365
- "bindings",
5366
- "unresolvedRequirements",
5367
- "suggestedEdits"
5368
- ]
5369
- }
5370
- );
5371
- objectSchema(
5372
- {
5373
- packageId: stringSchema({ minLength: 1 }),
5374
- key: stringSchema({ minLength: 1 }),
5375
- version: stringSchema({ minLength: 1 })
5376
- },
5377
- {
5378
- title: "OpensteerReverseExportInput",
5379
- required: ["packageId"]
5380
- }
5381
- );
5382
- objectSchema(
5383
- {
5384
- package: opensteerReversePackageRecordSchema,
5385
- requestPlan: opensteerRequestPlanRecordSchema
5386
- },
5387
- {
5388
- title: "OpensteerReverseExportOutput",
5389
- required: ["package"]
5390
- }
5391
- );
5392
- objectSchema(
5393
- {
5394
- caseId: stringSchema({ minLength: 1 }),
5395
- packageId: stringSchema({ minLength: 1 }),
5396
- reportId: stringSchema({ minLength: 1 }),
5397
- kind: opensteerReverseReportKindSchema
5398
- },
5399
- {
5400
- title: "OpensteerReverseReportInput"
5401
- }
5402
- );
5403
- objectSchema(
5404
- {
5405
- report: opensteerReverseReportRecordSchema
5406
- },
5407
- {
5408
- title: "OpensteerReverseReportOutput",
5409
- required: ["report"]
5410
- }
5411
- );
5412
- objectSchema(
5413
- {
5414
- packageId: stringSchema({ minLength: 1 })
5415
- },
5416
- {
5417
- title: "OpensteerReversePackageGetInput",
5418
- required: ["packageId"]
5419
- }
5420
- );
5421
- objectSchema(
5422
- {
5423
- package: opensteerReversePackageRecordSchema
5424
- },
5425
- {
5426
- title: "OpensteerReversePackageGetOutput",
5427
- required: ["package"]
5428
- }
5429
- );
5430
- objectSchema(
5431
- {
5432
- caseId: stringSchema({ minLength: 1 }),
5433
- key: stringSchema({ minLength: 1 }),
5434
- kind: opensteerReversePackageKindSchema,
5435
- readiness: opensteerReversePackageReadinessSchema
3469
+ {
3470
+ urlPattern: stringSchema({ minLength: 1 }),
3471
+ mode: sandboxAjaxModeSchema,
3472
+ mockResponse: objectSchema(
3473
+ {
3474
+ status: integerSchema({ minimum: 100, maximum: 599 }),
3475
+ headers: recordSchema(stringSchema(), {
3476
+ title: "SandboxAjaxMockHeaders"
3477
+ }),
3478
+ body: stringSchema()
3479
+ },
3480
+ {
3481
+ title: "SandboxAjaxMockResponse",
3482
+ required: ["status"]
3483
+ }
3484
+ )
5436
3485
  },
5437
3486
  {
5438
- title: "OpensteerReversePackageListInput"
3487
+ title: "SandboxAjaxRoute",
3488
+ required: ["urlPattern", "mode"]
5439
3489
  }
5440
3490
  );
5441
- objectSchema(
3491
+ var opensteerScriptSandboxInputSchema = objectSchema(
5442
3492
  {
5443
- packages: arraySchema(opensteerReversePackageRecordSchema)
3493
+ artifactId: stringSchema({ minLength: 1 }),
3494
+ content: stringSchema(),
3495
+ fidelity: sandboxFidelitySchema,
3496
+ ajaxRoutes: arraySchema(sandboxAjaxRouteSchema),
3497
+ cookies: recordSchema(stringSchema(), {
3498
+ title: "SandboxCookies"
3499
+ }),
3500
+ globals: objectSchema(
3501
+ {},
3502
+ {
3503
+ title: "SandboxGlobals",
3504
+ additionalProperties: true
3505
+ }
3506
+ ),
3507
+ timeoutMs: integerSchema({ minimum: 1 }),
3508
+ clockMode: enumSchema(["real", "manual"])
5444
3509
  },
5445
3510
  {
5446
- title: "OpensteerReversePackageListOutput",
5447
- required: ["packages"]
3511
+ title: "OpensteerScriptSandboxInput"
5448
3512
  }
5449
3513
  );
5450
- objectSchema(
3514
+ var sandboxCapturedAjaxCallSchema = objectSchema(
5451
3515
  {
5452
- packageId: stringSchema({ minLength: 1 }),
5453
- key: stringSchema({ minLength: 1 }),
5454
- version: stringSchema({ minLength: 1 }),
5455
- notes: stringSchema({ minLength: 1 }),
5456
- workflow: arraySchema(opensteerReverseWorkflowStepSchema),
5457
- resolvers: arraySchema(opensteerExecutableResolverSchema),
5458
- validators: arraySchema(opensteerValidationRuleSchema),
5459
- attachedTraceIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5460
- attachedArtifactIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5461
- attachedRecordIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true }),
5462
- stateSnapshotIds: arraySchema(stringSchema({ minLength: 1 }), { uniqueItems: true })
3516
+ method: stringSchema({ minLength: 1 }),
3517
+ url: stringSchema({ minLength: 1 }),
3518
+ headers: recordSchema(stringSchema(), {
3519
+ title: "SandboxCapturedAjaxHeaders"
3520
+ }),
3521
+ body: stringSchema(),
3522
+ timestamp: integerSchema({ minimum: 0 })
5463
3523
  },
5464
3524
  {
5465
- title: "OpensteerReversePackagePatchInput",
5466
- required: ["packageId"]
3525
+ title: "SandboxCapturedAjaxCall",
3526
+ required: ["method", "url", "headers", "timestamp"]
5467
3527
  }
5468
3528
  );
5469
- objectSchema(
3529
+ var opensteerScriptSandboxOutputSchema = objectSchema(
5470
3530
  {
5471
- package: opensteerReversePackageRecordSchema,
5472
- report: opensteerReverseReportRecordSchema
3531
+ result: oneOfSchema(
3532
+ [
3533
+ objectSchema({}, { additionalProperties: true }),
3534
+ arraySchema({}),
3535
+ stringSchema(),
3536
+ { type: "number" },
3537
+ enumSchema([true, false, null])
3538
+ ],
3539
+ {
3540
+ title: "SandboxResult"
3541
+ }
3542
+ ),
3543
+ capturedAjax: arraySchema(sandboxCapturedAjaxCallSchema),
3544
+ errors: arraySchema(stringSchema({ minLength: 1 })),
3545
+ durationMs: integerSchema({ minimum: 0 })
5473
3546
  },
5474
3547
  {
5475
- title: "OpensteerReversePackagePatchOutput",
5476
- required: ["package", "report"]
3548
+ title: "OpensteerScriptSandboxOutput",
3549
+ required: ["capturedAjax", "errors", "durationMs"]
5477
3550
  }
5478
3551
  );
5479
3552
 
@@ -6328,12 +4401,12 @@ var opensteerDomExtractInputSchema = defineSchema({
6328
4401
  ),
6329
4402
  anyOf: [defineSchema({ required: ["persist"] }), defineSchema({ required: ["schema"] })]
6330
4403
  });
6331
- var jsonValueSchema3 = recordSchema({}, { title: "JsonValueRecord" });
4404
+ var jsonValueSchema2 = recordSchema({}, { title: "JsonValueRecord" });
6332
4405
  var opensteerDomExtractOutputSchema = objectSchema(
6333
4406
  {
6334
4407
  data: oneOfSchema(
6335
4408
  [
6336
- jsonValueSchema3,
4409
+ jsonValueSchema2,
6337
4410
  arraySchema({}),
6338
4411
  stringSchema(),
6339
4412
  numberSchema(),
@@ -6736,7 +4809,7 @@ var opensteerSemanticOperationSpecificationsBase = [
6736
4809
  }),
6737
4810
  defineSemanticOperationSpec({
6738
4811
  name: "artifact.read",
6739
- description: "Read a persisted artifact by ID so agents can inspect captured scripts, storage, cookies, or snapshots linked from reverse packages and reports.",
4812
+ description: "Read a persisted artifact by ID so agents can inspect captured scripts, storage, cookies, or snapshots linked from recorded workflows.",
6740
4813
  inputSchema: opensteerArtifactReadInputSchema,
6741
4814
  outputSchema: opensteerArtifactReadOutputSchema,
6742
4815
  requiredCapabilities: []
@@ -8056,76 +6129,6 @@ var FilesystemRequestPlanRegistry = class extends FilesystemRegistryStore {
8056
6129
  });
8057
6130
  }
8058
6131
  };
8059
- var FilesystemAuthRecipeRegistry = class extends FilesystemRegistryStore {
8060
- constructor(rootPath) {
8061
- super(rootPath, ["registry", "auth-recipes"]);
8062
- }
8063
- async write(input) {
8064
- const id = normalizeNonEmptyString("id", input.id ?? `auth-recipe:${randomUUID()}`);
8065
- const key = normalizeNonEmptyString("key", input.key);
8066
- const version = normalizeNonEmptyString("version", input.version);
8067
- const createdAt = normalizeTimestamp("createdAt", input.createdAt ?? Date.now());
8068
- const updatedAt = normalizeTimestamp("updatedAt", input.updatedAt ?? createdAt);
8069
- if (updatedAt < createdAt) {
8070
- throw new RangeError("updatedAt must be greater than or equal to createdAt");
8071
- }
8072
- const payload = input.payload;
8073
- const contentHash = sha256Hex(Buffer.from(canonicalJsonString(payload), "utf8"));
8074
- const provenance = normalizeProvenance2(input.provenance);
8075
- const record = {
8076
- id,
8077
- key,
8078
- version,
8079
- createdAt,
8080
- updatedAt,
8081
- contentHash,
8082
- tags: normalizeTags(input.tags),
8083
- ...provenance === void 0 ? {} : { provenance },
8084
- payload
8085
- };
8086
- return this.writeRecord(record);
8087
- }
8088
- async list(input = {}) {
8089
- const key = input.key === void 0 ? void 0 : normalizeNonEmptyString("key", input.key);
8090
- const records = await this.readAllRecords();
8091
- return key === void 0 ? records : records.filter((record) => record.key === key);
8092
- }
8093
- };
8094
- var FilesystemRecipeRegistry = class extends FilesystemRegistryStore {
8095
- constructor(rootPath) {
8096
- super(rootPath, ["registry", "recipes"]);
8097
- }
8098
- async write(input) {
8099
- const id = normalizeNonEmptyString("id", input.id ?? `recipe:${randomUUID()}`);
8100
- const key = normalizeNonEmptyString("key", input.key);
8101
- const version = normalizeNonEmptyString("version", input.version);
8102
- const createdAt = normalizeTimestamp("createdAt", input.createdAt ?? Date.now());
8103
- const updatedAt = normalizeTimestamp("updatedAt", input.updatedAt ?? createdAt);
8104
- if (updatedAt < createdAt) {
8105
- throw new RangeError("updatedAt must be greater than or equal to createdAt");
8106
- }
8107
- const payload = input.payload;
8108
- const contentHash = sha256Hex(Buffer.from(canonicalJsonString(payload), "utf8"));
8109
- const provenance = normalizeProvenance2(input.provenance);
8110
- const record = {
8111
- id,
8112
- key,
8113
- version,
8114
- createdAt,
8115
- updatedAt,
8116
- contentHash,
8117
- tags: normalizeTags(input.tags),
8118
- ...provenance === void 0 ? {} : { provenance },
8119
- payload
8120
- };
8121
- return this.writeRecord(record);
8122
- }
8123
- async list(input = {}) {
8124
- const key = input.key === void 0 ? void 0 : normalizeNonEmptyString("key", input.key);
8125
- const records = await this.readAllRecords();
8126
- return key === void 0 ? records : records.filter((record) => record.key === key);
8127
- }
8128
- };
8129
6132
  var FilesystemInteractionTraceRegistry = class extends FilesystemRegistryStore {
8130
6133
  constructor(rootPath) {
8131
6134
  super(rootPath, ["registry", "interaction-traces"]);
@@ -8161,163 +6164,15 @@ var FilesystemInteractionTraceRegistry = class extends FilesystemRegistryStore {
8161
6164
  return key === void 0 ? records : records.filter((record) => record.key === key);
8162
6165
  }
8163
6166
  };
8164
- var FilesystemReverseCaseRegistry = class extends FilesystemRegistryStore {
8165
- constructor(rootPath) {
8166
- super(rootPath, ["registry", "reverse-cases"]);
8167
- }
8168
- async write(input) {
8169
- const id = normalizeNonEmptyString("id", input.id ?? `reverse-case:${randomUUID()}`);
8170
- const key = normalizeNonEmptyString("key", input.key);
8171
- const version = normalizeNonEmptyString("version", input.version);
8172
- const createdAt = normalizeTimestamp("createdAt", input.createdAt ?? Date.now());
8173
- const updatedAt = normalizeTimestamp("updatedAt", input.updatedAt ?? createdAt);
8174
- if (updatedAt < createdAt) {
8175
- throw new RangeError("updatedAt must be greater than or equal to createdAt");
8176
- }
8177
- const payload = input.payload;
8178
- const contentHash = sha256Hex(Buffer.from(canonicalJsonString(payload), "utf8"));
8179
- const provenance = normalizeProvenance2(input.provenance);
8180
- const record = {
8181
- id,
8182
- key,
8183
- version,
8184
- createdAt,
8185
- updatedAt,
8186
- contentHash,
8187
- tags: normalizeTags(input.tags),
8188
- ...provenance === void 0 ? {} : { provenance },
8189
- payload
8190
- };
8191
- return this.writeRecord(record);
8192
- }
8193
- async list(input = {}) {
8194
- const key = input.key === void 0 ? void 0 : normalizeNonEmptyString("key", input.key);
8195
- const records = await this.readAllRecords();
8196
- return key === void 0 ? records : records.filter((record) => record.key === key);
8197
- }
8198
- async update(input) {
8199
- const id = normalizeNonEmptyString("id", input.id);
8200
- return withFilesystemLock(this.writeLockPath(), async () => {
8201
- const existing = await this.getById(id);
8202
- if (existing === void 0) {
8203
- throw new Error(`registry record ${id} was not found`);
8204
- }
8205
- const nextUpdatedAt = normalizeTimestamp(
8206
- "updatedAt",
8207
- input.updatedAt ?? Math.max(Date.now(), existing.updatedAt)
8208
- );
8209
- if (nextUpdatedAt < existing.createdAt) {
8210
- throw new RangeError("updatedAt must be greater than or equal to createdAt");
8211
- }
8212
- const nextPayload = input.payload;
8213
- const nextProvenance = normalizeProvenance2(input.provenance ?? existing.provenance);
8214
- const nextRecord = {
8215
- ...existing,
8216
- updatedAt: nextUpdatedAt,
8217
- contentHash: sha256Hex(Buffer.from(canonicalJsonString(nextPayload), "utf8")),
8218
- tags: normalizeTags(input.tags ?? existing.tags),
8219
- ...nextProvenance === void 0 ? {} : { provenance: nextProvenance },
8220
- payload: nextPayload
8221
- };
8222
- await writeJsonFileAtomic(this.recordPath(id), nextRecord);
8223
- return nextRecord;
8224
- });
8225
- }
8226
- };
8227
- var FilesystemReversePackageRegistry = class extends FilesystemRegistryStore {
8228
- constructor(rootPath) {
8229
- super(rootPath, ["registry", "reverse-packages"]);
8230
- }
8231
- async write(input) {
8232
- const id = normalizeNonEmptyString("id", input.id ?? `reverse-package:${randomUUID()}`);
8233
- const key = normalizeNonEmptyString("key", input.key);
8234
- const version = normalizeNonEmptyString("version", input.version);
8235
- const createdAt = normalizeTimestamp("createdAt", input.createdAt ?? Date.now());
8236
- const updatedAt = normalizeTimestamp("updatedAt", input.updatedAt ?? createdAt);
8237
- if (updatedAt < createdAt) {
8238
- throw new RangeError("updatedAt must be greater than or equal to createdAt");
8239
- }
8240
- const payload = input.payload;
8241
- const contentHash = sha256Hex(Buffer.from(canonicalJsonString(payload), "utf8"));
8242
- const provenance = normalizeProvenance2(input.provenance);
8243
- const record = {
8244
- id,
8245
- key,
8246
- version,
8247
- createdAt,
8248
- updatedAt,
8249
- contentHash,
8250
- tags: normalizeTags(input.tags),
8251
- ...provenance === void 0 ? {} : { provenance },
8252
- payload
8253
- };
8254
- return this.writeRecord(record);
8255
- }
8256
- async list(input = {}) {
8257
- const key = input.key === void 0 ? void 0 : normalizeNonEmptyString("key", input.key);
8258
- const records = await this.readAllRecords();
8259
- return key === void 0 ? records : records.filter((record) => record.key === key);
8260
- }
8261
- };
8262
- var FilesystemReverseReportRegistry = class extends FilesystemRegistryStore {
8263
- constructor(rootPath) {
8264
- super(rootPath, ["registry", "reverse-reports"]);
8265
- }
8266
- async write(input) {
8267
- const id = normalizeNonEmptyString("id", input.id ?? `reverse-report:${randomUUID()}`);
8268
- const key = normalizeNonEmptyString("key", input.key);
8269
- const version = normalizeNonEmptyString("version", input.version);
8270
- const createdAt = normalizeTimestamp("createdAt", input.createdAt ?? Date.now());
8271
- const updatedAt = normalizeTimestamp("updatedAt", input.updatedAt ?? createdAt);
8272
- if (updatedAt < createdAt) {
8273
- throw new RangeError("updatedAt must be greater than or equal to createdAt");
8274
- }
8275
- const payload = input.payload;
8276
- const contentHash = sha256Hex(Buffer.from(canonicalJsonString(payload), "utf8"));
8277
- const provenance = normalizeProvenance2(input.provenance);
8278
- const record = {
8279
- id,
8280
- key,
8281
- version,
8282
- createdAt,
8283
- updatedAt,
8284
- contentHash,
8285
- tags: normalizeTags(input.tags),
8286
- ...provenance === void 0 ? {} : { provenance },
8287
- payload
8288
- };
8289
- return this.writeRecord(record);
8290
- }
8291
- async list(input = {}) {
8292
- const key = input.key === void 0 ? void 0 : normalizeNonEmptyString("key", input.key);
8293
- const records = await this.readAllRecords();
8294
- return key === void 0 ? records : records.filter((record) => record.key === key);
8295
- }
8296
- };
8297
6167
  function createDescriptorRegistry(rootPath) {
8298
6168
  return new FilesystemDescriptorRegistry(rootPath);
8299
6169
  }
8300
6170
  function createRequestPlanRegistry(rootPath) {
8301
6171
  return new FilesystemRequestPlanRegistry(rootPath);
8302
6172
  }
8303
- function createAuthRecipeRegistry(rootPath) {
8304
- return new FilesystemAuthRecipeRegistry(rootPath);
8305
- }
8306
- function createRecipeRegistry(rootPath) {
8307
- return new FilesystemRecipeRegistry(rootPath);
8308
- }
8309
6173
  function createInteractionTraceRegistry(rootPath) {
8310
6174
  return new FilesystemInteractionTraceRegistry(rootPath);
8311
6175
  }
8312
- function createReverseCaseRegistry(rootPath) {
8313
- return new FilesystemReverseCaseRegistry(rootPath);
8314
- }
8315
- function createReversePackageRegistry(rootPath) {
8316
- return new FilesystemReversePackageRegistry(rootPath);
8317
- }
8318
- function createReverseReportRegistry(rootPath) {
8319
- return new FilesystemReverseReportRegistry(rootPath);
8320
- }
8321
6176
  var TAG_DELIMITER = "";
8322
6177
  var NODE_SQLITE_SPECIFIER = `node:${"sqlite"}`;
8323
6178
  var SAVED_NETWORK_SQLITE_SUPPORT_ERROR = "Saved-network operations require Node's built-in SQLite support. Use a Node runtime with node:sqlite enabled.";
@@ -9230,20 +7085,10 @@ async function createFilesystemOpensteerWorkspace(options) {
9230
7085
  await descriptors.initialize();
9231
7086
  const requestPlans = createRequestPlanRegistry(options.rootPath);
9232
7087
  await requestPlans.initialize();
9233
- const authRecipes = createAuthRecipeRegistry(options.rootPath);
9234
- await authRecipes.initialize();
9235
- const recipes = createRecipeRegistry(options.rootPath);
9236
- await recipes.initialize();
9237
7088
  const savedNetwork = createSavedNetworkStore(options.rootPath);
9238
7089
  await savedNetwork.initialize();
9239
- const reverseCases = createReverseCaseRegistry(options.rootPath);
9240
- await reverseCases.initialize();
9241
7090
  const interactionTraces = createInteractionTraceRegistry(options.rootPath);
9242
7091
  await interactionTraces.initialize();
9243
- const reversePackages = createReversePackageRegistry(options.rootPath);
9244
- await reversePackages.initialize();
9245
- const reverseReports = createReverseReportRegistry(options.rootPath);
9246
- await reverseReports.initialize();
9247
7092
  const traces = createTraceStore(options.rootPath, artifacts);
9248
7093
  await traces.initialize();
9249
7094
  const observations = createObservationStore(options.rootPath, artifacts);
@@ -9269,13 +7114,8 @@ async function createFilesystemOpensteerWorkspace(options) {
9269
7114
  registry: {
9270
7115
  descriptors,
9271
7116
  requestPlans,
9272
- authRecipes,
9273
- recipes,
9274
7117
  savedNetwork,
9275
- reverseCases,
9276
- interactionTraces,
9277
- reversePackages,
9278
- reverseReports
7118
+ interactionTraces
9279
7119
  },
9280
7120
  lock(task) {
9281
7121
  return withFilesystemLock(lockPath, task);