Implement the expand-id API.

I've been using bson.D rather than bson.M in general. It's equivalent, but just slightly more lightweight at runtime.