Topolo Docs Topolo Platform
Open workspace

Export contacts

Export the workspace's contacts as JSON for data portability, optionally filtered by status, ordered by email. Returns at most 5000 contacts; truncated is true when more exist, in which case page through contacts.list instead.

Outcome

Export the workspace's contacts as JSON for data portability, optionally filtered by status, ordered by email. Returns at most 5000 contacts; truncated is true when more exist, in which case page through contacts.list instead.

Before you start

  • Verify identity and pin the intended organization and environment before discovering the action.
  • Discover a granted Nurture workspace. The application permission is workspace:read; required workspace access is read. A permission alone does not supply a workspace grant.
  • Organization and workspace come from verified context. Select resourceType/resourceId separately from action input; body fields cannot grant a different organization or workspace. The first authorized product action can initialize an identity-only workspace mirror.
  • Obtain authorization for the documented effect or personal-data export before supplying CLI --confirm or MCP confirm:true.

Discover the target

topolo whoami --json
topolo actions get app_topolo_nurture.contacts.export --detail --json
topolo resources topolo-nurture --json
topolo workspaces list topolo-nurture --json

Request

GET /api/contacts/export

Save action input as payload.json. The reviewed plan separates path identifiers, query fields and HTTP body. Set NURTURE_WORKSPACE_ID from granted resource discovery; it is separate from action input.

Inspect and test this action in the signed action console. A test response still requires the verification below.

Input fields

FieldRequiredTypeConstraints
statusOptionalstring{"enum":["active","archived"]}

Exact input schema:

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "status": {
      "type": "string",
      "enum": [
        "active",
        "archived"
      ]
    }
  },
  "additionalProperties": false
}

Effects

  • Reads contacts without changing state. The response contains personal data; handle it as such.

Interpret the response

The returned identifier path is $.contacts[].id for contact. Empty lists do not discover a target.

Confirm $.truncated is false before treating the export as complete.

Exact success schema:

{
  "type": "object",
  "required": [
    "contacts",
    "truncated",
    "cap"
  ],
  "properties": {
    "contacts": {
      "type": "array",
      "items": {
        "type": "object",
        "required": [
          "id",
          "email",
          "status"
        ],
        "properties": {
          "id": {
            "type": "string"
          },
          "email": {
            "type": "string"
          },
          "emailHash": {
            "type": "string",
            "description": "Org-scoped salted SHA-256 address key shared with @topolo-io/audience."
          },
          "firstName": {
            "type": [
              "string",
              "null"
            ]
          },
          "lastName": {
            "type": [
              "string",
              "null"
            ]
          },
          "locale": {
            "type": [
              "string",
              "null"
            ]
          },
          "timezone": {
            "type": [
              "string",
              "null"
            ]
          },
          "attributes": {
            "type": "object"
          },
          "source": {
            "type": "string",
            "enum": [
              "manual",
              "csv",
              "signup",
              "connector"
            ]
          },
          "sourceRef": {
            "type": [
              "string",
              "null"
            ]
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "archived"
            ]
          },
          "createdAt": {
            "type": "string"
          },
          "updatedAt": {
            "type": "string"
          }
        }
      }
    },
    "truncated": {
      "type": "boolean"
    },
    "cap": {
      "type": "integer"
    }
  }
}

Worked examples

Actual dispatcher and migration-created SQLite or Worker handlers; identity/workspace and external service dependencies are simulated. Fixture identifiers and timestamps are synthetic. These responses establish no live authorization, paid generation, credential provisioning or message delivery. Replace synthetic identifiers using credential-scoped discovery. A local success is not evidence of a deployed effect, configured provider or delivered message.

Successful request

Actual dispatcher and migration-created SQLite; verified identity/workspace and external CRM, Engage, Notify, Consent, Nexus, Brand, Generator, Voice and delivery dependencies are simulated. No live authorization, paid generation or external delivery is established.

Input · payload.json:

{}

CLI:

topolo actions validate app_topolo_nurture.contacts.export --data @payload.json --json
topolo actions plan app_topolo_nurture.contacts.export --resource-type workspace --resource-id "$NURTURE_WORKSPACE_ID" --data @payload.json --json
topolo actions call app_topolo_nurture.contacts.export --resource-type workspace --resource-id "$NURTURE_WORKSPACE_ID" --data @payload.json --confirm --json

MCP tool and arguments:

{
  "tool": "topolo_call_action",
  "arguments": {
    "actionId": "app_topolo_nurture.contacts.export",
    "input": {},
    "resourceType": "workspace",
    "resourceId": "<identifier returned by resource discovery>",
    "confirm": true
  }
}

Captured local response · HTTP 200:

{
  "contacts": [
    {
      "id": "nct_0ef6bd1295f24442b7a6a0b7eb612989",
      "email": "a@x.io",
      "emailHash": "e9930e2168489b9230606b9aed42b9bb6fd32c772a131a17de8cf6d19b0a25bc",
      "firstName": null,
      "lastName": null,
      "locale": null,
      "timezone": null,
      "attributes": {},
      "source": "manual",
      "sourceRef": null,
      "status": "active",
      "createdAt": "2026-10-04T00:32:34.638Z",
      "updatedAt": "2026-10-04T00:32:34.638Z"
    },
    {
      "id": "nct_ea839ca8c1504e3ebd0b8851f40f0cbe",
      "email": "b@x.io",
      "emailHash": "fdb64c2ea678a9a04c706ebdcceef9c2d673b6ada204cc545a2e880e0cbf6840",
      "firstName": null,
      "lastName": null,
      "locale": null,
      "timezone": null,
      "attributes": {},
      "source": "manual",
      "sourceRef": null,
      "status": "archived",
      "createdAt": "2026-10-04T00:32:34.639Z",
      "updatedAt": "2026-10-04T00:32:34.640Z"
    }
  ],
  "truncated": false,
  "cap": 5000
}

HTTP 200. Confirm $.truncated is false before treating the export as complete.

Another supported request

Actual dispatcher and migration-created SQLite; verified identity/workspace and external CRM, Engage, Notify, Consent, Nexus, Brand, Generator, Voice and delivery dependencies are simulated. No live authorization, paid generation or external delivery is established.

Input · payload.json:

{
  "status": "archived"
}

CLI:

topolo actions validate app_topolo_nurture.contacts.export --data @payload.json --json
topolo actions plan app_topolo_nurture.contacts.export --resource-type workspace --resource-id "$NURTURE_WORKSPACE_ID" --data @payload.json --json
topolo actions call app_topolo_nurture.contacts.export --resource-type workspace --resource-id "$NURTURE_WORKSPACE_ID" --data @payload.json --confirm --json

MCP tool and arguments:

{
  "tool": "topolo_call_action",
  "arguments": {
    "actionId": "app_topolo_nurture.contacts.export",
    "input": {
      "status": "archived"
    },
    "resourceType": "workspace",
    "resourceId": "<identifier returned by resource discovery>",
    "confirm": true
  }
}

Captured local response · HTTP 200:

{
  "contacts": [
    {
      "id": "nct_ea839ca8c1504e3ebd0b8851f40f0cbe",
      "email": "b@x.io",
      "emailHash": "fdb64c2ea678a9a04c706ebdcceef9c2d673b6ada204cc545a2e880e0cbf6840",
      "firstName": null,
      "lastName": null,
      "locale": null,
      "timezone": null,
      "attributes": {},
      "source": "manual",
      "sourceRef": null,
      "status": "archived",
      "createdAt": "2026-10-04T00:32:34.639Z",
      "updatedAt": "2026-10-04T00:32:34.640Z"
    }
  ],
  "truncated": false,
  "cap": 5000
}

HTTP 200. Confirm $.truncated is false before treating the export as complete.

Verify the result

  • Confirm $.truncated is false before treating the export as complete.

Errors and recovery

  • organization_required (HTTP 403): Select an organization available to the verified caller before choosing a Nurture workspace.
  • permission_denied (HTTP 403): Grant the credential the required Nurture workspace permission.
  • workspace_required (HTTP 409): Create a Nurture workspace, or pass the workspace resource context.
  • invalid_input (HTTP 422): Correct the fields named in error.details using inputSchema, then retry.

Auth or gateway failures may precede this handler. Preserve the exact response shape, error string/code, request id and credential context; no synthetic fixture establishes live credential access.

Recovery boundary

This action does not change service state.

  • List contacts: List the contacts Nurture holds for the caller's workspace, ordered by email, optionally filtered by status and a prefix search on email, first or last name. Pages of up to 200; pass nextCursor back as cursor for the next page.

Evidence

Actual dispatcher and migration-created SQLite or Worker handlers; identity/workspace and external service dependencies are simulated. Fixture identifiers and timestamps are synthetic. These responses establish no live authorization, paid generation, credential provisioning or message delivery. Test scenario and capture digests are retained with each fixture.