Bonsai API

Last updated: August 31, 2026

Version 0.1.0

The Bonsai robot publishes a set of ROS 2 sensor topics. To access it, you need to install a zenoh-bridge-ros2dds instance on your host machine (it is already running on Bonsai's Brain), connect it to our Brain via an ethernet port, and the topics appear in your ROS 2 graph. Each side of the bride is independent and your machine keeps its own ROS 2 distribution and DDS.

Requirements

  • ROS 2 with a supported DDS. See Compatibility in our Repo.

  • A direct ethernet link to the Bonsai robot.

  • Docker, if you run the bridge with the bundled compose.yaml (optional).

Refer to our Bonsai-SDK repo for more detailed information on installation and releases. If you do not have access to the repo, contact support@bonsairobotics.ai.

Topics available

Every topic uses a stock ROS 2 type except three:

  •  point_cloud_interfaces (CompressedPointCloud2);

  • foxglove_msgs (GeoJSON);

    bonsai_msgs.

The first two are installed by install.sh, and you build bonsai_msgs from msgs/.

Here are the topics you have access to:

Cameras

Topic

Type

Rate

/camera_front_center/left/image_compressed_raw

sensor_msgs/CompressedImage

15 Hz

/camera_front_center/right/image_compressed_raw

sensor_msgs/CompressedImage

15 Hz

/camera_rear_center/left/image_compressed_raw

sensor_msgs/CompressedImage

15 Hz

/camera_rear_center/right/image_compressed_raw

sensor_msgs/CompressedImage

15 Hz

/camera_{front,rear}_center/{left,right}/camera_info

sensor_msgs/CameraInfo

15 Hz

The images are format="h265". Decode them with compressed_image_decoder.

IMU

Topic

Type

Rate

/imu/data

sensor_msgs/Imu

>100 Hz

/lidar/imu

sensor_msgs/Imu

~400 Hz

/camera_{front,rear}_center/imu

sensor_msgs/Imu

>100 Hz

All IMU topics report linear acceleration and angular velocity only. None report orientation: the orientation field is an identity quaternion with covariance [-1, ...], marked unusable by REP 145.

GNSS

Topic

Type

Rate

/gnss_1/llh_position

sensor_msgs/NavSatFix

10 Hz

/gnss_2/llh_position

sensor_msgs/NavSatFix

10 Hz

/gnss/heading_raw

sensor_msgs/Imu

10 Hz

/gnss/heading_raw reports the raw dual-antenna heading as an ENU orientation. Yaw and pitch accuracy are in orientation_covariance. Acceleration and angular velocity are marked unusable by REP 145.

Lidar

Topic

Type

Rate

/lidar/points/zstd

point_cloud_interfaces/CompressedPointCloud2

10 Hz

The points are format="zstd", wire-compatible with zstd_point_cloud_transport. Decode them with compressed_pointcloud_decoder, and subscribe reliable (see Reliable QoS for large topics).

Wheel odometry

Topic

Type

Rate

/meas_twist

geometry_msgs/TwistStamped

>30 Hz

Vehicle state and navigation

Topic

Type

Rate

/vehicle_state

bonsai_msgs/VehicleState

10 Hz

/geopath

foxglove_msgs/GeoJSON

on update

VehicleState is defined in bonsai_msgs (see Setup). /geopath is not latched, so a subscriber that joins late receives the next update rather than the current path.

Examples

Future implementations

The current capabilities allow users in the Research and Education programs to read data only from our robots. We are working towards gradually implementing more features, so reach out if you have specific needs. This is a non-extensive list of upcoming features:

  • Start, pause, resume, stop jobs sent from Bonsai Pilot (web or mobile apps).

  • Control digital and analog outputs.

  • Send twist commands.

  • Send GPS routes.