Skip to Content
Runlane
ReferenceContract values

Realtime contract values

Permission and transport error values shared by server and browser clients.

Import these enums from @runlane/contracts/realtime. The realtime API reference defines their behavior. Wire timestamps decode to Date; cursors remain branded opaque strings.

MemberValue
RunReadPermission.Statusstatus
RunReadPermission.Metameta
RunReadPermission.Outputoutput
RunReadPermission.Streamsstreams
ErrorCode.AccessDeniedaccess_denied
ErrorCode.ConfigurationInvalidconfiguration_invalid
ErrorCode.ValidationFailedvalidation_failed
ErrorCode.RunCursorInvalidrun_cursor_invalid
ErrorCode.RunNotFoundrun_not_found
ErrorCode.InternalErrorinternal_error
ErrorCode.EventTooLargeevent_too_large
ErrorCode.WireInvalidwire_invalid
ErrorCode.Disconnecteddisconnected
RealtimeConnectionState.Connectingconnecting
RealtimeConnectionState.Openopen
RealtimeConnectionState.Reconnectingreconnecting
RealtimeConnectionState.Closedclosed
RealtimeConnectionCloseReason.Completedcompleted
RealtimeConnectionCloseReason.Abortedaborted
RealtimeConnectionCloseReason.Failedfailed

Browser failures allow only name, code, message, and retryable. Snapshots and status deltas exclude stack and failure meta, including when Output is granted.

RunOutput<TTask> uses the task output schema's input type, matching the stored handler return sent to browsers. Output transforms and defaults are not applied to that value. RunStreamPart<TTask, TName> uses the stream schema's parsed output type. Manual RunTypes declarations describe these sent values.