pgbeam 0.4.16 → 0.4.18

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.
@@ -1,6 +1,6 @@
1
1
  Object.defineProperty(exports, '__esModule', { value: true });
2
2
 
3
- var operationsMap_gen = require('./operations-map.gen-mwk22v4l.cjs');
3
+ var operationsMap_gen = require('./operations-map.gen-j3jalb8e.cjs');
4
4
 
5
5
  /**
6
6
  * Generated by generate-sdk-ts-maps.ts from backend/openapi/bundles/public.yaml — do not edit manually.
@@ -329,6 +329,169 @@ var operationsMap_gen = require('./operations-map.gen-mwk22v4l.cjs');
329
329
  "responseType": "{ acknowledged_at?: string; acknowledged_by?: string; created_at: string; credential_id?: string; details?: Record<string, unknown>; id: string; kind: string; project_id: string; severity: \"info\" | \"warning\" | \"critical\"; status: \"open\" | \"acknowledged\" | \"resolved\"; title: string; window_end?: string; window_start?: string }",
330
330
  "responseStatus": "200"
331
331
  },
332
+ "listAnomalyRules": {
333
+ "operationId": "listAnomalyRules",
334
+ "method": "GET",
335
+ "path": "/v1/projects/{project_id}/anomaly-rules",
336
+ "summary": "List anomaly rules",
337
+ "description": "Lists the project's anomaly rules, including silenced ones.",
338
+ "parameters": [
339
+ {
340
+ "name": "project_id",
341
+ "in": "path",
342
+ "required": true,
343
+ "type": "string",
344
+ "description": "Unique project identifier (prefixed, e.g. prj_xxx)."
345
+ },
346
+ {
347
+ "name": "page_size",
348
+ "in": "query",
349
+ "required": false,
350
+ "type": "number",
351
+ "description": "Maximum number of items to return (1-100, default 20)."
352
+ },
353
+ {
354
+ "name": "page_token",
355
+ "in": "query",
356
+ "required": false,
357
+ "type": "string",
358
+ "description": "Opaque token for cursor-based pagination."
359
+ },
360
+ {
361
+ "name": "If-None-Match",
362
+ "in": "header",
363
+ "required": false,
364
+ "type": "string",
365
+ "description": "Entity tag the client already holds, taken from the `ETag` of an earlier response. When it still matches the current representation the server answers `304 Not Modified` with no body, so a poll that finds nothing changed costs a round trip rather than a transfer.\n\nA comma-separated list is accepted, and `*` matches any current representation."
366
+ }
367
+ ],
368
+ "requestBodyType": "",
369
+ "requestBodyRequired": false,
370
+ "responseType": "{ anomaly_rules: ({ created_at: string; credential_id?: string; enabled: boolean; floor?: number; id: string; metric: \"queries_per_hour\" | \"bytes_per_hour\" | \"distinct_shapes\" | \"errors_per_hour\" | \"active_hours\"; project_id: string; sigma_threshold?: number; updated_at: string })[]; next_page_token?: string }",
371
+ "responseStatus": "200"
372
+ },
373
+ "createAnomalyRule": {
374
+ "operationId": "createAnomalyRule",
375
+ "method": "POST",
376
+ "path": "/v1/projects/{project_id}/anomaly-rules",
377
+ "summary": "Create an anomaly rule",
378
+ "description": "Retunes one detection metric for this project, or for one agent credential\nin it. Without a rule every metric resolves to the deployment default.\n\nA rule adds no detection algorithm and no alert kind: it changes how\nsensitive one of the five existing metrics is. enabled=false silences that\nmetric for that scope; the baseline keeps advancing, so re-enabling\nresumes from the existing history rather than a cold warm-up.\n",
379
+ "parameters": [
380
+ {
381
+ "name": "project_id",
382
+ "in": "path",
383
+ "required": true,
384
+ "type": "string",
385
+ "description": "Unique project identifier (prefixed, e.g. prj_xxx)."
386
+ },
387
+ {
388
+ "name": "Idempotency-Key",
389
+ "in": "header",
390
+ "required": false,
391
+ "type": "string",
392
+ "description": "Client-generated key that makes a retry of this request safe. The first request carrying a given key executes normally and its response (status, content type and body) is stored for 24 hours; a later request with the same key returns that stored response without running the operation again, so a retry after a lost or timed-out response cannot create a second resource.\n\nReusing a key with a different request body returns `409 Conflict`: a key is a promise about one specific request, so a changed body is a client bug rather than a retry. Keys are scoped to the calling organization (or to the user, for account-scoped tokens), so one tenant can never read another's stored response.\n\nA `5xx`, `408` or `429` is never stored, because those describe a request that produced no settled answer and the next attempt with the same key must run for real. A `4xx` is stored: it is the server's settled answer about this exact request.\n\nUse a fresh UUID per logical operation. The PgBeam SDKs generate one per call and reuse it across their own automatic retries."
393
+ }
394
+ ],
395
+ "requestBodyType": "{ credential_id?: string; enabled?: boolean; floor?: number; metric: \"queries_per_hour\" | \"bytes_per_hour\" | \"distinct_shapes\" | \"errors_per_hour\" | \"active_hours\"; sigma_threshold?: number }",
396
+ "requestBodyRequired": true,
397
+ "responseType": "{ created_at: string; credential_id?: string; enabled: boolean; floor?: number; id: string; metric: \"queries_per_hour\" | \"bytes_per_hour\" | \"distinct_shapes\" | \"errors_per_hour\" | \"active_hours\"; project_id: string; sigma_threshold?: number; updated_at: string }",
398
+ "responseStatus": "201"
399
+ },
400
+ "getAnomalyRule": {
401
+ "operationId": "getAnomalyRule",
402
+ "method": "GET",
403
+ "path": "/v1/projects/{project_id}/anomaly-rules/{anomaly_rule_id}",
404
+ "summary": "Get an anomaly rule",
405
+ "description": "Returns a single anomaly rule by ID.",
406
+ "parameters": [
407
+ {
408
+ "name": "project_id",
409
+ "in": "path",
410
+ "required": true,
411
+ "type": "string",
412
+ "description": "Unique project identifier (prefixed, e.g. prj_xxx)."
413
+ },
414
+ {
415
+ "name": "anomaly_rule_id",
416
+ "in": "path",
417
+ "required": true,
418
+ "type": "string",
419
+ "description": "Unique anomaly rule identifier (prefixed, e.g. anr_xxx)."
420
+ },
421
+ {
422
+ "name": "If-None-Match",
423
+ "in": "header",
424
+ "required": false,
425
+ "type": "string",
426
+ "description": "Entity tag the client already holds, taken from the `ETag` of an earlier response. When it still matches the current representation the server answers `304 Not Modified` with no body, so a poll that finds nothing changed costs a round trip rather than a transfer.\n\nA comma-separated list is accepted, and `*` matches any current representation."
427
+ }
428
+ ],
429
+ "requestBodyType": "",
430
+ "requestBodyRequired": false,
431
+ "responseType": "{ created_at: string; credential_id?: string; enabled: boolean; floor?: number; id: string; metric: \"queries_per_hour\" | \"bytes_per_hour\" | \"distinct_shapes\" | \"errors_per_hour\" | \"active_hours\"; project_id: string; sigma_threshold?: number; updated_at: string }",
432
+ "responseStatus": "200"
433
+ },
434
+ "updateAnomalyRule": {
435
+ "operationId": "updateAnomalyRule",
436
+ "method": "PUT",
437
+ "path": "/v1/projects/{project_id}/anomaly-rules/{anomaly_rule_id}",
438
+ "summary": "Update an anomaly rule",
439
+ "description": "Replaces the rule's scope, metric and sensitivity. A rule whose enabled\nflag is turned off silences its metric for its scope rather than being\ndeactivated.\n",
440
+ "parameters": [
441
+ {
442
+ "name": "project_id",
443
+ "in": "path",
444
+ "required": true,
445
+ "type": "string",
446
+ "description": "Unique project identifier (prefixed, e.g. prj_xxx)."
447
+ },
448
+ {
449
+ "name": "anomaly_rule_id",
450
+ "in": "path",
451
+ "required": true,
452
+ "type": "string",
453
+ "description": "Unique anomaly rule identifier (prefixed, e.g. anr_xxx)."
454
+ },
455
+ {
456
+ "name": "If-Match",
457
+ "in": "header",
458
+ "required": false,
459
+ "type": "string",
460
+ "description": "Entity tag the write is based on, taken from the `ETag` of the read that produced the values being sent. The write proceeds only if it still matches the current representation; otherwise it is refused with `412 Precondition Failed` and nothing is changed.\n\nThis is what makes a read-modify-write safe. Without it the last writer wins and a concurrent edit is silently discarded, which is the failure an agent is most likely to cause and least likely to notice. The `412` response carries the current `ETag`, so a caller can re-read, re-apply its change and retry.\n\nOmitting the header keeps the old unconditional behaviour. `*` matches any current representation, which asserts only that the resource exists."
461
+ }
462
+ ],
463
+ "requestBodyType": "{ credential_id?: string; enabled?: boolean; floor?: number; metric: \"queries_per_hour\" | \"bytes_per_hour\" | \"distinct_shapes\" | \"errors_per_hour\" | \"active_hours\"; sigma_threshold?: number }",
464
+ "requestBodyRequired": true,
465
+ "responseType": "{ created_at: string; credential_id?: string; enabled: boolean; floor?: number; id: string; metric: \"queries_per_hour\" | \"bytes_per_hour\" | \"distinct_shapes\" | \"errors_per_hour\" | \"active_hours\"; project_id: string; sigma_threshold?: number; updated_at: string }",
466
+ "responseStatus": "200"
467
+ },
468
+ "deleteAnomalyRule": {
469
+ "operationId": "deleteAnomalyRule",
470
+ "method": "DELETE",
471
+ "path": "/v1/projects/{project_id}/anomaly-rules/{anomaly_rule_id}",
472
+ "summary": "Delete an anomaly rule",
473
+ "description": "Removes the rule, so its metric returns to the deployment default for that\nscope. Deleting a rule that was silencing a metric turns that metric's\nalerts back on.\n",
474
+ "parameters": [
475
+ {
476
+ "name": "project_id",
477
+ "in": "path",
478
+ "required": true,
479
+ "type": "string",
480
+ "description": "Unique project identifier (prefixed, e.g. prj_xxx)."
481
+ },
482
+ {
483
+ "name": "anomaly_rule_id",
484
+ "in": "path",
485
+ "required": true,
486
+ "type": "string",
487
+ "description": "Unique anomaly rule identifier (prefixed, e.g. anr_xxx)."
488
+ }
489
+ ],
490
+ "requestBodyType": "",
491
+ "requestBodyRequired": false,
492
+ "responseType": "",
493
+ "responseStatus": "204"
494
+ },
332
495
  "listApprovalRequests": {
333
496
  "operationId": "listApprovalRequests",
334
497
  "method": "GET",
@@ -3021,7 +3184,7 @@ var operationsMap_gen = require('./operations-map.gen-mwk22v4l.cjs');
3021
3184
  ],
3022
3185
  "requestBodyType": "",
3023
3186
  "requestBodyRequired": false,
3024
- "responseType": "{ next_page_token?: string; webhooks: ({ created_at: string; description?: string; enabled: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"audit_checkpoint\" | \"webhook.test\")[]; format: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; id: string; project_id: string; updated_at: string; url: string })[] }",
3187
+ "responseType": "{ next_page_token?: string; webhooks: ({ created_at: string; description?: string; enabled: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"content_flagged\" | \"audit_checkpoint\" | \"webhook.test\")[]; format: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; id: string; project_id: string; updated_at: string; url: string })[] }",
3025
3188
  "responseStatus": "200"
3026
3189
  },
3027
3190
  "createWebhookEndpoint": {
@@ -3046,9 +3209,9 @@ var operationsMap_gen = require('./operations-map.gen-mwk22v4l.cjs');
3046
3209
  "description": "Client-generated key that makes a retry of this request safe. The first request carrying a given key executes normally and its response (status, content type and body) is stored for 24 hours; a later request with the same key returns that stored response without running the operation again, so a retry after a lost or timed-out response cannot create a second resource.\n\nReusing a key with a different request body returns `409 Conflict`: a key is a promise about one specific request, so a changed body is a client bug rather than a retry. Keys are scoped to the calling organization (or to the user, for account-scoped tokens), so one tenant can never read another's stored response.\n\nA `5xx`, `408` or `429` is never stored, because those describe a request that produced no settled answer and the next attempt with the same key must run for real. A `4xx` is stored: it is the server's settled answer about this exact request.\n\nUse a fresh UUID per logical operation. The PgBeam SDKs generate one per call and reuse it across their own automatic retries."
3047
3210
  }
3048
3211
  ],
3049
- "requestBodyType": "{ description?: string; enabled?: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"audit_checkpoint\" | \"webhook.test\")[]; format?: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; secret?: string; url: string }",
3212
+ "requestBodyType": "{ description?: string; enabled?: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"content_flagged\" | \"audit_checkpoint\" | \"webhook.test\")[]; format?: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; secret?: string; url: string }",
3050
3213
  "requestBodyRequired": true,
3051
- "responseType": "{ created_at: string; description?: string; enabled: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"audit_checkpoint\" | \"webhook.test\")[]; format: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; id: string; project_id: string; updated_at: string; url: string }",
3214
+ "responseType": "{ created_at: string; description?: string; enabled: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"content_flagged\" | \"audit_checkpoint\" | \"webhook.test\")[]; format: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; id: string; project_id: string; updated_at: string; url: string }",
3052
3215
  "responseStatus": "201"
3053
3216
  },
3054
3217
  "getWebhookEndpoint": {
@@ -3082,7 +3245,7 @@ var operationsMap_gen = require('./operations-map.gen-mwk22v4l.cjs');
3082
3245
  ],
3083
3246
  "requestBodyType": "",
3084
3247
  "requestBodyRequired": false,
3085
- "responseType": "{ created_at: string; description?: string; enabled: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"audit_checkpoint\" | \"webhook.test\")[]; format: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; id: string; project_id: string; updated_at: string; url: string }",
3248
+ "responseType": "{ created_at: string; description?: string; enabled: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"content_flagged\" | \"audit_checkpoint\" | \"webhook.test\")[]; format: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; id: string; project_id: string; updated_at: string; url: string }",
3086
3249
  "responseStatus": "200"
3087
3250
  },
3088
3251
  "updateWebhookEndpoint": {
@@ -3114,9 +3277,9 @@ var operationsMap_gen = require('./operations-map.gen-mwk22v4l.cjs');
3114
3277
  "description": "Entity tag the write is based on, taken from the `ETag` of the read that produced the values being sent. The write proceeds only if it still matches the current representation; otherwise it is refused with `412 Precondition Failed` and nothing is changed.\n\nThis is what makes a read-modify-write safe. Without it the last writer wins and a concurrent edit is silently discarded, which is the failure an agent is most likely to cause and least likely to notice. The `412` response carries the current `ETag`, so a caller can re-read, re-apply its change and retry.\n\nOmitting the header keeps the old unconditional behaviour. `*` matches any current representation, which asserts only that the resource exists."
3115
3278
  }
3116
3279
  ],
3117
- "requestBodyType": "{ description?: string; enabled?: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"audit_checkpoint\" | \"webhook.test\")[]; format?: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; secret?: string; url: string }",
3280
+ "requestBodyType": "{ description?: string; enabled?: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"content_flagged\" | \"audit_checkpoint\" | \"webhook.test\")[]; format?: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; secret?: string; url: string }",
3118
3281
  "requestBodyRequired": true,
3119
- "responseType": "{ created_at: string; description?: string; enabled: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"audit_checkpoint\" | \"webhook.test\")[]; format: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; id: string; project_id: string; updated_at: string; url: string }",
3282
+ "responseType": "{ created_at: string; description?: string; enabled: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"content_flagged\" | \"audit_checkpoint\" | \"webhook.test\")[]; format: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; id: string; project_id: string; updated_at: string; url: string }",
3120
3283
  "responseStatus": "200"
3121
3284
  },
3122
3285
  "deleteWebhookEndpoint": {
@@ -1,4 +1,4 @@
1
- export { xU as ApiOperations, xV as ApiTag, xW as RequestMap, xX as Route, xY as operationsByPath, xZ as operationsByTag } from './operations-map.gen-gsmkoqb5.js';
1
+ export { z0 as ApiOperations, z1 as ApiTag, z2 as RequestMap, z3 as Route, z4 as operationsByPath, z5 as operationsByTag } from './operations-map.gen-jrixe5ek.js';
2
2
 
3
3
  /**
4
4
  * Generated by generate-sdk-ts-maps.ts from backend/openapi/bundles/public.yaml — do not edit manually.
@@ -1,4 +1,4 @@
1
- export { xU as ApiOperations, xV as ApiTag, xW as RequestMap, xX as Route, xY as operationsByPath, xZ as operationsByTag } from './operations-map.gen-gsmkoqb5.js';
1
+ export { z0 as ApiOperations, z1 as ApiTag, z2 as RequestMap, z3 as Route, z4 as operationsByPath, z5 as operationsByTag } from './operations-map.gen-jrixe5ek.js';
2
2
 
3
3
  /**
4
4
  * Generated by generate-sdk-ts-maps.ts from backend/openapi/bundles/public.yaml — do not edit manually.
@@ -1,4 +1,4 @@
1
- export { o as operationsByPath, a as operationsByTag } from './operations-map.gen-cr323vpc.js';
1
+ export { o as operationsByPath, a as operationsByTag } from './operations-map.gen-gmrf5uyf.js';
2
2
 
3
3
  /**
4
4
  * Generated by generate-sdk-ts-maps.ts from backend/openapi/bundles/public.yaml — do not edit manually.
@@ -327,6 +327,169 @@ export { o as operationsByPath, a as operationsByTag } from './operations-map.ge
327
327
  "responseType": "{ acknowledged_at?: string; acknowledged_by?: string; created_at: string; credential_id?: string; details?: Record<string, unknown>; id: string; kind: string; project_id: string; severity: \"info\" | \"warning\" | \"critical\"; status: \"open\" | \"acknowledged\" | \"resolved\"; title: string; window_end?: string; window_start?: string }",
328
328
  "responseStatus": "200"
329
329
  },
330
+ "listAnomalyRules": {
331
+ "operationId": "listAnomalyRules",
332
+ "method": "GET",
333
+ "path": "/v1/projects/{project_id}/anomaly-rules",
334
+ "summary": "List anomaly rules",
335
+ "description": "Lists the project's anomaly rules, including silenced ones.",
336
+ "parameters": [
337
+ {
338
+ "name": "project_id",
339
+ "in": "path",
340
+ "required": true,
341
+ "type": "string",
342
+ "description": "Unique project identifier (prefixed, e.g. prj_xxx)."
343
+ },
344
+ {
345
+ "name": "page_size",
346
+ "in": "query",
347
+ "required": false,
348
+ "type": "number",
349
+ "description": "Maximum number of items to return (1-100, default 20)."
350
+ },
351
+ {
352
+ "name": "page_token",
353
+ "in": "query",
354
+ "required": false,
355
+ "type": "string",
356
+ "description": "Opaque token for cursor-based pagination."
357
+ },
358
+ {
359
+ "name": "If-None-Match",
360
+ "in": "header",
361
+ "required": false,
362
+ "type": "string",
363
+ "description": "Entity tag the client already holds, taken from the `ETag` of an earlier response. When it still matches the current representation the server answers `304 Not Modified` with no body, so a poll that finds nothing changed costs a round trip rather than a transfer.\n\nA comma-separated list is accepted, and `*` matches any current representation."
364
+ }
365
+ ],
366
+ "requestBodyType": "",
367
+ "requestBodyRequired": false,
368
+ "responseType": "{ anomaly_rules: ({ created_at: string; credential_id?: string; enabled: boolean; floor?: number; id: string; metric: \"queries_per_hour\" | \"bytes_per_hour\" | \"distinct_shapes\" | \"errors_per_hour\" | \"active_hours\"; project_id: string; sigma_threshold?: number; updated_at: string })[]; next_page_token?: string }",
369
+ "responseStatus": "200"
370
+ },
371
+ "createAnomalyRule": {
372
+ "operationId": "createAnomalyRule",
373
+ "method": "POST",
374
+ "path": "/v1/projects/{project_id}/anomaly-rules",
375
+ "summary": "Create an anomaly rule",
376
+ "description": "Retunes one detection metric for this project, or for one agent credential\nin it. Without a rule every metric resolves to the deployment default.\n\nA rule adds no detection algorithm and no alert kind: it changes how\nsensitive one of the five existing metrics is. enabled=false silences that\nmetric for that scope; the baseline keeps advancing, so re-enabling\nresumes from the existing history rather than a cold warm-up.\n",
377
+ "parameters": [
378
+ {
379
+ "name": "project_id",
380
+ "in": "path",
381
+ "required": true,
382
+ "type": "string",
383
+ "description": "Unique project identifier (prefixed, e.g. prj_xxx)."
384
+ },
385
+ {
386
+ "name": "Idempotency-Key",
387
+ "in": "header",
388
+ "required": false,
389
+ "type": "string",
390
+ "description": "Client-generated key that makes a retry of this request safe. The first request carrying a given key executes normally and its response (status, content type and body) is stored for 24 hours; a later request with the same key returns that stored response without running the operation again, so a retry after a lost or timed-out response cannot create a second resource.\n\nReusing a key with a different request body returns `409 Conflict`: a key is a promise about one specific request, so a changed body is a client bug rather than a retry. Keys are scoped to the calling organization (or to the user, for account-scoped tokens), so one tenant can never read another's stored response.\n\nA `5xx`, `408` or `429` is never stored, because those describe a request that produced no settled answer and the next attempt with the same key must run for real. A `4xx` is stored: it is the server's settled answer about this exact request.\n\nUse a fresh UUID per logical operation. The PgBeam SDKs generate one per call and reuse it across their own automatic retries."
391
+ }
392
+ ],
393
+ "requestBodyType": "{ credential_id?: string; enabled?: boolean; floor?: number; metric: \"queries_per_hour\" | \"bytes_per_hour\" | \"distinct_shapes\" | \"errors_per_hour\" | \"active_hours\"; sigma_threshold?: number }",
394
+ "requestBodyRequired": true,
395
+ "responseType": "{ created_at: string; credential_id?: string; enabled: boolean; floor?: number; id: string; metric: \"queries_per_hour\" | \"bytes_per_hour\" | \"distinct_shapes\" | \"errors_per_hour\" | \"active_hours\"; project_id: string; sigma_threshold?: number; updated_at: string }",
396
+ "responseStatus": "201"
397
+ },
398
+ "getAnomalyRule": {
399
+ "operationId": "getAnomalyRule",
400
+ "method": "GET",
401
+ "path": "/v1/projects/{project_id}/anomaly-rules/{anomaly_rule_id}",
402
+ "summary": "Get an anomaly rule",
403
+ "description": "Returns a single anomaly rule by ID.",
404
+ "parameters": [
405
+ {
406
+ "name": "project_id",
407
+ "in": "path",
408
+ "required": true,
409
+ "type": "string",
410
+ "description": "Unique project identifier (prefixed, e.g. prj_xxx)."
411
+ },
412
+ {
413
+ "name": "anomaly_rule_id",
414
+ "in": "path",
415
+ "required": true,
416
+ "type": "string",
417
+ "description": "Unique anomaly rule identifier (prefixed, e.g. anr_xxx)."
418
+ },
419
+ {
420
+ "name": "If-None-Match",
421
+ "in": "header",
422
+ "required": false,
423
+ "type": "string",
424
+ "description": "Entity tag the client already holds, taken from the `ETag` of an earlier response. When it still matches the current representation the server answers `304 Not Modified` with no body, so a poll that finds nothing changed costs a round trip rather than a transfer.\n\nA comma-separated list is accepted, and `*` matches any current representation."
425
+ }
426
+ ],
427
+ "requestBodyType": "",
428
+ "requestBodyRequired": false,
429
+ "responseType": "{ created_at: string; credential_id?: string; enabled: boolean; floor?: number; id: string; metric: \"queries_per_hour\" | \"bytes_per_hour\" | \"distinct_shapes\" | \"errors_per_hour\" | \"active_hours\"; project_id: string; sigma_threshold?: number; updated_at: string }",
430
+ "responseStatus": "200"
431
+ },
432
+ "updateAnomalyRule": {
433
+ "operationId": "updateAnomalyRule",
434
+ "method": "PUT",
435
+ "path": "/v1/projects/{project_id}/anomaly-rules/{anomaly_rule_id}",
436
+ "summary": "Update an anomaly rule",
437
+ "description": "Replaces the rule's scope, metric and sensitivity. A rule whose enabled\nflag is turned off silences its metric for its scope rather than being\ndeactivated.\n",
438
+ "parameters": [
439
+ {
440
+ "name": "project_id",
441
+ "in": "path",
442
+ "required": true,
443
+ "type": "string",
444
+ "description": "Unique project identifier (prefixed, e.g. prj_xxx)."
445
+ },
446
+ {
447
+ "name": "anomaly_rule_id",
448
+ "in": "path",
449
+ "required": true,
450
+ "type": "string",
451
+ "description": "Unique anomaly rule identifier (prefixed, e.g. anr_xxx)."
452
+ },
453
+ {
454
+ "name": "If-Match",
455
+ "in": "header",
456
+ "required": false,
457
+ "type": "string",
458
+ "description": "Entity tag the write is based on, taken from the `ETag` of the read that produced the values being sent. The write proceeds only if it still matches the current representation; otherwise it is refused with `412 Precondition Failed` and nothing is changed.\n\nThis is what makes a read-modify-write safe. Without it the last writer wins and a concurrent edit is silently discarded, which is the failure an agent is most likely to cause and least likely to notice. The `412` response carries the current `ETag`, so a caller can re-read, re-apply its change and retry.\n\nOmitting the header keeps the old unconditional behaviour. `*` matches any current representation, which asserts only that the resource exists."
459
+ }
460
+ ],
461
+ "requestBodyType": "{ credential_id?: string; enabled?: boolean; floor?: number; metric: \"queries_per_hour\" | \"bytes_per_hour\" | \"distinct_shapes\" | \"errors_per_hour\" | \"active_hours\"; sigma_threshold?: number }",
462
+ "requestBodyRequired": true,
463
+ "responseType": "{ created_at: string; credential_id?: string; enabled: boolean; floor?: number; id: string; metric: \"queries_per_hour\" | \"bytes_per_hour\" | \"distinct_shapes\" | \"errors_per_hour\" | \"active_hours\"; project_id: string; sigma_threshold?: number; updated_at: string }",
464
+ "responseStatus": "200"
465
+ },
466
+ "deleteAnomalyRule": {
467
+ "operationId": "deleteAnomalyRule",
468
+ "method": "DELETE",
469
+ "path": "/v1/projects/{project_id}/anomaly-rules/{anomaly_rule_id}",
470
+ "summary": "Delete an anomaly rule",
471
+ "description": "Removes the rule, so its metric returns to the deployment default for that\nscope. Deleting a rule that was silencing a metric turns that metric's\nalerts back on.\n",
472
+ "parameters": [
473
+ {
474
+ "name": "project_id",
475
+ "in": "path",
476
+ "required": true,
477
+ "type": "string",
478
+ "description": "Unique project identifier (prefixed, e.g. prj_xxx)."
479
+ },
480
+ {
481
+ "name": "anomaly_rule_id",
482
+ "in": "path",
483
+ "required": true,
484
+ "type": "string",
485
+ "description": "Unique anomaly rule identifier (prefixed, e.g. anr_xxx)."
486
+ }
487
+ ],
488
+ "requestBodyType": "",
489
+ "requestBodyRequired": false,
490
+ "responseType": "",
491
+ "responseStatus": "204"
492
+ },
330
493
  "listApprovalRequests": {
331
494
  "operationId": "listApprovalRequests",
332
495
  "method": "GET",
@@ -3019,7 +3182,7 @@ export { o as operationsByPath, a as operationsByTag } from './operations-map.ge
3019
3182
  ],
3020
3183
  "requestBodyType": "",
3021
3184
  "requestBodyRequired": false,
3022
- "responseType": "{ next_page_token?: string; webhooks: ({ created_at: string; description?: string; enabled: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"audit_checkpoint\" | \"webhook.test\")[]; format: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; id: string; project_id: string; updated_at: string; url: string })[] }",
3185
+ "responseType": "{ next_page_token?: string; webhooks: ({ created_at: string; description?: string; enabled: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"content_flagged\" | \"audit_checkpoint\" | \"webhook.test\")[]; format: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; id: string; project_id: string; updated_at: string; url: string })[] }",
3023
3186
  "responseStatus": "200"
3024
3187
  },
3025
3188
  "createWebhookEndpoint": {
@@ -3044,9 +3207,9 @@ export { o as operationsByPath, a as operationsByTag } from './operations-map.ge
3044
3207
  "description": "Client-generated key that makes a retry of this request safe. The first request carrying a given key executes normally and its response (status, content type and body) is stored for 24 hours; a later request with the same key returns that stored response without running the operation again, so a retry after a lost or timed-out response cannot create a second resource.\n\nReusing a key with a different request body returns `409 Conflict`: a key is a promise about one specific request, so a changed body is a client bug rather than a retry. Keys are scoped to the calling organization (or to the user, for account-scoped tokens), so one tenant can never read another's stored response.\n\nA `5xx`, `408` or `429` is never stored, because those describe a request that produced no settled answer and the next attempt with the same key must run for real. A `4xx` is stored: it is the server's settled answer about this exact request.\n\nUse a fresh UUID per logical operation. The PgBeam SDKs generate one per call and reuse it across their own automatic retries."
3045
3208
  }
3046
3209
  ],
3047
- "requestBodyType": "{ description?: string; enabled?: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"audit_checkpoint\" | \"webhook.test\")[]; format?: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; secret?: string; url: string }",
3210
+ "requestBodyType": "{ description?: string; enabled?: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"content_flagged\" | \"audit_checkpoint\" | \"webhook.test\")[]; format?: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; secret?: string; url: string }",
3048
3211
  "requestBodyRequired": true,
3049
- "responseType": "{ created_at: string; description?: string; enabled: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"audit_checkpoint\" | \"webhook.test\")[]; format: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; id: string; project_id: string; updated_at: string; url: string }",
3212
+ "responseType": "{ created_at: string; description?: string; enabled: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"content_flagged\" | \"audit_checkpoint\" | \"webhook.test\")[]; format: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; id: string; project_id: string; updated_at: string; url: string }",
3050
3213
  "responseStatus": "201"
3051
3214
  },
3052
3215
  "getWebhookEndpoint": {
@@ -3080,7 +3243,7 @@ export { o as operationsByPath, a as operationsByTag } from './operations-map.ge
3080
3243
  ],
3081
3244
  "requestBodyType": "",
3082
3245
  "requestBodyRequired": false,
3083
- "responseType": "{ created_at: string; description?: string; enabled: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"audit_checkpoint\" | \"webhook.test\")[]; format: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; id: string; project_id: string; updated_at: string; url: string }",
3246
+ "responseType": "{ created_at: string; description?: string; enabled: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"content_flagged\" | \"audit_checkpoint\" | \"webhook.test\")[]; format: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; id: string; project_id: string; updated_at: string; url: string }",
3084
3247
  "responseStatus": "200"
3085
3248
  },
3086
3249
  "updateWebhookEndpoint": {
@@ -3112,9 +3275,9 @@ export { o as operationsByPath, a as operationsByTag } from './operations-map.ge
3112
3275
  "description": "Entity tag the write is based on, taken from the `ETag` of the read that produced the values being sent. The write proceeds only if it still matches the current representation; otherwise it is refused with `412 Precondition Failed` and nothing is changed.\n\nThis is what makes a read-modify-write safe. Without it the last writer wins and a concurrent edit is silently discarded, which is the failure an agent is most likely to cause and least likely to notice. The `412` response carries the current `ETag`, so a caller can re-read, re-apply its change and retry.\n\nOmitting the header keeps the old unconditional behaviour. `*` matches any current representation, which asserts only that the resource exists."
3113
3276
  }
3114
3277
  ],
3115
- "requestBodyType": "{ description?: string; enabled?: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"audit_checkpoint\" | \"webhook.test\")[]; format?: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; secret?: string; url: string }",
3278
+ "requestBodyType": "{ description?: string; enabled?: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"content_flagged\" | \"audit_checkpoint\" | \"webhook.test\")[]; format?: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; secret?: string; url: string }",
3116
3279
  "requestBodyRequired": true,
3117
- "responseType": "{ created_at: string; description?: string; enabled: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"audit_checkpoint\" | \"webhook.test\")[]; format: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; id: string; project_id: string; updated_at: string; url: string }",
3280
+ "responseType": "{ created_at: string; description?: string; enabled: boolean; event_types?: (\"query_blocked\" | \"budget_exhausted\" | \"kill_switch\" | \"masked\" | \"migration_flagged\" | \"approval_requested\" | \"anomaly_alert\" | \"canary_tripped\" | \"content_flagged\" | \"audit_checkpoint\" | \"webhook.test\")[]; format: \"json\" | \"splunk_hec\" | \"datadog\" | \"elastic\"; id: string; project_id: string; updated_at: string; url: string }",
3118
3281
  "responseStatus": "200"
3119
3282
  },
3120
3283
  "deleteWebhookEndpoint": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pgbeam",
3
- "version": "0.4.16",
3
+ "version": "0.4.18",
4
4
  "description": "TypeScript SDK for the PgBeam API, a Postgres proxy for safe AI agent access with policy enforcement in the wire protocol",
5
5
  "type": "module",
6
6
  "exports": {
@@ -47,13 +47,13 @@
47
47
  ],
48
48
  "homepage": "https://pgbeam.com",
49
49
  "devDependencies": {
50
- "@kubb/adapter-oas": "5.2.5",
50
+ "@kubb/adapter-oas": "5.3.10",
51
51
  "@kubb/middleware-barrel": "5.0.0-beta.35",
52
52
  "@kubb/plugin-ts": "5.0.2",
53
53
  "@pgbeam/config": "0.0.1",
54
54
  "@typescript/typescript6": "6.0.2",
55
55
  "bunchee": "7.0.1",
56
- "kubb": "5.2.5",
56
+ "kubb": "5.3.10",
57
57
  "typescript": "7.0.2"
58
58
  },
59
59
  "scripts": {