If I'm trying to send a message to something that's expecting a MSGPACK_OBJECT_DOUBLE I am currently unable to do so if the number also happens to be an integer - 0 for example - as MSGPACK_OBJECT_POSITIVE_INTEGER is chosen for me and the receiver doesn't know what to do with it.
A possible API could go like this:
var value = new Number(0);
value.msgpackType = msgpack.MSGPACK_OBJECT_DOUBLE; // 4
var msg = msgpack.pack([1, value]);