motia Package Exports
Reference for what the motia npm package exports in v1.x.
This page documents the public exports of the motia npm package.
Install
Package entrypoints
motia currently publishes these entrypoints:
| Entrypoint | Purpose |
|---|---|
motia | Main runtime/framework API used by Steps |
motia/build | Build-time utilities |
Main exports (motia)
These are exported from the root package:
Runtime primitives
stepmultiTriggerStephttp,queue,cron,state,stream,api
api is a legacy alias kept for backward compatibility. Prefer http for all new code.
Runtime services
enqueueloggerstateManagerStream
Initialization and internals
Internal use only. These exports are implementation details of the iii engine integration and may change without notice. Do not rely on them in application code.
initIII,getInstancesetupStepEndpointgenerateStepIdMotia
Types and helpers
- All exports from
./types - All exports from
./types-stream - All exports from
./guards StreamAuthInput,StreamAuthResult,StreamContext(fromiii-sdk/stream)Logger,ChannelReader,ChannelWriter(fromiii-sdk)
motia/build exports
The package defines a motia/build subpath export intended for build workflows and tooling integration. Common use:
This entrypoint is primarily consumed by CLI tooling (motia build) and bundler integrations. See the CLI reference for usage in project build scripts.
Important note about React stream hooks
React stream hooks are provided by a separate package:
Use:
MotiaStreamProvideruseMotiaStreamuseStreamGroupuseStreamItem
See React Stream Client.