It appears I can use ````riakc_pb_socket.set_search_index``` to set a search index to a bucket within a bucket type, but not to the overall type programatically.
I am trying to find a way to get the same behavior I can get using riak-admin on the command line.
For example, if I run
riak-admin bucket-type update counters '{"props":{"search_index":"counter_search"}}'
 
I can see that the counter_search index gets added to the console:

But, if I do this via code:
  :ok = :riakc_pb_socket.set_search_index(shared.pid, {"counters", shared.bucket}, "counter_search")
 
The result is that no index is found:

I've tried variations of set_search_index with no avail:
  :ok = :riakc_pb_socket.set_search_index(shared.pid, "counters", "counter_search")
 
Thanks in advance for any help you can provide.