Weird error using AWS Elasticsearch with Laravel ES packages

Using these packages:


Here is my dotenv:

ES_HOST=search-****-w3skhs3k55*****trko6qhjsxq.eu-central-1.es.amazonaws.com
ES_PORT=443
ES_SCHEME=https

I'm getting this error while trying to add an index:

{"message":"Authorization header requires 'Credential' parameter. Authorization header requires 'Signature' parameter. Authorization header requires 'SignedHeaders' parameter. Authorization header requires existence of either a 'X-Amz-Date' or a 'Date' header. Authorization=Basic Og=="}

But! All works okay when I'm creating index/adding json document to AWS ES directly via rest client without any additional headers which described in exception! What am I missing?

It could be something specific with the AWS service, as they don't run native Elasticsearch.

1 Like

Hi @warkolm and thank you for you reply!
Nobody answered me before and I'm stuck with that issue :frowning:

Could you please explain in more details what exactly do you mean? Where should I take a look at to search for solution?

Also why in that case all works with restful client like Insomnia (with simple http/https requests to AWS ES endpoints)?

Not an answer but did you look at https://www.elastic.co/cloud and https://aws.amazon.com/marketplace/pp/B01N6YCISK ?

Cloud by elastic is one way to have access to all features, all managed by us. Think about what is there yet like Security, Monitoring, Reporting, SQL, Canvas, APM, Logs UI, Infra UI and what is coming next :slight_smile: ...

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.