Ponder Logo

Ponder

API Reference

PonderProvider and usePonder() hook reference.

See NPM package here: @ponderai/react

<PonderProvider />

proptypedefaultdescription
assistantIdstringID of the assistant configured on the server
hoststringBase HTTP(S) URL running the Ponder WebSocket (/ws/talk)
includePathsstring[][]Render the widget only on these routes (empty ⇒ everywhere)
childrenReactNodeRest of your application

usePonder()

const {
  updateActions,
  updateInstructions,
  toggleActive,
  isListening,
} = usePonder();
memberpurpose
updateActions(list)Replace the current set of callable functions
updateInstructions()Update the instructions for the assistant
toggleActive()Programmatically click the mic (handy for keyboard shortcuts)
isListeningbooleantrue while the mic is actively capturing user speech