deepline 0.3.74 → 0.3.75
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/bundling-sources/sdk/src/client.ts +279 -21
- package/dist/bundling-sources/sdk/src/config.ts +21 -3
- package/dist/bundling-sources/sdk/src/index.ts +1 -0
- package/dist/bundling-sources/sdk/src/play.ts +3 -6
- package/dist/bundling-sources/sdk/src/release.ts +1 -1
- package/dist/bundling-sources/sdk/src/types.ts +3 -2
- package/dist/bundling-sources/shared_libs/monitors/deactivation-reasons.ts +186 -0
- package/dist/bundling-sources/shared_libs/monitors/monitor-fleet-limits.ts +41 -0
- package/dist/bundling-sources/shared_libs/play-runtime/async-operation.ts +213 -55
- package/dist/bundling-sources/shared_libs/play-runtime/context.ts +172 -299
- package/dist/bundling-sources/shared_libs/play-runtime/ctx-types.ts +10 -0
- package/dist/bundling-sources/shared_libs/play-runtime/durable-call-cache.ts +13 -32
- package/dist/bundling-sources/shared_libs/play-runtime/governor/governor.ts +5 -1
- package/dist/bundling-sources/shared_libs/play-runtime/resource-governor.ts +7 -2
- package/dist/bundling-sources/shared_libs/play-runtime/runner-backends/backends/daytona-lifecycle.ts +11 -2
- package/dist/bundling-sources/shared_libs/play-runtime/runtime-incident-drills.ts +1 -1
- package/dist/bundling-sources/shared_libs/play-runtime/suspension.ts +16 -0
- package/dist/bundling-sources/shared_libs/play-runtime/tool-call/native-batch.ts +1 -0
- package/dist/bundling-sources/shared_libs/play-runtime/tool-call/testkit.ts +5 -4
- package/dist/bundling-sources/shared_libs/play-runtime/tool-execute-retry-policy.ts +12 -2
- package/dist/bundling-sources/shared_libs/plays/authoring-contract.ts +1 -1
- package/dist/bundling-sources/shared_libs/plays/deployment-status.ts +74 -0
- package/dist/cli/index.js +918 -167
- package/dist/cli/index.mjs +918 -167
- package/dist/{compiler-manifest-CMNgA_JQ.d.mts → compiler-manifest-Dbov16F7.d.mts} +1 -1
- package/dist/{compiler-manifest-CMNgA_JQ.d.ts → compiler-manifest-Dbov16F7.d.ts} +1 -1
- package/dist/index.d.mts +176 -23
- package/dist/index.d.ts +176 -23
- package/dist/index.js +109 -12
- package/dist/index.mjs +109 -12
- package/dist/install-integrity.json +4 -2
- package/dist/plays/bundle-play-file.d.mts +2 -2
- package/dist/plays/bundle-play-file.d.ts +2 -2
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference path="./text-imports.d.ts" />
|
|
2
|
-
import { c as PlayCompilerManifest, i as PlayAuthoringColumnMap, j as PlayAuthoringColumnResolver, k as PlayAuthoringRuntimeContext, l as PlayAuthoringConditionalStepResolver, m as PlayAuthoringCsvInput, n as PlayAuthoringCsvOptions, o as PlayAuthoringDatasetBuilder, p as PlayAuthoringDatasetColumnDefinition, q as PlayAuthoringDatasetColumnRunInput, T as ToolExecuteResult, r as PlayAuthoringReferenceLike, s as PlayReturnObject$1, t as PlayAuthoringDefineConfig, u as PlayAuthoringDefinedPlay, v as PlayAuthoringFetchOptions, w as PlayAuthoringFileInput, x as PlayAuthoringBindings, y as PlayAuthoringCallExecution, z as PlayAuthoringCallOptions, A as PlayAuthoringFetchResponse, B as PlayAuthoringInputContract, C as PlayAuthoringStepProgramStep, D as PlayAuthoringRuntimeStepOptions, E as PlaySqlListenerDeclaration, F as PlaySqlListenerEvent, G as PlaySqlListenerOperation, H as PlaySqlQuery, I as PlayAuthoringStepOptions, J as PlayAuthoringStepProgram, K as PlayAuthoringStepProgramResolver, L as PlayAuthoringStepResolver, M as PlayToolExecutionRequest, N as PlayAuthoringStepProgramOptions, O as DeeplineError, Q as ToolExecutionError, R as ToolExecutionErrorOptions } from './compiler-manifest-
|
|
3
|
-
export { S as CtxFetchHttpError, U as DEEPLINE_EXTRACTOR_TARGETS, V as DEEPLINE_EXTRACTOR_TARGET_DEFINITIONS, W as DeeplineEmailStatusGetterValue, X as DeeplineExtractorTarget, Y as DeeplineGetterValue, Z as DeeplineGetterValueMap, _ as JOB_CHANGE_STATUS_VALUES, $ as JobChangeStatus, a0 as PHONE_STATUS_VALUES, a1 as PhoneStatus, a2 as PlayDataset, a3 as PlayDatasetInput, a4 as PreviousCell, a5 as ProviderTransientError, a6 as ProviderTransientErrorCategory, a7 as ProviderUnavailableError, a8 as ProviderUnavailableReason, a9 as ToolExecutionErrorCategory, aa as ToolExecutionErrorOrigin, ab as ToolExecutionFailureV1, ac as ToolExecutionNetworkKind, ad as ToolExecutionNetworkScope, ae as ToolExecutionPublicDetails, af as getProviderUnavailableReason, ag as isDeeplineExtractorTarget, ah as isProviderUnavailable, ai as isProviderWaterfallUnavailableError } from './compiler-manifest-
|
|
2
|
+
import { c as PlayCompilerManifest, i as PlayAuthoringColumnMap, j as PlayAuthoringColumnResolver, k as PlayAuthoringRuntimeContext, l as PlayAuthoringConditionalStepResolver, m as PlayAuthoringCsvInput, n as PlayAuthoringCsvOptions, o as PlayAuthoringDatasetBuilder, p as PlayAuthoringDatasetColumnDefinition, q as PlayAuthoringDatasetColumnRunInput, T as ToolExecuteResult, r as PlayAuthoringReferenceLike, s as PlayReturnObject$1, t as PlayAuthoringDefineConfig, u as PlayAuthoringDefinedPlay, v as PlayAuthoringFetchOptions, w as PlayAuthoringFileInput, x as PlayAuthoringBindings, y as PlayAuthoringCallExecution, z as PlayAuthoringCallOptions, A as PlayAuthoringFetchResponse, B as PlayAuthoringInputContract, C as PlayAuthoringStepProgramStep, D as PlayAuthoringRuntimeStepOptions, E as PlaySqlListenerDeclaration, F as PlaySqlListenerEvent, G as PlaySqlListenerOperation, H as PlaySqlQuery, I as PlayAuthoringStepOptions, J as PlayAuthoringStepProgram, K as PlayAuthoringStepProgramResolver, L as PlayAuthoringStepResolver, M as PlayToolExecutionRequest, N as PlayAuthoringStepProgramOptions, O as DeeplineError, Q as ToolExecutionError, R as ToolExecutionErrorOptions } from './compiler-manifest-Dbov16F7.js';
|
|
3
|
+
export { S as CtxFetchHttpError, U as DEEPLINE_EXTRACTOR_TARGETS, V as DEEPLINE_EXTRACTOR_TARGET_DEFINITIONS, W as DeeplineEmailStatusGetterValue, X as DeeplineExtractorTarget, Y as DeeplineGetterValue, Z as DeeplineGetterValueMap, _ as JOB_CHANGE_STATUS_VALUES, $ as JobChangeStatus, a0 as PHONE_STATUS_VALUES, a1 as PhoneStatus, a2 as PlayDataset, a3 as PlayDatasetInput, a4 as PreviousCell, a5 as ProviderTransientError, a6 as ProviderTransientErrorCategory, a7 as ProviderUnavailableError, a8 as ProviderUnavailableReason, a9 as ToolExecutionErrorCategory, aa as ToolExecutionErrorOrigin, ab as ToolExecutionFailureV1, ac as ToolExecutionNetworkKind, ad as ToolExecutionNetworkScope, ae as ToolExecutionPublicDetails, af as getProviderUnavailableReason, ag as isDeeplineExtractorTarget, ah as isProviderUnavailable, ai as isProviderWaterfallUnavailableError } from './compiler-manifest-Dbov16F7.js';
|
|
4
4
|
import '@sinclair/typebox';
|
|
5
5
|
|
|
6
6
|
declare const FIXTURE_BEHAVIOR_VERSION: 1;
|
|
@@ -406,8 +406,9 @@ interface ToolDefinition {
|
|
|
406
406
|
term?: string;
|
|
407
407
|
}>;
|
|
408
408
|
/**
|
|
409
|
-
* Whether this tool is callable in the current workspace. `false`
|
|
410
|
-
*
|
|
409
|
+
* Whether this tool is callable in the current workspace. `false` when a
|
|
410
|
+
* required customer credential is missing or a managed provider is
|
|
411
|
+
* temporarily unavailable.
|
|
411
412
|
*/
|
|
412
413
|
connected?: boolean;
|
|
413
414
|
/** Whether the tool can be executed. Exact lookup may return non-callable deprecated aliases. */
|
|
@@ -2461,6 +2462,8 @@ type MonitorsListResult = {
|
|
|
2461
2462
|
monitors?: MonitorListEntry[];
|
|
2462
2463
|
total?: number;
|
|
2463
2464
|
returned?: number;
|
|
2465
|
+
has_more?: boolean;
|
|
2466
|
+
/** @deprecated Use has_more. */
|
|
2464
2467
|
is_truncated?: boolean;
|
|
2465
2468
|
next_cursor?: string | null;
|
|
2466
2469
|
status_filter_applied?: string;
|
|
@@ -2478,6 +2481,7 @@ type MonitorsListOptions = {
|
|
|
2478
2481
|
limit?: number | string;
|
|
2479
2482
|
/** Page past a truncated result using a prior response's `next_cursor`. */
|
|
2480
2483
|
cursor?: string;
|
|
2484
|
+
/** @deprecated Accepted as a no-op for compatibility. */
|
|
2481
2485
|
compact?: boolean;
|
|
2482
2486
|
/** Include bounded current SQL-listener delivery/run health (requires limit <= 20). */
|
|
2483
2487
|
includeConsumers?: boolean;
|
|
@@ -2543,6 +2547,14 @@ type MonitorUpdateResult = {
|
|
|
2543
2547
|
type MonitorDeleteResult = Record<string, unknown>;
|
|
2544
2548
|
type MonitorReactivateResult = Record<string, unknown>;
|
|
2545
2549
|
type MonitorTestResult = Record<string, unknown>;
|
|
2550
|
+
/**
|
|
2551
|
+
* @deprecated Monitor tests are always validation-only. `dispatch` and
|
|
2552
|
+
* `validationOnly: false` are rejected before a request is made.
|
|
2553
|
+
*/
|
|
2554
|
+
type MonitorTestOptions = {
|
|
2555
|
+
validationOnly?: boolean;
|
|
2556
|
+
dispatch?: boolean;
|
|
2557
|
+
};
|
|
2546
2558
|
type MonitorValidateResult = Record<string, unknown>;
|
|
2547
2559
|
/**
|
|
2548
2560
|
* Server-owned fleet response envelope.
|
|
@@ -2554,7 +2566,7 @@ type MonitorValidateResult = Record<string, unknown>;
|
|
|
2554
2566
|
*/
|
|
2555
2567
|
type MonitorFleetResult = Record<string, unknown>;
|
|
2556
2568
|
/** Server-computed fleet verdict. Never derived client-side. */
|
|
2557
|
-
type MonitorFleetStatus = 'converging' | 'converged' | 'degraded' | 'deactivating' | 'deactivated';
|
|
2569
|
+
type MonitorFleetStatus = 'converging' | 'converged' | 'degraded' | 'deactivating' | 'deactivated' | 'billing_suspending' | 'billing_suspended' | 'billing_reactivating';
|
|
2558
2570
|
type MonitorFleetSyncOptions = {
|
|
2559
2571
|
/** Return the plan without changing fleet state (`dry_run: true`). */
|
|
2560
2572
|
dryRun?: boolean;
|
|
@@ -2574,6 +2586,9 @@ type MonitorFleetDeactivateOptions = {
|
|
|
2574
2586
|
dryRun?: boolean;
|
|
2575
2587
|
idempotencyKey?: string;
|
|
2576
2588
|
};
|
|
2589
|
+
type MonitorFleetReactivateOptions = {
|
|
2590
|
+
idempotencyKey?: string;
|
|
2591
|
+
};
|
|
2577
2592
|
type MonitorFleetWaitOptions = {
|
|
2578
2593
|
/** Give up after this long. Default 10 minutes. */
|
|
2579
2594
|
timeoutMs?: number;
|
|
@@ -2601,9 +2616,119 @@ type MonitorFleetsNamespace = {
|
|
|
2601
2616
|
list: () => Promise<MonitorFleetResult>;
|
|
2602
2617
|
/** Deactivate a fleet and the monitors it owns. */
|
|
2603
2618
|
deactivate: (fleetId: string, options?: MonitorFleetDeactivateOptions) => Promise<MonitorFleetResult>;
|
|
2619
|
+
/** Explicitly recreate a fleet after a credit-triggered suspension. */
|
|
2620
|
+
reactivate: (fleetId: string, options?: MonitorFleetReactivateOptions) => Promise<MonitorFleetResult>;
|
|
2604
2621
|
/** Poll the fleet until the server reports a terminal status (or the timeout elapses). */
|
|
2605
2622
|
waitForConvergence: (fleetId: string, options?: MonitorFleetWaitOptions) => Promise<MonitorFleetResult>;
|
|
2606
2623
|
};
|
|
2624
|
+
/**
|
|
2625
|
+
* Delivery and convergence health for a scope, from
|
|
2626
|
+
* `GET /api/v2/monitors/health`.
|
|
2627
|
+
*
|
|
2628
|
+
* Counts and bounded samples on purpose. It is also what `--watch` polls, so
|
|
2629
|
+
* its shape is fixed independently of the transport: phase 2b publishes the
|
|
2630
|
+
* same object over a reactive subscription without changing this contract.
|
|
2631
|
+
*/
|
|
2632
|
+
type MonitorsHealth = {
|
|
2633
|
+
ok?: boolean;
|
|
2634
|
+
scope: {
|
|
2635
|
+
org_id: string;
|
|
2636
|
+
fleet_id?: string;
|
|
2637
|
+
};
|
|
2638
|
+
scanned: number;
|
|
2639
|
+
/** True when the scope was larger than one bounded read; counts are partial. */
|
|
2640
|
+
truncated: boolean;
|
|
2641
|
+
desired: {
|
|
2642
|
+
active: number;
|
|
2643
|
+
inactive: number;
|
|
2644
|
+
unset: number;
|
|
2645
|
+
};
|
|
2646
|
+
observed: {
|
|
2647
|
+
active: number;
|
|
2648
|
+
inactive: number;
|
|
2649
|
+
missing: number;
|
|
2650
|
+
unknown: number;
|
|
2651
|
+
unset: number;
|
|
2652
|
+
};
|
|
2653
|
+
converged: number;
|
|
2654
|
+
needs_repair: number;
|
|
2655
|
+
/** Observed active, but nothing delivered inside `silent_window_days`. */
|
|
2656
|
+
silent: number;
|
|
2657
|
+
silent_window_days: number;
|
|
2658
|
+
deactivation_reasons: Array<{
|
|
2659
|
+
reason: string;
|
|
2660
|
+
count: number;
|
|
2661
|
+
summary: string | null;
|
|
2662
|
+
resolution: string | null;
|
|
2663
|
+
}>;
|
|
2664
|
+
worst_offenders: Array<{
|
|
2665
|
+
monitor_key: string;
|
|
2666
|
+
tool: string;
|
|
2667
|
+
last_event_at: number | null;
|
|
2668
|
+
observed_at: number | null;
|
|
2669
|
+
provider_resource_id: string | null;
|
|
2670
|
+
}>;
|
|
2671
|
+
};
|
|
2672
|
+
/** One bounded audit pass, from `POST /api/v2/monitors/audit`. */
|
|
2673
|
+
type MonitorsAuditResult = {
|
|
2674
|
+
ok?: boolean;
|
|
2675
|
+
scope: {
|
|
2676
|
+
org_id: string;
|
|
2677
|
+
fleet_id?: string;
|
|
2678
|
+
};
|
|
2679
|
+
audit: {
|
|
2680
|
+
scanned: number;
|
|
2681
|
+
asked: number;
|
|
2682
|
+
observed: {
|
|
2683
|
+
active: number;
|
|
2684
|
+
inactive: number;
|
|
2685
|
+
missing: number;
|
|
2686
|
+
unknown: number;
|
|
2687
|
+
};
|
|
2688
|
+
/** Observations a concurrent settle overtook. Not an error. */
|
|
2689
|
+
stale: number;
|
|
2690
|
+
absent: number;
|
|
2691
|
+
/** Capabilities that declare no batch read, so nothing could be asked. */
|
|
2692
|
+
unauditable_capabilities: string[];
|
|
2693
|
+
complete: boolean;
|
|
2694
|
+
/** Non-null when the scope was larger than one pass. Pass it back. */
|
|
2695
|
+
cursor: string | null;
|
|
2696
|
+
};
|
|
2697
|
+
health: MonitorsHealth;
|
|
2698
|
+
};
|
|
2699
|
+
/** One repair pass or plan, from `POST /api/v2/monitors/repair`. */
|
|
2700
|
+
type MonitorsRepairResult = {
|
|
2701
|
+
ok?: boolean;
|
|
2702
|
+
dry_run: boolean;
|
|
2703
|
+
scope: {
|
|
2704
|
+
org_id: string;
|
|
2705
|
+
fleet_id?: string;
|
|
2706
|
+
};
|
|
2707
|
+
repair: {
|
|
2708
|
+
scanned: number;
|
|
2709
|
+
queued: number;
|
|
2710
|
+
plan: Array<{
|
|
2711
|
+
monitor_key: string;
|
|
2712
|
+
action: 'create' | 'remove';
|
|
2713
|
+
desired: 'active' | 'inactive';
|
|
2714
|
+
observed: 'active' | 'inactive' | 'missing';
|
|
2715
|
+
deactivation_reason?: string;
|
|
2716
|
+
}>;
|
|
2717
|
+
/** Disagreeing monitors no fleet owns; the convergence driver cannot move them. */
|
|
2718
|
+
unowned: string[];
|
|
2719
|
+
/** Monitors nobody has observed. Run audit first. */
|
|
2720
|
+
unaudited: string[];
|
|
2721
|
+
/**
|
|
2722
|
+
* Monitors with a provider operation still in flight. Deepline's own
|
|
2723
|
+
* convergence loop owns these; repair leaves them alone rather than risk
|
|
2724
|
+
* asking the provider to do the same work twice.
|
|
2725
|
+
*/
|
|
2726
|
+
fenced: string[];
|
|
2727
|
+
refused: string[];
|
|
2728
|
+
complete: boolean;
|
|
2729
|
+
};
|
|
2730
|
+
health: MonitorsHealth;
|
|
2731
|
+
};
|
|
2607
2732
|
/**
|
|
2608
2733
|
* Public monitors namespace exposed as `client.monitors`.
|
|
2609
2734
|
*
|
|
@@ -2636,14 +2761,8 @@ type MonitorsNamespace = {
|
|
|
2636
2761
|
list: (options?: MonitorsListOptions) => Promise<MonitorsListResult>;
|
|
2637
2762
|
/** Fetch one deployed monitor by public key with bounded current listener health. */
|
|
2638
2763
|
get: (key: string) => Promise<MonitorDetail>;
|
|
2639
|
-
/**
|
|
2640
|
-
|
|
2641
|
-
* envelope; omitted options preserve the historic full-ingestion behavior.
|
|
2642
|
-
*/
|
|
2643
|
-
test: (key: string, payload: Record<string, unknown>, options?: {
|
|
2644
|
-
validationOnly?: boolean;
|
|
2645
|
-
dispatch?: boolean;
|
|
2646
|
-
}) => Promise<MonitorTestResult>;
|
|
2764
|
+
/** Test a deployed monitor's callback envelope without side effects. */
|
|
2765
|
+
test: (key: string, payload: Record<string, unknown>, options?: MonitorTestOptions) => Promise<MonitorTestResult>;
|
|
2647
2766
|
validate: (key: string) => Promise<MonitorValidateResult>;
|
|
2648
2767
|
/** List the published plays depending on one monitor's output streams. */
|
|
2649
2768
|
dependents: (key: string) => Promise<MonitorDependents>;
|
|
@@ -2657,6 +2776,26 @@ type MonitorsNamespace = {
|
|
|
2657
2776
|
reactivate: (key: string, options?: {
|
|
2658
2777
|
dryRun?: boolean;
|
|
2659
2778
|
}) => Promise<MonitorReactivateResult>;
|
|
2779
|
+
/**
|
|
2780
|
+
* Re-read what the provider holds onto the monitors that claim it. Bounded
|
|
2781
|
+
* and idempotent: pass `cursor` back while `audit.cursor` is non-null.
|
|
2782
|
+
*/
|
|
2783
|
+
audit: (options?: {
|
|
2784
|
+
fleetId?: string;
|
|
2785
|
+
cursor?: string | null;
|
|
2786
|
+
}) => Promise<MonitorsAuditResult>;
|
|
2787
|
+
/**
|
|
2788
|
+
* Converge the monitors whose desired and observed states disagree.
|
|
2789
|
+
* `dryRun` returns the same plan without queueing anything.
|
|
2790
|
+
*/
|
|
2791
|
+
repair: (options?: {
|
|
2792
|
+
fleetId?: string;
|
|
2793
|
+
dryRun?: boolean;
|
|
2794
|
+
}) => Promise<MonitorsRepairResult>;
|
|
2795
|
+
/** Delivery and convergence health for the workspace or one fleet. */
|
|
2796
|
+
health: (options?: {
|
|
2797
|
+
fleetId?: string;
|
|
2798
|
+
}) => Promise<MonitorsHealth>;
|
|
2660
2799
|
/** Define, reconcile, and control table-backed monitor fleets. */
|
|
2661
2800
|
fleets: MonitorFleetsNamespace;
|
|
2662
2801
|
};
|
|
@@ -4012,6 +4151,25 @@ declare class DeeplineClient {
|
|
|
4012
4151
|
* `client.monitors.status()`.
|
|
4013
4152
|
*/
|
|
4014
4153
|
getMonitorsAccess(): Promise<MonitorsAccessStatus>;
|
|
4154
|
+
/**
|
|
4155
|
+
* One bounded audit pass. Prefer `client.monitors.audit(...)`.
|
|
4156
|
+
*
|
|
4157
|
+
* Never auto-retried: it is idempotent, but a retry that races the caller's
|
|
4158
|
+
* own next pass would spend a provider slot to learn nothing new.
|
|
4159
|
+
*/
|
|
4160
|
+
auditMonitors(options?: {
|
|
4161
|
+
fleetId?: string;
|
|
4162
|
+
cursor?: string | null;
|
|
4163
|
+
}): Promise<MonitorsAuditResult>;
|
|
4164
|
+
/** One repair pass or plan. Prefer `client.monitors.repair(...)`. */
|
|
4165
|
+
repairMonitors(options?: {
|
|
4166
|
+
fleetId?: string;
|
|
4167
|
+
dryRun?: boolean;
|
|
4168
|
+
}): Promise<MonitorsRepairResult>;
|
|
4169
|
+
/** Delivery and convergence health. Prefer `client.monitors.health(...)`. */
|
|
4170
|
+
readMonitorsHealth(options?: {
|
|
4171
|
+
fleetId?: string;
|
|
4172
|
+
}): Promise<MonitorsHealth>;
|
|
4015
4173
|
/**
|
|
4016
4174
|
* The deployable monitor tools catalog. Pass a tool id (positional or
|
|
4017
4175
|
* `{ tool }`) to describe one tool's full payload/stream contract, or no tool
|
|
@@ -4034,10 +4192,7 @@ declare class DeeplineClient {
|
|
|
4034
4192
|
listMonitors(options?: MonitorsListOptions): Promise<MonitorsListResult>;
|
|
4035
4193
|
/** Fetch one deployed monitor by public key. Prefer `client.monitors.get(...)`. */
|
|
4036
4194
|
getMonitor(key: string): Promise<MonitorDetail>;
|
|
4037
|
-
testMonitorWebhook(key: string, payload: Record<string, unknown>, options?:
|
|
4038
|
-
validationOnly?: boolean;
|
|
4039
|
-
dispatch?: boolean;
|
|
4040
|
-
}): Promise<MonitorTestResult>;
|
|
4195
|
+
testMonitorWebhook(key: string, payload: Record<string, unknown>, options?: MonitorTestOptions): Promise<MonitorTestResult>;
|
|
4041
4196
|
setupMonitor(tool: string, payload: Record<string, unknown>): Promise<Record<string, unknown>>;
|
|
4042
4197
|
validateMonitor(key: string): Promise<MonitorValidateResult>;
|
|
4043
4198
|
/** Published plays depending on one monitor. Prefer `client.monitors.dependents(...)`. */
|
|
@@ -4072,6 +4227,7 @@ declare class DeeplineClient {
|
|
|
4072
4227
|
listMonitorFleets(): Promise<MonitorFleetResult>;
|
|
4073
4228
|
getMonitorFleet(fleetId: string, options?: MonitorFleetGetOptions): Promise<MonitorFleetResult>;
|
|
4074
4229
|
deactivateMonitorFleet(fleetId: string, options?: MonitorFleetDeactivateOptions): Promise<MonitorFleetResult>;
|
|
4230
|
+
reactivateMonitorFleet(fleetId: string, options?: MonitorFleetReactivateOptions): Promise<MonitorFleetResult>;
|
|
4075
4231
|
/**
|
|
4076
4232
|
* Poll one fleet until the server reports a terminal status.
|
|
4077
4233
|
*
|
|
@@ -4187,8 +4343,8 @@ type SqlQuery = PlaySqlQuery;
|
|
|
4187
4343
|
* Keyword-style request object for `ctx.tools.execute(...)`.
|
|
4188
4344
|
*
|
|
4189
4345
|
* The `tool` value comes from live tool discovery. The `id` is the stable
|
|
4190
|
-
* logical call name used for logs, metadata, and
|
|
4191
|
-
*
|
|
4346
|
+
* logical call name used for logs, metadata, and result-cache identity. Provider
|
|
4347
|
+
* result reuse is keyed by play, tool, semantic input, auth scope, provider action
|
|
4192
4348
|
* version, and cache policy.
|
|
4193
4349
|
*
|
|
4194
4350
|
* @sdkReference runtime 160
|
|
@@ -4937,9 +5093,6 @@ declare class ConfigError extends DeeplineError {
|
|
|
4937
5093
|
|
|
4938
5094
|
/** Production API base URL. */
|
|
4939
5095
|
declare const PROD_URL = "https://code.deepline.com";
|
|
4940
|
-
/**
|
|
4941
|
-
* Resolve SDK configuration from the public SDK CLI env contract.
|
|
4942
|
-
*/
|
|
4943
5096
|
declare function resolveConfig(options?: DeeplineClientOptions): ResolvedConfig;
|
|
4944
5097
|
|
|
4945
5098
|
/**
|
|
@@ -5086,4 +5239,4 @@ declare function writeCsvOutputFile(rows: Array<Record<string, unknown>>, stem:
|
|
|
5086
5239
|
*/
|
|
5087
5240
|
declare function extractSummaryFields(payload: unknown): Record<string, Scalar>;
|
|
5088
5241
|
|
|
5089
|
-
export { type AdmittedMonitorFleetAuthoringContract, AuthError, type BillingCreditPool, type BillingInvoiceEntry, type BillingInvoicesResult, type BillingNamespace, type BillingPaymentMethodSummary, type BillingSubscriptionCancelResult, type BillingSubscriptionStatus, type BillingTopUpResult, type ClearPlayHistoryRequest, type ClearPlayHistoryResult, type ColumnMap, type ColumnResolver, type ConditionalStepResolver, ConfigError, type CsvInput, type CsvOptions, type CustomerDbQueryResult, DEEPLINE_TOOL_CATEGORIES, type DatasetBuilder, type DatasetColumnDefinition, type DatasetColumnRunInput, type DbNamespace, Deepline, DeeplineClient, type DeeplineClientOptions, DeeplineContext, DeeplineError, type DeeplineNamedPlay, type DeeplinePlayRuntimeContext, type DeeplinePlaysNamespace, type DeeplineToolCategory, type DeeplineToolsNamespace, type DefinePlayConfig, type DefinedPlay, type FetchOptions, type FileInput, type IngestionStorageRepairResult, type LiveEventEnvelope, MONITOR_FLEET_AUTHORING_CONTRACT_CHANGELOG, MONITOR_FLEET_AUTHORING_CONTRACT_EDITION, MONITOR_FLEET_DOCUMENTATION, MONITOR_FLEET_FRONTIER_MAX_ROWS, MONITOR_FLEET_MAX_MEMBERS, type MonitorCheckResult, type MonitorControls, type MonitorDefinition, type MonitorDeleteResult, type MonitorDependents, type MonitorDeployResult, type MonitorDetail, type MonitorFleetAuthoringContractEdition, type MonitorFleetAuthoringContractResult, type MonitorFleetColumn, type MonitorFleetContractIssue, type MonitorFleetDeactivateOptions, type MonitorFleetDefinition, type MonitorFleetExpression, type MonitorFleetGetOptions, type MonitorFleetResult, type MonitorFleetStatus, type MonitorFleetSyncOptions, type MonitorFleetTemplate, type MonitorFleetWaitOptions, type MonitorFleetsNamespace, type MonitorListEntry, type MonitorPayload, type MonitorReactivateResult, type MonitorSpec, type MonitorUpdateChangeSummary, type MonitorUpdateResult, type MonitorsAccessStatus, type MonitorsAvailableOptions, type MonitorsAvailableResult, type MonitorsListOptions, type MonitorsListResult, type MonitorsNamespace, PLAY_BOOTSTRAP_COMPANY_FIELDS, PLAY_BOOTSTRAP_COMPANY_PROVIDER_CATEGORY, PLAY_BOOTSTRAP_CONTACT_FIELDS, PLAY_BOOTSTRAP_FINDER_KINDS, PLAY_BOOTSTRAP_OUTPUT_FIELD_BY_FINDER, PLAY_BOOTSTRAP_PEOPLE_PROVIDER_CATEGORY, PLAY_BOOTSTRAP_PROVIDER_CATEGORY_BY_FINDER, PLAY_BOOTSTRAP_SOURCE_KINDS, PLAY_BOOTSTRAP_STAGE_KINDS, PLAY_BOOTSTRAP_TEMPLATES, PROD_URL, type PlayActivityObservation, type PlayActivityState, type PlayActivityTarget, type PlayBindings, type PlayBootstrapEntityKind, type PlayBootstrapFinderKind, type PlayCallExecution, type PlayCallOptions, type PlayFetchResponse, type PlayInputContract, type PlayJob, type PlayListItem, type PlayLiveEvent, type PlayRevisionSummary, type PlayRunActionPackage, type PlayRunActivityProjection, type PlayRunDatasetActions, type PlayRunPackage, type PlayRunResult, type PlayRunStart, type PlaySheetRow, type PlaySheetRowsResult, type PlayStatus, type PlayStepProgramStep, type PrebuiltPlayRef, type PublishPlayVersionRequest, type PublishPlayVersionResult, RateLimitError, type ResolvedConfig, RunObserveTransportUnavailableError, type RunsListOptions, type RunsLogsOptions, type RunsLogsResult, type RunsNamespace, type RunsTailOptions, type RuntimeStepOptions, SDK_API_CONTRACT, SDK_VERSION, type SqlListenerDeclaration, type SqlListenerEvent, type SqlListenerOperation, type SqlQuery, type StartPlayRunRequest, type StepOptions, type StepProgram, type StepProgramResolver, type StepResolver, type StopPlayRunResult, type ToolDefinition, ToolExecuteResult, type ToolExecution, ToolExecutionError, ToolExecutionErrorOptions, type ToolExecutionRequest, type ToolMetadata, ToolRateLimitError, type ToolSearchOptions, type ToolSearchResult, type WorkspaceCreateResult, type WorkspacesNamespace, admitMonitorFleetAuthoringContract, defineInput, defineMonitor, defineMonitorFleet, definePlay, defineWorkflow, extractSummaryFields, fleetColumn, fleetKey, formatPlayBootstrapFinderKinds, formatPlayBootstrapFinderKindsForSentence, formatPlayBootstrapTemplates, getDefinedPlayMetadata, isPlayBootstrapFinderKind, isPlayBootstrapTemplate, resolveConfig, runIf, steps, tryConvertToList, validateMonitorFleetDefinition, writeCsvOutputFile, writeJsonOutputFile };
|
|
5242
|
+
export { type AdmittedMonitorFleetAuthoringContract, AuthError, type BillingCreditPool, type BillingInvoiceEntry, type BillingInvoicesResult, type BillingNamespace, type BillingPaymentMethodSummary, type BillingSubscriptionCancelResult, type BillingSubscriptionStatus, type BillingTopUpResult, type ClearPlayHistoryRequest, type ClearPlayHistoryResult, type ColumnMap, type ColumnResolver, type ConditionalStepResolver, ConfigError, type CsvInput, type CsvOptions, type CustomerDbQueryResult, DEEPLINE_TOOL_CATEGORIES, type DatasetBuilder, type DatasetColumnDefinition, type DatasetColumnRunInput, type DbNamespace, Deepline, DeeplineClient, type DeeplineClientOptions, DeeplineContext, DeeplineError, type DeeplineNamedPlay, type DeeplinePlayRuntimeContext, type DeeplinePlaysNamespace, type DeeplineToolCategory, type DeeplineToolsNamespace, type DefinePlayConfig, type DefinedPlay, type FetchOptions, type FileInput, type IngestionStorageRepairResult, type LiveEventEnvelope, MONITOR_FLEET_AUTHORING_CONTRACT_CHANGELOG, MONITOR_FLEET_AUTHORING_CONTRACT_EDITION, MONITOR_FLEET_DOCUMENTATION, MONITOR_FLEET_FRONTIER_MAX_ROWS, MONITOR_FLEET_MAX_MEMBERS, type MonitorCheckResult, type MonitorControls, type MonitorDefinition, type MonitorDeleteResult, type MonitorDependents, type MonitorDeployResult, type MonitorDetail, type MonitorFleetAuthoringContractEdition, type MonitorFleetAuthoringContractResult, type MonitorFleetColumn, type MonitorFleetContractIssue, type MonitorFleetDeactivateOptions, type MonitorFleetDefinition, type MonitorFleetExpression, type MonitorFleetGetOptions, type MonitorFleetReactivateOptions, type MonitorFleetResult, type MonitorFleetStatus, type MonitorFleetSyncOptions, type MonitorFleetTemplate, type MonitorFleetWaitOptions, type MonitorFleetsNamespace, type MonitorListEntry, type MonitorPayload, type MonitorReactivateResult, type MonitorSpec, type MonitorUpdateChangeSummary, type MonitorUpdateResult, type MonitorsAccessStatus, type MonitorsAvailableOptions, type MonitorsAvailableResult, type MonitorsListOptions, type MonitorsListResult, type MonitorsNamespace, PLAY_BOOTSTRAP_COMPANY_FIELDS, PLAY_BOOTSTRAP_COMPANY_PROVIDER_CATEGORY, PLAY_BOOTSTRAP_CONTACT_FIELDS, PLAY_BOOTSTRAP_FINDER_KINDS, PLAY_BOOTSTRAP_OUTPUT_FIELD_BY_FINDER, PLAY_BOOTSTRAP_PEOPLE_PROVIDER_CATEGORY, PLAY_BOOTSTRAP_PROVIDER_CATEGORY_BY_FINDER, PLAY_BOOTSTRAP_SOURCE_KINDS, PLAY_BOOTSTRAP_STAGE_KINDS, PLAY_BOOTSTRAP_TEMPLATES, PROD_URL, type PlayActivityObservation, type PlayActivityState, type PlayActivityTarget, type PlayBindings, type PlayBootstrapEntityKind, type PlayBootstrapFinderKind, type PlayCallExecution, type PlayCallOptions, type PlayFetchResponse, type PlayInputContract, type PlayJob, type PlayListItem, type PlayLiveEvent, type PlayRevisionSummary, type PlayRunActionPackage, type PlayRunActivityProjection, type PlayRunDatasetActions, type PlayRunPackage, type PlayRunResult, type PlayRunStart, type PlaySheetRow, type PlaySheetRowsResult, type PlayStatus, type PlayStepProgramStep, type PrebuiltPlayRef, type PublishPlayVersionRequest, type PublishPlayVersionResult, RateLimitError, type ResolvedConfig, RunObserveTransportUnavailableError, type RunsListOptions, type RunsLogsOptions, type RunsLogsResult, type RunsNamespace, type RunsTailOptions, type RuntimeStepOptions, SDK_API_CONTRACT, SDK_VERSION, type SqlListenerDeclaration, type SqlListenerEvent, type SqlListenerOperation, type SqlQuery, type StartPlayRunRequest, type StepOptions, type StepProgram, type StepProgramResolver, type StepResolver, type StopPlayRunResult, type ToolDefinition, ToolExecuteResult, type ToolExecution, ToolExecutionError, ToolExecutionErrorOptions, type ToolExecutionRequest, type ToolMetadata, ToolRateLimitError, type ToolSearchOptions, type ToolSearchResult, type WorkspaceCreateResult, type WorkspacesNamespace, admitMonitorFleetAuthoringContract, defineInput, defineMonitor, defineMonitorFleet, definePlay, defineWorkflow, extractSummaryFields, fleetColumn, fleetKey, formatPlayBootstrapFinderKinds, formatPlayBootstrapFinderKindsForSentence, formatPlayBootstrapTemplates, getDefinedPlayMetadata, isPlayBootstrapFinderKind, isPlayBootstrapTemplate, resolveConfig, runIf, steps, tryConvertToList, validateMonitorFleetDefinition, writeCsvOutputFile, writeJsonOutputFile };
|
package/dist/index.js
CHANGED
|
@@ -832,7 +832,7 @@ var SDK_RELEASE = {
|
|
|
832
832
|
// available at toolResponse.rawV2 while toolResponse.raw and all declared
|
|
833
833
|
// getters keep their established compatibility behavior.
|
|
834
834
|
// 0.3.1 deprecated the legacy `deepline enrich` command in favor of Plays.
|
|
835
|
-
version: "0.3.
|
|
835
|
+
version: "0.3.75",
|
|
836
836
|
updateSummary: "Automatic CLI updates are now enabled by default. To opt out, run `deepline settings autoupdate off`; use `deepline settings autoupdate on` to re-enable updates or `deepline settings autoupdate pin <version>` to hold an exact release. This release also adds raw-v2 tool responses at toolResponse.rawV2 while preserving existing toolResponse.raw and declared getters.",
|
|
837
837
|
packageCapabilities: {
|
|
838
838
|
updatePreferences: 1
|
|
@@ -1245,7 +1245,7 @@ var RUNTIME_INCIDENT_DRILL_CATALOG = [
|
|
|
1245
1245
|
valueMeaning: "occurrence"
|
|
1246
1246
|
},
|
|
1247
1247
|
expected: {
|
|
1248
|
-
outcome: "The same logical run completes through
|
|
1248
|
+
outcome: "The same logical run completes through terminal-cache replay; any provider retry is governed by its separate operation policy.",
|
|
1249
1249
|
safetyFacts: ["same_logical_run", "bounded_provider_execution"]
|
|
1250
1250
|
},
|
|
1251
1251
|
verification: {
|
|
@@ -3975,6 +3975,10 @@ var TERMINAL_PLAY_STATUSES = /* @__PURE__ */ new Set(["completed", "failed", "ca
|
|
|
3975
3975
|
var INCLUDE_TOOL_METADATA_HEADER = "x-deepline-include-tool-metadata";
|
|
3976
3976
|
var EXECUTE_RESPONSE_CONTRACT_HEADER = "x-deepline-execute-response-contract";
|
|
3977
3977
|
var EXECUTE_RESPONSE_INTENT_HEADER = "x-deepline-execute-response-intent";
|
|
3978
|
+
var MONITOR_NON_RETRYABLE_MUTATION_OPTIONS = {
|
|
3979
|
+
maxRetries: 0,
|
|
3980
|
+
exactUrlOnly: true
|
|
3981
|
+
};
|
|
3978
3982
|
var RAW_V2_EXECUTE_RESPONSE_CONTRACT = RAW_V2_TOOL_RESPONSE_CONTRACT;
|
|
3979
3983
|
var COMPILE_MANIFEST_RETRY_DELAYS_MS = [250, 1e3];
|
|
3980
3984
|
var REGISTER_PLAY_ARTIFACTS_COMPILE_CONCURRENCY = 3;
|
|
@@ -4533,11 +4537,15 @@ var DeeplineClient = class {
|
|
|
4533
4537
|
update: (key, patch) => this.updateMonitor(key, patch),
|
|
4534
4538
|
delete: (key, options2) => this.deleteMonitor(key, options2),
|
|
4535
4539
|
reactivate: (key, options2) => this.reactivateMonitor(key, options2),
|
|
4540
|
+
audit: (options2) => this.auditMonitors(options2),
|
|
4541
|
+
repair: (options2) => this.repairMonitors(options2),
|
|
4542
|
+
health: (options2) => this.readMonitorsHealth(options2),
|
|
4536
4543
|
fleets: {
|
|
4537
4544
|
sync: (definitionOrId, options2) => this.syncMonitorFleet(definitionOrId, options2),
|
|
4538
4545
|
get: (fleetId, options2) => fleetId === void 0 ? this.listMonitorFleets() : this.getMonitorFleet(fleetId, options2),
|
|
4539
4546
|
list: () => this.listMonitorFleets(),
|
|
4540
4547
|
deactivate: (fleetId, options2) => this.deactivateMonitorFleet(fleetId, options2),
|
|
4548
|
+
reactivate: (fleetId, options2) => this.reactivateMonitorFleet(fleetId, options2),
|
|
4541
4549
|
waitForConvergence: (fleetId, options2) => this.waitForMonitorFleetConvergence(fleetId, options2)
|
|
4542
4550
|
}
|
|
4543
4551
|
};
|
|
@@ -6123,13 +6131,23 @@ var DeeplineClient = class {
|
|
|
6123
6131
|
if (options?.grep?.trim()) {
|
|
6124
6132
|
params.set("grep", options.grep.trim());
|
|
6125
6133
|
params.set("grep_mode", options.grepMode ?? "all");
|
|
6134
|
+
params.set("grep_paginated", "1");
|
|
6126
6135
|
params.set("limit", "60");
|
|
6127
6136
|
}
|
|
6128
|
-
const
|
|
6129
|
-
|
|
6130
|
-
|
|
6131
|
-
|
|
6132
|
-
|
|
6137
|
+
const plays = [];
|
|
6138
|
+
let cursor = null;
|
|
6139
|
+
let hasMore = true;
|
|
6140
|
+
do {
|
|
6141
|
+
if (cursor) params.set("cursor", cursor);
|
|
6142
|
+
const suffix = params.toString() ? `?${params.toString()}` : "";
|
|
6143
|
+
const response = await this.http.get(
|
|
6144
|
+
`/api/v2/plays${suffix}`
|
|
6145
|
+
);
|
|
6146
|
+
plays.push(...response.plays ?? []);
|
|
6147
|
+
cursor = response.pagination?.cursor ?? response.cursor ?? null;
|
|
6148
|
+
hasMore = Boolean(response.pagination?.hasMore ?? response.hasMore);
|
|
6149
|
+
} while (Boolean(options?.grep?.trim()) && hasMore && cursor);
|
|
6150
|
+
return plays;
|
|
6133
6151
|
}
|
|
6134
6152
|
/** Set whether an org-owned Play sorts before unpinned Plays. */
|
|
6135
6153
|
async setPlayPinned(playName, pinned) {
|
|
@@ -6706,6 +6724,44 @@ var DeeplineClient = class {
|
|
|
6706
6724
|
...typeof payload.reason === "string" && payload.reason.trim() ? { reason: payload.reason.trim() } : {}
|
|
6707
6725
|
};
|
|
6708
6726
|
}
|
|
6727
|
+
/**
|
|
6728
|
+
* One bounded audit pass. Prefer `client.monitors.audit(...)`.
|
|
6729
|
+
*
|
|
6730
|
+
* Never auto-retried: it is idempotent, but a retry that races the caller's
|
|
6731
|
+
* own next pass would spend a provider slot to learn nothing new.
|
|
6732
|
+
*/
|
|
6733
|
+
async auditMonitors(options) {
|
|
6734
|
+
return this.http.request("/api/v2/monitors/audit", {
|
|
6735
|
+
method: "POST",
|
|
6736
|
+
body: {
|
|
6737
|
+
...options?.fleetId ? { fleet_id: options.fleetId } : {},
|
|
6738
|
+
...options?.cursor ? { cursor: options.cursor } : {}
|
|
6739
|
+
},
|
|
6740
|
+
maxRetries: 0
|
|
6741
|
+
});
|
|
6742
|
+
}
|
|
6743
|
+
/** One repair pass or plan. Prefer `client.monitors.repair(...)`. */
|
|
6744
|
+
async repairMonitors(options) {
|
|
6745
|
+
return this.http.request("/api/v2/monitors/repair", {
|
|
6746
|
+
method: "POST",
|
|
6747
|
+
body: {
|
|
6748
|
+
...options?.fleetId ? { fleet_id: options.fleetId } : {},
|
|
6749
|
+
...options?.dryRun === void 0 ? {} : { dry_run: options.dryRun }
|
|
6750
|
+
},
|
|
6751
|
+
maxRetries: 0
|
|
6752
|
+
});
|
|
6753
|
+
}
|
|
6754
|
+
/** Delivery and convergence health. Prefer `client.monitors.health(...)`. */
|
|
6755
|
+
async readMonitorsHealth(options) {
|
|
6756
|
+
const params = new URLSearchParams();
|
|
6757
|
+
if (options?.fleetId) params.set("fleet_id", options.fleetId);
|
|
6758
|
+
const query = params.toString();
|
|
6759
|
+
const suffix = query ? `?${query}` : "";
|
|
6760
|
+
return this.http.request(
|
|
6761
|
+
`/api/v2/monitors/health${suffix}`,
|
|
6762
|
+
{ method: "GET" }
|
|
6763
|
+
);
|
|
6764
|
+
}
|
|
6709
6765
|
/**
|
|
6710
6766
|
* The deployable monitor tools catalog. Pass a tool id (positional or
|
|
6711
6767
|
* `{ tool }`) to describe one tool's full payload/stream contract, or no tool
|
|
@@ -6783,7 +6839,6 @@ var DeeplineClient = class {
|
|
|
6783
6839
|
if (options?.limit !== void 0)
|
|
6784
6840
|
params.set("limit", String(options.limit));
|
|
6785
6841
|
if (options?.cursor) params.set("cursor", options.cursor);
|
|
6786
|
-
if (options?.compact) params.set("compact", "true");
|
|
6787
6842
|
if (options?.includeConsumers) params.set("include_consumers", "true");
|
|
6788
6843
|
const query = params.toString();
|
|
6789
6844
|
const suffix = query ? `?${query}` : "";
|
|
@@ -6800,13 +6855,22 @@ var DeeplineClient = class {
|
|
|
6800
6855
|
);
|
|
6801
6856
|
}
|
|
6802
6857
|
async testMonitorWebhook(key, payload, options) {
|
|
6858
|
+
if (options?.dispatch === true || options?.validationOnly === false) {
|
|
6859
|
+
throw new DeeplineError(
|
|
6860
|
+
"Monitor tests are validation-only and cannot dispatch events.",
|
|
6861
|
+
void 0,
|
|
6862
|
+
"MONITOR_TEST_DISPATCH_NOT_SUPPORTED"
|
|
6863
|
+
);
|
|
6864
|
+
}
|
|
6803
6865
|
return this.http.request(
|
|
6804
6866
|
`/api/v2/monitors/deployed/${encodeURIComponent(key)}/test`,
|
|
6805
6867
|
{
|
|
6806
6868
|
method: "POST",
|
|
6807
6869
|
body: {
|
|
6808
6870
|
payload,
|
|
6809
|
-
|
|
6871
|
+
// Send the legacy safe mode as well as accepting it server-side: an
|
|
6872
|
+
// upgraded SDK must be safe when it reaches a still-running server.
|
|
6873
|
+
mode: "validation_only"
|
|
6810
6874
|
}
|
|
6811
6875
|
}
|
|
6812
6876
|
);
|
|
@@ -6834,7 +6898,14 @@ var DeeplineClient = class {
|
|
|
6834
6898
|
async updateMonitor(key, patch) {
|
|
6835
6899
|
return this.http.request(
|
|
6836
6900
|
`/api/v2/monitors/deployed/${encodeURIComponent(key)}`,
|
|
6837
|
-
{
|
|
6901
|
+
{
|
|
6902
|
+
method: "PATCH",
|
|
6903
|
+
body: patch,
|
|
6904
|
+
// A monitor write may have reached the control plane before a network
|
|
6905
|
+
// failure reaches the caller. Do not turn that unknown outcome into a
|
|
6906
|
+
// second mutation with a fresh snapshot.
|
|
6907
|
+
...MONITOR_NON_RETRYABLE_MUTATION_OPTIONS
|
|
6908
|
+
}
|
|
6838
6909
|
);
|
|
6839
6910
|
}
|
|
6840
6911
|
/** Delete a deployed monitor and its upstream provider resource. `dryRun` returns the delete plan. Prefer `client.monitors.delete(...)`. */
|
|
@@ -6851,7 +6922,12 @@ var DeeplineClient = class {
|
|
|
6851
6922
|
const query = params.toString();
|
|
6852
6923
|
return this.http.request(
|
|
6853
6924
|
`/api/v2/monitors/deployed/${encodeURIComponent(key)}${query ? `?${query}` : ""}`,
|
|
6854
|
-
{ method: "DELETE" }
|
|
6925
|
+
options?.dryRun ? { method: "DELETE" } : {
|
|
6926
|
+
method: "DELETE",
|
|
6927
|
+
// Deletion is a provider lifecycle operation. A timeout is an
|
|
6928
|
+
// unknown outcome, not authority to begin another delete attempt.
|
|
6929
|
+
...MONITOR_NON_RETRYABLE_MUTATION_OPTIONS
|
|
6930
|
+
}
|
|
6855
6931
|
);
|
|
6856
6932
|
}
|
|
6857
6933
|
/**
|
|
@@ -6862,7 +6938,13 @@ var DeeplineClient = class {
|
|
|
6862
6938
|
const query = options?.dryRun ? "?dry_run=true" : "";
|
|
6863
6939
|
return this.http.request(
|
|
6864
6940
|
`/api/v2/monitors/deployed/${encodeURIComponent(key)}/reactivate${query}`,
|
|
6865
|
-
{ method: "POST", body: {} }
|
|
6941
|
+
options?.dryRun ? { method: "POST", body: {} } : {
|
|
6942
|
+
method: "POST",
|
|
6943
|
+
body: {},
|
|
6944
|
+
// Reactivation can create an upstream resource, so it must not use
|
|
6945
|
+
// the generic transport's automatic replay policy.
|
|
6946
|
+
...MONITOR_NON_RETRYABLE_MUTATION_OPTIONS
|
|
6947
|
+
}
|
|
6866
6948
|
);
|
|
6867
6949
|
}
|
|
6868
6950
|
// ——————————————————————————————————————————————————————————
|
|
@@ -6939,6 +7021,21 @@ var DeeplineClient = class {
|
|
|
6939
7021
|
}
|
|
6940
7022
|
);
|
|
6941
7023
|
}
|
|
7024
|
+
async reactivateMonitorFleet(fleetId, options) {
|
|
7025
|
+
return this.http.request(
|
|
7026
|
+
`${this.monitorFleetPath(fleetId)}/reactivate`,
|
|
7027
|
+
{
|
|
7028
|
+
method: "POST",
|
|
7029
|
+
body: {},
|
|
7030
|
+
headers: this.monitorFleetHeaders(
|
|
7031
|
+
"reactivate",
|
|
7032
|
+
options?.idempotencyKey
|
|
7033
|
+
),
|
|
7034
|
+
maxRetries: 0,
|
|
7035
|
+
exactUrlOnly: true
|
|
7036
|
+
}
|
|
7037
|
+
);
|
|
7038
|
+
}
|
|
6942
7039
|
/**
|
|
6943
7040
|
* Poll one fleet until the server reports a terminal status.
|
|
6944
7041
|
*
|