# How to get details from \_nodes api with java client?

**URL:** https://discuss.elastic.co/t/how-to-get-details-from-nodes-api-with-java-client/305732
**Category:** Elasticsearch
**Tags:** language-clients
**Created:** [May 26, 2022, 4:09pm UTC](https://discuss.elastic.co/t/how-to-get-details-from-nodes-api-with-java-client/305732 "2022-05-26T16:09:17Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![iatalay](https://avatars.discourse-cdn.com/v4/letter/i/a183cd/32.png) [@iatalay](https://discuss.elastic.co/u/iatalay)
#### Post date: [May 26, 2022, 4:09pm UTC](https://discuss.elastic.co/t/how-to-get-details-from-nodes-api-with-java-client/305732/1 "2022-05-26T16:09:17Z")

</div>

Hello,

I am trying to get details from \_nodes api using Elasticsearch java client 7.17.3.  
Following code block throws an exception. Is there anyone have an idea about what is wrong here?

Thanks,

```java
NodesInfoRequest.Builder nodesInfoRequest = new NodesInfoRequest.Builder();
NodesInfoResponse nodesInfoResponse = esClient.nodes().info(nodesInfoRequest.build());

```

```auto
co.elastic.clients.json.JsonpMappingException: Error deserializing co.elastic.clients.elasticsearch.nodes.info.NodeInfoSettings: co.elastic.clients.util.MissingRequiredPropertyException: Missing required property 'NodeInfoPath.repo' (JSON path: nodes.xqnmmoxXQhK_3KLqXq_9aw.settings.path) (line no=1, column no=911, offset=-1)
        at co.elastic.clients.json.JsonpMappingException.from0(JsonpMappingException.java:134)
        at co.elastic.clients.json.JsonpMappingException.from(JsonpMappingException.java:121)
        at co.elastic.clients.json.ObjectDeserializer.deserialize(ObjectDeserializer.java:206)
        at co.elastic.clients.json.ObjectDeserializer.deserialize(ObjectDeserializer.java:136)
        at co.elastic.clients.json.JsonpDeserializer.deserialize(JsonpDeserializer.java:75)
        at co.elastic.clients.json.ObjectBuilderDeserializer.deserialize(ObjectBuilderDeserializer.java:79)
        at co.elastic.clients.json.DelegatingDeserializer$SameType.deserialize(DelegatingDeserializer.java:43)
        at co.elastic.clients.json.ObjectDeserializer$FieldObjectDeserializer.deserialize(ObjectDeserializer.java:71)
        at co.elastic.clients.json.ObjectDeserializer.deserialize(ObjectDeserializer.java:180)
        at co.elastic.clients.json.ObjectDeserializer.deserialize(ObjectDeserializer.java:136)
        at co.elastic.clients.json.JsonpDeserializer.deserialize(JsonpDeserializer.java:75)
        at co.elastic.clients.json.ObjectBuilderDeserializer.deserialize(ObjectBuilderDeserializer.java:79)
        at co.elastic.clients.json.DelegatingDeserializer$SameType.deserialize(DelegatingDeserializer.java:43)
        at co.elastic.clients.json.JsonpDeserializerBase$StringMapDeserializer.deserialize(JsonpDeserializerBase.java:347)
        at co.elastic.clients.json.JsonpDeserializerBase$StringMapDeserializer.deserialize(JsonpDeserializerBase.java:331)
        at co.elastic.clients.json.JsonpDeserializer.deserialize(JsonpDeserializer.java:75)
        at co.elastic.clients.json.ObjectDeserializer$FieldObjectDeserializer.deserialize(ObjectDeserializer.java:71)
        at co.elastic.clients.json.ObjectDeserializer.deserialize(ObjectDeserializer.java:180)
        at co.elastic.clients.json.ObjectDeserializer.deserialize(ObjectDeserializer.java:136)
        at co.elastic.clients.json.JsonpDeserializer.deserialize(JsonpDeserializer.java:75)
        at co.elastic.clients.json.ObjectBuilderDeserializer.deserialize(ObjectBuilderDeserializer.java:79)
        at co.elastic.clients.json.DelegatingDeserializer$SameType.deserialize(DelegatingDeserializer.java:43)
        at co.elastic.clients.transport.rest_client.RestClientTransport.decodeResponse(RestClientTransport.java:328)
        at co.elastic.clients.transport.rest_client.RestClientTransport.getHighLevelResponse(RestClientTransport.java:294)
        at co.elastic.clients.transport.rest_client.RestClientTransport.performRequest(RestClientTransport.java:147)
        at co.elastic.clients.elasticsearch.nodes.ElasticsearchNodesClient.info(ElasticsearchNodesClient.java:190)
        at App4.main(App4.java:44)
Caused by: co.elastic.clients.util.MissingRequiredPropertyException: Missing required property 'NodeInfoPath.repo'
        at co.elastic.clients.util.ApiTypeHelper.requireNonNull(ApiTypeHelper.java:76)
        at co.elastic.clients.util.ApiTypeHelper.unmodifiableRequired(ApiTypeHelper.java:141)
        at co.elastic.clients.elasticsearch.nodes.info.NodeInfoPath.<init>(NodeInfoPath.java:65)
        at co.elastic.clients.elasticsearch.nodes.info.NodeInfoPath.<init>(NodeInfoPath.java:50)
        at co.elastic.clients.elasticsearch.nodes.info.NodeInfoPath$Builder.build(NodeInfoPath.java:228)
        at co.elastic.clients.elasticsearch.nodes.info.NodeInfoPath$Builder.build(NodeInfoPath.java:148)
        at co.elastic.clients.json.ObjectBuilderDeserializer.deserialize(ObjectBuilderDeserializer.java:80)
        at co.elastic.clients.json.DelegatingDeserializer$SameType.deserialize(DelegatingDeserializer.java:43)
        at co.elastic.clients.json.ObjectDeserializer$FieldObjectDeserializer.deserialize(ObjectDeserializer.java:71)
        at co.elastic.clients.json.ObjectDeserializer.deserialize(ObjectDeserializer.java:180)
        ... 24 more

```

---

<div class="post-metadata">

### Author: ![swallez](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/swallez/32/11972_2.png) [@swallez](https://discuss.elastic.co/u/swallez)
#### Post date: [June 1, 2022, 9:53am UTC](https://discuss.elastic.co/t/how-to-get-details-from-nodes-api-with-java-client/305732/2 "2022-06-01T09:53:36Z")

</div>

This is a bug, and I opened [`NodeInfoPath.repo` should be optional · Issue #305 · elastic/elasticsearch-java · GitHub](https://github.com/elastic/elasticsearch-java/issues/305) so that we can fix it. Please subscribe to that issue to be updated when it's resolved.

In the meantime, you can use the the workaround described at [MissingRequiredPropertyException in a response | Elasticsearch Java API Client [8.2] | Elastic](https://www.elastic.co/guide/en/elasticsearch/client/java-api-client/current/missing-required-property.html)

Thanks having reported this issue!

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)
#### Post date: [June 29, 2022, 9:54am UTC](https://discuss.elastic.co/t/how-to-get-details-from-nodes-api-with-java-client/305732/3 "2022-06-29T09:54:26Z")

</div>

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