---
title: "Set up and manage a Workspace"
description: "Sign in, create a Workspace, choose where its data lives, form Teams, connect a directory and export your account data. Each step names its action and fields."
url: "https://harnesty.com/en/docs/workspaces"
language: "en"
kind: "docs"
updated: "2026-12-02"
summary:
  - "Sign in with an emailed link, then create a Workspace with workspace.create and follow it with workspace.creation.get."
  - "Choose the residency in the create call, because it is fixed at creation."
  - "Form Teams with the group actions, connect your directory, and export your account data."
sources:
  - title: "General REST and MCP reference"
    url: "https://harnesty.com/en/docs/api-reference"
---

# Set up and manage a Workspace

A Workspace is your business's own space in Harnesty. It holds your records, your Mandates and your workspace audit log. A Mandate is a signed record of what a person, an agent or a tool may do. The Workspace is also the boundary for isolation, data residency and billing.

## In short

- Sign in with an emailed link, then create a Workspace with workspace.create and follow it with workspace.creation.get.
- Choose the residency in the create call, because it is fixed at creation.
- Form Teams with the group actions, connect your directory, and export your account data.

One account can belong to several Workspaces. In each one, you may do what the Mandates that Workspace holds for you allow.

Set up a Workspace in this order: sign in, create the Workspace and choose where it keeps its data, then form Teams and connect your directory.

## Sign in with an email link

Harnesty has no passwords. You sign in with a link that we email to you.

1. Call [`auth.signin.request`](https://harnesty.com/en/docs/api-reference#auth.signin.request@v2). Put your email address in `address`, and the language of the sign-in email in `formLocale`, such as `en` or `cs`. To come back to a page of this site after you sign in, add it as `returnPath`.
1. Open the link in the message we send. A link works once, on any device, until it expires.

The request gets the same answer whether or not we hold that address, so nobody can use it to find out who has an account.

## Create a Workspace

Call [`workspace.create`](https://harnesty.com/en/docs/api-reference#workspace.create@v1). You become the founding owner of the Workspace.

1. Set `name`, `slug`, `defaultLocale` (such as `en` or `cs`) and `tier`, the plan the Workspace starts on. All four are required. `slug` is the name in the Workspace's own address, such as `meridian`, and it never changes after the create. Before you send the create, ask [`workspace.slug.check`](https://harnesty.com/en/docs/api-reference#workspace.slug.check@v1) whether the slug is free.
1. Choose how the Workspace is paid for. Send either `anchorReference`, the reference from your payment card setup, or `businessCode`, a code from a Business Manager account. Send one of the two, never both.
1. Set `residencyClass`. The next section says what each value means.
1. Set `ageConfirmed` to true to confirm that you are 18 or older. If the call leaves it out or sends false, we refuse the call, and nothing is created.
1. Send the call with an `Idempotency-Key` header, which makes a repeated call safe. If the connection drops, send the same call again with the same key: the answer names the same Workspace, and no second Workspace is created. The same key with a different input is refused.
1. Keep the answer. `workspace` is the id of the new Workspace. `operation` is the Operation that sets the Workspace up: the record of that set-up, which runs to its end even if your connection drops.
1. Call [`workspace.creation.get`](https://harnesty.com/en/docs/api-reference#workspace.creation.get@v1) with `workspace`, or with your `Idempotency-Key` as `key`. `provision` shows where the set-up stands, and `founding` shows where the founding stands. When the Workspace is set up and founded, you can work in it. If either fails, `provisionCode` or `foundingCode` says why.

## Choose where the Workspace keeps its data

You choose the residency, the place where the Workspace's data stays, in the create call. It is fixed when you create the Workspace. `residencyClass` takes one of two values:

- `eu-guaranteed` stores and processes its data in the EU. You get this value when you leave `residencyClass` out. Traffic to a Catalog integration is an exception: a provider hosted in the US serves the Catalog kind for every Workspace, and our subprocessor list names it. The [data processing agreement](https://harnesty.com/en/legal/data-processing) lists the transfers that our cloud provider documents for an EU region.
- `global` permits every region our terms permit.

A call you make through a Connection to a tool outside Harnesty reaches that tool where the tool is hosted.

To check the residency of an existing Workspace, call [`workspace.residency.get`](https://harnesty.com/en/docs/workspace-reference#workspace.residency.get@v1). It returns `residencyClass` and `permittedRoutes`, the routes to AI models that this residency lets you use. An empty list means that no route serves this residency.

## Form Teams

A Team is a set of members that holds its own Mandates. The API calls it a Group. Members can be people, Agents, Machines and other Teams, and each member acts with everything the Team holds.

- [`group.create`](https://harnesty.com/en/docs/workspace-reference#group.create@v1) creates a Team. Set `displayName`, and set `owner` to the Team that will own the new one: a Team is always owned by a Team, never by one member. `workspaceEnvironments` limits the Workspace Environments, such as production or non-production, that the Team may act in. Leave it out, and the Team gets the same set as you.
- [`group.member.add`](https://harnesty.com/en/docs/workspace-reference#group.member.add@v1) adds a `member` to a `group`. The membership is itself a Mandate, and your workspace audit log records it, with you as the one who added the member.
- [`group.member.remove`](https://harnesty.com/en/docs/workspace-reference#group.member.remove@v1) removes a member. Each Mandate that member issued for the Team stays in force under a new issuer, so what the Team owns keeps working. A Mandate below a moved one ends if it no longer fits under the new issuer, and the answer counts these in `left`. If you will not be in the Team yourself after the member leaves, name a member who stays as `issuer`.
- [`group.list`](https://harnesty.com/en/docs/workspace-reference#group.list@v1) lists the members of your Teams, one page at a time. Set `group` to read one Team's members, `member` to read one member's Teams, or both. `memberKind` on each row says what kind of Principal the member is, such as a person or an Agent.

The owners of a Workspace are the members of its Owners Team, so you add an owner the same way as any other member.

## Connect your directory

A directory is the system where your business keeps its user accounts, such as Microsoft Entra ID. Call [`directory.connection.create`](https://harnesty.com/en/docs/workspace-reference#directory.connection.create@v1) to connect your Workspace to it.

1. Set `source` to the kind of directory, such as `entra-id`, and `trustAnchor` to where its identifiers come from, such as your tenant ID. You cannot connect a directory that gives no person an identifier that never changes.
1. Set `credential` to the credential we use to read the directory. It goes to your Workspace's vault, and no answer ever returns it.
1. Set `fallback` to what happens when the directory cannot prove that a new identifier belongs to the same person. `bar-and-start` bars the old Principal and starts a new one with no Mandates. `refuse-new` keeps the old Principal and refuses the new identifier.
1. Set `ceilingKind` and `ceiling` to one node below your Workspace. That node limits every Policy that reads a fact from this directory.
1. Optionally, set `readFilter` to read only part of the directory, and `schedule` to read it on a schedule. Harnesty does not read the directory yet: it keeps the filter and the schedule for when it does.

A directory connection grants nobody anything. A directory administrator cannot give anyone authority in your Workspace: a person the directory names holds only the Mandates you grant them. Your workspace audit log records the connection, who made it and under what authority.

[`directory.connection.remove`](https://harnesty.com/en/docs/workspace-reference#directory.connection.remove@v1) removes the connection and the identifiers it linked to people. It bars nobody: a person who has another way to sign in keeps working, and everyone keeps their Mandates and their history.

## Export your account data

[`user.account.export`](https://harnesty.com/en/docs/api-reference#user.account.export@v1) returns your account data at once, in one machine-readable document. It answers for your own account alone.

The document holds your account and your email addresses. For each list that Harnesty holds about your account, it returns the count and the first entries. These lists are the Workspaces you belong to, your sign-ins, and the consent history and messages of your marketing addresses. Read the rest of each list with [`user.account.workspaces`](https://harnesty.com/en/docs/api-reference#user.account.workspaces@v1), [`user.account.sessions`](https://harnesty.com/en/docs/api-reference#user.account.sessions@v1), [`user.account.provenance`](https://harnesty.com/en/docs/api-reference#user.account.provenance@v1) and [`user.account.sends`](https://harnesty.com/en/docs/api-reference#user.account.sends@v1).

The document and these reads name each Workspace you belong to, but nothing inside it. The data a Workspace holds about you as its member belongs to the business that owns that Workspace, so ask that business for it.

## Sources

1. [General REST and MCP reference](https://harnesty.com/en/docs/api-reference)
