# Time Out on @elastic/elasticsearch node js

**URL:** <https://discuss.elastic.co/t/time-out-on-elastic-elasticsearch-node-js/376144>\
**Category:** Elasticsearch\
**Created:** [March 19, 2025, 10:12pm UTC](https://discuss.elastic.co/t/time-out-on-elastic-elasticsearch-node-js/376144 "2025-03-19T22:12:27Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Santos\_Cocom](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/santos_cocom/32/142148_2.png) [@Santos\_Cocom](https://discuss.elastic.co/u/Santos_Cocom)\
**Post date:** [March 19, 2025, 10:12pm UTC](https://discuss.elastic.co/t/time-out-on-elastic-elasticsearch-node-js/376144/1 "2025-03-19T22:12:27Z")

</div>

I've set up a cluster, but I've created an index to perform semantic searches. When I try to send a request, I always get a timeout. I use @elastic/elasticsearch with NodeJS.

```auto
const elastichSearchClient = new Client({
  cloud: { id: env.ELASTICSEARCH_CLOUD_ID },
  auth: { apiKey: env.ELASTICSEARCH_API_KEY }
})

const dataPrivate = await elastichSearchClient.search({
      index: env.ELASTICSEARCH_INDEX_PROFILES,
      body: {
        query: {
          bool: {
            must: [
              {
                semantic: {
                  field: "profesional_experience",
                  query: searchText
                }
              },
              {
                terms: {
                  "_id": user_suggested_ids.map(id => id.toString()) // Incluir solo los documentos con estos IDs
                }
              }
            ]
          }
        },
        size: count,
        _source: ["user_id"] // Solo necesitamos el user_id
      }
    });

```

Has anyone had the same problem and been able to solve it?
