Skip to main content
This page includes practical examples of how to integrate and use the Adopt AI SDK—whether you’re working in plain HTML, using a modern framework like React, or handling dynamic scenarios like login/logout flows or token refreshes.

Example 1: Basic HTML Setup (Script/CDN)

This is the simplest way to get started with Adopt—no build tools required.

HTML →

Example 2: React Integration (NPM Package)

A typical use case for SPAs with login and logout flows.

Example 3: Updating User Info and Headers Dynamically

Script →

NPM →

Next Step

You’ve now seen the SDK in action. Let’s wrap up with some frequently asked questions and troubleshooting tips: FAQ → Answers to the most common setup and usage questions.