# invite

URL: /business/nouns/tenant/invite · Id: `verb:Tenant.invite` · Call: `await $.Tenant.invite({ … })` (SDK) or the `do` tool at `https://api.sb/mcp`. Inputs says what to pass, Outputs what returns, When it waits who approves.

> Invite asks a Person to join a Customer’s Tenant, and resizes the Subscription when the Offer prices per member.

Invite asks a [Person](/business/nouns/person) to join a [Customer](/business/nouns/customer)’s [Tenant](/business/nouns/tenant), and resizes the [Subscription](/business/nouns/subscription) when the [Offer](/business/nouns/offer) prices per member.

## Inputs
| Input | Type | Required | Description |
| --- | --- | --- | --- |
| `tenant` | [Tenant](/business/nouns/tenant) | Yes | The Customer’s Tenant. |
| `email` | `email` | Yes | Where the invitation goes. |

## Outputs
| Output | Type | Required | Description |
| --- | --- | --- | --- |
| `person` | [Person](/business/nouns/person) | Yes | The invited Person. |
| `tenant` | [Tenant](/business/nouns/tenant) | Yes | The Tenant the Person was invited to. |

## Effects
- Emits [`Tenant.invited`](/business/events/Tenant.invited).
- Performed by the [Security Engineer](/agents/engineering/security-engineer).
- Two-way: it runs at once, in the `try`, `send` and `do` modes.
- Adds one unit through `Subscription.resize` when no unit is free.
- Grants the Tenant’s Entitlements to the Person once they accept.

## Refuses when
| Check | Error | Fix | Then call |
| --- | --- | --- | --- |
| The key is valid, but its scopes do not allow this operation. | [`forbidden`](/code/api/errors/forbidden) | Use a key whose scopes cover the operation, or ask an owner of the namespace to grant them. | [Tenant.invite](/business/nouns/tenant/invite) |

## When it waits
| Gate | Default |
| --- | --- |
| Decision class | Low: two-way, nothing at stake |
| [Delay window](/systems/trust-and-governance/controls/one-way-windows) | None: it runs once review passes. |
| Limit | The call [Limit](/business/nouns/limit) of the [Permission](/business/nouns/permission) it runs under. |
| Over the Limit | It waits `pending` for an [Approval](/business/nouns/approval) from the [Founder](/agents/founding/founder). Approved, it runs; refused, it ends `refused` with [`limit-exceeded`](/code/api/errors/limit-exceeded); unanswered by its deadline, it ends `canceled`. |

## Example

**Ask**

```text
Invite the latest tenant.
```

**API**

```bash
curl -X POST https://api.sb/routewise.dev/tenants/tenant_1/invite \
  -H "Authorization: Bearer $STARTUP_BUILDER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"email":"hana@routewise.dev"}'
```

```json
{
  "api": "https://api.sb/routewise.dev",
  "person": {
    "$id": "https://api.sb/routewise.dev/people/person_1",
    "$type": "Person",
    "name": "Hana Sato"
  },
  "tenant": {
    "$id": "https://api.sb/routewise.dev/tenants/tenant_1",
    "$type": "Tenant",
    "placement": "path",
    "apiVersion": "v2"
  },
  "action": {
    "$id": "https://api.sb/routewise.dev/actions/action_1",
    "operation": "Tenant.invite",
    "status": "done"
  },
  "links": {
    "self": "https://api.sb/routewise.dev/actions/action_1"
  }
}
```

**SDK**

```ts
import { $ } from 'startup-builder'

const { person, tenant } = await $.Tenant.invite({ tenant: 'tenant_1', email: 'hana@routewise.dev' })
```

**CLI**

```bash
npx startup-builder do Tenant.invite --json '{"tenant":"tenant_1","email":"hana@routewise.dev"}'
```

**MCP**

```json
{
  "name": "do",
  "arguments": {
    "code": "return await $.Tenant.invite({ tenant: 'tenant_1', email: 'hana@routewise.dev' })"
  }
}
```

Guides that call it: [Let customers sign in](/products/app/let-customers-sign-in).