Export a segment as CSV

The contacts matching a segment as CSV text, newest first, with the contact book's properties as columns.

GEThttps://app.usenotix.dev/api/v1/contactBooks/{contactBookId}/segments/{segmentId}/export

Full access and read only keys can call this. Sending access keys cannot. Key permissions lists the extra rules some calls have.

The contacts matching a segment as CSV text, newest first, with the contact book's properties as columns. limit is 1 to 5,000 (1,000 by default); truncated says when more matched. A cell that would run as a spreadsheet formula starts with an apostrophe.

Path parameters

contactBookIdstringrequired
segmentIdstringrequired

Query parameters

limitinteger

Rows to export, 1 to 5000. Defaults to 1000.

Minimum 1. Maximum 5000. Default 1000.

Headers

Authorizationstringrequired

Bearer followed by your API key.

Errors

403

The key is not FULL, or is pinned to one domain.

404

No segment with this id in the contact book for the calling team.

422

The segment took longer than 30 seconds to evaluate.

429

Another export for this team is still running.

Every error has the same shape. See all error codes.

curl -X GET "https://app.usenotix.dev/api/v1/contactBooks/<contactBookId>/segments/<segmentId>/export" \
  -H "Authorization: Bearer $NOTIX_API_KEY"
Response200
{
  "segmentId": "cm1x8f3k20001qz7v5b9d2e4a",
  "contactBookId": "cm1x8f3k20001qz7v5b9d2e4a",
  "columns": [
    "string"
  ],
  "csv": "string",
  "rows": 1,
  "truncated": true
}
Open in ClaudeOpen in ChatGPT