Workspace - TypeScript SDK

Workspace type definition

The TypeScript SDK and docs are currently in beta. Report issues on GitHub.

Example Usage

1import { Workspace } from "@openrouter/sdk/models";
2
3let value: Workspace = {
4 createdAt: "2025-08-24T10:30:00Z",
5 createdBy: "user_abc123",
6 defaultImageModel: "openai/dall-e-3",
7 defaultProviderSort: "price",
8 defaultTextModel: "openai/gpt-4o",
9 description: "Production environment workspace",
10 id: "550e8400-e29b-41d4-a716-446655440000",
11 isDataDiscountLoggingEnabled: true,
12 isObservabilityBroadcastEnabled: false,
13 isObservabilityIoLoggingEnabled: false,
14 name: "Production",
15 slug: "production",
16 updatedAt: "2025-08-24T15:45:00Z",
17};

Fields

FieldTypeRequiredDescriptionExample
createdAtstring✔️ISO 8601 timestamp of when the workspace was created2025-08-24T10:30:00Z
createdBystring✔️User ID of the workspace creatoruser_abc123
defaultImageModelstring✔️Default image model for this workspaceopenai/dall-e-3
defaultProviderSortstring✔️Default provider sort preference (price, throughput, latency, exacto)price
defaultTextModelstring✔️Default text model for this workspaceopenai/gpt-4o
descriptionstring✔️Description of the workspaceProduction environment workspace
idstring✔️Unique identifier for the workspace550e8400-e29b-41d4-a716-446655440000
isDataDiscountLoggingEnabledboolean✔️Whether data discount logging is enabled for this workspacetrue
isObservabilityBroadcastEnabledboolean✔️Whether broadcast is enabled for this workspacefalse
isObservabilityIoLoggingEnabledboolean✔️Whether private logging is enabled for this workspacefalse
namestring✔️Name of the workspaceProduction
slugstring✔️URL-friendly slug for the workspaceproduction
updatedAtstring✔️ISO 8601 timestamp of when the workspace was last updated2025-08-24T15:45:00Z