Socket
Socket
Sign inDemoInstall

@elastic/elasticsearch

Package Overview
Dependencies
Maintainers
53
Versions
107
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@elastic/elasticsearch - npm Package Compare versions

Comparing version 8.7.0 to 8.8.0

.buildkite/Dockerfile

2

index.d.ts

@@ -25,4 +25,4 @@ /*

export * as estypes from './lib/api/types'
export * as estypesWithBody from './lib/api/types'
export * as estypesWithBody from './lib/api/typesWithBodyKey'
export { Client, SniffingTransport }
export type { ClientOptions, NodeOptions } from './lib/client'

@@ -7,5 +7,5 @@ import { Transport, TransportRequestOptions, TransportRequestOptionsWithMeta, TransportRequestOptionsWithOutMeta, TransportResult } from '@elastic/transport';

}
export default function HealthReportApi(this: That, params?: T.TODO | TB.TODO, options?: TransportRequestOptionsWithOutMeta): Promise<T.TODO>;
export default function HealthReportApi(this: That, params?: T.TODO | TB.TODO, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.TODO, unknown>>;
export default function HealthReportApi(this: That, params?: T.TODO | TB.TODO, options?: TransportRequestOptions): Promise<T.TODO>;
export default function HealthReportApi(this: That, params?: T.HealthReportRequest | TB.HealthReportRequest, options?: TransportRequestOptionsWithOutMeta): Promise<T.HealthReportResponse>;
export default function HealthReportApi(this: That, params?: T.HealthReportRequest | TB.HealthReportRequest, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.HealthReportResponse, unknown>>;
export default function HealthReportApi(this: That, params?: T.HealthReportRequest | TB.HealthReportRequest, options?: TransportRequestOptions): Promise<T.HealthReportResponse>;
export {};

@@ -31,2 +31,3 @@ "use strict";

else if (key !== 'body') {
// @ts-expect-error
querystring[key] = params[key];

@@ -33,0 +34,0 @@ }

@@ -40,2 +40,5 @@ import { Transport, TransportRequestOptions, TransportRequestOptionsWithMeta, TransportRequestOptionsWithOutMeta, TransportResult } from '@elastic/transport';

deleteAlias(this: That, params: T.IndicesDeleteAliasRequest | TB.IndicesDeleteAliasRequest, options?: TransportRequestOptions): Promise<T.IndicesDeleteAliasResponse>;
deleteDataLifecycle(this: That, params: T.IndicesDeleteDataLifecycleRequest | TB.IndicesDeleteDataLifecycleRequest, options?: TransportRequestOptionsWithOutMeta): Promise<T.IndicesDeleteDataLifecycleResponse>;
deleteDataLifecycle(this: That, params: T.IndicesDeleteDataLifecycleRequest | TB.IndicesDeleteDataLifecycleRequest, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.IndicesDeleteDataLifecycleResponse, unknown>>;
deleteDataLifecycle(this: That, params: T.IndicesDeleteDataLifecycleRequest | TB.IndicesDeleteDataLifecycleRequest, options?: TransportRequestOptions): Promise<T.IndicesDeleteDataLifecycleResponse>;
deleteDataStream(this: That, params: T.IndicesDeleteDataStreamRequest | TB.IndicesDeleteDataStreamRequest, options?: TransportRequestOptionsWithOutMeta): Promise<T.IndicesDeleteDataStreamResponse>;

@@ -68,2 +71,5 @@ deleteDataStream(this: That, params: T.IndicesDeleteDataStreamRequest | TB.IndicesDeleteDataStreamRequest, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.IndicesDeleteDataStreamResponse, unknown>>;

existsTemplate(this: That, params: T.IndicesExistsTemplateRequest | TB.IndicesExistsTemplateRequest, options?: TransportRequestOptions): Promise<T.IndicesExistsTemplateResponse>;
explainDataLifecycle(this: That, params: T.IndicesExplainDataLifecycleRequest | TB.IndicesExplainDataLifecycleRequest, options?: TransportRequestOptionsWithOutMeta): Promise<T.IndicesExplainDataLifecycleResponse>;
explainDataLifecycle(this: That, params: T.IndicesExplainDataLifecycleRequest | TB.IndicesExplainDataLifecycleRequest, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.IndicesExplainDataLifecycleResponse, unknown>>;
explainDataLifecycle(this: That, params: T.IndicesExplainDataLifecycleRequest | TB.IndicesExplainDataLifecycleRequest, options?: TransportRequestOptions): Promise<T.IndicesExplainDataLifecycleResponse>;
fieldUsageStats(this: That, params: T.IndicesFieldUsageStatsRequest | TB.IndicesFieldUsageStatsRequest, options?: TransportRequestOptionsWithOutMeta): Promise<T.IndicesFieldUsageStatsResponse>;

@@ -84,2 +90,5 @@ fieldUsageStats(this: That, params: T.IndicesFieldUsageStatsRequest | TB.IndicesFieldUsageStatsRequest, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.IndicesFieldUsageStatsResponse, unknown>>;

getAlias(this: That, params?: T.IndicesGetAliasRequest | TB.IndicesGetAliasRequest, options?: TransportRequestOptions): Promise<T.IndicesGetAliasResponse>;
getDataLifecycle(this: That, params: T.IndicesGetDataLifecycleRequest | TB.IndicesGetDataLifecycleRequest, options?: TransportRequestOptionsWithOutMeta): Promise<T.IndicesGetDataLifecycleResponse>;
getDataLifecycle(this: That, params: T.IndicesGetDataLifecycleRequest | TB.IndicesGetDataLifecycleRequest, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.IndicesGetDataLifecycleResponse, unknown>>;
getDataLifecycle(this: That, params: T.IndicesGetDataLifecycleRequest | TB.IndicesGetDataLifecycleRequest, options?: TransportRequestOptions): Promise<T.IndicesGetDataLifecycleResponse>;
getDataStream(this: That, params?: T.IndicesGetDataStreamRequest | TB.IndicesGetDataStreamRequest, options?: TransportRequestOptionsWithOutMeta): Promise<T.IndicesGetDataStreamResponse>;

@@ -118,2 +127,5 @@ getDataStream(this: That, params?: T.IndicesGetDataStreamRequest | TB.IndicesGetDataStreamRequest, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.IndicesGetDataStreamResponse, unknown>>;

putAlias(this: That, params: T.IndicesPutAliasRequest | TB.IndicesPutAliasRequest, options?: TransportRequestOptions): Promise<T.IndicesPutAliasResponse>;
putDataLifecycle(this: That, params: T.IndicesPutDataLifecycleRequest | TB.IndicesPutDataLifecycleRequest, options?: TransportRequestOptionsWithOutMeta): Promise<T.IndicesPutDataLifecycleResponse>;
putDataLifecycle(this: That, params: T.IndicesPutDataLifecycleRequest | TB.IndicesPutDataLifecycleRequest, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.IndicesPutDataLifecycleResponse, unknown>>;
putDataLifecycle(this: That, params: T.IndicesPutDataLifecycleRequest | TB.IndicesPutDataLifecycleRequest, options?: TransportRequestOptions): Promise<T.IndicesPutDataLifecycleResponse>;
putIndexTemplate(this: That, params: T.IndicesPutIndexTemplateRequest | TB.IndicesPutIndexTemplateRequest, options?: TransportRequestOptionsWithOutMeta): Promise<T.IndicesPutIndexTemplateResponse>;

@@ -120,0 +132,0 @@ putIndexTemplate(this: That, params: T.IndicesPutIndexTemplateRequest | TB.IndicesPutIndexTemplateRequest, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.IndicesPutIndexTemplateResponse, unknown>>;

@@ -278,2 +278,19 @@ "use strict";

}
async deleteDataLifecycle(params, options) {
const acceptedPath = ['name'];
const querystring = {};
const body = undefined;
for (const key in params) {
if (acceptedPath.includes(key)) {
continue;
}
else if (key !== 'body') {
// @ts-expect-error
querystring[key] = params[key];
}
}
const method = 'DELETE';
const path = `/_data_stream/${encodeURIComponent(params.name.toString())}/_lifecycle`;
return await this.transport.request({ path, method, querystring, body }, options);
}
async deleteDataStream(params, options) {

@@ -447,2 +464,19 @@ const acceptedPath = ['name'];

}
async explainDataLifecycle(params, options) {
const acceptedPath = ['index'];
const querystring = {};
const body = undefined;
for (const key in params) {
if (acceptedPath.includes(key)) {
continue;
}
else if (key !== 'body') {
// @ts-expect-error
querystring[key] = params[key];
}
}
const method = 'GET';
const path = `/${encodeURIComponent(params.index.toString())}/_lifecycle/explain`;
return await this.transport.request({ path, method, querystring, body }, options);
}
async fieldUsageStats(params, options) {

@@ -568,2 +602,19 @@ const acceptedPath = ['index'];

}
async getDataLifecycle(params, options) {
const acceptedPath = ['name'];
const querystring = {};
const body = undefined;
for (const key in params) {
if (acceptedPath.includes(key)) {
continue;
}
else if (key !== 'body') {
// @ts-expect-error
querystring[key] = params[key];
}
}
const method = 'GET';
const path = `/_data_stream/${encodeURIComponent(params.name.toString())}/_lifecycle`;
return await this.transport.request({ path, method, querystring, body }, options);
}
async getDataStream(params, options) {

@@ -853,2 +904,33 @@ const acceptedPath = ['name'];

}
async putDataLifecycle(params, options) {
const acceptedPath = ['name'];
const acceptedBody = ['data_retention'];
const querystring = {};
// @ts-expect-error
const userBody = params === null || params === void 0 ? void 0 : params.body;
let body;
if (typeof userBody === 'string') {
body = userBody;
}
else {
body = userBody != null ? { ...userBody } : undefined;
}
for (const key in params) {
if (acceptedBody.includes(key)) {
body = body !== null && body !== void 0 ? body : {};
// @ts-expect-error
body[key] = params[key];
}
else if (acceptedPath.includes(key)) {
continue;
}
else if (key !== 'body') {
// @ts-expect-error
querystring[key] = params[key];
}
}
const method = 'PUT';
const path = `/_data_stream/${encodeURIComponent(params.name.toString())}/_lifecycle`;
return await this.transport.request({ path, method, querystring, body }, options);
}
async putIndexTemplate(params, options) {

@@ -855,0 +937,0 @@ const acceptedPath = ['name'];

@@ -61,4 +61,12 @@ "use strict";

}
const method = 'GET';
const path = `/_logstash/pipeline/${encodeURIComponent(params.id.toString())}`;
let method = '';
let path = '';
if (params.id != null) {
method = 'GET';
path = `/_logstash/pipeline/${encodeURIComponent(params.id.toString())}`;
}
else {
method = 'GET';
path = '/_logstash/pipeline';
}
return await this.transport.request({ path, method, querystring, body }, options);

@@ -65,0 +73,0 @@ }

@@ -70,3 +70,3 @@ "use strict";

method = 'GET';
path = '/_rollup/job/';
path = '/_rollup/job';
}

@@ -97,3 +97,3 @@ return await this.transport.request({ path, method, querystring, body }, options);

method = 'GET';
path = '/_rollup/data/';
path = '/_rollup/data';
}

@@ -100,0 +100,0 @@ return await this.transport.request({ path, method, querystring, body }, options);

@@ -964,3 +964,3 @@ "use strict";

const method = 'PUT';
const path = '/_security/privilege/';
const path = '/_security/privilege';
return await this.transport.request({ path, method, querystring, body }, options);

@@ -967,0 +967,0 @@ }

@@ -237,3 +237,3 @@ "use strict";

const acceptedPath = ['repository', 'snapshot'];
const acceptedBody = ['ignore_index_settings', 'ignore_unavailable', 'include_aliases', 'include_global_state', 'index_settings', 'indices', 'partial', 'rename_pattern', 'rename_replacement'];
const acceptedBody = ['feature_states', 'ignore_index_settings', 'ignore_unavailable', 'include_aliases', 'include_global_state', 'index_settings', 'indices', 'partial', 'rename_pattern', 'rename_replacement'];
const querystring = {};

@@ -240,0 +240,0 @@ // @ts-expect-error

@@ -28,5 +28,5 @@ import { Transport, TransportRequestOptions, TransportRequestOptionsWithMeta, TransportRequestOptionsWithOutMeta, TransportResult } from '@elastic/transport';

resetTransform(this: That, params: T.TransformResetTransformRequest | TB.TransformResetTransformRequest, options?: TransportRequestOptions): Promise<T.TransformResetTransformResponse>;
scheduleNowTransform(this: That, params?: T.TODO | TB.TODO, options?: TransportRequestOptionsWithOutMeta): Promise<T.TODO>;
scheduleNowTransform(this: That, params?: T.TODO | TB.TODO, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.TODO, unknown>>;
scheduleNowTransform(this: That, params?: T.TODO | TB.TODO, options?: TransportRequestOptions): Promise<T.TODO>;
scheduleNowTransform(this: That, params: T.TransformScheduleNowTransformRequest | TB.TransformScheduleNowTransformRequest, options?: TransportRequestOptionsWithOutMeta): Promise<T.TransformScheduleNowTransformResponse>;
scheduleNowTransform(this: That, params: T.TransformScheduleNowTransformRequest | TB.TransformScheduleNowTransformRequest, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.TransformScheduleNowTransformResponse, unknown>>;
scheduleNowTransform(this: That, params: T.TransformScheduleNowTransformRequest | TB.TransformScheduleNowTransformRequest, options?: TransportRequestOptions): Promise<T.TransformScheduleNowTransformResponse>;
startTransform(this: That, params: T.TransformStartTransformRequest | TB.TransformStartTransformRequest, options?: TransportRequestOptionsWithOutMeta): Promise<T.TransformStartTransformResponse>;

@@ -33,0 +33,0 @@ startTransform(this: That, params: T.TransformStartTransformRequest | TB.TransformStartTransformRequest, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.TransformStartTransformResponse, unknown>>;

@@ -183,3 +183,2 @@ "use strict";

const body = undefined;
params = params !== null && params !== void 0 ? params : {};
for (const key in params) {

@@ -190,2 +189,3 @@ if (acceptedPath.includes(key)) {

else if (key !== 'body') {
// @ts-expect-error
querystring[key] = params[key];

@@ -192,0 +192,0 @@ }

@@ -25,2 +25,5 @@ import { Transport, TransportRequestOptions, TransportRequestOptionsWithMeta, TransportRequestOptionsWithOutMeta, TransportResult } from '@elastic/transport';

executeWatch(this: That, params?: T.WatcherExecuteWatchRequest | TB.WatcherExecuteWatchRequest, options?: TransportRequestOptions): Promise<T.WatcherExecuteWatchResponse>;
getSettings(this: That, params?: T.TODO | TB.TODO, options?: TransportRequestOptionsWithOutMeta): Promise<T.TODO>;
getSettings(this: That, params?: T.TODO | TB.TODO, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.TODO, unknown>>;
getSettings(this: That, params?: T.TODO | TB.TODO, options?: TransportRequestOptions): Promise<T.TODO>;
getWatch(this: That, params: T.WatcherGetWatchRequest | TB.WatcherGetWatchRequest, options?: TransportRequestOptionsWithOutMeta): Promise<T.WatcherGetWatchResponse>;

@@ -44,3 +47,6 @@ getWatch(this: That, params: T.WatcherGetWatchRequest | TB.WatcherGetWatchRequest, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.WatcherGetWatchResponse, unknown>>;

stop(this: That, params?: T.WatcherStopRequest | TB.WatcherStopRequest, options?: TransportRequestOptions): Promise<T.WatcherStopResponse>;
updateSettings(this: That, params?: T.TODO | TB.TODO, options?: TransportRequestOptionsWithOutMeta): Promise<T.TODO>;
updateSettings(this: That, params?: T.TODO | TB.TODO, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.TODO, unknown>>;
updateSettings(this: That, params?: T.TODO | TB.TODO, options?: TransportRequestOptions): Promise<T.TODO>;
}
export {};

@@ -147,2 +147,19 @@ "use strict";

}
async getSettings(params, options) {
const acceptedPath = [];
const querystring = {};
const body = undefined;
params = params !== null && params !== void 0 ? params : {};
for (const key in params) {
if (acceptedPath.includes(key)) {
continue;
}
else if (key !== 'body') {
querystring[key] = params[key];
}
}
const method = 'GET';
const path = '/_watcher/settings';
return await this.transport.request({ path, method, querystring, body }, options);
}
async getWatch(params, options) {

@@ -290,4 +307,21 @@ const acceptedPath = ['id'];

}
async updateSettings(params, options) {
const acceptedPath = [];
const querystring = {};
const body = undefined;
params = params !== null && params !== void 0 ? params : {};
for (const key in params) {
if (acceptedPath.includes(key)) {
continue;
}
else if (key !== 'body') {
querystring[key] = params[key];
}
}
const method = 'PUT';
const path = '/_watcher/settings';
return await this.transport.request({ path, method, querystring, body }, options);
}
}
exports.default = Watcher;
//# sourceMappingURL=watcher.js.map

@@ -58,2 +58,3 @@ import AsyncSearchApi from './api/async_search';

import searchApi from './api/search';
import SearchApplicationApi from './api/search_application';
import searchMvtApi from './api/search_mvt';

@@ -138,2 +139,3 @@ import searchShardsApi from './api/search_shards';

search: typeof searchApi;
searchApplication: SearchApplicationApi;
searchMvt: typeof searchMvtApi;

@@ -181,2 +183,3 @@ searchShards: typeof searchShardsApi;

declare const kRollup: unique symbol;
declare const kSearchApplication: unique symbol;
declare const kSearchableSnapshots: unique symbol;

@@ -216,2 +219,3 @@ declare const kSecurity: unique symbol;

[kRollup]: symbol | null;
[kSearchApplication]: symbol | null;
[kSearchableSnapshots]: symbol | null;

@@ -218,0 +222,0 @@ [kSecurity]: symbol | null;

@@ -20,3 +20,3 @@ "use strict";

*/
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8;
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8, _9;
Object.defineProperty(exports, "__esModule", { value: true });

@@ -88,2 +88,3 @@ const tslib_1 = require("tslib");

const search_1 = tslib_1.__importDefault(require("./api/search"));
const search_application_1 = tslib_1.__importDefault(require("./api/search_application"));
const search_mvt_1 = tslib_1.__importDefault(require("./api/search_mvt"));

@@ -130,2 +131,3 @@ const search_shards_1 = tslib_1.__importDefault(require("./api/search_shards"));

const kRollup = Symbol('Rollup');
const kSearchApplication = Symbol('SearchApplication');
const kSearchableSnapshots = Symbol('SearchableSnapshots');

@@ -343,2 +345,8 @@ const kSecurity = Symbol('Security');

});
Object.defineProperty(this, _9, {
enumerable: true,
configurable: true,
writable: true,
value: void 0
});
this[kAsyncSearch] = null;

@@ -365,2 +373,3 @@ this[kAutoscaling] = null;

this[kRollup] = null;
this[kSearchApplication] = null;
this[kSearchableSnapshots] = null;

@@ -381,3 +390,3 @@ this[kSecurity] = null;

exports.default = API;
_a = kAsyncSearch, _b = kAutoscaling, _c = kCat, _d = kCcr, _e = kCluster, _f = kDanglingIndices, _g = kEnrich, _h = kEql, _j = kFeatures, _k = kFleet, _l = kGraph, _m = kIlm, _o = kIndices, _p = kIngest, _q = kLicense, _r = kLogstash, _s = kMigration, _t = kMl, _u = kMonitoring, _v = kNodes, _w = kRollup, _x = kSearchableSnapshots, _y = kSecurity, _z = kShutdown, _0 = kSlm, _1 = kSnapshot, _2 = kSql, _3 = kSsl, _4 = kTasks, _5 = kTextStructure, _6 = kTransform, _7 = kWatcher, _8 = kXpack;
_a = kAsyncSearch, _b = kAutoscaling, _c = kCat, _d = kCcr, _e = kCluster, _f = kDanglingIndices, _g = kEnrich, _h = kEql, _j = kFeatures, _k = kFleet, _l = kGraph, _m = kIlm, _o = kIndices, _p = kIngest, _q = kLicense, _r = kLogstash, _s = kMigration, _t = kMl, _u = kMonitoring, _v = kNodes, _w = kRollup, _x = kSearchApplication, _y = kSearchableSnapshots, _z = kSecurity, _0 = kShutdown, _1 = kSlm, _2 = kSnapshot, _3 = kSql, _4 = kSsl, _5 = kTasks, _6 = kTextStructure, _7 = kTransform, _8 = kWatcher, _9 = kXpack;
API.prototype.bulk = bulk_1.default;

@@ -491,2 +500,5 @@ API.prototype.clearScroll = clear_scroll_1.default;

},
searchApplication: {
get() { return this[kSearchApplication] === null ? (this[kSearchApplication] = new search_application_1.default(this.transport)) : this[kSearchApplication]; }
},
searchableSnapshots: {

@@ -493,0 +505,0 @@ get() { return this[kSearchableSnapshots] === null ? (this[kSearchableSnapshots] = new searchable_snapshots_1.default(this.transport)) : this[kSearchableSnapshots]; }

@@ -24,2 +24,3 @@ "use strict";

const buffer_1 = tslib_1.__importDefault(require("buffer"));
const os_1 = tslib_1.__importDefault(require("os"));
const transport_1 = require("@elastic/transport");

@@ -131,3 +132,5 @@ const BaseConnection_1 = require("@elastic/transport/lib/connection/BaseConnection");

agent: null,
headers: {},
headers: {
'user-agent': `elasticsearch-js/${clientVersion} Node.js ${nodeVersion}; Transport ${transportVersion}; (${os_1.default.platform()} ${os_1.default.release()} ${os_1.default.arch()})`
},
nodeFilter: null,

@@ -134,0 +137,0 @@ generateRequestId: null,

{
"name": "@elastic/elasticsearch",
"version": "8.7.0",
"versionCanary": "8.7.0-canary.1",
"version": "8.8.0",
"versionCanary": "8.8.0-canary.2",
"description": "The official Elasticsearch client for Node.js",

@@ -6,0 +6,0 @@ "main": "index.js",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc