Not able to sort the records properly while Export

While using the export API endpoint under CRM, we are not able to sort the results in descending order although the document specifies it.

Just to confirm the documentation says that the order for descending should be DES.

Also the documentation states the request body should be of this format:

///Example request body
{
“exportType”: “VIEW”,
“exportName”: “All contacts”,
“format”: “xlsx”,
“language”: “DE”,
“objectType”: “CONTACT”,
“exportInternalValuesOptions”: [“NAMES”, “VALUES”],
“objectProperties”: [“email”, “firstname”, “lastname”],
“associatedObjectType”: “COMPANY”,
“publicCrmSearchRequest”: {
“filters”: [
{
“value”: " hello@test.com",
“propertyName”: “email”,
“operator”: “EQ”
}
],
“query”: “hello”,
“sorts”: [
      {
        “propertyName”: “hs_object_id”,
        “order”: “DES”
      }
    ]

}
}

Can you please let us know about this issue ASAP.

Thanks & Regards,

Hubspot AWS Team

Hi @hubspotAWS,

Instead of DES, try using DESC:

“propertyName”: “hs_object_id”,
“order”: “DESC”

Josh

Tried that as well. But, it’s the same behaviour.

Is there any other solution. Any help is appreciated!!!