BrandApp Playground

Terms

Jurisdiction- and locale-aware BrandApp agreements. The consent panel below forwards legal evidence fields to sdk.terms.consent with the signed-in user's access token.

US
jurisdiction
geo
source
US
country
*
locale
No active terms defined for this BrandApp.
lib/terms.ts
import { createReoptSDK } from "@reopt-ai/brandapp-sdk";

const sdk = createReoptSDK({
  clientId: process.env.BRANDAPP_CLIENT_ID!,
  clientSecret: process.env.BRANDAPP_CLIENT_SECRET!,
  brandappId: process.env.BRANDAPP_ID!,
});

// Public: works with the app's Basic Auth credentials. Pass country/locale
// when you already know the user's market; otherwise the server infers them
// from geo and Accept-Language headers.
const response = await sdk.terms.listWithMeta({
  country: "KR",
  locale: "ko-KR",
});
const terms = response.terms;

for (const t of terms) {
  console.log(t.title, t.jurisdiction, t.currentVersion?.locale);
  console.log(t.currentVersion?.content);
}

// Legacy/simple call still returns only the terms array:
// const terms = await sdk.terms.list({ jurisdiction: "EU", accessToken });