Complete API reference for React hooks and context providers
Example screenshot – your actual API key will be different.
apiKey
(string, optional): Your HumanBehavior API keyclient
(HumanBehaviorTracker, optional): Existing tracker instancechildren
(ReactNode, required): React components to wrapaddEvent(event)
event
(object, required): Raw event objectvoid
Example:
addUserInfo(userProperties)
userProperties
(object, required): User properties to trackPromise<void>
Example:
start()
Promise<void>
Example:
stop()
Promise<void>
Example:
setRedactedFields(fields)
fields
(string[], required): Array of CSS selectors for fields to redactvoid
Example:
isRedactionActive()
boolean
Example:
getRedactedFields()
string[]
Example:
redact(options)
options
(RedactionOptions, optional): Redaction configurationPromise<void>
Example:
auth(authFields)
authFields
(string[], required): Array of field names to use for authenticationPromise<void>
Example:
getUserInfo()
getSessionId()
string
Example:
getCurrentUrl()
string
Example: