expose protobuf encoding/decoing API