@athenaintel/sdk 4.3.308 → 4.3.309

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.
@@ -49,8 +49,8 @@ class AthenaIntelligenceClient {
49
49
  this._options = Object.assign(Object.assign({}, _options), { headers: (0, headers_js_1.mergeHeaders)({
50
50
  "X-Fern-Language": "JavaScript",
51
51
  "X-Fern-SDK-Name": "@athenaintel/sdk",
52
- "X-Fern-SDK-Version": "4.3.308",
53
- "User-Agent": "@athenaintel/sdk/4.3.308",
52
+ "X-Fern-SDK-Version": "4.3.309",
53
+ "User-Agent": "@athenaintel/sdk/4.3.309",
54
54
  "X-Fern-Runtime": core.RUNTIME.type,
55
55
  "X-Fern-Runtime-Version": core.RUNTIME.version,
56
56
  }, _options === null || _options === void 0 ? void 0 : _options.headers) });
@@ -94,11 +94,11 @@ export declare class Databases {
94
94
  /**
95
95
  * Delete rows matching the filter conditions. Filter conditions are passed as query parameters using PostgREST syntax (e.g., `?id=eq.5`).
96
96
  *
97
- * **Warning:** Without filters, this will delete ALL rows in the table.
97
+ * **Safety:** Filters are required by default to prevent accidental bulk deletes. To delete all rows intentionally, pass `?force=true`.
98
98
  *
99
99
  * @param {string} assetId
100
100
  * @param {string} tableName
101
- * @param {AthenaIntelligence.DeleteDataRequest} request
101
+ * @param {AthenaIntelligence.DatabasesDeleteRequest} request
102
102
  * @param {Databases.RequestOptions} requestOptions - Request-specific configuration.
103
103
  *
104
104
  * @throws {@link AthenaIntelligence.BadRequestError}
@@ -110,15 +110,18 @@ export declare class Databases {
110
110
  *
111
111
  * @example
112
112
  * await client.databases.delete("asset_id", "table_name", {
113
- * return_representation: false
113
+ * force: true,
114
+ * body: {
115
+ * return_representation: false
116
+ * }
114
117
  * })
115
118
  */
116
- delete(assetId: string, tableName: string, request?: AthenaIntelligence.DeleteDataRequest, requestOptions?: Databases.RequestOptions): core.HttpResponsePromise<AthenaIntelligence.DatabaseMutationResponse>;
119
+ delete(assetId: string, tableName: string, request?: AthenaIntelligence.DatabasesDeleteRequest, requestOptions?: Databases.RequestOptions): core.HttpResponsePromise<AthenaIntelligence.DatabaseMutationResponse>;
117
120
  private __delete;
118
121
  /**
119
122
  * Update rows matching the filter conditions. Filter conditions are passed as query parameters using PostgREST syntax (e.g., `?id=eq.5`).
120
123
  *
121
- * **Warning:** Without filters, this will update ALL rows in the table.
124
+ * **Safety:** Filters are required by default to prevent accidental bulk updates. To update all rows intentionally, pass `?force=true`.
122
125
  *
123
126
  * @param {string} assetId
124
127
  * @param {string} tableName
@@ -134,6 +137,7 @@ export declare class Databases {
134
137
  *
135
138
  * @example
136
139
  * await client.databases.update("asset_id", "table_name", {
140
+ * force: true,
137
141
  * data: {
138
142
  * "email": "alice.smith@example.com",
139
143
  * "name": "Alice Smith"
@@ -42,6 +42,17 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
42
42
  step((generator = generator.apply(thisArg, _arguments || [])).next());
43
43
  });
44
44
  };
45
+ var __rest = (this && this.__rest) || function (s, e) {
46
+ var t = {};
47
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
48
+ t[p] = s[p];
49
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
50
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
51
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
52
+ t[p[i]] = s[p[i]];
53
+ }
54
+ return t;
55
+ };
45
56
  Object.defineProperty(exports, "__esModule", { value: true });
46
57
  exports.Databases = void 0;
47
58
  const environments = __importStar(require("../../../../environments.js"));
@@ -331,11 +342,11 @@ class Databases {
331
342
  /**
332
343
  * Delete rows matching the filter conditions. Filter conditions are passed as query parameters using PostgREST syntax (e.g., `?id=eq.5`).
333
344
  *
334
- * **Warning:** Without filters, this will delete ALL rows in the table.
345
+ * **Safety:** Filters are required by default to prevent accidental bulk deletes. To delete all rows intentionally, pass `?force=true`.
335
346
  *
336
347
  * @param {string} assetId
337
348
  * @param {string} tableName
338
- * @param {AthenaIntelligence.DeleteDataRequest} request
349
+ * @param {AthenaIntelligence.DatabasesDeleteRequest} request
339
350
  * @param {Databases.RequestOptions} requestOptions - Request-specific configuration.
340
351
  *
341
352
  * @throws {@link AthenaIntelligence.BadRequestError}
@@ -347,24 +358,32 @@ class Databases {
347
358
  *
348
359
  * @example
349
360
  * await client.databases.delete("asset_id", "table_name", {
350
- * return_representation: false
361
+ * force: true,
362
+ * body: {
363
+ * return_representation: false
364
+ * }
351
365
  * })
352
366
  */
353
- delete(assetId, tableName, request, requestOptions) {
367
+ delete(assetId, tableName, request = {}, requestOptions) {
354
368
  return core.HttpResponsePromise.fromPromise(this.__delete(assetId, tableName, request, requestOptions));
355
369
  }
356
- __delete(assetId, tableName, request, requestOptions) {
357
- return __awaiter(this, void 0, void 0, function* () {
370
+ __delete(assetId_1, tableName_1) {
371
+ return __awaiter(this, arguments, void 0, function* (assetId, tableName, request = {}, requestOptions) {
358
372
  var _a, _b, _c, _d, _e, _f, _g, _h, _j;
373
+ const { force, body: _body } = request;
374
+ const _queryParams = {};
375
+ if (force != null) {
376
+ _queryParams["force"] = force.toString();
377
+ }
359
378
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
360
379
  const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
361
380
  url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.AthenaIntelligenceEnvironment.Production, `api/v0/databases/${encodeURIComponent(assetId)}/data/${encodeURIComponent(tableName)}`),
362
381
  method: "DELETE",
363
382
  headers: _headers,
364
383
  contentType: "application/json",
365
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
384
+ queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
366
385
  requestType: "json",
367
- body: request != null ? request : undefined,
386
+ body: _body != null ? _body : undefined,
368
387
  timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
369
388
  maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
370
389
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
@@ -417,7 +436,7 @@ class Databases {
417
436
  /**
418
437
  * Update rows matching the filter conditions. Filter conditions are passed as query parameters using PostgREST syntax (e.g., `?id=eq.5`).
419
438
  *
420
- * **Warning:** Without filters, this will update ALL rows in the table.
439
+ * **Safety:** Filters are required by default to prevent accidental bulk updates. To update all rows intentionally, pass `?force=true`.
421
440
  *
422
441
  * @param {string} assetId
423
442
  * @param {string} tableName
@@ -433,6 +452,7 @@ class Databases {
433
452
  *
434
453
  * @example
435
454
  * await client.databases.update("asset_id", "table_name", {
455
+ * force: true,
436
456
  * data: {
437
457
  * "email": "alice.smith@example.com",
438
458
  * "name": "Alice Smith"
@@ -446,15 +466,20 @@ class Databases {
446
466
  __update(assetId, tableName, request, requestOptions) {
447
467
  return __awaiter(this, void 0, void 0, function* () {
448
468
  var _a, _b, _c, _d, _e, _f, _g, _h, _j;
469
+ const { force } = request, _body = __rest(request, ["force"]);
470
+ const _queryParams = {};
471
+ if (force != null) {
472
+ _queryParams["force"] = force.toString();
473
+ }
449
474
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
450
475
  const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
451
476
  url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.AthenaIntelligenceEnvironment.Production, `api/v0/databases/${encodeURIComponent(assetId)}/data/${encodeURIComponent(tableName)}`),
452
477
  method: "PATCH",
453
478
  headers: _headers,
454
479
  contentType: "application/json",
455
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
480
+ queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
456
481
  requestType: "json",
457
- body: request,
482
+ body: _body,
458
483
  timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
459
484
  maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
460
485
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
@@ -0,0 +1,15 @@
1
+ import * as AthenaIntelligence from "../../../../index.js";
2
+ /**
3
+ * @example
4
+ * {
5
+ * force: true,
6
+ * body: {
7
+ * return_representation: false
8
+ * }
9
+ * }
10
+ */
11
+ export interface DatabasesDeleteRequest {
12
+ /** Set to true to delete all rows (required when no filters provided) */
13
+ force?: boolean;
14
+ body?: AthenaIntelligence.DeleteDataRequest;
15
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ // This file was auto-generated by Fern from our API Definition.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,6 +1,7 @@
1
1
  /**
2
2
  * @example
3
3
  * {
4
+ * force: true,
4
5
  * data: {
5
6
  * "email": "alice.smith@example.com",
6
7
  * "name": "Alice Smith"
@@ -9,6 +10,8 @@
9
10
  * }
10
11
  */
11
12
  export interface UpdateDataRequest {
13
+ /** Set to true to update all rows (required when no filters provided) */
14
+ force?: boolean;
12
15
  /** Column values to update */
13
16
  data: Record<string, unknown>;
14
17
  /** If true, return the updated rows in the response */
@@ -1,3 +1,4 @@
1
1
  export { type DatabasesSelectRequest } from "./DatabasesSelectRequest.js";
2
2
  export { type InsertDataRequest } from "./InsertDataRequest.js";
3
+ export { type DatabasesDeleteRequest } from "./DatabasesDeleteRequest.js";
3
4
  export { type UpdateDataRequest } from "./UpdateDataRequest.js";
@@ -1 +1 @@
1
- export declare const SDK_VERSION = "4.3.308";
1
+ export declare const SDK_VERSION = "4.3.309";
@@ -1,4 +1,4 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.SDK_VERSION = void 0;
4
- exports.SDK_VERSION = "4.3.308";
4
+ exports.SDK_VERSION = "4.3.309";
@@ -14,8 +14,8 @@ export class AthenaIntelligenceClient {
14
14
  this._options = Object.assign(Object.assign({}, _options), { headers: mergeHeaders({
15
15
  "X-Fern-Language": "JavaScript",
16
16
  "X-Fern-SDK-Name": "@athenaintel/sdk",
17
- "X-Fern-SDK-Version": "4.3.308",
18
- "User-Agent": "@athenaintel/sdk/4.3.308",
17
+ "X-Fern-SDK-Version": "4.3.309",
18
+ "User-Agent": "@athenaintel/sdk/4.3.309",
19
19
  "X-Fern-Runtime": core.RUNTIME.type,
20
20
  "X-Fern-Runtime-Version": core.RUNTIME.version,
21
21
  }, _options === null || _options === void 0 ? void 0 : _options.headers) });
@@ -94,11 +94,11 @@ export declare class Databases {
94
94
  /**
95
95
  * Delete rows matching the filter conditions. Filter conditions are passed as query parameters using PostgREST syntax (e.g., `?id=eq.5`).
96
96
  *
97
- * **Warning:** Without filters, this will delete ALL rows in the table.
97
+ * **Safety:** Filters are required by default to prevent accidental bulk deletes. To delete all rows intentionally, pass `?force=true`.
98
98
  *
99
99
  * @param {string} assetId
100
100
  * @param {string} tableName
101
- * @param {AthenaIntelligence.DeleteDataRequest} request
101
+ * @param {AthenaIntelligence.DatabasesDeleteRequest} request
102
102
  * @param {Databases.RequestOptions} requestOptions - Request-specific configuration.
103
103
  *
104
104
  * @throws {@link AthenaIntelligence.BadRequestError}
@@ -110,15 +110,18 @@ export declare class Databases {
110
110
  *
111
111
  * @example
112
112
  * await client.databases.delete("asset_id", "table_name", {
113
- * return_representation: false
113
+ * force: true,
114
+ * body: {
115
+ * return_representation: false
116
+ * }
114
117
  * })
115
118
  */
116
- delete(assetId: string, tableName: string, request?: AthenaIntelligence.DeleteDataRequest, requestOptions?: Databases.RequestOptions): core.HttpResponsePromise<AthenaIntelligence.DatabaseMutationResponse>;
119
+ delete(assetId: string, tableName: string, request?: AthenaIntelligence.DatabasesDeleteRequest, requestOptions?: Databases.RequestOptions): core.HttpResponsePromise<AthenaIntelligence.DatabaseMutationResponse>;
117
120
  private __delete;
118
121
  /**
119
122
  * Update rows matching the filter conditions. Filter conditions are passed as query parameters using PostgREST syntax (e.g., `?id=eq.5`).
120
123
  *
121
- * **Warning:** Without filters, this will update ALL rows in the table.
124
+ * **Safety:** Filters are required by default to prevent accidental bulk updates. To update all rows intentionally, pass `?force=true`.
122
125
  *
123
126
  * @param {string} assetId
124
127
  * @param {string} tableName
@@ -134,6 +137,7 @@ export declare class Databases {
134
137
  *
135
138
  * @example
136
139
  * await client.databases.update("asset_id", "table_name", {
140
+ * force: true,
137
141
  * data: {
138
142
  * "email": "alice.smith@example.com",
139
143
  * "name": "Alice Smith"
@@ -8,6 +8,17 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
8
8
  step((generator = generator.apply(thisArg, _arguments || [])).next());
9
9
  });
10
10
  };
11
+ var __rest = (this && this.__rest) || function (s, e) {
12
+ var t = {};
13
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
14
+ t[p] = s[p];
15
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
16
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
17
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
18
+ t[p[i]] = s[p[i]];
19
+ }
20
+ return t;
21
+ };
11
22
  import * as environments from "../../../../environments.mjs";
12
23
  import * as core from "../../../../core/index.mjs";
13
24
  import * as AthenaIntelligence from "../../../index.mjs";
@@ -295,11 +306,11 @@ export class Databases {
295
306
  /**
296
307
  * Delete rows matching the filter conditions. Filter conditions are passed as query parameters using PostgREST syntax (e.g., `?id=eq.5`).
297
308
  *
298
- * **Warning:** Without filters, this will delete ALL rows in the table.
309
+ * **Safety:** Filters are required by default to prevent accidental bulk deletes. To delete all rows intentionally, pass `?force=true`.
299
310
  *
300
311
  * @param {string} assetId
301
312
  * @param {string} tableName
302
- * @param {AthenaIntelligence.DeleteDataRequest} request
313
+ * @param {AthenaIntelligence.DatabasesDeleteRequest} request
303
314
  * @param {Databases.RequestOptions} requestOptions - Request-specific configuration.
304
315
  *
305
316
  * @throws {@link AthenaIntelligence.BadRequestError}
@@ -311,24 +322,32 @@ export class Databases {
311
322
  *
312
323
  * @example
313
324
  * await client.databases.delete("asset_id", "table_name", {
314
- * return_representation: false
325
+ * force: true,
326
+ * body: {
327
+ * return_representation: false
328
+ * }
315
329
  * })
316
330
  */
317
- delete(assetId, tableName, request, requestOptions) {
331
+ delete(assetId, tableName, request = {}, requestOptions) {
318
332
  return core.HttpResponsePromise.fromPromise(this.__delete(assetId, tableName, request, requestOptions));
319
333
  }
320
- __delete(assetId, tableName, request, requestOptions) {
321
- return __awaiter(this, void 0, void 0, function* () {
334
+ __delete(assetId_1, tableName_1) {
335
+ return __awaiter(this, arguments, void 0, function* (assetId, tableName, request = {}, requestOptions) {
322
336
  var _a, _b, _c, _d, _e, _f, _g, _h, _j;
337
+ const { force, body: _body } = request;
338
+ const _queryParams = {};
339
+ if (force != null) {
340
+ _queryParams["force"] = force.toString();
341
+ }
323
342
  let _headers = mergeHeaders((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, mergeOnlyDefinedHeaders(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
324
343
  const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
325
344
  url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.AthenaIntelligenceEnvironment.Production, `api/v0/databases/${encodeURIComponent(assetId)}/data/${encodeURIComponent(tableName)}`),
326
345
  method: "DELETE",
327
346
  headers: _headers,
328
347
  contentType: "application/json",
329
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
348
+ queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
330
349
  requestType: "json",
331
- body: request != null ? request : undefined,
350
+ body: _body != null ? _body : undefined,
332
351
  timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
333
352
  maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
334
353
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
@@ -381,7 +400,7 @@ export class Databases {
381
400
  /**
382
401
  * Update rows matching the filter conditions. Filter conditions are passed as query parameters using PostgREST syntax (e.g., `?id=eq.5`).
383
402
  *
384
- * **Warning:** Without filters, this will update ALL rows in the table.
403
+ * **Safety:** Filters are required by default to prevent accidental bulk updates. To update all rows intentionally, pass `?force=true`.
385
404
  *
386
405
  * @param {string} assetId
387
406
  * @param {string} tableName
@@ -397,6 +416,7 @@ export class Databases {
397
416
  *
398
417
  * @example
399
418
  * await client.databases.update("asset_id", "table_name", {
419
+ * force: true,
400
420
  * data: {
401
421
  * "email": "alice.smith@example.com",
402
422
  * "name": "Alice Smith"
@@ -410,15 +430,20 @@ export class Databases {
410
430
  __update(assetId, tableName, request, requestOptions) {
411
431
  return __awaiter(this, void 0, void 0, function* () {
412
432
  var _a, _b, _c, _d, _e, _f, _g, _h, _j;
433
+ const { force } = request, _body = __rest(request, ["force"]);
434
+ const _queryParams = {};
435
+ if (force != null) {
436
+ _queryParams["force"] = force.toString();
437
+ }
413
438
  let _headers = mergeHeaders((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, mergeOnlyDefinedHeaders(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
414
439
  const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
415
440
  url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.AthenaIntelligenceEnvironment.Production, `api/v0/databases/${encodeURIComponent(assetId)}/data/${encodeURIComponent(tableName)}`),
416
441
  method: "PATCH",
417
442
  headers: _headers,
418
443
  contentType: "application/json",
419
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
444
+ queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
420
445
  requestType: "json",
421
- body: request,
446
+ body: _body,
422
447
  timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
423
448
  maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
424
449
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
@@ -0,0 +1,15 @@
1
+ import * as AthenaIntelligence from "../../../../index.mjs";
2
+ /**
3
+ * @example
4
+ * {
5
+ * force: true,
6
+ * body: {
7
+ * return_representation: false
8
+ * }
9
+ * }
10
+ */
11
+ export interface DatabasesDeleteRequest {
12
+ /** Set to true to delete all rows (required when no filters provided) */
13
+ force?: boolean;
14
+ body?: AthenaIntelligence.DeleteDataRequest;
15
+ }
@@ -0,0 +1,2 @@
1
+ // This file was auto-generated by Fern from our API Definition.
2
+ import * as AthenaIntelligence from "../../../../index.mjs";
@@ -1,6 +1,7 @@
1
1
  /**
2
2
  * @example
3
3
  * {
4
+ * force: true,
4
5
  * data: {
5
6
  * "email": "alice.smith@example.com",
6
7
  * "name": "Alice Smith"
@@ -9,6 +10,8 @@
9
10
  * }
10
11
  */
11
12
  export interface UpdateDataRequest {
13
+ /** Set to true to update all rows (required when no filters provided) */
14
+ force?: boolean;
12
15
  /** Column values to update */
13
16
  data: Record<string, unknown>;
14
17
  /** If true, return the updated rows in the response */
@@ -1,3 +1,4 @@
1
1
  export { type DatabasesSelectRequest } from "./DatabasesSelectRequest.mjs";
2
2
  export { type InsertDataRequest } from "./InsertDataRequest.mjs";
3
+ export { type DatabasesDeleteRequest } from "./DatabasesDeleteRequest.mjs";
3
4
  export { type UpdateDataRequest } from "./UpdateDataRequest.mjs";
@@ -1,3 +1,4 @@
1
1
  export {} from "./DatabasesSelectRequest.mjs";
2
2
  export {} from "./InsertDataRequest.mjs";
3
+ export {} from "./DatabasesDeleteRequest.mjs";
3
4
  export {} from "./UpdateDataRequest.mjs";
@@ -1 +1 @@
1
- export declare const SDK_VERSION = "4.3.308";
1
+ export declare const SDK_VERSION = "4.3.309";
@@ -1 +1 @@
1
- export const SDK_VERSION = "4.3.308";
1
+ export const SDK_VERSION = "4.3.309";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@athenaintel/sdk",
3
- "version": "4.3.308",
3
+ "version": "4.3.309",
4
4
  "private": false,
5
5
  "repository": "github:Athena-Intel/athena-typescript",
6
6
  "type": "commonjs",
package/reference.md CHANGED
@@ -764,7 +764,7 @@ await client.databases.insert("asset_id", "table_name", {
764
764
 
765
765
  Delete rows matching the filter conditions. Filter conditions are passed as query parameters using PostgREST syntax (e.g., `?id=eq.5`).
766
766
 
767
- **Warning:** Without filters, this will delete ALL rows in the table.
767
+ **Safety:** Filters are required by default to prevent accidental bulk deletes. To delete all rows intentionally, pass `?force=true`.
768
768
 
769
769
  </dd>
770
770
  </dl>
@@ -781,7 +781,10 @@ Delete rows matching the filter conditions. Filter conditions are passed as quer
781
781
 
782
782
  ```typescript
783
783
  await client.databases.delete("asset_id", "table_name", {
784
- return_representation: false,
784
+ force: true,
785
+ body: {
786
+ return_representation: false,
787
+ },
785
788
  });
786
789
  ```
787
790
 
@@ -814,7 +817,7 @@ await client.databases.delete("asset_id", "table_name", {
814
817
  <dl>
815
818
  <dd>
816
819
 
817
- **request:** `AthenaIntelligence.DeleteDataRequest`
820
+ **request:** `AthenaIntelligence.DatabasesDeleteRequest`
818
821
 
819
822
  </dd>
820
823
  </dl>
@@ -847,7 +850,7 @@ await client.databases.delete("asset_id", "table_name", {
847
850
 
848
851
  Update rows matching the filter conditions. Filter conditions are passed as query parameters using PostgREST syntax (e.g., `?id=eq.5`).
849
852
 
850
- **Warning:** Without filters, this will update ALL rows in the table.
853
+ **Safety:** Filters are required by default to prevent accidental bulk updates. To update all rows intentionally, pass `?force=true`.
851
854
 
852
855
  </dd>
853
856
  </dl>
@@ -864,6 +867,7 @@ Update rows matching the filter conditions. Filter conditions are passed as quer
864
867
 
865
868
  ```typescript
866
869
  await client.databases.update("asset_id", "table_name", {
870
+ force: true,
867
871
  data: {
868
872
  email: "alice.smith@example.com",
869
873
  name: "Alice Smith",