Answer as each employee
Let your own system ask Nexa on behalf of each employee, so everyone sees only what they're allowed to.
Last updated Nov 1, 2026
What it is
With the chat:delegate permission, your server tells Nexa which employee is asking by sending a short signed header. Nexa then answers with that employee's permissions only.
What it's for
Employees can use Nexa inside your own portal without logging into Nexa. Department-only material stays with the people allowed to see it, and nobody's Private space, the employee's own included, is ever read this way.
How to use it
- As the workspace owner, create a key with
chatandchat:delegate(only the owner can); copy the delegation secret shown once. - On your server, sign
X-Nexa-Acting-Userfor the employee (their email, your workspace, a 5-minute expiry and a one-time nonce). The Developer page has ready Node and Python examples. - Send it with each
/chator/searchrequest. - Use
sources[].indexto link each[n]in the answer to its source.
Tips
- Pass
locale: "ar"or"en"to control the language of clarifications.
Good to know
- Only sign identities on your server — never in the browser.
- Expired, replayed, tampered or non-member assertions are refused; Nexa never falls back to the key creator's access.
- Answers through the API never include anyone's Private files, or tasks and quotes that came only from them, even for the employee who owns them. In the Nexa app nothing changes.
- Only keys created by the workspace owner answer for employees. A key an admin created earlier is refused (
delegation_key_not_usable) and marked on Settings → Developer; the owner creates a new one. An admin who tries to create or replace such a key getsdelegation_owner_only. - Actions that need confirmation are not available through the API.
