# Index creation failing using Nest 7.6.1 with "Root mapping definition has unsupported parameters"

**URL:** <https://discuss.elastic.co/t/index-creation-failing-using-nest-7-6-1-with-root-mapping-definition-has-unsupported-parameters/225672>\
**Category:** Elasticsearch\
**Created:** [March 30, 2020, 12:32pm UTC](https://discuss.elastic.co/t/index-creation-failing-using-nest-7-6-1-with-root-mapping-definition-has-unsupported-parameters/225672 "2020-03-30T12:32:24Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Shahed\_Aziz](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/shahed_aziz/32/65311_2.png) [@Shahed\_Aziz](https://discuss.elastic.co/u/Shahed_Aziz)\
**Post date:** [March 30, 2020, 12:32pm UTC](https://discuss.elastic.co/t/index-creation-failing-using-nest-7-6-1-with-root-mapping-definition-has-unsupported-parameters/225672/1 "2020-03-30T12:32:25Z")

</div>

Hi,

Im trying to create index for a very simple class. My class :

```auto
    public class ElasticSearchDto
    {
        public string Id { get; set; }
        public string ApplicationNumber { get; set; }
    }

```

Using the following code to create my index (using Elasticsearch.Net.Aws as im using aws elastic search service)

```auto
    var httpConnection = new AwsHttpConnection();

    var pool = new SingleNodeConnectionPool(uri);
    var config = new ConnectionSettings(pool, httpConnection).DisableDirectStreaming().PrettyJson();
    var client = new ElasticClient(config);

    var result = client.Indices.Create("Test", x => x
        .Map<ElasticSearchDto>(m => m
            .Properties(ps => ps
                .Text(t => t.Name(n => n.Id))
                .Text(t => t.Name(n => n.ApplicationNumber)))
        )
    );

```

Also tried auto mapping, nothing work. Getting the following response.

```auto
# Request:
{"mappings":{"properties":{"id":{"type":"text"},"applicationNumber":{"type":"text"}}}}
# Response:
{
  "error" : {
    "root_cause" : [
      {
        "type" : "mapper_parsing_exception",
        "reason" : "Root mapping definition has unsupported parameters: [applicationNumber : {type=text}] [id : {type=text}]"
      }
    ],
    "type" : "mapper_parsing_exception",
    "reason" : "Failed to parse mapping [properties]: Root mapping definition has unsupported parameters: [applicationNumber : {type=text}] [id : {type=text}]",
    "caused_by" : {
      "type" : "mapper_parsing_exception",
      "reason" : "Root mapping definition has unsupported parameters: [applicationNumber : {type=text}] [id : {type=text}]"
    }
  },
  "status" : 400
}

```

I will really appreciate some help on this.

Kind regards,

Shahed

---

<div class="post-metadata">

**Author:** ![forloop](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/forloop/32/9021_2.png) [@forloop](https://discuss.elastic.co/u/forloop)\
**Post date:** [March 31, 2020, 6:13am UTC](https://discuss.elastic.co/t/index-creation-failing-using-nest-7-6-1-with-root-mapping-definition-has-unsupported-parameters/225672/2 "2020-03-31T06:13:03Z")

</div>

NEST 7.6.1 is compatible with Elasticsearch 7.x.

What version of Elasticsearch are you using? It sounds like you might be using a version older than 7.x, based on the error message.

---

<div class="post-metadata">

**Author:** ![Shahed\_Aziz](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/shahed_aziz/32/65311_2.png) [@Shahed\_Aziz](https://discuss.elastic.co/u/Shahed_Aziz)\
**Post date:** [March 31, 2020, 8:50am UTC](https://discuss.elastic.co/t/index-creation-failing-using-nest-7-6-1-with-root-mapping-definition-has-unsupported-parameters/225672/3 "2020-03-31T08:50:57Z")

</div>

You are absolutely right. I was using an older version of local stack that was not spinning up with Elastic search version 7.x. Hence the issue. I updated my local stack. Thank you so much for your help

---

<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:** [April 28, 2020, 8:50am UTC](https://discuss.elastic.co/t/index-creation-failing-using-nest-7-6-1-with-root-mapping-definition-has-unsupported-parameters/225672/4 "2020-04-28T08:50:59Z")

</div>

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