Skip to content
Пилотная фаза – пока не коммерческое предложение. Первые 500 пользователей работают бесплатно и дают нам обратную связь. Первый тарифный раунд стартует в мае 2027
Firmspace
Назад в блог

Who May See the Till: Seven Roles, a Closed Door and an Assistant That Obeys Both

Access debates usually begin after something has gone wrong: a quote sent with the margin visible, a salary file opened by the wrong person, an intern who could delete an invoice. In Firmspace the question is asked earlier, and it is asked by the server rather than by the screen. Every API call has to answer three things at once: who is asking, which section of the firm the address belongs to, and whether the method changes data. If the answer is unclear, the answer is no.

The mechanics are boring on purpose. A request arrives with a token; the server finds the person, finds the firm the person is working in, and reads the membership — the role plus an optional list of extra sections. From the address it derives a section, from the method it derives read or write, and the three values are compared once. A mismatch returns HTTP 403 with one of three codes: forbidden when the role lacks the section, plan when the section is not part of the tariff, demo when the account is a demonstration firm. Three reasons, one door.

There are seven roles. Five are ordinary: owner, administrator, manager, employee and viewer. Two are guests — an accountant and a lawyer who work inside a client's firm through a practice link; they are never invited through the team screen and never receive a salary record. The guest roles are a separate mechanism and deserve their own article; for the daily work of a normal firm the first five are the ones that matter.

The defaults are readable at a glance. The owner has every section, including billing. An administrator has everything except billing — the subscription stays with the person who pays. A manager gets CRM, tasks, the company record, collaboration, mail, marketing and finance. An employee gets CRM, tasks, collaboration and mail. A viewer gets the same four sections but reads only: any method other than GET or HEAD is refused for a viewer, everywhere, without exceptions for convenience.

Above the role sits an optional list of sections. An owner or an administrator can hand out individual sections instead of accepting the default: a bookkeeper who needs finance but not the pipeline, a salesperson who needs CRM but not the till. The list of what can be handed out is fixed and deliberately shorter than the list of what exists: settings, members and billing can never be granted. And an empty list is not the same as an empty firm — a special value marks 'no sections at all', otherwise an empty list would silently mean 'role defaults'.

Finance is one very wide door. Invoices, quotes, orders, contracts, expenses, bank transactions, stock, purchases and production sit behind the same section, because they are one accounting story. That is convenient, and it is also where a small firm most often over-grants: 'finance' for someone who only needs to see quotes. The one exception is the guest role, where a client can cut access into ten narrow permissions such as invoices, bank or clients — but that narrowing exists for outside specialists, not for your own team.

The mapping from address to section is a written list, and the default is closed. Any API prefix that nobody has mapped is denied to everyone — not to employees, to everyone, including the owner. A new route cannot be forgotten open; it can only be forgotten closed. There is a short allow-list for genuinely public addresses such as webhooks, the public chat and the status endpoint, and everything else has to earn its section in that table.

The check runs on every request and is not cached. Revoking a section does not wait for a session to expire or for the person to log out: the next click already fails. The same is true of firms: a person can belong to several, the active one arrives in a header, and access is always evaluated for the firm that is open in that tab — not for the one that was open yesterday.

Role and tariff are two different questions, and it is worth keeping them apart. A section can exist for the role and still be closed because the plan does not include it; the answer is then a 403 with the code plan, and the screen can say 'this is not in your plan' instead of pretending the feature does not exist. A firm that upgrades does not have to change its roles; a firm that changes roles does not have to change its plan.

Now the part this article is really about. The assistant in the CRM does not have a private key to the firm. Before a request is sent to the model, the server builds the tool list with the same function that guards the pages: a tool belongs to a section, and a write tool additionally requires the right to change data. A viewer therefore receives read tools only — and may still ask the assistant, because the chat request is classified as a read: the answer changes nothing, the changes happen later, separately, under the same rights.

When a section is closed, the assistant is not told that the tool does not exist. It gets a plain refusal — the user has no access to this section — and the instruction not to guess around it. This distinction matters in practice: a model that believes a tool is missing starts improvising from other sources, while a model that knows it hit a wall stops and says so. The generic browsing tool follows the same rule per record type, so a wide question cannot be used as a side door into inventory or mail.

Inside the open sections the assistant behaves like a careful administrator. It can create an invoice, mark one as paid, order what is out of stock, move a deal or write a note — but every write passes through a confirmation card that names the record, and the write happens afterwards. A confirmation is a second pair of eyes, not a permission. If the role cannot write finance, no amount of confirming will help: the tool is not in the list to begin with.

Exports and imports have their own small door. Downloading contacts and companies requires the CRM section; downloading invoices, quotes, orders, expenses or the DATEV file requires finance. That is why a person who can see the client list cannot simply pull the whole invoice history into a spreadsheet, and why an accountant who only needs the export still gets exactly the sections the owner granted.

Two edge cases are worth knowing. A demonstration firm is blocked from the write routes specifically, and answers with the code demo — which is why a demo cannot be used to test what happens after a real change. And a guest of a practice is checked against the live client link and the client's consent on every single request, with an access record written for reads as well: the narrowest door in the product.

What to do with this on a Monday morning: list the people who can open finance and ask why each one needs it; replace role defaults with explicit sections where the default is wider than the work; check that nobody is an administrator because it was easier than deciding; and remember that the assistant inherits all of it. What this article cannot give you is a number — how many firms over-grant, or how often a section is misconfigured. That would need access to other firms' settings, and without that access any figure would be invented.

Автоматизируем ваш следующий процесс вместе.

Опишите повторяющийся рабочий процесс. Мы вместе проверим, можно ли его разумно автоматизировать.