Why Meta Quest?
Design
Develop
API reference
Distribute and grow
Blog
Support
API reference
API reference
Select your platform
No SDKs available
No versions available
Overview
AudioClipAudioSource
ImageViewer
Lib
Meta
Conduit
Net
Voice
Voice
AboutWindow
Audio
Hub
INLPRequestOptions
INLPRequestResponseDecoder
INLPRequestResults
ITranscriptionRequestOptions
ITranscriptionRequestResults
IVoiceRequestOptions
IVoiceRequestResults
Logging
NLPRequest
NLPRequestEvents
NLPRequestResponseEvent
NLPRequestResponseValidatorEvent
NLayer
Net
Encoding
PubSub
WebSockets
WebSockets
IWebSocket
IWebSocketProvider
IWitWebSocketClient
IWitWebSocketClientProvider
IWitWebSocketRequest
MockWebSocket
NativeWebSocketWrapper
Requests
WitWebSocketAdapter
WitWebSocketClient
WitWebSocketSettings
Samples
TelemetryUtilities
TranscriptionRequest
TranscriptionRequestEvent
TranscriptionRequestEvents
UnityOpus
UserTranscriptionRequestEvent
VSDKHub
VoiceRequest
VoiceRequestEvents
Windows
WitAi
Oculus
Code samples
Downloads
Release notes
Supported platforms
Meta
WitWebSocketAdapter Class
Extends
MonoBehaviour,
IPubSubAdapter
,
ILogSource
,
IWitInspectorTools
A publish/subscribe MonoBehaviour adapter for WitWebSocketClients
Properties
IVLogger
Logger
[Get]
IWitWebSocketClient
WebSocketClient
[Get]
The current web socket client
PubSubSettings
Settings
[Get]
The various pub sub settings available
PubSubSubscriptionState
SubscriptionState
[Get]
The current subscription state of the adapter
UnityEvent
OnSubscribed
[Get]
Callback when successfully subscribed to the current topic
UnityEvent
OnUnsubscribed
[Get]
Callback when successfully unsubscribed from the current topic
Fields
IWitWebSocketClientProvider
WebSocketProvider
[Get]
The script used to provide the
WitWebSocketClient
Events
Action<
PubSubSubscriptionState
>
OnTopicSubscriptionStateChange
Event callback for subscription state change
WitWebSocketResponseProcessor
OnProcessForwardedResponse
An event callback for processing a response for a request originating on a different client with a topic this client adapter has subscribed to.
Action<
IWitWebSocketRequest
>
OnRequestGenerated
Callback when a request is generated for the subscribed topic
Protected Functions
virtual void
OnEnable
( )
virtual bool
RaiseProcessForwardedResponse
( string topicId,
string requestId,
string clientUserId,
WitChunk
responseChunk )
virtual void
HandleRequestGenerated
( string topicId,
IWitWebSocketRequest
request )
virtual void
OnDisable
( )
virtual void
OnDestroy
( )
virtual void
ApplySubscriptionPerTopic
( string topicId,
PubSubSubscriptionState
subscriptionState )
Handle currently set topic id subscription changes only
PubSubSubscriptionState
DetermineSubscriptionState
( )
Determines the current subscription state
Member Functions
void
SetClientProvider
(
IWitWebSocketClientProvider
clientProvider )
Safely sets the new web socket client provider if possible
void
SendRequest
(
IWitWebSocketRequest
request )
Send a request with a specified topic
void
SetSettings
(
PubSubSettings
settings )
Set the pubsub settings, unsubscribe to the previous & subscribe to a new
Build with Meta
Social Technologies
Meta Horizon
AI
Worlds
About us
Careers
Research
Products
Virtual reality / Meta Horizon
Developer Blog
Download SDKs
Meta for Work
Programs
Start
Meta Horizon Creator Program
Discover
Why Meta Quest?
What is mixed reality?
Platforms and tools
2D apps for Meta Horizon OS
Devices
Meta Avatars
Success stories
Use cases
Support and legal
Developer policies
Legal
Privacy
Forums
Support
Build with Meta
Social Technologies
Meta Horizon
AI
Worlds
About us
Careers
Research
Products
Virtual reality / Meta Horizon
Developer Blog
Download SDKs
Meta for Work
Programs
Start
Meta Horizon Creator Program
Discover
Why Meta Quest?
What is mixed reality?
Platforms and tools
2D apps for Meta Horizon OS
Devices
Meta Avatars
Success stories
Use cases
Support and legal
Developer policies
Legal
Privacy
Forums
Support
Build with Meta
Social Technologies
Meta Horizon
AI
Worlds
About us
Careers
Research
Products
Virtual reality / Meta Horizon
Developer Blog
Download SDKs
Meta for Work
Programs
Start
Meta Horizon Creator Program
Discover
Why Meta Quest?
What is mixed reality?
Platforms and tools
2D apps for Meta Horizon OS
Devices
Meta Avatars
Success stories
Use cases
Support and legal
Developer policies
Legal
Privacy
Forums
Support
English (US)
© 2026 Meta