@zuplo/cli 7.2.0 → 7.2.1

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.
@@ -333,8 +333,8 @@ export declare interface AIGatewayConfigurationLoaderV2InboundPolicyOptions {
333
333
  }
334
334
 
335
335
  /**
336
- * AI Gateway DLP Inbound Policy
337
- * @title AI Gateway DLP
336
+ * Data Loss Prevention (DLP) Inbound Policy for the AI Gateway
337
+ * @title Data Loss Prevention (DLP)
338
338
  * @product ai-gateway
339
339
  * @hidden
340
340
  * @requiresAI
@@ -366,7 +366,7 @@ export declare function AIGatewayDlpInboundPolicy(
366
366
  ): Promise<ZuploRequest | Response>;
367
367
 
368
368
  /**
369
- * The options for the AI Gateway DLP policy. Scans the content of AI requests and responses — system prompts, messages, and tool-call arguments — for sensitive data such as credit cards, national identifiers, and API keys, applying a per-rule action (mask, block, or log). Detection runs entirely inside the gateway and streaming responses are scanned as they stream.
369
+ * The options for the Data Loss Prevention (DLP) policy. Scans the content of AI requests and responses — system prompts, messages, and tool-call arguments — for sensitive data such as credit cards, national identifiers, and API keys, applying a per-rule action (mask, block, or log). Detection runs entirely inside the gateway and streaming responses are scanned as they stream.
370
370
  * @public
371
371
  */
372
372
  export declare interface AIGatewayDlpInboundPolicyOptions {
@@ -379,10 +379,6 @@ export declare interface AIGatewayDlpInboundPolicyOptions {
379
379
  * Exact strings that are never flagged by any rule — documentation samples like Stripe's public test card `4242 4242 4242 4242`, or your own support email address. Matching is case-sensitive against the exact detected text, including when a value arrives split across streaming chunks.
380
380
  */
381
381
  allowValues?: string[];
382
- /**
383
- * The replacement text for masked matches. The `{type}` token inserts the detected type id in UPPER_SNAKE form (for example `[CONTACT_EMAIL]`), which keeps masked conversations legible to the model. Individual rules can override this.
384
- */
385
- mask?: string;
386
382
  /**
387
383
  * Default evidence level for rules that do not set their own. See the per-rule `detection` description for the level semantics. There are no numeric confidence thresholds to tune — levels are the whole dial.
388
384
  */
@@ -4871,19 +4867,23 @@ declare interface DlpCustomRule {
4871
4867
  */
4872
4868
  context?: string[];
4873
4869
  /**
4874
- * What happens when this type is found. `mask` replaces the matched text with a placeholder and the conversation continues; `block` rejects the request or terminates the response with an error naming only the detected types (never the values); `log` records a finding and lets the traffic pass unchanged use it to trial a rule before enforcing it; `off` excludes this type from a group enabled by a broader key.
4870
+ * What happens when this rule matches, in BOTH directions. `mask` replaces the matched text with a placeholder and the conversation continues; `block` rejects the request or terminates the response with an error naming only the rule's name (never the values); `log` records a finding and lets the traffic pass unchanged; `off` disables the rule. A rule states either `action` or the directional pair (`inboundAction`/`outboundAction`), never both.
4875
4871
  */
4876
- action: "mask" | "block" | "log" | "off";
4872
+ action?: "mask" | "block" | "log" | "off";
4877
4873
  /**
4878
- * Where the rule applies. `inbound` scans what callers send the model (system prompt, message text, and tool-call arguments); `outbound` scans what the model sends back (buffered responses whole, streaming responses chunk by chunk). Defaults to `both`.
4874
+ * What happens when this rule matches in what callers send the model. Use with `outboundAction` to give the rule different behavior per direction. Omitting it (or `off`) leaves the inbound direction unscanned for this rule. Cannot be combined with `action`.
4879
4875
  */
4880
- direction?: "both" | "inbound" | "outbound";
4876
+ inboundAction?: "mask" | "block" | "log" | "off";
4877
+ /**
4878
+ * What happens when this rule matches in what the model sends back. Omitting it (or `off`) leaves the outbound direction unscanned for this rule. Cannot be combined with `action`.
4879
+ */
4880
+ outboundAction?: "mask" | "block" | "log" | "off";
4881
4881
  /**
4882
4882
  * How much evidence a match needs before this rule acts. `corroborated` additionally requires one of the type's context words near the match (types that define no context words behave as `standard`); `standard` uses the catalog as tuned — distinctive shapes act on their own while ambiguous shapes need nearby context; `aggressive` counts every pattern match and is false-positive-prone — pair it with the `log` action for audits. Overrides the policy-level `detection` for this rule.
4883
4883
  */
4884
4884
  detection?: "corroborated" | "standard" | "aggressive";
4885
4885
  /**
4886
- * Replacement text for this rule when `action` is `mask`, overriding the policy-level `mask`. The `{type}` token inserts the detected type id in UPPER_SNAKE form (for example `[CONTACT_EMAIL]`).
4886
+ * Replacement text for this rule's masked matches. The `{type}` token inserts the detected type id in UPPER_SNAKE form, so the default turns a matched email into `[CONTACT_EMAIL]` — typed placeholders keep masked conversations legible to the model. Set a literal like `[REDACTED]` to hide the type.
4887
4887
  */
4888
4888
  mask?: string;
4889
4889
  partialMask?: DlpPartialMask;
@@ -4898,26 +4898,30 @@ declare interface DlpPartialMask {
4898
4898
 
4899
4899
  declare interface DlpRule {
4900
4900
  /**
4901
- * What happens when this type is found. `mask` replaces the matched text with a placeholder and the conversation continues; `block` rejects the request or terminates the response with an error naming only the detected types (never the values); `log` records a finding and lets the traffic pass unchanged — use it to trial a rule before enforcing it; `off` excludes this type from a group enabled by a broader key.
4901
+ * What happens when this type is found, in BOTH directions. `mask` replaces the matched text with a placeholder and the conversation continues; `block` rejects the request or terminates the response with an error naming only the detected types (never the values); `log` records a finding and lets the traffic pass unchanged — use it to trial a rule before enforcing it; `off` excludes this type from a group enabled by a broader key. A rule states either `action` or the directional pair (`inboundAction`/`outboundAction`), never both.
4902
+ */
4903
+ action?: "mask" | "block" | "log" | "off";
4904
+ /**
4905
+ * What happens when this type is found in what callers send the model (system prompt, message text, and tool-call arguments). Use with `outboundAction` to give one type different behavior per direction — for example mask PII on the way in and block it on the way out. Omitting it (or `off`) leaves the inbound direction unscanned for this type. Cannot be combined with `action`.
4902
4906
  */
4903
- action: "mask" | "block" | "log" | "off";
4907
+ inboundAction?: "mask" | "block" | "log" | "off";
4904
4908
  /**
4905
- * Where the rule applies. `inbound` scans what callers send the model (system prompt, message text, and tool-call arguments); `outbound` scans what the model sends back (buffered responses whole, streaming responses chunk by chunk). Defaults to `both`.
4909
+ * What happens when this type is found in what the model sends back (buffered responses whole, streaming responses as they stream). Omitting it (or `off`) leaves the outbound direction unscanned for this type. Cannot be combined with `action`.
4906
4910
  */
4907
- direction?: "both" | "inbound" | "outbound";
4911
+ outboundAction?: "mask" | "block" | "log" | "off";
4908
4912
  /**
4909
4913
  * How much evidence a match needs before this rule acts. `corroborated` additionally requires one of the type's context words near the match (types that define no context words behave as `standard`); `standard` uses the catalog as tuned — distinctive shapes act on their own while ambiguous shapes need nearby context; `aggressive` counts every pattern match and is false-positive-prone — pair it with the `log` action for audits. Overrides the policy-level `detection` for this rule.
4910
4914
  */
4911
4915
  detection?: "corroborated" | "standard" | "aggressive";
4912
4916
  /**
4913
- * Replacement text for this rule when `action` is `mask`, overriding the policy-level `mask`. The `{type}` token inserts the detected type id in UPPER_SNAKE form (for example `[CONTACT_EMAIL]`).
4917
+ * Replacement text for this rule's masked matches. The `{type}` token inserts the detected type id in UPPER_SNAKE form, so the default turns a matched email into `[CONTACT_EMAIL]` — typed placeholders keep masked conversations legible to the model. Set a literal like `[REDACTED]` to hide the type.
4914
4918
  */
4915
4919
  mask?: string;
4916
4920
  partialMask?: DlpPartialMask;
4917
4921
  }
4918
4922
 
4919
4923
  /**
4920
- * What to find and what to do about it. Each key is a built-in data type id (like `id-us-ssn`) or a group selector (like `pii` or `secret`, plus any dash-aligned id prefix such as `secret-aws`); each value is a rule object whose required `action` says what happens when that type is found. Types you do not mention are not scanned. The most specific key wins — an exact id beats a prefix beats a group — and the winning entry decides everything for its type, direction included. When one stretch of text matches multiple rules, the severest action wins (block > mask > log). At least one rule must scan something.
4924
+ * What to find and what to do about it. Each key is a built-in data type id (like `id-us-ssn`) or a group selector (like `pii` or `secret`, plus any dash-aligned id prefix such as `secret-aws`); each value is a rule object stating either one `action` for both directions or a directional pair (`inboundAction`/`outboundAction`) — for example mask PII inbound and block it outbound. Types you do not mention are not scanned. The most specific key wins — an exact id beats a prefix beats a group — and the winning entry decides everything for its type. When one stretch of text matches multiple rules, the severest action wins (block > mask > log). At least one rule must scan something.
4921
4925
  * @public
4922
4926
  */
4923
4927
  declare interface DlpRules {
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@zuplo/runtime",
3
3
  "type": "module",
4
- "version": "7.2.0",
4
+ "version": "7.2.1",
5
5
  "repository": "https://github.com/zuplo/zuplo",
6
6
  "author": "Zuplo, Inc.",
7
7
  "exports": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zuplo/cli",
3
- "version": "7.2.0",
3
+ "version": "7.2.1",
4
4
  "repository": "https://github.com/zuplo/zuplo",
5
5
  "author": "Zuplo, Inc.",
6
6
  "type": "module",
@@ -28,10 +28,10 @@
28
28
  "@opentelemetry/api": "1.9.0",
29
29
  "@opentelemetry/api-logs": "0.220.0",
30
30
  "@swc/core": "1.10.18",
31
- "@zuplo/core": "7.2.0",
31
+ "@zuplo/core": "7.2.1",
32
32
  "@zuplo/editor": "1.0.31094607111",
33
- "@zuplo/openapi-tools": "7.2.0",
34
- "@zuplo/runtime": "7.2.0",
33
+ "@zuplo/openapi-tools": "7.2.1",
34
+ "@zuplo/runtime": "7.2.1",
35
35
  "chalk": "5.4.1",
36
36
  "chokidar": "3.5.3",
37
37
  "cookie": "1.0.2",
@@ -62,8 +62,8 @@
62
62
  "workerd": "1.20241230.0",
63
63
  "yargs": "17.7.2",
64
64
  "zod": "4.4.3",
65
- "@zuplo/graphql": "7.2.0",
66
- "@zuplo/otel": "7.2.0"
65
+ "@zuplo/graphql": "7.2.1",
66
+ "@zuplo/otel": "7.2.1"
67
67
  },
68
68
  "bundleDependencies": [
69
69
  "@inquirer/prompts",