Skip to content
Sendora Cloud
Create account
Grow

Experiments

Targeted feature flags via the same audience engine used for messaging. Server-evaluated; SDK fetches per-user resolved flags on init.

Features

  • **Flag types** — `boolean / string / number / json` per the Zod schema. **Honest:** no first-class `multivariate` enum value — express multi-arm via `string` or `json`.
  • **Rule engine** — each rule is `{ audienceId?, percentage?, value? }`. First matching rule wins; default value otherwise. Max 20 rules per flag.
  • **Audience-targeted rollouts** — pick audiences from Customers; real-time membership (audiences evaluate at query time).
  • **Percentage rollouts** — hash-bucket per entityId so sticky-by-user roll-out is deterministic.
  • **Per-environment toggles** — `environments: { production: true, staging: false }` per flag.
  • **Kill-switch toggle** — `POST /feature-flags/:id/toggle` flips `isActive`; logAudit captures actor + timestamp.
  • **Evaluation log** — every `evaluate` + `evaluate-all` call writes to `flag_evaluations` (fire-and-forget) with the rule matched + the final value.
  • **SDK helpers** — Web `sendora.flags.*`; RN 0.18.7+ ships `flags.evaluate(key)` + `flags.evaluateAll()`.
  • **Honest non-features:** no statistical experiment readout (no funnel / retention auto-cohorting by variant); no winner auto-promote to In-App / Push A/B; no `experiment.assigned` event on the platform `events` bus (flag_evaluations is a separate table); no SDK streaming connection (each evaluate is a real HTTPS call); no scheduled flag changes.

Common use cases

  • Audience-gated feature rollouts (enterprise + active 30d gets the new dashboard) with kill-switch + audit log.
  • Percentage canary releases with sticky-by-user assignment.
  • Operational kill-switches where the audit trail (who flipped what, when) is the regulatory deliverable.
  • Build your own experiment readout by querying `flag_evaluations` + Analytics events in the same tenant.

Feature flags

Evaluate a single flag

FREE

Returns boolean / string / number per the flag's rules. Cached client-side; falls back to default if SDK offline.

const isEnabled = await sendora.flags.evaluate("new-checkout", false);
if (isEnabled) showNewCheckout();

Bootstrap all flags

FREE

One round-trip on app boot. Returns the full evaluated map for the current user. Recommended over per-flag calls in hot paths.

const flags = await sendora.flags.evaluateAll();
// flags = { "new-checkout": true, "max-items": 50, ... }

Create a flag

FREE

Boolean, string, or number type. Rules: percentage rollout, audience targeting, per-user overrides. Authored in the dashboard or via API.

curl -X POST https://api.sendoracloud.com/api/v1/orgs/<ORG_UUID>/feature-flags \
  -H "x-api-key: pk_prod_…" \
  -d '{
    "key": "new-checkout",
    "type": "boolean",
    "default": false,
    "rules": [{ "audience": "<audience_uuid>", "value": true }]
  }'

Related