Skip to main content

Python implementation of the RapidPro flow engine

Project description

RapidPro Flows

Python implementation of the RapidPro flow engine.


org = Org("RW", "eng", pytz.timezone("Africa/Kigali"), DateStyle.DAY_FIRST, False)
fields = [...]
contact = Contact(...)
flow = Flow.from_json("...")

runner = Runner()

run = runner.start(org, fields, contact, flow)

steps = run.get_completed_steps()
fields_to_create = run.get_created_fields()

runner.resume(run, Input.of("Yes"))

json = run.to_json() # run state can be serialized as JSON

restored = RunState.from_json(json, flow) # and then de-serialized when needed

runner.resume(run, Input.of(123))


Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for rapidpro-flows, version 1.2.9
Filename, size File type Python version Upload date Hashes
Filename, size rapidpro_flows-1.2.9-py2.py3-none-any.whl (32.7 kB) File type Wheel Python version py2.py3 Upload date Hashes View
Filename, size rapidpro-flows-1.2.9.tar.gz (28.9 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring DigiCert DigiCert EV certificate Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page