The python client wraps the rust client and uses nearly the exact same function definitions. It currently does not support the administrator features that the rust client does. Handling async runners across the rust FFI is a bit tricky so for now, this client does not support async python.

The returns an object which implements python iterator convention to allow for iterating over the stream in a for-loop.

To see the full docs, visit our pdoc page.



To connect to fluvio do:

from fluvio import Fluvio
fluvio = Fluvio.connect()


To get a producer do:

producer = fluvio.topic_producer("my-topic")


To send a record for the producer do:

partition = 0
producer.send_record_string("my-record", partition)

send is also available. You will need to convert your key/value into a byte array first to use it.



To get a consumer, do:

partition = 0
consumer = fluvio.partition_consumer("my-topic", partition)


To get a stream from the consumer do:

stream =
for i in stream:
    key = i.key_string()
    value = i.value_string()
    print("%s - %s" % (key, value))