# Models: T

> API models starting with T.

## `Team`

- `id: str`
- `tenant_id: str` (`tenantId` on the wire)
- `org_id: str | None` (`orgId` on the wire) (optional)
- `name: str`
- `slug: str`
- `description: str | None` (optional)
- `created_at: str` (`createdAt` on the wire)
- `updated_at: str` (`updatedAt` on the wire)

## `TeamCollectionPage`

- `data: list[kindgi.client.Team]`
- `has_more: bool` (`hasMore` on the wire)
- `next_cursor: str | None` (`nextCursor` on the wire) (optional)

## `TeamMembership`

- `team_id: str` (`teamId` on the wire)
- `user_id: str` (`userId` on the wire)
- `role: Literal['member', 'admin']`
- `joined_at: str` (`joinedAt` on the wire)

## `TeamMembershipCollectionPage`

- `data: list[kindgi.client.TeamMembership]`
- `has_more: bool` (`hasMore` on the wire)
- `next_cursor: str | None` (`nextCursor` on the wire) (optional)

## `TeamPatch`

- `name: str | None` (optional)
- `slug: str | None` (optional)
- `description: str | None` (optional)
- `org_id: str | None` (`orgId` on the wire) (optional)

## `TeamProjectGrant`

A team's role on a project.

- `team_id: str` (`teamId` on the wire)
- `project_id: str` (`projectId` on the wire)
- `role: Literal['viewer', 'editor', 'admin']`
- `granted_at: AwareDatetime | None` (`grantedAt` on the wire) (optional)
- `team_name: str | None` (`teamName` on the wire) (optional)
- `project_name: str | None` (`projectName` on the wire) (optional)

## `TeamProjectGrantCollectionPage`

- `data: list[kindgi.client.TeamProjectGrant]`
- `has_more: bool` (`hasMore` on the wire)
- `next_cursor: str | None` (`nextCursor` on the wire) (optional)

## `TeamSpec`

- `name: str`
- `slug: str`
- `description: str | None` (optional)
- `org_id: str | None` (`orgId` on the wire) (optional)

## `Tenant`

- `id: uuid.UUID`
- `name: str`
- `slug: str`
- `created_at: AwareDatetime` (`createdAt` on the wire)
- `updated_at: AwareDatetime` (`updatedAt` on the wire)
- `production_allowed: bool | None` (`productionAllowed` on the wire) (optional)
- `production_next: str | None` (`productionNext` on the wire) (optional)
- `state: Optional[Literal['active', 'suspended', 'closing']]` (optional)
- `limits: kindgi.client.TenantLimits | None` (optional)

## `TenantAdminContacts`

- `data: list[kindgi.client.Datum3]`

## `TenantConfigCollectionPage`

- `data: list[kindgi.client.TenantConfigEntry]`
- `has_more: bool` (`hasMore` on the wire)
- `next_cursor: str | None` (`nextCursor` on the wire) (optional)

## `TenantConfigEntry`

- `tenant_id: str` (`tenantId` on the wire)
- `kind: Literal['env', 'config', 'secret']`
- `key: str`
- `value: str`
- `sensitive: bool`
- `revision: int`
- `updated_at: str` (`updatedAt` on the wire)

## `TenantLimits`

The tenant's limits that are set. A limit that isn't set is absent, and isn't enforced.

- `api_requests_per_minute: int | None` (`apiRequestsPerMinute` on the wire) (optional)
- `webhook_receives_per_minute: int | None` (`webhookReceivesPerMinute` on the wire) (optional)
- `runs_at_once: int | None` (`runsAtOnce` on the wire) (optional)
- `runs_pending: int | None` (`runsPending` on the wire) (optional)
- `tool_calls_in_flight: int | None` (`toolCallsInFlight` on the wire) (optional)
- `approvals_pending: int | None` (`approvalsPending` on the wire) (optional)
- `projects_in_production: int | None` (`projectsInProduction` on the wire) (optional)

## `TenantLimitsInUse`

How much of each limit that counts something the tenant uses now, whether the limit is set or not: on `GET …/limits` only, and only from a runtime that counts it. A limit can be lowered below it: nothing is taken back, and the next one waits until the count is under the limit.

- `projects_in_production: int` (`projectsInProduction` on the wire)

## `TenantLimitsResult`

- `tenant_id: uuid.UUID` (`tenantId` on the wire)
- `limits: kindgi.client.TenantLimits`
- `in_use: kindgi.client.TenantLimitsInUse | None` (`inUse` on the wire) (optional)

## `TenantProductionAllowed`

- `tenant_id: uuid.UUID` (`tenantId` on the wire)
- `production_allowed: bool` (`productionAllowed` on the wire)

## `TestAdapterBody`

## `Threshold`

Default 5 judgments, across 3 runs, from 2 judges.

- `judgments: int | None` (optional)
- `runs: int | None` (optional)
- `judges: int | None` (optional)

## `TimeRange`

- `from_: AwareDatetime` (`from` on the wire)
- `to: AwareDatetime`

## `TokenSignInResult`

- `user_id: str` (`userId` on the wire)
- `expires_at: AwareDatetime` (`expiresAt` on the wire)

## `Tool`

For a tool call held for review: which tool and which call. Never the call's arguments.

- `id: str`
- `version: str`
- `call_id: str` (`callId` on the wire)

## `Tool1`

- `id: str`
- `project_id: uuid.UUID | None` (`projectId` on the wire) (optional)
- `description: str`
- `version: str | None` (optional)
- `input: dict[str, Any]`
- `output: dict[str, Any]`
- `needs: list[kindgi.client.ToolNeed] | None` (optional)
- `effects: list[kindgi.client.ToolEffect] | None` (optional)
- `transport: Optional[Literal['auto', 'native', 'mcp']]` (optional)
- `mcp_endpoint: str | None` (`mcpEndpoint` on the wire) (optional)
- `metadata: dict[str, Any] | None` (optional)
- `mutating: bool | None` (optional)
- `sandbox: Optional[Literal['none', 'context-isolated', 'strict']]` (optional)
- `limits: kindgi.client.RuntimeLimits | None` (optional)
- `network: kindgi.client.NetworkPolicy1 | kindgi.client.NetworkPolicy2 | None` (optional)
- `needs_spec: kindgi.client.TypedNeeds | None` (`needsSpec` on the wire) (optional)
- `code_artifact_ref: kindgi.client.CodeArtifactRef1 | kindgi.client.CodeArtifactRef2 | None` (`codeArtifactRef` on the wire) (optional)
- `spec: kindgi.client.ToolSpec | None` (optional)
- `unregistered_at: AwareDatetime | None` (`unregisteredAt` on the wire) (optional)
- `secret_scopes: dict[str, kindgi.client.RecordedSecretScope1 | kindgi.client.RecordedSecretScope2 | kindgi.client.RecordedSecretScope3 | None] | None` (`secretScopes` on the wire) (optional)

## `Tool2`

- `step: int`
- `call_id: str` (`callId` on the wire)
- `tool_id: str` (`toolId` on the wire)
- `tool_version: str` (`toolVersion` on the wire)
- `arguments: Any`
- `source: Literal['live', 'recorded', 'refused']`
- `recomputed: bool | None` (optional)
- `reason: str | None` (optional)

## `Tool3`

- `id: str`
- `version: str | None` (optional)

## `ToolCall`

- `tool_id: str` (`toolId` on the wire)
- `invocation_id: str` (`invocationId` on the wire)

## `ToolCollectionPage`

- `data: list[kindgi.client.Tool1]`
- `next_cursor: str | None` (`nextCursor` on the wire) (optional)
- `has_more: bool` (`hasMore` on the wire)

## `ToolEffect`

- `kind: Literal['reads', 'writes', 'deletes', 'network', 'spawns-run', 'emits-event', 'external-side-effect', 'sensitive-data-egress']`
- `resource: str | None` (optional)
- `notes: str | None` (optional)

## `ToolErrorsSpec`

- `max_retries: int | None` (`maxRetries` on the wire) (optional)
- `retry_on: list[Literal['invalid-arguments', 'unknown-tool', 'tool-error']] | None` (`retryOn` on the wire) (optional)

## `ToolNeed`

- `name: str`
- `optional: bool | None` (optional)

## `ToolRef`

Typed tool reference. `version` is a semver **range** (npm-style: `1.2.3` exact pin, `^1.2.3` compatible-updates, `~1.2.3` patch-updates-only, `>=1.0.0 <2.0.0` explicit range). Dispatch resolves the range to a concrete active version via `semver.maxSatisfying` at run start. No implicit "latest" — every tool ref names both id and range.

- `id: str`
- `version: str`

## `ToolSecretRef`

- `env_name: str` (`envName` on the wire)
- `name: str`

## `ToolSpec`

- `root: kindgi.client.HttpToolSpec`

## `ToolVersionCollectionPage`

- `data: list[kindgi.client.ToolVersionRow]`
- `next_cursor: str | None` (`nextCursor` on the wire) (optional)
- `has_more: bool` (`hasMore` on the wire)

## `ToolVersionRow`

- `id: str`
- `project_id: uuid.UUID | None` (`projectId` on the wire) (optional)
- `description: str`
- `version: str | None` (optional)
- `input: dict[str, Any]`
- `output: dict[str, Any]`
- `needs: list[kindgi.client.ToolNeed] | None` (optional)
- `effects: list[kindgi.client.ToolEffect] | None` (optional)
- `transport: Optional[Literal['auto', 'native', 'mcp']]` (optional)
- `mcp_endpoint: str | None` (`mcpEndpoint` on the wire) (optional)
- `metadata: dict[str, Any] | None` (optional)
- `mutating: bool | None` (optional)
- `sandbox: Optional[Literal['none', 'context-isolated', 'strict']]` (optional)
- `limits: kindgi.client.RuntimeLimits | None` (optional)
- `network: kindgi.client.NetworkPolicy1 | kindgi.client.NetworkPolicy2 | None` (optional)
- `needs_spec: kindgi.client.TypedNeeds | None` (`needsSpec` on the wire) (optional)
- `code_artifact_ref: kindgi.client.CodeArtifactRef1 | kindgi.client.CodeArtifactRef2 | None` (`codeArtifactRef` on the wire) (optional)
- `spec: kindgi.client.ToolSpec | None` (optional)
- `unregistered_at: AwareDatetime | None` (`unregisteredAt` on the wire) (optional)
- `secret_scopes: dict[str, kindgi.client.RecordedSecretScope1 | kindgi.client.RecordedSecretScope2 | kindgi.client.RecordedSecretScope3 | None] | None` (`secretScopes` on the wire) (optional)

## `TopK`

- `yes_weight: float` (`yesWeight` on the wire)
- `total_weight: float` (`totalWeight` on the wire)

## `Trigger`

The improve schedule and fire that started it (`GET /v1/schedules/{triggerId}/fires`); absent for a pass a person started.

- `trigger_id: str` (`triggerId` on the wire)
- `fire_id: str` (`fireId` on the wire)

## `TriggerOwner`

- `kind: Literal['user', 'service']`
- `id: str`
- `display_name: str | None` (`displayName` on the wire) (optional)

## `TrustSigningKeyBody`

- `key_id: str` (`keyId` on the wire)
- `algorithm: Optional[Literal['ed25519']]` (optional)
- `public_key: str` (`publicKey` on the wire)
- `label: str | None` (optional)

## `TrustedSigningKey`

A public key the tenant trusts to sign deployments (`POST /v1/deployments`). A revoked key stays readable, with `revokedAt`, so the deployments it signed can be audited; it verifies no new ones.

- `key_id: str` (`keyId` on the wire)
- `tenant_id: uuid.UUID` (`tenantId` on the wire)
- `algorithm: Literal['ed25519']`
- `public_key: str` (`publicKey` on the wire)
- `label: str | None` (optional)
- `created_at: AwareDatetime` (`createdAt` on the wire)
- `revoked_at: AwareDatetime | None` (`revokedAt` on the wire) (optional)
- `revoked_reason: str | None` (`revokedReason` on the wire) (optional)

## `TrustedSigningKeyPage`

- `data: list[kindgi.client.TrustedSigningKey]`
- `next_cursor: str | None` (`nextCursor` on the wire) (optional)
- `has_more: bool` (`hasMore` on the wire)

## `TurnBudget`

- `max_steps: int | None` (`maxSteps` on the wire) (optional)
- `max_cost_usd: float | None` (`maxCostUsd` on the wire) (optional)
- `max_wall_ms: int | None` (`maxWallMs` on the wire) (optional)

## `Type`

- `root: str`

## `TypedNeeds`

Typed discriminated needs (env / secrets / config / capabilities / bindings). Optional additive field.

- `env: dict[str, dict[str, Any]] | None` (optional)
- `secrets: dict[str, dict[str, Any]] | None` (optional)
- `config: dict[str, dict[str, Any]] | None` (optional)
- `capabilities: list[kindgi.client.Capability5] | None` (optional)
- `bindings: list[kindgi.client.Binding] | None` (optional)
