Getting Started
Quickstart
Get from zero to a working fraud detection integration in under 10 minutes.
This guide walks you through adding VerifyStack to your application. By the end you'll have real-time fraud scoring on your login or checkout flow.
1. Add the Browser SDK
Script tag (recommended)html
<script src="https://verifystack.io/sdk/browser.js"></script>2. Initialize
Create clientjavascript
// With script tag (IIFE) — window.VerifyStack is available globally
const vs = new VerifyStack({
apiKey: 'pk_live_xxxxxxxxx',
endpoint: 'https://verifystack.io'
});
// Or as ES module:
import { VerifyStack } from 'https://verifystack.io/sdk/browser.mjs';3. Make a Decision Request
decide()javascript
const decision = await vs.decide({
action: 'login',
userId: 'user_123'
});Use publishable keys (pk_) in browser code. Keep secret keys (sk_) server-side only.
4. Optional Feedback Loop
POST /api/v1/feedbackbash
curl -X POST https://verifystack.io/api/v1/feedback \
-H "X-API-Key: sk_live_xxxxxxxxx" \
-H "Content-Type: application/json" \
-d '{"decisionId":"dec_abc123","actualOutcome":"fraud"}'