:warning: App Search and Workplace Search will be discontinued in 9.0
Starting with Elastic version 9.0, the standalone Enterprise Search products, will no longer be included in our offering.
They remain supported in their current form in version 8.x and will only receive security upgrades and fixes.
Enterprise Search clients will continue to be supported in their current form throughout 8.x versions, according to our EOL policy.
We recommend transitioning to our actively developed Elastic Stack tools for your search use cases. However, if you're still using any Enterprise Search products, we recommend using the latest stable release of the clients.
Here are some useful links with more information:
. 
Official Node.js client for Elastic Enterprise Search, App Search, and Workplace Search.
:information_source: Read the full documentation for this client at elastic.co.
Install
npm install @elastic/enterprise-search
Quick start
const { Client } = require('@elastic/enterprise-search')
const client = new Client({
url: 'http://localhost:3002',
auth: {
username: 'elastic',
password: 'changeme'
}
auth: {
token: 'my-token'
}
})
const response = await client.enterprise.getHealth()
console.log(response)
const response = await client.app.search({
engine_name: 'games',
body: {
query: 'Pack-Man'
}
})
console.log(response)
const response = await client.workplace.getDocument({
content_source_id: 'test',
document_id: 'id'
})
console.log(response)
License
This software is licensed under the Apache 2 license.