Join a machine
Invite people, create a join command and connect each developer's zn-gate to the organization with zn team join.
A developer is part of your organization in two steps: their account joins (an invitation), and each machine they code on joins (a join command run in zn-gate).
1. Invite people
In the dashboard, open your organization's workspace, then Members. Enter an email and a role and send the invitation. The invitation link works for 7 days; owners and admins can revoke it before it is used.
Pending invitations count as seats in use. If every seat is taken, the owner adds seats before the invitation can be accepted.
2. Connect each machine
-
In Members → Installs, create a join command. It works for as many machines as the organization has seats and expires after 7 days.
-
The developer runs it on their machine:
zn team join <token>zn-gate asks for confirmation in a window outside the coding agent, so an agent cannot join a machine to an organization on its own. The confirmation has two steps.
First, with the default server (api.usezn.com), zn-gate asks whether it may send the join token to usezn.com to find out which organization the token is for. This window shows the server, the last 6 characters of the token (compare them with the ones your administrator sent you) and what would be sent. If you choose Deny, nothing is sent.
Second, another window shows the organization and who invited you. The machine joins only after you confirm this window too.
With a custom
--apiserver there is a single window and no lookup. That window cannot name the organization, and it says so. With no confirmation window (no terminal, or when an AI agent runs the command), nothing is sent and the command refuses. If you did not just run the command yourself, choose Deny. -
From then on zn-gate downloads the organization's policy, verifies its signature and applies it, and uploads the audit trail in the background.
When it joins, zn-gate stores the organization, the API address and the organization's public signing key in ~/.zn/team.json, and the install token in the system keychain, never in plain text. The pinned key is how each machine checks that a policy really comes from your organization.
The Team client is part of zn-gate 1.6.0 and later. Machines on older versions keep working with their local configuration.
When the server refuses
Both answers below leave nothing half-written, so it is safe to run the step again.
| Status | Body | Meaning |
|---|---|---|
| 409 | { "error": "This installation changed while it was being registered; try again", "code": "install_conflict" } |
The installation changed while zn team join was registering it, for example two registrations of the same installation at the same moment. Run zn team join again. |
| 409 | { "error": "This installation already belongs to another organization" } |
This installation is already registered with a different organization, active or revoked. It is never moved or replaced: leave that organization first, or join from a clean installation. |
An invitation can also be refused when the organization's Team has lapsed. See the section on accepting an invitation below.
Accepting an invitation
When someone opens an invitation link, the dashboard calls POST /v1/org/invitations/accept with their signed-in session and the invitation token. Besides the usual answers (invalid link, another email, no free seat, an organization that is being deleted, a link that is invalid or already used), it can answer:
| Status | Body | Meaning |
|---|---|---|
| 402 | { "error": "This organization has no active Team subscription", "code": "no_subscription" } |
The invitation was sent while the Team was active or in trial, but it is no longer active. The invitation stays pending and no member is added. It can be accepted once the organization has an active Team again, until it expires. |
| 409 | { "error": "The organization changed while you were joining; try again", "code": "org_changed" } |
The organization's plan or subscription changed at the moment of accepting. Nothing was written: accept again. |
Everyday commands
| Command | What it does |
|---|---|
zn team status |
Organization, policy version and when it was checked, and the upload state. --json for scripts |
zn team status --rules |
The active signed policy in plain words: its version, the key id it was signed with, when it expires, and each rule (what it blocks, warns about or restricts, for which secret names and agents, and the reason). It reads the saved copy and checks its signature again, makes no network call and shows no rules from a copy that does not verify or has expired. --json adds a rules object |
zn team sync |
Download the policy and upload the audit trail now |
zn team leave |
Disconnect this machine (confirmed outside the agent, like join) |
A machine belongs to one organization at a time. To move it to another one, run zn team leave first.
Remove a machine or a person
- Revoke an install in Members → Installs. That machine stops uploading and keeps applying its cached policy until it expires; then it falls back to strict mode (see Offline mode).
- Remove a member in Members. Their seat is freed and their installs stop receiving the policy.