ContactGroups
List contact groups
Returns the organization's contact groups, newest first, filterable by type and active state.
GET
Returns the organization's contact groups, newest first, filterable by type and active state. Pass nextCursor back as cursor for the next page; it is null on the last page.
apiKeyheader
x-api-key<token>limit?|nullcursor?stringtype?|array<>isActive?boolean|nullContactGroupPage
application/json- response
items*array<>nextCursor*string|nullimport { createClient } from "samva";const samva = createClient({ apiKey: process.env.SAMVA_API_KEY! });const result = await samva.contactGroups.list({});Example Response
{ "items": [ { "id": "string", "organizationId": "string", "name": "string", "description": "string", "type": "static", "criteria": { "property1": "string", "property2": "string" }, "color": "clay", "icon": "string", "parentGroupId": "string", "contactCount": 0, "lastCalculatedAt": "string", "isActive": true, "createdAt": "string", "updatedAt": "string" } ], "nextCursor": "string"}Related documentation
List members of a contact group
Returns a contact group's members, most recently joined first. Pass `nextCursor` back as `cursor` for the next page; it is null on the last page.
Preview contact group criteria
Evaluates group criteria without persisting, returning the matching contact count and a sample of matches.