Quickstart
Make your first Vitable API call and embed the Employee Dashboard in under 5 minutes.
1. Get Your API Key
Section titled “1. Get Your API Key”Contact us to receive your API key and base URL.
2. Make Your First API Call
Section titled “2. Make Your First API Call”Verify your credentials by listing employers on your account:
curl -X GET https://api.vitablehealth.com/v1/employers \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Content-Type: application/json"import requests
response = requests.get( "https://api.vitablehealth.com/v1/employers", headers={"Authorization": "Bearer YOUR_API_KEY"},)
print(response.json())const response = await fetch("https://api.vitablehealth.com/v1/employers", { headers: { Authorization: "Bearer YOUR_API_KEY" },})
const data = await response.json()console.log(data)You should get back a JSON response with your employers list. If you see 200 OK, your credentials are working.
3. Embed the Employee Dashboard
Section titled “3. Embed the Employee Dashboard”Install the SDK and drop the widget into your React app:
npm install @vitable/connectimport { VitableConnectProvider, EmployeeViewWidget } from "@vitable/connect/react"import type { AccessTokenResponse } from "@vitable/connect/react"
async function fetchToken(): Promise<AccessTokenResponse> { const res = await fetch("https://my.backend.com/api/token", { method: "POST", headers: { "Content-Type": "application/json" }, body: JSON.stringify({ employee_id: "empl_abc123" }), }) if (!res.ok) throw new Error(`Token fetch failed: ${res.status}`) const data = await res.json() return { token: data.token, expiresIn: data.expiresIn }}
export default function App() { return ( <VitableConnectProvider baseUrl="https://widget.vitablehealth.com" fetchToken={fetchToken} > <EmployeeViewWidget height="800px" /> </VitableConnectProvider> )}What’s Next
Section titled “What’s Next”- Authentication — API keys, bound tokens, and error responses
- Employee Dashboard Widget — Full integration guide with backend setup, props, and token lifecycle
- API Reference — All available endpoints