Favorites
Create a favorite
Star a group, view, or contact. Body must include **exactly one** of `group_id`, `view_id`, or `contact_id`. `ranking` is optional. **Requires `Idempotency-Key`.** Returns `{ data: { favorite: {...} }
POST /v2/favorites/
Request body
Content-Type: application/json
id
string (uuid)
group_id
string (uuid)
view_id
string (uuid)
contact_id
string (uuid)
ranking
integer
Example
{
"id": "00000000-0000-0000-0000-000000000000",
"group_id": "00000000-0000-0000-0000-000000000000"
}
Responses
201 — Created
Content-Type: application/json
data
object required
data.favorite
object required
data.favorite.id
string (uuid) required
data.favorite.user_id
string
data.favorite.group_id
string (uuid) | null
data.favorite.view_id
string (uuid) | null
data.favorite.contact_id
string (uuid) | null
data.favorite.ranking
integer | null
data.favorite.created_at
string (date-time) required
data.favorite.updated_at
string (date-time) required
data.favorite.groups
object | null
data.favorite.views
object | null
data.favorite.contacts
object | null
Example
{
"data": {
"favorite": {
"id": "00000000-0000-0000-0000-000000000000",
"created_at": "2026-08-21T15:31:00.974Z",
"updated_at": "2026-08-21T15:31:00.974Z"
}
}
}
400
No response body.
401
No response body.
403
No response body.
404
No response body.
409
No response body.
429
No response body.
500
No response body.
Code samples
curl https://api.prod.getdex.com/v2/favorites/ \
--request POST \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/json' \
--data '{
"id": "00000000-0000-0000-0000-000000000000",
"group_id": "00000000-0000-0000-0000-000000000000"
}'
fetch('https://api.prod.getdex.com/v2/favorites/', {
method: 'POST',
headers: {
Authorization: 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
id: '00000000-0000-0000-0000-000000000000',
group_id: '00000000-0000-0000-0000-000000000000'
})
})
requests.post(
"https://api.prod.getdex.com/v2/favorites/",
headers={
"Authorization": "Bearer YOUR_API_KEY",
"Content-Type": "application/json"
},
json={
"id": "00000000-0000-0000-0000-000000000000",
"group_id": "00000000-0000-0000-0000-000000000000"
}
)
List favorites
List all of the authenticated user's favorites across groups, views, and contacts. Returns `{ data: { favorites: [...], pagination: { nextCursor, count } } }`. Supports `?take=`, `?cursor=`, and `?ord
Count favorites
Return the count of the authenticated user's favorites. Cheap path for a sidebar badge / quota check without loading the full list.

