@runtypelabs/sdk 4.19.2 → 4.20.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -143,6 +143,7 @@ __export(index_exports, {
143
143
  parseOffloadedOutputId: () => parseOffloadedOutputId,
144
144
  parseSSEChunk: () => parseSSEChunk,
145
145
  processStream: () => processStream,
146
+ pullFpo: () => pullFpo,
146
147
  registerWorkflowHook: () => registerWorkflowHook,
147
148
  resolveStallStopAfter: () => resolveStallStopAfter,
148
149
  resolveWorkflowHook: () => resolveWorkflowHook,
@@ -4426,13 +4427,17 @@ function defineFpo(fpo) {
4426
4427
  return fpo;
4427
4428
  }
4428
4429
  async function ensureFpo(client, fpo, options = {}) {
4429
- const { dryRun, onConflict } = options;
4430
+ const { dryRun, onConflict, prune } = options;
4430
4431
  return client.post("/products/ensure-fpo", {
4431
4432
  fpo,
4432
4433
  ...dryRun ? { dryRun: true } : {},
4433
- ...onConflict ? { onConflict } : {}
4434
+ ...onConflict ? { onConflict } : {},
4435
+ ...prune ? { prune: true } : {}
4434
4436
  });
4435
4437
  }
4438
+ async function pullFpo(client, name) {
4439
+ return client.get("/products/pull-fpo", { name });
4440
+ }
4436
4441
 
4437
4442
  // src/products-namespace.ts
4438
4443
  var ProductsNamespace = class {
@@ -4490,6 +4495,24 @@ var ProductsNamespace = class {
4490
4495
  async ensureFpo(fpo, options = {}) {
4491
4496
  return ensureFpo(this.getClient(), fpo, options);
4492
4497
  }
4498
+ /**
4499
+ * Reconstruct a self-contained Full Product Object from the live product graph
4500
+ * (resolved by name) — the absorb-drift direction of `ensureFpo`. Feeding the
4501
+ * returned `fpo` back into `ensureFpo` converges to `unchanged`.
4502
+ *
4503
+ * records/schedules/secrets are not reconstructed and `tools` is emitted empty
4504
+ * (tool refs are portable `tool:<name>`); inspect `result.warnings` for
4505
+ * per-pull caveats.
4506
+ *
4507
+ * @example
4508
+ * ```typescript
4509
+ * const { fpo } = await Runtype.products.pullFpo('Support Copilot')
4510
+ * await Runtype.products.ensureFpo(fpo, { dryRun: true }) // → result: 'unchanged'
4511
+ * ```
4512
+ */
4513
+ async pullFpo(name) {
4514
+ return pullFpo(this.getClient(), name);
4515
+ }
4493
4516
  };
4494
4517
 
4495
4518
  // src/surfaces-ensure.ts
@@ -5228,7 +5251,7 @@ var Runtype = class {
5228
5251
 
5229
5252
  // src/version.ts
5230
5253
  var FALLBACK_VERSION = "0.0.0";
5231
- var SDK_VERSION = "4.19.2".length > 0 ? "4.19.2" : FALLBACK_VERSION;
5254
+ var SDK_VERSION = "4.20.0".length > 0 ? "4.20.0" : FALLBACK_VERSION;
5232
5255
  var RUNTYPE_CLIENT_KIND = "sdk";
5233
5256
  var SDK_USER_AGENT = `runtype-sdk/${SDK_VERSION} (typescript)`;
5234
5257
 
@@ -12975,6 +12998,7 @@ var STEP_TYPE_TO_METHOD = {
12975
12998
  parseOffloadedOutputId,
12976
12999
  parseSSEChunk,
12977
13000
  processStream,
13001
+ pullFpo,
12978
13002
  registerWorkflowHook,
12979
13003
  resolveStallStopAfter,
12980
13004
  resolveWorkflowHook,