In this section, we will add environment variables to the Lambda function to ensure it can interact with the OpenSearch Service domain.
upload-data
)ES_DOMAIN_URL
https://search-water-temp-domain-xxxxxxxxxxxxxxxxxxxxxxxxx.us-east-1.es.amazonaws.com
Ensure that the OpenSearch Service domain endpoint doesn’t have a slash (/) at the end.
5. Choose Save.
You have successfully added an environment variable to the Lambda function, allowing it to interact with the OpenSearch Service domain.