Field to use for the survey to data record mapping

Hi! I am importing survey data from the API into another application.

I use the assets endpoint to retrieve metadata for my project / survey:

/api/v2/assets/{id}

This gives me content such as this:

{
  "content": {
    "survey": [
      {
        "name": "Q15",
        "type": "integer",
        "$kuid": "RpbsFZikj",
        "label": ["Q15. Number of activate attends absent"],
        "$qpath": "PARTICIPATION_ACTIVITE-ABSENCE1-Q15",
        "$xpath": "PARTICIPATION_ACTIVITE/ABSENCE1/Q15",
        "required": true,
        "$autoname": "Q15"
      }
    ]
  }
}

I use the assets data endpoint to retrieve data records:

/api/v2/assets/{id}/data

This gives me a results object / map with records as expected.

{
  "results": [
    {
      "PARTICIPATION_ACTIVITE/ABSENCE1/Q15": "3"
    }
  ]
}

My question is: Which survey field property should I use to match the survey fields with the data records?

In my case, it appears to be the $xpath property. Though in other cases, it appeared to be the $autoname property.

Could you confirm which field to use for the survey to data record mapping?

Would also appreciate a pointer to documentation for the API response format, to understand which fields are mandatory, if it exists.

best regards,

Lars