默认情况下,排序以升序方式提供。 要按降序排序,请附加 %20desc 到 顺序(_O) 参数的值。
要了解某个字段是否可以排序,请将“可排序”参数检查到资源元数据中。 如需详细信息,请参阅此部分。
示例请求
用于检索数据库中按字母顺序排列的电子邮件的示例GET请求。
-X GET https://mc.adobe.io/<ORGANIZATION>/campaign/profileAndServices/profile/email?_order=email \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer <ACCESS_TOKEN>' \
-H 'Cache-Control: no-cache' \
-H 'X-Api-Key: <API_KEY>'
对请求的响应。
{
"content": [
"adam@email.com",
"allison.durance@example.com",
"amy.dakota@mail.com",
"andrea.johnson@mail.com",
...
]
...
}
在数据库中以降序Alpha顺序检索电子邮件的示例GET请求。
-X GET https://mc.adobe.io/<ORGANIZATION>/campaign/profileAndServices/profile/email?_order=email%20desc \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer <ACCESS_TOKEN>' \
-H 'Cache-Control: no-cache' \
-H 'X-Api-Key: <API_KEY>'
对请求的响应。
{
"content": [
"tombinder@example.com",
"tombinder@example.com",
"timross@example.com",
"john.smith@example.com",
...
]
}