Merge different index in function two fields and paste eleement of fields

That's the idea and to eliminate redundant information I am inspired by this post (Merging documents based on matched fields values , , I work on siren investigate, I managed to make my aggregation as below :

GET df_extrait/_search?size=0
{
"aggs": {
    "my composite": {
      "composite": {
        "sources": [
          {
            "source_principal": {
              "terms": {
                "field": "source.keyword"
              }
            }
          },
          {
            "target_principal": {
              "terms": {
                "field": "target.keyword"
              }
            }
          }
        ]
        
      }
    }
  }

When I try to create a new index in this way I get this error: