Skip to content

organization

Pydantic models related to organizations.

The organization is the billing / quota / tenancy boundary.

MemberUsageOut pydantic-model

Bases: BaseModel

One member's share of the organization's usage.

Read by the organization's owner and admins, who pay for what every member holds but cannot open a colleague's private projects: the figures say where the space and the credits go without naming what is in them.

Config:

  • frozen: True

Fields:

analysis_count pydantic-field

The member's analyses that are neither deleted nor failed, cancelled or rejected.

credits_used pydantic-field

Credits the organization has spent or reserved on those analyses.

email pydantic-field

The member's email address.

name = None pydantic-field

The member's display name, if set.

private_storage_bytes pydantic-field

The part of storage_bytes inside the member's private projects, which only they can open or free.

project_count pydantic-field

Projects the member owns in the organization, private ones included.

role pydantic-field

The member's role in the organization.

storage_bytes pydantic-field

Bytes the member's recordings, results and exports hold against the organization's storage ceiling, private projects included.

user_id pydantic-field

The member's user id.

OrganizationUpdate pydantic-model

Bases: BaseModel

Self-service organization update (owner or admin).

Name what changes and leave out the rest: its display name, whether its analyses run at its site, and whether it keeps its recordings there.

Fields:

Validators:

  • _set_or_left

analyses_at_site = None pydantic-field

Whether the organization's analyses run at its site, from the next one submitted. Turning it on needs site compute and an approved runner at the site taking work; turning it off needs its recordings kept on the platform.

name = None pydantic-field

New display name for the organization: a team label of at most 64 characters, shown wherever the organization is named (member list, dialogs, emails).

recordings_at_site = None pydantic-field

Whether the organization keeps its recordings at its site. While it does, every new project is stored in its bucket, and its projects on the platform take no new recordings; what they hold stays. Turning it on needs site storage, analyses at the site, and a ready bucket.

OrganizationUsageOut pydantic-model

Bases: BaseModel

What the organization holds now, against its ceilings.

Every member reads the totals. The owner and admins also get one row per member, largest holder first: their answer to "what fills the storage". Private projects count, because the organization pays for them; their names and contents do not appear here.

Config:

  • frozen: True

Fields:

analysis_hours pydantic-field

Hours of signal the organization's analyses cover: those neither deleted nor failed, cancelled or rejected.

members = None pydantic-field

For the owner and admins, one row per member, the largest storage holder first; ties keep the members' order (owner, admins, then by joining date). Null for any other member.

project_cap = None pydantic-field

Projects the organization may hold; null when uncapped.

project_count pydantic-field

Projects in the organization.

storage_bytes pydantic-field

Bytes the organization holds against its storage ceiling.

storage_ceiling_bytes pydantic-field

The organization's storage ceiling, in bytes.

study_count pydantic-field

Studies across the organization's projects.

OwnershipTransfer pydantic-model

Bases: FreshCheck

Hand the organization to another member (owner only), with a fresh check.

The current owner becomes an admin. The check is asked because the transfer hands over every project, member and credit of the organization in one step.

Fields:

user_id pydantic-field

The member who becomes the owner.

UserOrganizationOut pydantic-model

Bases: BaseModel

The caller's organization, as the caller sees it.

A member-level view: identity, the caller's own role and membership, and the seat picture. Admin-only organization details (overrides, insolvency state) stay behind the admin endpoints.

Every account belongs to exactly one organization: the one created for it at sign-up, or the one it joined by invitation. Projects, credits and storage all belong to it.

Config:

  • frozen: True

Fields:

analyses_at_site = False pydantic-field

Whether the organization's analyses run at its site, on its own runners, instead of on the platform.

created_at pydantic-field

When the organization was created

id pydantic-field

Unique identifier of the organization

member_count = 1 pydantic-field

Members of the organization, the caller included.

membership_id = None pydantic-field

The caller's membership in this organization; the id to address when leaving it.

name pydantic-field

Display name of the organization

project_count = 0 pydantic-field

Projects in the organization. On accepting an invitation elsewhere they come along, private.

project_limit = None pydantic-field

Projects the organization may hold; null when unlimited.

recordings_at_site = False pydantic-field

Whether the organization keeps its recordings at its site: every new project is stored in its bucket, and its projects on the platform take no new recordings.

role pydantic-field

The caller's role in this organization.

seat_limit = None pydantic-field

Members plus pending invitations the organization may hold; null when unlimited.

site_storage = False pydantic-field

Whether the organization holds site storage, so a project's recordings may be kept in its bucket. False from a server that predates it.

site_storage_ready = False pydantic-field

Whether a new project can be stored in the organization's bucket now: the organization holds site storage and site compute, and its bucket is ready.

storage_ceiling_gb = None pydantic-field

The storage the organization may use, in GB. The ceiling in force, not an override.

study_limit = None pydantic-field

Studies one of the organization's projects may hold.