Bodygram
Playground

Platform Playground

Try the Bodygram Scanner Platform integration live — token generation, scanning, estimation, and full body measurements in one place.

See the Scanner Platform in action

The Bodygram Scanner Platform returns raw body measurements from two photos and user stats, or from stats alone. Unlike Body2Fit, there are no garments or size labels — you get the underlying measurement data directly and decide what to do with it.

This page lets you run the complete integration flow against your own credentials. Use it to understand each step before wiring it into your own application.

For the full integration guide, see Platform Integration.


Integration pattern

Every Platform integration follows four steps. The playground below runs all four live:

  1. Configure — initialize the SDK with your organization ID and locale. Generate a scan token on your server using your API key (this playground does it in the browser for convenience — never do this in production).
  2. User stats — collect the user's gender, age, height, and weight.
  3. Scan & estimate — optionally capture front and side photos with Scanflow, then call the estimation API to get body measurements.
  4. Measurements — view the full set of body dimensions in centimeters. Photo scans also return body composition and posture data.

Interactive Demo

1Configure

Enter your Bodygram Scanner Platform credentials. Sign up free at platform.bodygram.com to get your org ID and API key. This demo uses the API key in the browser for convenience — in production, always generate tokens server-side.

Your organization ID — safe to use in frontend code

Demo only — in production this must stay server-side and never reach the browser

2User Stats

Collect the shopper's stats first. Gender is used both by the estimation call and to pick the correct scanner silhouette in the next step.

years
cm
kg
3Scan & Estimate

Camera scanning gives more accurate measurements and also returns body composition and posture data. Stats-only works without a camera.

4Measurements
CODE
// ---- Backend Code Start ----
// Run this on your server.
// Never expose your API key to the browser.
//
// './sdk.es.js' is the path where you have downloaded
// the Bodygram Headless SDK (ES build). See the full
// server setup pattern in the integration guide:
// /headless/platform-integration#real-world-example-dashboard-app
import BodygramSDK from './sdk.es.js';

const serverSdk = new BodygramSDK({
  clientKey: 'org_...',
});

async function createScanToken() {
  const { token } = await serverSdk.getBodygramScannerPlatformScanToken({
    apiKey: process.env.BODYGRAM_API_KEY,
    scope: [
      'api.platform.bodygram.com/scans:create',
      'api.platform.bodygram.com/scans:read',
    ],
  });
  return token;
}
// ---- Backend Code End ----

// ---- Frontend Code Start ----
const sdk = new BodygramSDK({
  clientKey: 'org_...',
  locale: 'en',
});
// ---- Frontend Code End ----

API reference

Full signatures, parameters, and response shapes for every method used in the playground above live in the Headless SDK API reference.

Methods

Types

  • PlatformMeasurement — shape of each entry in entry.measurements, plus the full list of measurement names.
  • Avatar — shape of the 3D avatar returned by photo and stats estimation.
  • Posturefront and right pose data, including angle and line landmark definitions and the dashboard naming map.

On this page