Developers
Developer documentation
One SDK per platform, one slot in your app, and content delivered over the air. You place a named slot; ContentFlow renders the right native component into it — no webviews, no app-store release to change what's shown.
Install
Add the SDK for your platform. There is one package per platform, all on the same v2.4 line.
# React Native
npm i @contentflow/react-native
# iOS — Swift Package Manager
.package(url: "https://github.com/contentflow/contentflow-ios", from: "2.4.0")
# or CocoaPods
pod 'ContentFlow', '~> 2.4'
# Android — Gradle
implementation "click.contentflow:sdk:2.4.0"
# Web
npm i @contentflow/web
Initialize
Initialize once at app startup with your tenant-scoped API key. Keys look like pk_live_….
import { ContentFlow } from '@contentflow/react-native';
ContentFlow.init({
apiKey: 'pk_live_…',
locale: user.locale,
});
Drop a slot
Place a ContentFlowSlot wherever you want managed content to appear, and give it a placement string. That placement is the address the canvas delivers to.
import { ContentFlow, ContentFlowSlot } from '@contentflow/react-native';
function HomeScreen() {
return (
<ContentFlowSlot placement="home.discovery" />
);
}
Other platforms
// iOS (SwiftUI)
ContentFlowSlot(placement: "home.discovery")
// Android (Compose)
ContentFlowSlot(placement = "home.discovery")
// Web
import { ContentFlow, ContentFlowSlot } from '@contentflow/web';
ContentFlow.init({ apiKey: 'pk_live_…', locale: navigator.language });
// mount a slot anywhere in your DOM
const slot = ContentFlowSlot({ placement: 'home.discovery' });
document.getElementById('home').append(slot);
The slot model
A placement is a dot-namespaced string like home.discovery or account.offers. It is a stable address in your app that you place once and then manage remotely.
- A placement can receive a block, a campaign, a journey, or an experiment — whatever the canvas targets to it.
- Rendering is native: the SDK draws real platform components into the slot, not a webview.
- What a placement shows can change over the air without a code change or a new build.
Configuration
| Option | Type | Description |
|---|---|---|
apiKey | string | Your pk_live_… publishable key. Tenant-scoped — it identifies the workspace content is delivered from. |
locale | string | Active locale for rendered content, e.g. en or ar. |
environment | enum sandbox | live | Which environment to resolve placements against. Defaults to live. |
user | object | Optional traits used for targeting, such as segment or locale. No end-user PII is required to render content. |
Publishing and environments
Every workspace has a sandbox and a live environment. Preview and test against sandbox, then publish to live when you are ready.
- Changes published on the canvas go live over the air in seconds.
- One-click rollback returns a placement to its previous state instantly.
- No app-store release is needed to change content in a placement you have already shipped.
Security and data
- API keys are tenant-scoped; a key only resolves content for its own workspace.
- All traffic is encrypted with TLS in transit.
- No end-user PII needs to leave the app to render content — targeting works on traits you choose to pass, such as segment or locale.
API and webhooks
A REST API and webhook events — such as campaign.published and block.updated — are available on Pro and Enterprise for automation and back-office integration. The example below is illustrative:
# Example only — publish a campaign
curl -X POST https://api.contentflow.click/v1/campaigns/cmp_123/publish \
-H "Authorization: Bearer pk_live_…" \
-H "Content-Type: application/json"
The full API and webhook reference is shared with design partners during onboarding. Get in touch to request access.
Quick AI setup
The fastest way to get a first slot rendering is to let the CLI wire it in for you. It detects your stack, adds the SDK, and drops in a starter placement.
npx @contentflow/cli init --ai
Support
Questions, edge cases, or something not behaving as documented? Email hello@contentflow.click or book a demo and we will walk through your integration.