{
  "template": {
    "mappings": {
      "properties": {
        "adapter_outcome": {
          "type": "keyword"
        },
        "adapter_duration_ms": {
          "type": "long",
          "meta": {
            "unit": "ms",
            "metric_type": "gauge"
          }
        },
        "adapter_request_method": {
          "type": "keyword"
        },
        "adapter_response_status_code": {
          "type": "short"
        },

        "adapter_url_host": {
          "type": "keyword"
        },
        "adapter_url_template": {
          "type": "keyword"
        },
        "adapter_url_path": {
          "type": "keyword",
          "doc_values": false
        },
        "adapter_url_query": {
          "type": "keyword",
          "doc_values": false
        },

        "adapter_slow": {
          "type": "boolean"
        },

        "adapter_request_headers": {
          "type": "keyword",
          "index": false,
          "doc_values": false
        },
        "adapter_response_headers": {
          "type": "keyword",
          "index": false,
          "doc_values": false
        },
        "adapter_request_body": {
          "type": "keyword",
          "index": false,
          "doc_values": false
        },
        "adapter_response_body": {
          "type": "keyword",
          "index": false,
          "doc_values": false
        }
      }
    }
  },
  "_meta": {
    "description": "Field mappings for the adapter_* exchange-log fields emitted by the legatium-restclient-logging and legatium-webclient-logging modules (one shared field enum, inlined into both). This is the DEFINITION, not an extract: the family is not yet part of any upstream data-stream mapping, and whoever wires the module into a log pipeline composes this template there. The MDC-carried fields (adapter_request_id, adapter_method, adapter_route, traceId, spanId) are deliberately absent - how MDC entries land in the document is the encoder's decision, not this module's.",
    "source": "docs/elk/README.md",
    "authority": "legatium-common/src/main/kotlin/eu/inqudium/legatium/common/ClientLogFields.kt"
  }
}
