Groups
Merge groups
Merge one or more source groups into the group identified by `groupId`. The destination keeps its ID, receives the final name, emoji, and de-duplicated union of contact memberships, while selected sou
POST /v2/groups/{groupId}/merge
Parameters
Path parameters
groupId
string (uuid) required
Header parameters
Idempotency-Key
string required
Required. UUID per logical operation, reused on every retry. See
apps/rest-api/src/shared/idempotency.ts for the full contract. Missing → 400 BadRequest; same key + different body → 409 Conflict.Request body
Content-Type: application/json
sourceGroupIds
array<string (uuid)> required
finalName
string required
finalEmoji
string required
Example
{
"sourceGroupIds": [
"00000000-0000-0000-0000-000000000000"
],
"finalName": "string",
"finalEmoji": "string"
}
Responses
200 — Successful response
Content-Type: application/json
data
object required
data.group
any required
data.mergedGroupIds
array<string (uuid)> required
data.reparentedGroupIds
array<string (uuid)> required
data.contactIds
array<string (uuid)> required
data.movedViewIds
array<string (uuid)> required
data.deletedFavoriteIds
array<string (uuid)> required
data.deletedShareLinkIds
array<string (uuid)> required
Example
{
"data": {
"group": null,
"mergedGroupIds": [
"00000000-0000-0000-0000-000000000000"
],
"reparentedGroupIds": [
"00000000-0000-0000-0000-000000000000"
],
"contactIds": [
"00000000-0000-0000-0000-000000000000"
],
"movedViewIds": [
"00000000-0000-0000-0000-000000000000"
],
"deletedFavoriteIds": [
"00000000-0000-0000-0000-000000000000"
],
"deletedShareLinkIds": [
"00000000-0000-0000-0000-000000000000"
]
}
}
400 — Request body failed validation.
Content-Type: application/json
(body)
any
401 — Missing or invalid API key.
Content-Type: application/json
(body)
any
403 — Valid key, insufficient permission.
Content-Type: application/json
(body)
any
404 — Resource does not exist.
Content-Type: application/json
(body)
any
409 — Request conflicts with the current state of the resource.
Content-Type: application/json
(body)
any
429 — Rate limit exceeded.
Content-Type: application/json
(body)
any
500 — Unexpected server error.
Content-Type: application/json
(body)
any
Code samples
curl https://api.prod.getdex.com/v2/groups/00000000-0000-0000-0000-000000000000/merge \
--request POST \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/json' \
--data '{
"sourceGroupIds": [
"00000000-0000-0000-0000-000000000000"
],
"finalName": "string",
"finalEmoji": "string"
}'
fetch('https://api.prod.getdex.com/v2/groups/00000000-0000-0000-0000-000000000000/merge', {
method: 'POST',
headers: {
Authorization: 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
sourceGroupIds: ['00000000-0000-0000-0000-000000000000'],
finalName: 'string',
finalEmoji: 'string'
})
})
requests.post(
"https://api.prod.getdex.com/v2/groups/00000000-0000-0000-0000-000000000000/merge",
headers={
"Authorization": "Bearer YOUR_API_KEY",
"Content-Type": "application/json"
},
json={
"sourceGroupIds": [
"00000000-0000-0000-0000-000000000000"
],
"finalName": "string",
"finalEmoji": "string"
}
)
Get a group
Retrieve a single group by its unique ID. Returns the canonical envelope: `{ data: { group: {...} } }`. Pass `?include[is_favorite]=true` to inflate the response with a computed `is_favorite` boolean,
Bulk-delete groups
Permanently delete multiple groups in a single request. Uses `Promise.allSettled` semantics: a 200 response can carry per-row failures in `data.failed[]` so cache writers can invalidate just the rows

