> ## Documentation Index
> Fetch the complete documentation index at: https://docs.technicallyfit.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Drop-in components

> Embed today's session, a teammate's verified record, and live workout cues inside your own web or mobile app with hosted frames.

Drop-in components let you show a teammate their training session for today, their verified measurement record, or real-time workout cues without building those screens from scratch. Each element loads a hosted frame from TechnicallyFit and receives the teammate's token by `postMessage`, never in the URL.

## Available elements

| Element | What it shows | Token scope required |
| - | - | - |
| `<tf-today-session>` | Today's scheduled session and movements (read-only) | `programs:read` (teammate token) |
| `<tf-record>` | Verified measurements and assessment results with vouching levels (read-only) | `record:read` (Sign in with TechnicallyFit token) |
| `<tf-live-cues>` | Live workout cues and session adaptations (read-only, supports `setCues(cues)` for live WebSocket streams) | `programs:read` (teammate token) |

Sensitive measures never appear in embedded reads.

## 1. Load the developer embed script

Include `/embeds/developer-v1.js` on a page served from an origin registered in your app's redirect URIs:

```html theme={null}
<script async src="https://technicallyfit.com/embeds/developer-v1.js"></script>
```

The frame only loads on origins registered for your `client_id`. Unregistered origins are refused with `403` and a strict `Content-Security-Policy: frame-ancestors` header.

## 2. Place an element and hand it a token

```html theme={null}
<tf-today-session id="session" client-id="tfc_your_client_id" theme="light"></tf-today-session>
<tf-record id="record" client-id="tfc_your_client_id" theme="dark" accent="#57ffbd"></tf-record>
<tf-live-cues id="cues" client-id="tfc_your_client_id" theme="light"></tf-live-cues>

<script>
  const token = getTeammateTokenFromMemory();
  document.getElementById('session').setToken(token);
  document.getElementById('record').setToken(token);
  document.getElementById('cues').setToken(token);
</script>
```

Never pass an organization API key (`tf_live_...` or `tf_test_...`) to a drop-in component. Organization keys belong on your server and are refused immediately inside the frame.

## Attributes

* `client-id` (required): your member app or self-registered app `client_id`.
* `theme` (optional): `light` (default) or `dark`.
* `accent` (optional): a 6-digit hex color (`#rrggbb`). The frame checks WCAG AA contrast (4.5:1) against the active theme surface and falls back to the default accent if contrast is too low.

## Mobile web views

Mobile apps can show the same elements inside a web view whose origin matches a registered redirect URI.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.