@sentry/junior-plugin-api 0.262.0 → 0.263.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.
Files changed (2) hide show
  1. package/dist/index.d.ts +16 -1
  2. package/package.json +1 -1
package/dist/index.d.ts CHANGED
@@ -1830,8 +1830,23 @@ export interface PluginEnv {
1830
1830
  get(key: string): string | undefined;
1831
1831
  set(key: string, value: string): void;
1832
1832
  }
1833
+ /**
1834
+ * Decide what happens to one tool call in `beforeToolExecute`.
1835
+ *
1836
+ * `redirect` and `deny` both stop the tool before it runs. Neither ends the
1837
+ * turn: the agent gets the message as the tool result.
1838
+ */
1833
1839
  export interface PluginDecision {
1834
- deny(message: string): void;
1840
+ /**
1841
+ * Block the call as a policy refusal. The agent is told not to retry or
1842
+ * reach the same result another way, and to explain the block.
1843
+ */
1844
+ deny(reason: string): void;
1845
+ /**
1846
+ * Block the call because a different path is correct, such as another
1847
+ * tool. The message tells the agent what to do instead.
1848
+ */
1849
+ redirect(message: string): void;
1835
1850
  replaceInput(input: Record<string, unknown>): void;
1836
1851
  }
1837
1852
  /** Thrown when a plugin tool rejects invalid model or user input. */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sentry/junior-plugin-api",
3
- "version": "0.262.0",
3
+ "version": "0.263.0",
4
4
  "private": false,
5
5
  "publishConfig": {
6
6
  "access": "public"