SafetyEvent
ug-js-sdk / SafetyEvent
Interface: SafetyEvent
Defined in: types/index.ts:822
Emitted when a safety policy is triggered.
Received via onSafetyEvent hook.
This indicates the content violated a safety policy.
Extends
InteractResponse
Properties
uid
uid:
string
Defined in: types/index.ts:474
Unique identifier matching the request
Inherited from
InteractResponse.uid
client_start_time?
optionalclient_start_time:string
Defined in: types/index.ts:476
ISO timestamp when client sent the original request
Inherited from
InteractResponse.client_start_time
server_start_time?
optionalserver_start_time:string
Defined in: types/index.ts:478
ISO timestamp when server started processing
Inherited from
InteractResponse.server_start_time
server_end_time?
optionalserver_end_time:string
Defined in: types/index.ts:480
ISO timestamp when server finished processing
Inherited from
InteractResponse.server_end_time
kind
kind:
"interact"
Defined in: types/index.ts:736
The kind of response matching the request
Inherited from
InteractResponse.kind
event
event:
"safety_policy"
Defined in: types/index.ts:823
The type of event
Overrides
InteractResponse.event