Are you using gRPC with Go bindings? There is work underway for rules_go in Bazel to expose generated types like your gRPC and Protobuf classes.
You can follow this issue for updates: https://github.com/bazelbuild/rules_go/issues/512
You can follow this issue for updates: https://github.com/bazelbuild/rules_go/issues/512