Using our Widget API with the Segment integration

Updated 2 months ago ​by Alexa Nguyen

If you're using the Segment integration, you can still use the Drift Widget API, but the Drift object won't be immediately available in the window. You can use Segment's analytics.ready function below to determine when the Drift Api has been installed and is ready for use. 

<script>
analytics.ready(function(){
    //interact with the api here
   })
})
</script>

Was this article helpful?


Can’t find what you’re looking for?

Talk To Us