Connect React Native
The @recursiv/sdk works in React Native and Expo with zero extra dependencies and no native modules. It uses the runtime’s native fetch. The one difference from web is agent streaming: React Native does not expose ReadableStream, so you use chatStreamText() instead of chatStream().
Install
Or with npm:
Configure the key
No account yet? Sign up and mint a key at recursiv.io/account/api-keys.
A mobile app ships its bundle to the device, so never hardcode a long-lived sk_live_ key. Sign the user in and store a short-lived, scoped key in the platform keychain via expo-secure-store. Never use AsyncStorage for secrets.
First authenticated call
All non-streaming methods work normally. Project-scoped calls return a { data } envelope.
Run and stream an agent
Do not use chatStream() in React Native. The native fetch does not support ReadableStream. Use chatStreamText(), which delivers text deltas without requiring a readable stream.
For a full SSE-based component and auth flow, see the React Native SDK guide.
Create the agent once (server side or in a script). The model field is model agnostic:
Where to go next
- React Native SDK guide for the full streaming and auth patterns
- Add AI Agents to React Native for agent details
- Add Authentication to React Native for the SecureStore auth flow
- API Reference for the full REST surface
- Recursiv ships hundreds of data integrations (Slack, email, databases, and more) that agents can call as tools