RealComposer
Upstream API

OpenAI Integration Recipes

Edge pipelines that call OpenAI securely from no-code and frontend clients - with vault-injected credentials and slim JSON responses.

OpenAI safe & unsafe practices
Security & Secret Vault

How to Hide OpenAI API Key in Client-Side React Apps

To use OpenAI in a client-side React app without leaking your secret key, never include OPENAI_API_KEY or REACT_APP_OPENAI_API_KEY in frontend .env files. Instead, route your fetch calls through a RealComposer edge endpoint that injects your secret key server-side on Cloudflare Workers and enforces CORS origin whitelisting.

Sub-10ms edgeView Recipe
Multi-API Aggregation

Combine anthropic claude with openai fallback router

Primary Anthropic Messages step plus OpenAI fallback step in one pipeline. For "combine anthropic claude with openai fallback router", store ANTHROPIC_API_KEY, OPENAI_API_KEY in Secret Vault, call https://api.anthropic.com/v1/messages from a Worker, and let Frontend / Web hit only https://realcomposer.com/v1/workspace/combine-anthropic-with-openai-fallback with an rc_live_ client token. POST upstream calls are not stored in caches.default; clients must send JSON bodies and headers forward unchanged.

Sub-10ms edgeView Recipe
Security & Secret Vault

Call OpenAI API from WeWeb Securely

An OpenAI key pasted into a WeWeb REST action is published with the app and readable in DevTools. Send WeWeb requests to a RealComposer pipeline instead. The edge injects OPENAI_API_KEY from the vault, checks the calling origin, and returns only the assistant message text.

Sub-10ms edgeView Recipe
Security & Secret Vault

Hide OpenAI API Key in a Flutter App

OpenAI keys bundled in Flutter apps through env files, assets, or dart-define are extractable from release builds. Route chat requests through a RealComposer pipeline that injects OPENAI_API_KEY at the edge, applies per-client rate limits, and returns only the reply text to the app.

Sub-10ms edgeView Recipe