Skip to main content

Documentation Index

Fetch the complete documentation index at: https://orbit-docs.devotel.io/llms.txt

Use this file to discover all available pages before exploring further.

Embedded Web SDK API

The endpoints that the @devotel/orbit-web-sdk (browser-side) hits at runtime. Mounted at /sdk/* (no /api/v1 prefix) so customer-side embeds don’t have to think about API versions. Base path: https://api.orbit.devotel.io/sdk (no /api prefix) Authentication: Tenant public key (pk_*). CORS is wide open — these endpoints are designed to be hit directly from the customer’s website JavaScript. Why a separate base path: server-to-server keys (dv_live_sk_*) are secret. Browser-embedded keys (pk_*) are public. The split base prevents accidentally exposing a server key in a browser bundle.

Identify

Resolve an anonymous browser visitor to a known contact (by email, phone, or external ID) so subsequent events attach to the right contact record.
fetch('https://api.orbit.devotel.io/sdk/identify', {
  method: 'POST',
  headers: { 'Content-Type': 'application/json', 'X-API-Key': 'pk_your_key' },
  body: JSON.stringify({ external_id: 'user_42', email: 'jane@example.com' })
});
MethodPathPurpose
POST/sdk/identifyResolve / merge anonymous → known contact

Track

Capture a custom event (page view, button click, video watched, item added to cart). Events flow into the same sdk_events store that powers segmentation, scoring, and contact timelines.
fetch('https://api.orbit.devotel.io/sdk/track', {
  method: 'POST',
  headers: { 'Content-Type': 'application/json', 'X-API-Key': 'pk_your_key' },
  body: JSON.stringify({
    event: 'item_added_to_cart',
    properties: { sku: 'shoe-42', value: 89.99 }
  })
});
MethodPathPurpose
POST/sdk/trackCapture a custom event

Personalize

Fetch the right personalization slot variant for the current visitor at runtime.
const res = await fetch(
  'https://api.orbit.devotel.io/sdk/personalize?slot=hero_banner',
  { headers: { 'X-API-Key': 'pk_your_key' } }
);
const { data: { content } } = await res.json();
MethodPathPurpose
GET/sdk/personalizeResolve a personalization slot for the calling visitor

See also