Skip to the content
MenuPeople

API reference

People

Units, members, learners and guardian consent.

POST/v1/people/{id}/memberships

Give a person another place

addMembershippeople:writewrite: 120/min per keyIdempotent by its inputSince 2026-10-01

A role at a unit, or at the organisation level. The same place again is returned as it is (200). ageBand: "18+" marks an adult learner, where the organisation marks adult learners (409 conflict otherwise). The API never gives, changes, switches off or removes an owner's place, and only a full-access key gives, changes, switches off or removes an ADMIN, AVATAR_BUILDER or WORKSPACE_ADMIN place (403 forbidden otherwise): people:write alone manages learners, leaders and observers.

Path parameters

  • idstringrequired

    Person id (usr_…); the id without its prefix is accepted too.

Body

  • role"OWNER" | "ADMIN" | "AVATAR_BUILDER" | "WORKSPACE_ADMIN" | "LEADER" | "LEARNER" | "OBSERVER"required

    OWNER (never given or changed through the API), ADMIN, AVATAR_BUILDER, WORKSPACE_ADMIN (these four at the organisation level only), LEADER, LEARNER, OBSERVER.

  • unitIdstring | null
  • workspaceIdstring | null
  • gradeBandstring | null
  • ageBand"18+" | null

Returns

201 The place. data is Membership.

Fields of data
  • idstringrequired

    Membership id (mbr_…).

    pattern `^mbr_.*`

  • personIdstringrequired

    Person id (usr_…).

    pattern `^usr_.*`

  • rolestringrequired

    One of the member roles.

  • unitIdstring | nullrequired

    The unit it is held at; null at the organisation level.

  • workspaceIdstring | nullrequired

    A workspace admin's subject (sub_…; bare for keys on 2026-07-08).

  • statusstringrequired

    active, waiting_consent (a child's place waiting for a parent's consent) or disabled.

  • gradeBandstring | nullrequired
  • ageBand"18+" | nullrequired

    "18+": an adult learner, who starts without a parent's or guardian's consent.

  • consentAtstring (date-time) | nullrequired
  • consentBy"organisation" | "guardian" | "teacher" | nullrequired

    Who gave a learner's consent: the organisation, a guardian or a teacher (never their details).

  • consentWithdrawnbooleanrequired

    A guardian's consent was withdrawn from this place (DELETE …/guardian-consent): it waits for a new consent, and nothing else switches it on.

  • createdAtstring (date-time)required

    ISO 8601 UTC timestamp.

  • updatedAtstring (date-time)required

    ISO 8601 UTC timestamp.

Errors

invalid_requestunauthorizedforbiddenupgrade_requirednot_foundconflictidempotency_conflictidempotency_in_progressrate_limitedserver_error

Events

member.added

Request

curl -X POST "https://app.zentiqai.com/v1/people/usr_123/memberships" \
  -H "Authorization: Bearer $ZENTIQ_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "role": "OWNER"
}'

Response

201 · JSON
{
  "data": {
    "id": "mbr_cmfq2b7x10000abcd1234",
    "personId": "usr_cmfq2b7x10000abcd1234",
    "role": "…",
    "unitId": "unit_cmfq2b7x10000abcd1234",
    "workspaceId": "sub_cmfq2b7x10000abcd1234",
    "status": "active"
  },
  "error": null,
  "requestId": "req_4f1c2e9a7b3d5e6f7a8b9c0d"
}
GET/v1/people

List people

listPeoplepeople:readread: 600/min per keySince 2026-10-01

Everyone in the organisation (members, learners, parents) with their places here, newest first. updatedAfter lists those whose account or places changed since: for keeping your system in step.

Query parameters

  • limitinteger

    Page size, 1-200 (default 50).

  • cursorstring

    The nextCursor of the previous page.

  • unitIdstring

    People with a place at this unit.

  • subtree"true" | "false"

    With unitId: the unit and every unit below it.

  • role"OWNER" | "ADMIN" | "AVATAR_BUILDER" | "WORKSPACE_ADMIN" | "LEADER" | "LEARNER" | "OBSERVER"

    People holding this role here.

  • status"active" | "waiting_consent" | "disabled"

    People with a place in this status.

  • externalIdstring

    The person you know by this id.

  • emailstring
  • updatedAfterstring

    Changed since (the account or one of its places): for syncing.

Returns

200 A page of people. A page: data is a list of Person, and nextCursor fetches the next page.

Fields of data
  • idstringrequired

    Person id (usr_…).

    pattern `^usr_.*`

  • externalIdstring | nullrequired

    Your own id for the person (the sync key), when you gave one.

  • namestringrequired
  • emailstring | nullrequired

    Null for a login card or a person known only by your id.

  • loginNamestring | nullrequired

    A login card's sign-in name (<organisation code>/<username>).

  • membershipsMembership[]required
  • lastSignInAtstring (date-time) | nullrequired
  • disabledbooleanrequired

    Switched off: no sign-in anywhere; their places keep their own status.

  • createdAtstring (date-time)required

    ISO 8601 UTC timestamp.

  • updatedAtstring (date-time)required

    ISO 8601 UTC timestamp.

Errors

invalid_requestunauthorizedforbiddenupgrade_requiredrate_limitedserver_error

Request

curl "https://app.zentiqai.com/v1/people?limit=20" \
  -H "Authorization: Bearer $ZENTIQ_API_KEY"

Response

200 · JSON
{
  "data": [
    {
      "id": "usr_cmfq2b7x10000abcd1234",
      "externalId": "…",
      "name": "Zoe",
      "email": "sam@example.com",
      "loginName": "…",
      "memberships": [
        {
          "id": "mbr_cmfq2b7x10000abcd1234",
          "personId": "usr_cmfq2b7x10000abcd1234",
          "role": "…",
          "unitId": "unit_cmfq2b7x10000abcd1234",
          "workspaceId": "sub_cmfq2b7x10000abcd1234",
          "status": "active"
        }
      ]
    }
  ],
  "error": null,
  "requestId": "req_4f1c2e9a7b3d5e6f7a8b9c0d",
  "nextCursor": null
}
POST/v1/people

Add a person (or find them) and give them a place

createPersonpeople:writewrite: 120/min per keyIdempotent by its inputSince 2026-10-01

By externalId (your own id, the sync key: a repeat returns the same person, 200), else by email, else a login card for a learner without an email. A new learner's place waits for a parent's consent where the organisation's rules say so (status: waiting_consent); never an adult learner's (ageBand: "18+", where the organisation marks adult learners). A new login card's PIN is in this answer only (Cache-Control: no-store): a retry never gets it again. No email is sent. The API never gives, changes, switches off or removes an owner's place, and only a full-access key gives, changes, switches off or removes an ADMIN, AVATAR_BUILDER or WORKSPACE_ADMIN place (403 forbidden otherwise): people:write alone manages learners, leaders and observers.

Body

  • externalIdstring | null

    Your own id for the person: the sync key. A repeat with it returns the same person.

  • emailstring (email) | null

    Without an externalId, the person is found or added by email. An email another account already has is refused (409).

  • namestring | null
  • role"OWNER" | "ADMIN" | "AVATAR_BUILDER" | "WORKSPACE_ADMIN" | "LEADER" | "LEARNER" | "OBSERVER"required

    OWNER (never given or changed through the API), ADMIN, AVATAR_BUILDER, WORKSPACE_ADMIN (these four at the organisation level only), LEADER, LEARNER, OBSERVER.

  • unitIdstring | null
  • workspaceIdstring | null

    A workspace admin's subject.

  • gradeBandstring | null
  • ageBand"18+" | null
  • loginCardboolean | null

    A learner without an email gets a login card (needs accounts without email switched on).

Returns

201 The person (201 when a person or a place was made, 200 when both existed). data is PersonCreated.

Fields of data
  • idstringrequired

    Person id (usr_…).

    pattern `^usr_.*`

  • externalIdstring | nullrequired

    Your own id for the person (the sync key), when you gave one.

  • namestringrequired
  • emailstring | nullrequired

    Null for a login card or a person known only by your id.

  • loginNamestring | nullrequired

    A login card's sign-in name (<organisation code>/<username>).

  • membershipsMembership[]required
  • lastSignInAtstring (date-time) | nullrequired
  • disabledbooleanrequired

    Switched off: no sign-in anywhere; their places keep their own status.

  • createdAtstring (date-time)required

    ISO 8601 UTC timestamp.

  • updatedAtstring (date-time)required

    ISO 8601 UTC timestamp.

  • loginCardLoginCard | nullrequired

    Only on the answer that made the card; never replayed.

Errors

invalid_requestunauthorizedforbiddenupgrade_requirednot_foundconflictidempotency_conflictidempotency_in_progressrate_limitedserver_error

Events

member.added

Request

curl -X POST "https://app.zentiqai.com/v1/people" \
  -H "Authorization: Bearer $ZENTIQ_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "role": "OWNER"
}'

Response

201 · JSON
{
  "data": {
    "id": "usr_cmfq2b7x10000abcd1234",
    "externalId": "…",
    "name": "Zoe",
    "email": "sam@example.com",
    "loginName": "…",
    "memberships": [
      {
        "id": "mbr_cmfq2b7x10000abcd1234",
        "personId": "usr_cmfq2b7x10000abcd1234",
        "role": "…",
        "unitId": "unit_cmfq2b7x10000abcd1234",
        "workspaceId": "sub_cmfq2b7x10000abcd1234",
        "status": "active"
      }
    ]
  },
  "error": null,
  "requestId": "req_4f1c2e9a7b3d5e6f7a8b9c0d"
}
GET/v1/units

List units

listUnitspeople:readread: 600/min per keySince 2026-10-01

The organisation's classes, teams and groups, in tree order, with their counts.

Query parameters

  • limitinteger

    Page size, 1-200 (default 50).

  • cursorstring

    The nextCursor of the previous page.

  • parentIdstring

    Only the units directly under this one.

  • includeDisabled"true" | "false"

    Include switched-off units (default true).

Returns

200 A page of units. A page: data is a list of Unit, and nextCursor fetches the next page.

Fields of data
  • idstringrequired

    Unit id (unit_…).

    pattern `^unit_.*`

  • parentIdstring | nullrequired

    The unit above it; null at the top level.

  • namestringrequired
  • kindstringrequired

    class, team, group, department, region, school or club.

  • gradeBandstring | nullrequired

    A class's year or grade: the default for learners who join with its code.

  • disabledbooleanrequired

    Switched off (itself or a unit above it): it grants nothing until switched on.

  • joinCodestring | nullrequired

    The code learners join with, where joining by code is on.

  • sortOrderintegerrequired
  • countsobjectrequired
    • membersintegerrequired
    • learnersintegerrequired
    • leadersintegerrequired
    • waitingintegerrequired

      Learners whose place waits for a parent's consent.

  • createdAtstring (date-time)required

    ISO 8601 UTC timestamp.

  • updatedAtstring (date-time)required

    ISO 8601 UTC timestamp.

Errors

invalid_requestunauthorizedforbiddenupgrade_requiredrate_limitedserver_error

Request

curl "https://app.zentiqai.com/v1/units?limit=20" \
  -H "Authorization: Bearer $ZENTIQ_API_KEY"

Response

200 · JSON
{
  "data": [
    {
      "id": "unit_cmfq2b7x10000abcd1234",
      "parentId": "unit_cmfq2b7x10000abcd1234",
      "name": "Zoe",
      "kind": "team",
      "gradeBand": "…",
      "disabled": true
    }
  ],
  "error": null,
  "requestId": "req_4f1c2e9a7b3d5e6f7a8b9c0d",
  "nextCursor": null
}
POST/v1/units

Add a unit (a class, team or group)

createUnitpeople:writewrite: 120/min per keyIdempotency-KeySince 2026-10-01

Under another unit (parentId) or at the top level. A second unit with the same name at the same level is allowed and flagged (duplicateName). A leader named by email is invited and counts as a staff member (403 upgrade_required when the plan has no room for another). An email another account already uses is 409 conflict (details.reason: email_in_use), checked before anything is made.

Body

  • namestringrequired

    1-80 characters

  • parentIdstring | null
  • kindstring | null

    class, team, group, department, region, school or club (default: the organisation's).

  • gradeBandstring | null
  • leaderobject | null

    Invites the unit's leader by email (counts as a staff member).

    • emailstring (email)required

Returns

201 The new unit. data is UnitWritten.

Fields of data
  • idstringrequired

    Unit id (unit_…).

    pattern `^unit_.*`

  • parentIdstring | nullrequired

    The unit above it; null at the top level.

  • namestringrequired
  • kindstringrequired

    class, team, group, department, region, school or club.

  • gradeBandstring | nullrequired

    A class's year or grade: the default for learners who join with its code.

  • disabledbooleanrequired

    Switched off (itself or a unit above it): it grants nothing until switched on.

  • joinCodestring | nullrequired

    The code learners join with, where joining by code is on.

  • sortOrderintegerrequired
  • countsobjectrequired
    • membersintegerrequired
    • learnersintegerrequired
    • leadersintegerrequired
    • waitingintegerrequired

      Learners whose place waits for a parent's consent.

  • createdAtstring (date-time)required

    ISO 8601 UTC timestamp.

  • updatedAtstring (date-time)required

    ISO 8601 UTC timestamp.

  • duplicateNameobject | nullrequired

    Another unit at the same level already has this name (allowed, flagged).

    • idstringrequired

      Unit id (unit_…).

      pattern `^unit_.*`

    • namestringrequired

Errors

invalid_requestunauthorizedforbiddenupgrade_requirednot_foundconflictidempotency_conflictidempotency_in_progressrate_limitedserver_error

Events

unit.createdmember.added

Request

curl -X POST "https://app.zentiqai.com/v1/units" \
  -H "Authorization: Bearer $ZENTIQ_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "name": "Zoe"
}'

Response

201 · JSON
{
  "data": {
    "id": "unit_cmfq2b7x10000abcd1234",
    "parentId": "unit_cmfq2b7x10000abcd1234",
    "name": "Zoe",
    "kind": "team",
    "gradeBand": "…",
    "disabled": true
  },
  "error": null,
  "requestId": "req_4f1c2e9a7b3d5e6f7a8b9c0d"
}
PATCH/v1/memberships/{id}

Change a place

updateMembershippeople:writewrite: 120/min per keySince 2026-10-01

Its role, unit, year or grade, whether it is an adult learner's, or switch it off or on. A place waiting for a parent's consent turns active only through guardian consent, or when it is marked as an adult learner's (ageBand: "18+", where the organisation marks adult learners: 409 conflict otherwise). The API never gives, changes, switches off or removes an owner's place, and only a full-access key gives, changes, switches off or removes an ADMIN, AVATAR_BUILDER or WORKSPACE_ADMIN place (403 forbidden otherwise): people:write alone manages learners, leaders and observers.

Path parameters

  • idstringrequired

    Membership id (mbr_…); the id without its prefix is accepted too.

Body

  • role"OWNER" | "ADMIN" | "AVATAR_BUILDER" | "WORKSPACE_ADMIN" | "LEADER" | "LEARNER" | "OBSERVER"

    OWNER (never given or changed through the API), ADMIN, AVATAR_BUILDER, WORKSPACE_ADMIN (these four at the organisation level only), LEADER, LEARNER, OBSERVER.

  • unitIdstring | null
  • gradeBandstring | null
  • ageBand"18+" | null

    "18+" marks an adult learner (a place waiting for consent is switched on); null clears it.

  • status"active" | "disabled"

    Switch this place off or on. A place waiting for consent turns active only through guardian consent.

Returns

200 The place. data is Membership.

Fields of data
  • idstringrequired

    Membership id (mbr_…).

    pattern `^mbr_.*`

  • personIdstringrequired

    Person id (usr_…).

    pattern `^usr_.*`

  • rolestringrequired

    One of the member roles.

  • unitIdstring | nullrequired

    The unit it is held at; null at the organisation level.

  • workspaceIdstring | nullrequired

    A workspace admin's subject (sub_…; bare for keys on 2026-07-08).

  • statusstringrequired

    active, waiting_consent (a child's place waiting for a parent's consent) or disabled.

  • gradeBandstring | nullrequired
  • ageBand"18+" | nullrequired

    "18+": an adult learner, who starts without a parent's or guardian's consent.

  • consentAtstring (date-time) | nullrequired
  • consentBy"organisation" | "guardian" | "teacher" | nullrequired

    Who gave a learner's consent: the organisation, a guardian or a teacher (never their details).

  • consentWithdrawnbooleanrequired

    A guardian's consent was withdrawn from this place (DELETE …/guardian-consent): it waits for a new consent, and nothing else switches it on.

  • createdAtstring (date-time)required

    ISO 8601 UTC timestamp.

  • updatedAtstring (date-time)required

    ISO 8601 UTC timestamp.

Errors

invalid_requestunauthorizedforbiddenupgrade_requirednot_foundconflictrate_limitedserver_error

Events

member.updatedmember.disabledmember.enabled

Request

curl -X PATCH "https://app.zentiqai.com/v1/memberships/mbr_123" \
  -H "Authorization: Bearer $ZENTIQ_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'

Response

200 · JSON
{
  "data": {
    "id": "mbr_cmfq2b7x10000abcd1234",
    "personId": "usr_cmfq2b7x10000abcd1234",
    "role": "…",
    "unitId": "unit_cmfq2b7x10000abcd1234",
    "workspaceId": "sub_cmfq2b7x10000abcd1234",
    "status": "active"
  },
  "error": null,
  "requestId": "req_4f1c2e9a7b3d5e6f7a8b9c0d"
}
DELETE/v1/memberships/{id}

Remove a place

deleteMembershippeople:writewrite: 120/min per keySince 2026-10-01

The account stays. Someone's only organisation-level owner or admin place can't be removed this way, nor the last place of an owner or admin invited in the console (409 conflict: without a place their account would count as an owner; an owner or admin removes them from the organisation in the console). The API never gives, changes, switches off or removes an owner's place, and only a full-access key gives, changes, switches off or removes an ADMIN, AVATAR_BUILDER or WORKSPACE_ADMIN place (403 forbidden otherwise): people:write alone manages learners, leaders and observers.

Path parameters

  • idstringrequired

    Membership id (mbr_…); the id without its prefix is accepted too.

Returns

200 Removed. data is object.

Fields of data
  • removedtruerequired
  • idstringrequired

    Membership id (mbr_…).

    pattern `^mbr_.*`

Errors

invalid_requestunauthorizedforbiddenupgrade_requirednot_foundconflictrate_limitedserver_error

Events

member.removed

Request

curl -X DELETE "https://app.zentiqai.com/v1/memberships/mbr_123" \
  -H "Authorization: Bearer $ZENTIQ_API_KEY"

Response

200 · JSON
{
  "data": {
    "removed": true,
    "id": "mbr_cmfq2b7x10000abcd1234"
  },
  "error": null,
  "requestId": "req_4f1c2e9a7b3d5e6f7a8b9c0d"
}
GET/v1/units/{id}

Get a unit

getUnitpeople:readread: 600/min per keySince 2026-10-01

Path parameters

  • idstringrequired

    Unit id (unit_…); the id without its prefix is accepted too.

Returns

200 The unit. data is Unit.

Fields of data
  • idstringrequired

    Unit id (unit_…).

    pattern `^unit_.*`

  • parentIdstring | nullrequired

    The unit above it; null at the top level.

  • namestringrequired
  • kindstringrequired

    class, team, group, department, region, school or club.

  • gradeBandstring | nullrequired

    A class's year or grade: the default for learners who join with its code.

  • disabledbooleanrequired

    Switched off (itself or a unit above it): it grants nothing until switched on.

  • joinCodestring | nullrequired

    The code learners join with, where joining by code is on.

  • sortOrderintegerrequired
  • countsobjectrequired
    • membersintegerrequired
    • learnersintegerrequired
    • leadersintegerrequired
    • waitingintegerrequired

      Learners whose place waits for a parent's consent.

  • createdAtstring (date-time)required

    ISO 8601 UTC timestamp.

  • updatedAtstring (date-time)required

    ISO 8601 UTC timestamp.

Errors

invalid_requestunauthorizedforbiddenupgrade_requirednot_foundrate_limitedserver_error

Request

curl "https://app.zentiqai.com/v1/units/unit_123" \
  -H "Authorization: Bearer $ZENTIQ_API_KEY"

Response

200 · JSON
{
  "data": {
    "id": "unit_cmfq2b7x10000abcd1234",
    "parentId": "unit_cmfq2b7x10000abcd1234",
    "name": "Zoe",
    "kind": "team",
    "gradeBand": "…",
    "disabled": true
  },
  "error": null,
  "requestId": "req_4f1c2e9a7b3d5e6f7a8b9c0d"
}
PATCH/v1/units/{id}

Rename, move or switch off a unit

updateUnitpeople:writewrite: 120/min per keySince 2026-10-01

Switching a unit off switches off everything below it: nothing is deleted, and it grants nothing until switched on. A unit can't move under itself.

Path parameters

  • idstringrequired

    Unit id (unit_…); the id without its prefix is accepted too.

Body

  • namestring

    1-80 characters

  • parentIdstring | null

    Move it under another unit; null moves it to the top level.

  • sortOrderinteger
  • gradeBandstring | null

    null clears it.

  • disabledboolean

    Switch it (and everything below it) off or on. Nothing is deleted.

Returns

200 The unit. data is UnitWritten.

Fields of data
  • idstringrequired

    Unit id (unit_…).

    pattern `^unit_.*`

  • parentIdstring | nullrequired

    The unit above it; null at the top level.

  • namestringrequired
  • kindstringrequired

    class, team, group, department, region, school or club.

  • gradeBandstring | nullrequired

    A class's year or grade: the default for learners who join with its code.

  • disabledbooleanrequired

    Switched off (itself or a unit above it): it grants nothing until switched on.

  • joinCodestring | nullrequired

    The code learners join with, where joining by code is on.

  • sortOrderintegerrequired
  • countsobjectrequired
    • membersintegerrequired
    • learnersintegerrequired
    • leadersintegerrequired
    • waitingintegerrequired

      Learners whose place waits for a parent's consent.

  • createdAtstring (date-time)required

    ISO 8601 UTC timestamp.

  • updatedAtstring (date-time)required

    ISO 8601 UTC timestamp.

  • duplicateNameobject | nullrequired

    Another unit at the same level already has this name (allowed, flagged).

    • idstringrequired

      Unit id (unit_…).

      pattern `^unit_.*`

    • namestringrequired

Errors

invalid_requestunauthorizedforbiddenupgrade_requirednot_foundrate_limitedserver_error

Events

unit.renamedunit.updatedunit.disabledunit.enabled

Request

curl -X PATCH "https://app.zentiqai.com/v1/units/unit_123" \
  -H "Authorization: Bearer $ZENTIQ_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'

Response

200 · JSON
{
  "data": {
    "id": "unit_cmfq2b7x10000abcd1234",
    "parentId": "unit_cmfq2b7x10000abcd1234",
    "name": "Zoe",
    "kind": "team",
    "gradeBand": "…",
    "disabled": true
  },
  "error": null,
  "requestId": "req_4f1c2e9a7b3d5e6f7a8b9c0d"
}
DELETE/v1/units/{id}

Delete a unit

deleteUnitpeople:writewrite: 120/min per keySince 2026-10-01

Its sub-units move up to its parent (or the top level) with everything below them, and the portals, subjects and assignments attached to it move with them. The places held on it are removed; the people's accounts and other places stay. Sessions, results and reports are never deleted. To keep everything, switch the unit off instead (PATCH /units/{id} with disabled: true). A unit holding an owner's place is never deleted through the API, and one holding an admin-level place only with a full-access key (403 forbidden). Preview it with GET /units/{id}/deletion-preview.

Path parameters

  • idstringrequired

    Unit id (unit_…); the id without its prefix is accepted too.

Returns

200 Deleted, and what moved. data is UnitDeleted.

Fields of data
  • deletedtruerequired
  • idstringrequired

    Unit id (unit_…).

    pattern `^unit_.*`

  • namestringrequired
  • movedTostring | nullrequired

    Where its sub-units, portals, subjects and assignments moved: its parent, or the top level (null).

  • subUnitsMovedintegerrequired
  • portalsMovedintegerrequired
  • subjectsMovedintegerrequired
  • assignmentsMovedintegerrequired
  • membershipsRemovedintegerrequired

    Places held on the unit, removed (the people's accounts and other places stay).

Errors

invalid_requestunauthorizedforbiddenupgrade_requirednot_foundconflictrate_limitedserver_error

Events

unit.deletedmember.removed

Request

curl -X DELETE "https://app.zentiqai.com/v1/units/unit_123" \
  -H "Authorization: Bearer $ZENTIQ_API_KEY"

Response

200 · JSON
{
  "data": {
    "deleted": true,
    "id": "unit_cmfq2b7x10000abcd1234",
    "name": "Zoe",
    "movedTo": "unit_cmfq2b7x10000abcd1234",
    "subUnitsMoved": 1,
    "portalsMoved": 1
  },
  "error": null,
  "requestId": "req_4f1c2e9a7b3d5e6f7a8b9c0d"
}
POST/v1/units/{id}/join-code

Create or replace a unit's join code

rotateUnitJoinCodepeople:writewrite: 120/min per keyIdempotency-KeySince 2026-10-01

Learners join the unit with this code. Each call makes a new code and the old one stops working. Making a code allows joining by code: where your organization has switched joining by code off for this unit, it is switched on for it (setting.changed); where the switch is locked above the unit, it is refused (409 conflict, details.reason: "join_by_code_off").

Path parameters

  • idstringrequired

    Unit id (unit_…); the id without its prefix is accepted too.

Returns

200 The unit, with its new `joinCode`. data is Unit.

Fields of data
  • idstringrequired

    Unit id (unit_…).

    pattern `^unit_.*`

  • parentIdstring | nullrequired

    The unit above it; null at the top level.

  • namestringrequired
  • kindstringrequired

    class, team, group, department, region, school or club.

  • gradeBandstring | nullrequired

    A class's year or grade: the default for learners who join with its code.

  • disabledbooleanrequired

    Switched off (itself or a unit above it): it grants nothing until switched on.

  • joinCodestring | nullrequired

    The code learners join with, where joining by code is on.

  • sortOrderintegerrequired
  • countsobjectrequired
    • membersintegerrequired
    • learnersintegerrequired
    • leadersintegerrequired
    • waitingintegerrequired

      Learners whose place waits for a parent's consent.

  • createdAtstring (date-time)required

    ISO 8601 UTC timestamp.

  • updatedAtstring (date-time)required

    ISO 8601 UTC timestamp.

Errors

invalid_requestunauthorizedforbiddenupgrade_requirednot_foundconflictidempotency_conflictidempotency_in_progressrate_limitedserver_error

Events

unit.updatedsetting.changed

Request

curl -X POST "https://app.zentiqai.com/v1/units/unit_123/join-code" \
  -H "Authorization: Bearer $ZENTIQ_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)"

Response

200 · JSON
{
  "data": {
    "id": "unit_cmfq2b7x10000abcd1234",
    "parentId": "unit_cmfq2b7x10000abcd1234",
    "name": "Zoe",
    "kind": "team",
    "gradeBand": "…",
    "disabled": true
  },
  "error": null,
  "requestId": "req_4f1c2e9a7b3d5e6f7a8b9c0d"
}
DELETE/v1/units/{id}/join-code

Remove a unit's join code

deleteUnitJoinCodepeople:writewrite: 120/min per keySince 2026-10-01

The code stops working at once; people who already joined keep their places. Removing a code that isn't there returns the unit as it is. Where joining by code is switched off for the unit, it is refused (409 conflict).

Path parameters

  • idstringrequired

    Unit id (unit_…); the id without its prefix is accepted too.

Returns

200 The unit, with `joinCode: null`. data is Unit.

Fields of data
  • idstringrequired

    Unit id (unit_…).

    pattern `^unit_.*`

  • parentIdstring | nullrequired

    The unit above it; null at the top level.

  • namestringrequired
  • kindstringrequired

    class, team, group, department, region, school or club.

  • gradeBandstring | nullrequired

    A class's year or grade: the default for learners who join with its code.

  • disabledbooleanrequired

    Switched off (itself or a unit above it): it grants nothing until switched on.

  • joinCodestring | nullrequired

    The code learners join with, where joining by code is on.

  • sortOrderintegerrequired
  • countsobjectrequired
    • membersintegerrequired
    • learnersintegerrequired
    • leadersintegerrequired
    • waitingintegerrequired

      Learners whose place waits for a parent's consent.

  • createdAtstring (date-time)required

    ISO 8601 UTC timestamp.

  • updatedAtstring (date-time)required

    ISO 8601 UTC timestamp.

Errors

invalid_requestunauthorizedforbiddenupgrade_requirednot_foundconflictrate_limitedserver_error

Events

unit.updated

Request

curl -X DELETE "https://app.zentiqai.com/v1/units/unit_123/join-code" \
  -H "Authorization: Bearer $ZENTIQ_API_KEY"

Response

200 · JSON
{
  "data": {
    "id": "unit_cmfq2b7x10000abcd1234",
    "parentId": "unit_cmfq2b7x10000abcd1234",
    "name": "Zoe",
    "kind": "team",
    "gradeBand": "…",
    "disabled": true
  },
  "error": null,
  "requestId": "req_4f1c2e9a7b3d5e6f7a8b9c0d"
}
GET/v1/people/{id}

Get a person

getPersonpeople:readread: 600/min per keySince 2026-10-01

Path parameters

  • idstringrequired

    Person id (usr_…); the id without its prefix is accepted too.

Returns

200 The person. data is Person.

Fields of data
  • idstringrequired

    Person id (usr_…).

    pattern `^usr_.*`

  • externalIdstring | nullrequired

    Your own id for the person (the sync key), when you gave one.

  • namestringrequired
  • emailstring | nullrequired

    Null for a login card or a person known only by your id.

  • loginNamestring | nullrequired

    A login card's sign-in name (<organisation code>/<username>).

  • membershipsMembership[]required
  • lastSignInAtstring (date-time) | nullrequired
  • disabledbooleanrequired

    Switched off: no sign-in anywhere; their places keep their own status.

  • createdAtstring (date-time)required

    ISO 8601 UTC timestamp.

  • updatedAtstring (date-time)required

    ISO 8601 UTC timestamp.

Errors

invalid_requestunauthorizedforbiddenupgrade_requirednot_foundrate_limitedserver_error

Request

curl "https://app.zentiqai.com/v1/people/usr_123" \
  -H "Authorization: Bearer $ZENTIQ_API_KEY"

Response

200 · JSON
{
  "data": {
    "id": "usr_cmfq2b7x10000abcd1234",
    "externalId": "…",
    "name": "Zoe",
    "email": "sam@example.com",
    "loginName": "…",
    "memberships": [
      {
        "id": "mbr_cmfq2b7x10000abcd1234",
        "personId": "usr_cmfq2b7x10000abcd1234",
        "role": "…",
        "unitId": "unit_cmfq2b7x10000abcd1234",
        "workspaceId": "sub_cmfq2b7x10000abcd1234",
        "status": "active"
      }
    ]
  },
  "error": null,
  "requestId": "req_4f1c2e9a7b3d5e6f7a8b9c0d"
}
PATCH/v1/people/{id}

Switch a person's account off or on

updatePersonpeople:writewrite: 120/min per keySince 2026-10-01

Off: no sign-in anywhere, they stop counting as a staff member, any conversation they are in now ends, and every record is kept; their places keep their own status. On: someone holding a staff role counts as a staff member again (403 upgrade_required when the plan has no room for another). Never the organization's last active owner, a person removed from the organization (add them again instead), or an account that belongs to another organization (409 conflict; switch off their places here instead). The API never switches an owner's account off or on, and only a full-access key switches off or on someone holding an ADMIN, AVATAR_BUILDER or WORKSPACE_ADMIN place (403 forbidden).

Path parameters

  • idstringrequired

    Person id (usr_…); the id without its prefix is accepted too.

Body

  • disabledbooleanrequired

    Switch the whole account off (true) or back on (false).

Returns

200 The person. data is Person.

Fields of data
  • idstringrequired

    Person id (usr_…).

    pattern `^usr_.*`

  • externalIdstring | nullrequired

    Your own id for the person (the sync key), when you gave one.

  • namestringrequired
  • emailstring | nullrequired

    Null for a login card or a person known only by your id.

  • loginNamestring | nullrequired

    A login card's sign-in name (<organisation code>/<username>).

  • membershipsMembership[]required
  • lastSignInAtstring (date-time) | nullrequired
  • disabledbooleanrequired

    Switched off: no sign-in anywhere; their places keep their own status.

  • createdAtstring (date-time)required

    ISO 8601 UTC timestamp.

  • updatedAtstring (date-time)required

    ISO 8601 UTC timestamp.

Errors

invalid_requestunauthorizedforbiddenupgrade_requirednot_foundconflictrate_limitedserver_error

Events

member.disabledmember.enabled

Request

curl -X PATCH "https://app.zentiqai.com/v1/people/usr_123" \
  -H "Authorization: Bearer $ZENTIQ_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "disabled": true
}'

Response

200 · JSON
{
  "data": {
    "id": "usr_cmfq2b7x10000abcd1234",
    "externalId": "…",
    "name": "Zoe",
    "email": "sam@example.com",
    "loginName": "…",
    "memberships": [
      {
        "id": "mbr_cmfq2b7x10000abcd1234",
        "personId": "usr_cmfq2b7x10000abcd1234",
        "role": "…",
        "unitId": "unit_cmfq2b7x10000abcd1234",
        "workspaceId": "sub_cmfq2b7x10000abcd1234",
        "status": "active"
      }
    ]
  },
  "error": null,
  "requestId": "req_4f1c2e9a7b3d5e6f7a8b9c0d"
}
GET/v1/units/{id}/deletion-preview

Preview deleting a unit

getUnitDeletionPreviewpeople:readread: 600/min per keySince 2026-10-01

What DELETE /units/{id} would move and remove, in numbers. Nothing changes.

Path parameters

  • idstringrequired

    Unit id (unit_…); the id without its prefix is accepted too.

Returns

200 What deleting it would do. data is UnitDeletionPreview.

Fields of data
  • idstringrequired

    Unit id (unit_…).

    pattern `^unit_.*`

  • namestringrequired
  • movedTostring | nullrequired

    Where its sub-units, portals, subjects and assignments would move: its parent, or the top level (null).

  • movedToNamestring | nullrequired
  • subUnitsintegerrequired

    Units directly under it, which would move up (with everything below them).

  • unitsBelowintegerrequired

    Every unit below it, at any depth.

  • nameClashesstring[]required

    Sub-units that would share a name with a unit already at the level they move to (allowed, flagged).

  • peopleintegerrequired

    People with a place on it (their places there would be removed).

  • leadersintegerrequired
  • peopleLeftWithoutPlaceintegerrequired

    People whose only place in the organization is on this unit.

  • portalsintegerrequired

    Portals attached to it, which would move.

  • subjectsintegerrequired
  • assignmentsintegerrequired

Errors

invalid_requestunauthorizedforbiddenupgrade_requirednot_foundrate_limitedserver_error

Request

curl "https://app.zentiqai.com/v1/units/unit_123/deletion-preview" \
  -H "Authorization: Bearer $ZENTIQ_API_KEY"

Response

200 · JSON
{
  "data": {
    "id": "unit_cmfq2b7x10000abcd1234",
    "name": "Zoe",
    "movedTo": "unit_cmfq2b7x10000abcd1234",
    "movedToName": "…",
    "subUnits": 1,
    "unitsBelow": 1
  },
  "error": null,
  "requestId": "req_4f1c2e9a7b3d5e6f7a8b9c0d"
}
POST/v1/people/import

Import learners

importPeoplepeople:writeheavy: 20/min per keyIdempotency-KeySince 2026-10-01

Up to 500 learners at once into a class or team (or the organization level), as the console's class-list import does. Each row gets its own result, in order, and one row failing never stops the others. A row with an email is invited by email (someone already holding this place is left as it is, created: false); a row without one gets a login card, only where accounts without email are switched on. A child's place waits for a parent's consent where your organization's rules say so (status: "waiting_consent"). A row with no year or grade takes the unit's own. No email is sent. New login cards' PINs are in this answer (Cache-Control: no-store); send an Idempotency-Key so a retry gets the same answer instead of new cards.

Body

  • unitIdstring | null

    The class or team they join; none: the organization level.

  • rowsImportPeopleRow[]required

    at most 500 items

Returns

201 Every row's outcome (201 when a place was made, 200 when none was). data is ImportPeopleResult.

Fields of data
  • addedintegerrequired

    New places made.

  • failedintegerrequired
  • resultsobject[]required

    One per row, in order.

    • rowintegerrequired

      The row's position in rows, from 0.

    • namestringrequired
    • okbooleanrequired
    • createdbooleanrequired

      A new place was made (false: they already held it, or the row failed).

    • personIdstring | nullrequired
    • membershipIdstring | nullrequired
    • statusstring | nullrequired

      The place's status: active, or waiting_consent for a child's place that waits for a parent's consent.

    • loginCardLoginCard | nullrequired

      A new login card, its PIN in this answer only.

    • errorstring | nullrequired

      Why the row failed, in plain English.

Errors

invalid_requestunauthorizedforbiddenupgrade_requirednot_foundidempotency_conflictidempotency_in_progressrate_limitedserver_error

Events

member.added

Request

curl -X POST "https://app.zentiqai.com/v1/people/import" \
  -H "Authorization: Bearer $ZENTIQ_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "rows": [
    {
      "name": "Zoe"
    }
  ]
}'

Response

201 · JSON
{
  "data": {
    "added": 1,
    "failed": 1,
    "results": [
      {
        "row": 1,
        "name": "Zoe",
        "ok": true,
        "created": true,
        "personId": "usr_cmfq2b7x10000abcd1234",
        "membershipId": "mbr_cmfq2b7x10000abcd1234"
      }
    ]
  },
  "error": null,
  "requestId": "req_4f1c2e9a7b3d5e6f7a8b9c0d"
}
POST/v1/memberships/{id}/guardian-consent

Record a parent's or guardian's consent

recordGuardianConsentpeople:writewrite: 120/min per keyIdempotent by its inputSince 2026-10-01

On a learner's place that waits for it: the place turns active. A place that already has consent is returned as it is; a place switched off is refused (409). consent.recorded says who gave it, never the guardian's address.

Path parameters

  • idstringrequired

    Membership id (mbr_…); the id without its prefix is accepted too.

Body

  • by"organisation" | "guardian" | "teacher"required

    Who gave it: the organisation attests, a guardian gave it, a teacher recorded it on file.

  • guardianEmailstring (email) | null

    Kept on the place as evidence; never sent in any event or webhook.

  • methodstringrequired

    How it was given: school_form, in_person, email, …

    1-40 characters

  • evidenceRefstring | null

    Your own reference to the evidence.

Returns

200 The place. data is Membership.

Fields of data
  • idstringrequired

    Membership id (mbr_…).

    pattern `^mbr_.*`

  • personIdstringrequired

    Person id (usr_…).

    pattern `^usr_.*`

  • rolestringrequired

    One of the member roles.

  • unitIdstring | nullrequired

    The unit it is held at; null at the organisation level.

  • workspaceIdstring | nullrequired

    A workspace admin's subject (sub_…; bare for keys on 2026-07-08).

  • statusstringrequired

    active, waiting_consent (a child's place waiting for a parent's consent) or disabled.

  • gradeBandstring | nullrequired
  • ageBand"18+" | nullrequired

    "18+": an adult learner, who starts without a parent's or guardian's consent.

  • consentAtstring (date-time) | nullrequired
  • consentBy"organisation" | "guardian" | "teacher" | nullrequired

    Who gave a learner's consent: the organisation, a guardian or a teacher (never their details).

  • consentWithdrawnbooleanrequired

    A guardian's consent was withdrawn from this place (DELETE …/guardian-consent): it waits for a new consent, and nothing else switches it on.

  • createdAtstring (date-time)required

    ISO 8601 UTC timestamp.

  • updatedAtstring (date-time)required

    ISO 8601 UTC timestamp.

Errors

invalid_requestunauthorizedforbiddenupgrade_requirednot_foundconflictidempotency_conflictidempotency_in_progressrate_limitedserver_error

Events

consent.recorded

Request

curl -X POST "https://app.zentiqai.com/v1/memberships/mbr_123/guardian-consent" \
  -H "Authorization: Bearer $ZENTIQ_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "by": "organisation",
  "method": "school_form"
}'

Response

200 · JSON
{
  "data": {
    "id": "mbr_cmfq2b7x10000abcd1234",
    "personId": "usr_cmfq2b7x10000abcd1234",
    "role": "…",
    "unitId": "unit_cmfq2b7x10000abcd1234",
    "workspaceId": "sub_cmfq2b7x10000abcd1234",
    "status": "active"
  },
  "error": null,
  "requestId": "req_4f1c2e9a7b3d5e6f7a8b9c0d"
}
DELETE/v1/memberships/{id}/guardian-consent

Withdraw a parent's or guardian's consent

withdrawGuardianConsentpeople:writewrite: 120/min per keySince 2026-10-01

The learner's place waits for consent again, and any conversation the learner is in now ends. Nothing switches it back on (not the organisation's attestation, not earlier sessions) until consent is recorded again with POST. Withdrawing twice returns the place unchanged. consent.withdrawn says who withdrew it, never why.

Path parameters

  • idstringrequired

    Membership id (mbr_…); the id without its prefix is accepted too.

Returns

200 The place. data is Membership.

Fields of data
  • idstringrequired

    Membership id (mbr_…).

    pattern `^mbr_.*`

  • personIdstringrequired

    Person id (usr_…).

    pattern `^usr_.*`

  • rolestringrequired

    One of the member roles.

  • unitIdstring | nullrequired

    The unit it is held at; null at the organisation level.

  • workspaceIdstring | nullrequired

    A workspace admin's subject (sub_…; bare for keys on 2026-07-08).

  • statusstringrequired

    active, waiting_consent (a child's place waiting for a parent's consent) or disabled.

  • gradeBandstring | nullrequired
  • ageBand"18+" | nullrequired

    "18+": an adult learner, who starts without a parent's or guardian's consent.

  • consentAtstring (date-time) | nullrequired
  • consentBy"organisation" | "guardian" | "teacher" | nullrequired

    Who gave a learner's consent: the organisation, a guardian or a teacher (never their details).

  • consentWithdrawnbooleanrequired

    A guardian's consent was withdrawn from this place (DELETE …/guardian-consent): it waits for a new consent, and nothing else switches it on.

  • createdAtstring (date-time)required

    ISO 8601 UTC timestamp.

  • updatedAtstring (date-time)required

    ISO 8601 UTC timestamp.

Errors

invalid_requestunauthorizedforbiddenupgrade_requirednot_foundconflictrate_limitedserver_error

Events

consent.withdrawn

Request

curl -X DELETE "https://app.zentiqai.com/v1/memberships/mbr_123/guardian-consent" \
  -H "Authorization: Bearer $ZENTIQ_API_KEY"

Response

200 · JSON
{
  "data": {
    "id": "mbr_cmfq2b7x10000abcd1234",
    "personId": "usr_cmfq2b7x10000abcd1234",
    "role": "…",
    "unitId": "unit_cmfq2b7x10000abcd1234",
    "workspaceId": "sub_cmfq2b7x10000abcd1234",
    "status": "active"
  },
  "error": null,
  "requestId": "req_4f1c2e9a7b3d5e6f7a8b9c0d"
}