---
sidebar:
  hidden: true
title: roboto.domain.orgs.org_records
---
## Module Contents

### EmailDomainVerificationChallengeRecord

```python
class roboto.domain.orgs.org_records.EmailDomainVerificationChallengeRecord(
    /,
    **data: Any,
)
```

`from roboto.domain.orgs import EmailDomainVerificationChallengeRecord`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L174-L200)

Bases: `pydantic.BaseModel`

Data record of an organization's pending verification of an email domain, as the Roboto API returns it.

The verification completes when an organization administrator asks Roboto to check the domain, with [`check_email_domain_verification()`](/docs/reference/python-sdk/roboto/domain/orgs/org#roboto.domain.orgs.org.Org.check_email_domain_verification), before `expires_at`, and Roboto finds the DNS TXT record it issued for the verification. Carried in `OrgEmailDomainListing.verification_challenges`, [`verification_challenge`](/docs/reference/python-sdk/roboto/domain/orgs/org_operations#roboto.domain.orgs.org_operations.BindEmailDomainResponse.verification_challenge) and [`verification_challenge`](/docs/reference/python-sdk/roboto/domain/orgs/org_operations#roboto.domain.orgs.org_operations.EmailDomainVerificationChallengeResponse.verification_challenge).

**Parameters**

- **data** (`Any`)

**Attributes**

- **EmailDomainVerificationChallengeRecord.auto_join_on_verify** (`bool`): Whether auto-join turns on when the verification completes, for a domain the organization does not hold yet.

  A domain the organization already holds keeps its auto-join setting.

- **EmailDomainVerificationChallengeRecord.created** (`datetime.datetime`): Time Roboto issued the verification's current DNS TXT record.

- **EmailDomainVerificationChallengeRecord.email_domain** (`str`): Email domain being verified.

- **EmailDomainVerificationChallengeRecord.expires_at** (`datetime.datetime`): Time from which the verification's DNS TXT record no longer completes it, 14 days after `created`.

- **EmailDomainVerificationChallengeRecord.org_id** (`str`): ID of the organization verifying the domain.

### EmailDomainVerificationTxtRecord

```python
class roboto.domain.orgs.org_records.EmailDomainVerificationTxtRecord(/, **data: Any)
```

`from roboto.domain.orgs import EmailDomainVerificationTxtRecord`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L203-L216)

Bases: `pydantic.BaseModel`

DNS TXT record to publish at an email domain to verify it for an organization.

Roboto shows its value once, in the response to the request that issued it, and keeps only a hash of its token. Carried in [`verification_txt_record`](/docs/reference/python-sdk/roboto/domain/orgs/org_operations#roboto.domain.orgs.org_operations.CreateOrgResponse.verification_txt_record), [`verification_txt_record`](/docs/reference/python-sdk/roboto/domain/orgs/org_operations#roboto.domain.orgs.org_operations.BindEmailDomainResponse.verification_txt_record) and [`verification_txt_record`](/docs/reference/python-sdk/roboto/domain/orgs/org_operations#roboto.domain.orgs.org_operations.EmailDomainVerificationChallengeResponse.verification_txt_record).

**Parameters**

- **data** (`Any`)

**Attributes**

- **EmailDomainVerificationTxtRecord.name** (`str`): DNS name to publish the record at, which is the email domain.
- **EmailDomainVerificationTxtRecord.value** (`str`): Value of the record: `roboto-domain-verification=` followed by a token.

### EventModel

```python
class roboto.domain.orgs.org_records.EventModel
```

`from roboto.domain.orgs import EventModel`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L39-L57)

Bases: `roboto.compat.StrEnum`

Stage of an organization's move from the legacy event store to the session event store.

Events on datasets, files, topics and message paths (IDs beginning with `ev_`) live in the legacy store. Events on sessions (IDs beginning with `evt_`) live in the session store. An organization moves forward through these stages, never back, in the order the members are listed.

**Attributes**

- **EventModel.Dual** = `'dual'`: Both stores, each readable and writable.
- **EventModel.Legacy** = `'legacy'`: Only the legacy store. Session events cannot be created or read.
- **EventModel.Migrating** = `'migrating'`: Both stores. The legacy store is read-only while its events are copied to the session store.
- **EventModel.Session** = `'session'`: Only the session store. Legacy events cannot be created or read.

### GuestOrMember

```python
type roboto.domain.orgs.org_records.GuestOrMember = typing.Literal[OrgBuiltInRole.guest, OrgBuiltInRole.member]
```

`from roboto.domain.orgs import GuestOrMember`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L277-L277)

The built-in roles a member is given by setting their roles or by accepting an invite: guest or member. Admin and owner are given through the organization's membership update, and admin also through an invite's `role`.

### OrgBuiltInRole

```python
class roboto.domain.orgs.org_records.OrgBuiltInRole
```

`from roboto.domain.orgs import OrgBuiltInRole`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L249-L274)

Bases: `roboto.compat.StrEnum`

The built-in role a member of an organization holds. Every member holds exactly one, and each includes the one before it: a member may do everything a guest may, an admin everything a member may, and an owner everything an admin may.

Presets and roles the organization defines add to a member's built-in role, whether held by the member or by a group they are in. Every such role gives only what a member already has, so it changes what a guest may do and nothing for anyone else. Guest exists only on a Roboto deployment that decides access from Roboto's own tables alone, in an organization whose `access_control_features` is on; everywhere else every member is a member, admin or owner.

**Attributes**

- **OrgBuiltInRole.admin** = `'admin'`: May also run the organization (its members, invites, groups, roles and settings) and open its restricted records.
- **OrgBuiltInRole.guest** = `'guest'`: May do what every member always may, such as reading the organization, its members, groups and roles, plus what their roles, their groups' roles and records shared with them allow. A guest never invites anyone or changes the organization's members, groups, roles or settings.
- **OrgBuiltInRole.member** = `'member'`: May open, change and upload to the organization's records that are not restricted, and invite people.
- **OrgBuiltInRole.owner** = `'owner'`: May also change and delete the organization.

### OrgEmailDomainListing

```python
class roboto.domain.orgs.org_records.OrgEmailDomainListing(/, **data: Any)
```

`from roboto.domain.orgs import OrgEmailDomainListing`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L219-L229)

Bases: `pydantic.BaseModel`

Response body of [`email_domain_listing()`](/docs/reference/python-sdk/roboto/domain/orgs/org#roboto.domain.orgs.org.Org.email_domain_listing).

Holds the email domains an organization holds, and its unexpired verifications of email domains.

**Parameters**

- **data** (`Any`)

**Attributes**

- **OrgEmailDomainListing.email_domains** (`list[OrgEmailDomainRecord]`): Email domains the organization holds.
- **OrgEmailDomainListing.verification_challenges** (`list[EmailDomainVerificationChallengeRecord]`): Unexpired verifications of email domains that the organization has in progress.

### OrgEmailDomainRecord

```python
class roboto.domain.orgs.org_records.OrgEmailDomainRecord(/, **data: Any)
```

`from roboto.domain.orgs import OrgEmailDomainRecord`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L127-L171)

Bases: `pydantic.BaseModel`

Data record of an email domain an organization holds, as the Roboto API returns it.

People who sign up with an address at the domain join the organization while `auto_join` is on and the domain is verified, or provisionally approved by Roboto with an approval that has not expired. Where Roboto does not require email domains to be verified, an unapproved domain lets them join too.

Returned by [`check_email_domain_verification()`](/docs/reference/python-sdk/roboto/domain/orgs/org#roboto.domain.orgs.org.Org.check_email_domain_verification) and [`set_email_domain_auto_join()`](/docs/reference/python-sdk/roboto/domain/orgs/org#roboto.domain.orgs.org.Org.set_email_domain_auto_join), and listed by [`email_domain_listing()`](/docs/reference/python-sdk/roboto/domain/orgs/org#roboto.domain.orgs.org.Org.email_domain_listing).

**Parameters**

- **data** (`Any`)

**Attributes**

- **OrgEmailDomainRecord.auto_join** (`bool`): Whether auto-join is on: whether people who sign up with an address at the domain join the organization.

- **OrgEmailDomainRecord.created** (`datetime.datetime`): Time the organization started holding the domain.

- **OrgEmailDomainRecord.email_domain** (`str`): Email domain, such as `example.com`, in lowercase.

- **OrgEmailDomainRecord.may_turn_on_auto_join** (`bool`): Whether auto-join could be turned on for the domain when Roboto built this record.

  It is `True` when the domain was verified then, or provisionally approved with an approval that had not expired. Every caller gets the same value; only an organization administrator can turn auto-join on.

- **OrgEmailDomainRecord.org_id** (`str`): ID of the organization that holds the domain.

- **OrgEmailDomainRecord.provisional_approval_expires_at** (`datetime.datetime | None`) = `None`: Time Roboto's provisional approval of the domain expires.

  `None` unless `status` is `ProvisionallyApproved`.

- **OrgEmailDomainRecord.status** (`OrgEmailDomainStatus`): Verification status of the domain.

- **OrgEmailDomainRecord.verification_method** (`OrgEmailDomainVerificationMethod | None`) = `None`: Method by which the domain was verified, or `None` unless `status` is `Verified`.

- **OrgEmailDomainRecord.verified_at** (`datetime.datetime | None`) = `None`: Time the domain was verified, or `None` unless `status` is `Verified`.

### OrgEmailDomainStatus

```python
class roboto.domain.orgs.org_records.OrgEmailDomainStatus
```

`from roboto.domain.orgs import OrgEmailDomainStatus`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L94-L114)

Bases: `roboto.compat.StrEnum`

Verification status of an email domain an organization holds.

Only a verified domain shows that the organization controls it.

**Attributes**

- **OrgEmailDomainStatus.ProvisionallyApproved** = `'provisionally_approved'`: Approved for the organization by Roboto without verification.

  The approval lasts until `OrgEmailDomainRecord.provisional_approval_expires_at`, and the status stays `ProvisionallyApproved` after that.

- **OrgEmailDomainStatus.Unapproved** = `'unapproved'`: Neither verified nor provisionally approved, as is a domain bound where Roboto does not require verification.

- **OrgEmailDomainStatus.Verified** = `'verified'`: Verified, either because Roboto found the DNS TXT record it issued for the domain or by a Roboto administrator.

  `OrgEmailDomainRecord.verification_method` says which.

### OrgEmailDomainVerificationMethod

```python
class roboto.domain.orgs.org_records.OrgEmailDomainVerificationMethod
```

`from roboto.domain.orgs import OrgEmailDomainVerificationMethod`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L117-L124)

Bases: `roboto.compat.StrEnum`

Method by which an email domain was verified.

**Attributes**

- **OrgEmailDomainVerificationMethod.DnsTxt** = `'dns_txt'`: Roboto found, at the domain, the DNS TXT record it issued for the organization's verification of it.
- **OrgEmailDomainVerificationMethod.Staff** = `'staff'`: A Roboto administrator verified the domain.

### OrgGroupMemberRecord

```python
class roboto.domain.orgs.org_records.OrgGroupMemberRecord(/, **data: Any)
```

`from roboto.domain.orgs import OrgGroupMemberRecord`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L415-L425)

Bases: `pydantic.BaseModel`

A wire-transmissible representation of a member of an organization's group.

**Parameters**

- **data** (`Any`)

**Attributes**

- **OrgGroupMemberRecord.added** (`datetime.datetime`): When they were added to the group.
- **OrgGroupMemberRecord.added_by** (`str | None`) = `None`: User ID of the person who added them to the group.
- **OrgGroupMemberRecord.user** (`roboto.domain.users.UserRecord`): User information for the group member.

### OrgGroupRecord

```python
class roboto.domain.orgs.org_records.OrgGroupRecord(/, **data: Any)
```

`from roboto.domain.orgs import OrgGroupRecord`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L388-L412)

Bases: `pydantic.BaseModel`

A wire-transmissible representation of a group of an organization's members, which the organization's records can be shared with.

**Parameters**

- **data** (`Any`)

**Attributes**

- **OrgGroupRecord.created** (`datetime.datetime`): When the group was made.
- **OrgGroupRecord.created_by** (`str | None`) = `None`: User ID of the person who made the group.
- **OrgGroupRecord.description** (`str | None`) = `None`: What the group is for, as its organization's admins wrote it.
- **OrgGroupRecord.group_id** (`str`): Unique identifier for the group.
- **OrgGroupRecord.name** (`str`): The group's name, unique within its organization whatever its case.
- **OrgGroupRecord.org_id** (`str`): Organization the group belongs to.
- **OrgGroupRecord.role_ids** (`list[str] | None`) = `None`: The IDs of the roles the group holds, presets included, ordered by ID. Each member of the group holds them through it. `None` unless roles apply to the organization (see [`OrgUserRecord.held_roles`](/docs/reference/python-sdk/roboto/domain/orgs/org_records#roboto.domain.orgs.org_records.OrgUserRecord.held_roles)).

### OrgHeldRoleRecord

```python
class roboto.domain.orgs.org_records.OrgHeldRoleRecord(/, **data: Any)
```

`from roboto.domain.orgs import OrgHeldRoleRecord`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L340-L352)

Bases: `pydantic.BaseModel`

A role a member of an organization holds, a preset or one the organization defined, and every way they hold it.

**Parameters**

- **data** (`Any`)

**Attributes**

- **OrgHeldRoleRecord.name** (`str`): The role's name.
- **OrgHeldRoleRecord.role_id** (`str`): The role's ID, which starts with `rl_` for a role the organization defined and `preset_` for a preset.
- **OrgHeldRoleRecord.through** (`list[OrgRoleSource]`): Every way the member holds the role: themselves, and each group of the organization that holds it and that they are in.

### OrgInviteRecord

```python
class roboto.domain.orgs.org_records.OrgInviteRecord(/, **data: Any)
```

`from roboto.domain.orgs import OrgInviteRecord`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L478-L513)

Bases: `pydantic.BaseModel`

Data record of an invitation to join an organization, as the Roboto API returns it.

[`OrgInvite`](/docs/reference/python-sdk/roboto/domain/orgs/org_invite#roboto.domain.orgs.org_invite.OrgInvite) wraps this record with methods to accept or decline the invitation.

**Parameters**

- **data** (`Any`)

**Attributes**

- **OrgInviteRecord.built_in_role** (`GuestOrMember | None`) = `None`: On an invite with the `user` role, the built-in role the invited user gets in the organization by accepting, where `None` means a member. `None` on an invite with any other role, whose [`role`](/docs/reference/python-sdk/roboto/domain/orgs/org_records#roboto.domain.orgs.org_records.OrgInviteRecord.role) decides.

- **OrgInviteRecord.expires_at** (`datetime.datetime | None`) = `None`: Time after which the invitation cannot be accepted, unless an organization administrator renews it.

  `None` from a Roboto deployment that does not set invitation expiry.

- **OrgInviteRecord.invite_id** (`str`): Unique ID of the invitation, beginning with `in_`.

- **OrgInviteRecord.invited_by** (`roboto.domain.users.UserRecord`): Record of the user who sent the invitation.

- **OrgInviteRecord.latest_email_bounced** (`bool`) = `False`: Whether the most recent email of the invitation bounced. `False` while a resent email waits to be sent.

- **OrgInviteRecord.org** (`OrgRecord`): Record of the organization the invitation is to.

- **OrgInviteRecord.role** (`OrgRoleName`): Role the invited user gets in the organization by accepting.

- **OrgInviteRecord.status** (`OrgInviteStatus`): Status of the invitation when Roboto read it. A pending invitation reads as `Expired` after its expiry.

- **OrgInviteRecord.user_id** (`str`): ID of the invited user, which for a person is their email address.

### OrgInviteStatus

```python
class roboto.domain.orgs.org_records.OrgInviteStatus
```

`from roboto.domain.orgs import OrgInviteStatus`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L296-L312)

Bases: `roboto.compat.StrEnum`

Status of an invitation to join an organization.

**Attributes**

- **OrgInviteStatus.Accepted** = `'accepted'`: Accepted by the invited user, who became a member.
- **OrgInviteStatus.Declined** = `'declined'`: Declined by the invited user.
- **OrgInviteStatus.Expired** = `'expired'`: Past its expiry while still pending.
- **OrgInviteStatus.Pending** = `'pending'`: Not yet accepted, declined, revoked, or past its expiry. The invited user may still accept or decline it.
- **OrgInviteStatus.Revoked** = `'revoked'`: Withdrawn by its sender or an organization administrator, or replaced by a Roboto administrator's new one.

### OrgRecord

```python
class roboto.domain.orgs.org_records.OrgRecord(/, **data: Any)
```

`from roboto.domain.orgs import OrgRecord`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L60-L91)

Bases: `pydantic.BaseModel`

Data record of an organization, as the Roboto API returns it.

An organization is a workspace in which users share datasets, actions and other resources in Roboto. [`Org`](/docs/reference/python-sdk/roboto/domain/orgs/org#roboto.domain.orgs.org.Org) wraps this record with methods that act on the organization.

**Parameters**

- **data** (`Any`)

**Attributes**

- **OrgRecord.access_control_features** (`bool`) = `False`: Whether Roboto has turned on groups, restricted records and organization-defined roles for the organization. Only Roboto staff can change it. While it is off, the organization's groups and roles cannot be made or changed, and the web app does not offer to restrict a dataset or collection, though the API restricts one either way.
- **OrgRecord.created** (`datetime.datetime`): Time the organization was created.
- **OrgRecord.created_by** (`str | None`) = `None`: ID of the user who created the organization.
- **OrgRecord.event_model** (`EventModel`): Stage of the organization's move from the legacy event store to the session event store.
- **OrgRecord.name** (`str`): Human-readable name of the organization.
- **OrgRecord.org_id** (`str`): Unique ID of the organization, beginning with `og_`.
- **OrgRecord.status** (`OrgStatus`): Lifecycle state of the organization.
- **OrgRecord.tier** (`OrgTier`): Subscription tier of the organization.

### OrgRoleHeldDirectly

```python
class roboto.domain.orgs.org_records.OrgRoleHeldDirectly(/, **data: Any)
```

`from roboto.domain.orgs import OrgRoleHeldDirectly`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L315-L318)

Bases: `pydantic.BaseModel`

A role held by the member themselves.

**Parameters**

- **data** (`Any`)

**Attributes**

- **OrgRoleHeldDirectly.kind** (`Literal['direct']`) = `'direct'`

### OrgRoleHeldThroughGroup

```python
class roboto.domain.orgs.org_records.OrgRoleHeldThroughGroup(/, **data: Any)
```

`from roboto.domain.orgs import OrgRoleHeldThroughGroup`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L321-L330)

Bases: `pydantic.BaseModel`

A role held through a group of the organization the member is in.

**Parameters**

- **data** (`Any`)

**Attributes**

- **OrgRoleHeldThroughGroup.group_id** (`str`): The group's ID.
- **OrgRoleHeldThroughGroup.kind** (`Literal['group']`) = `'group'`
- **OrgRoleHeldThroughGroup.name** (`str`): The group's name.

### OrgRoleKind

```python
class roboto.domain.orgs.org_records.OrgRoleKind
```

`from roboto.domain.orgs import OrgRoleKind`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L282-L293)

Bases: `roboto.compat.StrEnum`

Who defined a role an organization's members can hold.

**Attributes**

- **OrgRoleKind.built_in** = `'built_in'`: One of the four built-in roles ([`OrgBuiltInRole`](/docs/reference/python-sdk/roboto/domain/orgs/org_records#roboto.domain.orgs.org_records.OrgBuiltInRole)), which nobody may change or delete. A member's membership sets their built-in role; no member's or group's list of roles may name one.
- **OrgRoleKind.org_defined** = `'org_defined'`: A role the organization's admins or owners defined.
- **OrgRoleKind.preset** = `'preset'`: A role Roboto defined, which any organization's admins and owners may give and nobody may change or delete.

### OrgRoleName

```python
class roboto.domain.orgs.org_records.OrgRoleName
```

`from roboto.domain.orgs import OrgRoleName`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L232-L246)

Bases: `roboto.compat.StrEnum`

Role a user holds in an organization.

Each role includes the permissions of the roles below it: `owner` includes `admin`, and `admin` includes `user`. The user who creates an organization holds all three.

**Attributes**

- **OrgRoleName.admin** = `'admin'`: Member who can also manage the organization's settings, such as roles, email domains and integrations.
- **OrgRoleName.owner** = `'owner'`: Member who can also update and delete the organization.
- **OrgRoleName.user** = `'user'`: Member of the organization, with access to its resources.

### OrgRoleRecord

```python
class roboto.domain.orgs.org_records.OrgRoleRecord(/, **data: Any)
```

`from roboto.domain.orgs import OrgRoleRecord`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L428-L475)

Bases: `pydantic.BaseModel`

A wire-transmissible representation of a role an organization's members can hold, as the organization's roles list returns it.

A role is one of the four built-in roles ([`OrgBuiltInRole`](/docs/reference/python-sdk/roboto/domain/orgs/org_records#roboto.domain.orgs.org_records.OrgBuiltInRole)), a preset that Roboto defined, or one the organization's admins or owners defined; [`kind`](/docs/reference/python-sdk/roboto/domain/orgs/org_records#roboto.domain.orgs.org_records.OrgRoleRecord.kind) says which. Every member holds exactly one built-in role. Any member, and any group of the organization, may also hold presets and roles the organization defined. Each of those is a set of switches, such as `view_data` or `upload_data`, and each switch lets its holder do a group of things with the organization's records that are not restricted. A member may do what their built-in role lets them do plus what the switches of every role they hold, themselves or through a group, turn on. Roles only add to what a member may do. Every switch gives only what a member already has, so these roles change what a guest may do and nothing for a member, admin or owner.

Presets and roles the organization defined take effect only on a Roboto deployment that decides access from Roboto's own tables alone, and can be given only in an organization whose `access_control_features` is on.

**Parameters**

- **data** (`Any`)

**Attributes**

- **OrgRoleRecord.created** (`datetime.datetime | None`) = `None`: When the role was defined; `None` for a built-in role or a preset.
- **OrgRoleRecord.created_by** (`str | None`) = `None`: User ID of the person who defined the role; `None` for a built-in role or a preset.
- **OrgRoleRecord.description** (`str | None`) = `None`: What the role is for. For a built-in role, what it allows that no switch gives.
- **OrgRoleRecord.kind** (`OrgRoleKind`): Who defined the role. Only a role the organization defined can be changed or deleted.
- **OrgRoleRecord.modified** (`datetime.datetime | None`) = `None`: When the role was last changed; `None` for a built-in role or a preset.
- **OrgRoleRecord.modified_by** (`str | None`) = `None`: User ID of the person who last changed the role; `None` for a built-in role or a preset.
- **OrgRoleRecord.name** (`str`): The role's name. No two roles the organization defined share a name, whatever its case.
- **OrgRoleRecord.org_id** (`str`): Organization the role belongs to, or, for a built-in role or a preset, the organization it was listed for.
- **OrgRoleRecord.role_id** (`str`): The role's ID: the [`OrgBuiltInRole`](/docs/reference/python-sdk/roboto/domain/orgs/org_records#roboto.domain.orgs.org_records.OrgBuiltInRole) value for a built-in role, and otherwise starting with `rl_` for a role the organization defined and `preset_` for a preset.
- **OrgRoleRecord.switches** (`list[str]`): The switches the role turns on, in the order Roboto lists them; every other switch is off. A built-in role lists each switch whose every operation it allows.

### OrgRoleSource

```python
roboto.domain.orgs.org_records.OrgRoleSource
```

`from roboto.domain.orgs import OrgRoleSource`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L333-L335)

themselves (`{"kind": "direct"}`) or through a group (`{"kind": "group", "group_id", "name"}`).

### OrgStatus

```python
class roboto.domain.orgs.org_records.OrgStatus
```

`from roboto.domain.orgs import OrgStatus`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L16-L26)

Bases: `roboto.compat.StrEnum`

Lifecycle state of an organization.

**Attributes**

- **OrgStatus.Active** = `'active'`: Ready for use. Roboto creates every organization in this state.
- **OrgStatus.Deprovisioning** = `'de-provisioning'`: Unused. Roboto never sets this state, including when it deletes an organization.
- **OrgStatus.Provisioning** = `'provisioning'`: Unused. Roboto creates every organization as `Active` and never sets this state.

### OrgTier

```python
class roboto.domain.orgs.org_records.OrgTier
```

`from roboto.domain.orgs import OrgTier`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L29-L36)

Bases: `roboto.compat.StrEnum`

Subscription tier of an organization, which sets its usage limits and which features it can use.

**Attributes**

- **OrgTier.free** = `'free'`: Free tier, with lower usage limits and fewer features than premium.
- **OrgTier.premium** = `'premium'`: Premium tier, with higher usage limits and more features than free.

### OrgUserRecord

```python
class roboto.domain.orgs.org_records.OrgUserRecord(/, **data: Any)
```

`from roboto.domain.orgs import OrgUserRecord`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/domain/orgs/org_records.py#L355-L385)

Bases: `pydantic.BaseModel`

Data record of a user's membership in an organization, as the Roboto API returns it.

[`users()`](/docs/reference/python-sdk/roboto/domain/orgs/org#roboto.domain.orgs.org.Org.users) returns one for each member.

**Parameters**

- **data** (`Any`)

**Attributes**

- **OrgUserRecord.built_in_role** (`OrgBuiltInRole | None`) = `None`: The user's built-in role in the organization: `owner`, `admin`, `guest` or `member`. Filled on every membership a Roboto deployment returns; `None` only from an older deployment. It reads `guest` only where roles apply: on a Roboto deployment that decides access from Roboto's own tables alone, in an organization whose `access_control_features` is on. Elsewhere a guest reads `member`.

- **OrgUserRecord.held_roles** (`list[OrgHeldRoleRecord] | None`) = `None`: The roles, presets included, that the user holds, themselves or through a group, one entry per role with every way they hold it, ordered by name whatever its case. Each adds to what the user's [`built_in_role`](/docs/reference/python-sdk/roboto/domain/orgs/org_records#roboto.domain.orgs.org_records.OrgUserRecord.built_in_role) lets them do. Filled by the organization's members list ([`users()`](/docs/reference/python-sdk/roboto/domain/orgs/org#roboto.domain.orgs.org.Org.users)) and the response to setting a member's roles, only where roles apply (as for [`built_in_role`](/docs/reference/python-sdk/roboto/domain/orgs/org_records#roboto.domain.orgs.org_records.OrgUserRecord.built_in_role)), where a member who holds no role gets an empty list. `None` everywhere else, so a non-`None` value means roles apply to the organization.

- **OrgUserRecord.org** (`OrgRecord`): Record of the organization.

- **OrgUserRecord.roles** (`list[OrgRoleName]`): Roles the member holds in the organization.

  A guest and a member both hold `["user"]`; [`built_in_role`](/docs/reference/python-sdk/roboto/domain/orgs/org_records#roboto.domain.orgs.org_records.OrgUserRecord.built_in_role) tells them apart.

- **OrgUserRecord.user** (`roboto.domain.users.UserRecord`): Record of the member.
