AWS ElasticSearch Service Client
Unofficial AWS ElasticSearch Service client for Node.js
Getting Started
npm i @trmaphi/aws-elasticsearch-service-client @elastic/elasticsearch aws-sdk
Usage
const AWS = require('aws-sdk');
const { AWSElasticSearchClient } = require('@trmaphi/aws-elasticsearch-service-client');
AWS.config.update({
credentials: new AWS.SharedIniFileCredentials({ profile: 'YOUR LOCAL AWS PROFILE'}),
region: 'AWS REGION',
})
const client = new AWSElasticSearchClient({
node: 'URL to AWS ElasticSearch Node',
});
client.search({
index: 'Any index name',
body: { query: { match_all: {} } }
})
.then(res => console.log(res.body.hits.hits))
.catch(err => console.error(err));
Versioning
We use SemVer for versioning. For the versions available, see the tags on this repository.
Authors
- Truong Ma Phi - Initial work - trmaphi
License
This project is licensed under the MIT License - see the LICENSE.md file for details