Bits follow the chain data.message.data while subs and commerce follow data.message. The bits data seemingly have an unnecessary extra layer
Subs and commerce both have an emotes location struct, that is lacking in cheers. With the number of cheermote variants, this ‘emote’ struct is rather vital for parsing cheer messages
Subs and Commerce have display name while cheers only utilize an user_name. Having this data point live would be useful for when using it for a notifier as it will print out the way the user desired, rather than having to resort to all Upper or lower case.
It is kind of annoying that for Bits the data.message is Stringify’d and Subscription/Commerce are a regular object.
I’m guessing at this point it won’t be changed until a new PubSub version due to the breakage it’d cause.
The problem isn’t so much the escaped message, but rather the contents of said messages.
Bit messages resolve to:
blob: { data: { Message Data }}
Where as EVERYTHING else resolve to
blob: { Message Data }
These resolutions are AFTER the message has been escaped. As a case scenario, if I were to request the sub data I would simply call something similar to stored_SubData.user_name or stored_SubData[“user_name”].
Bits on the other hand required stored_BitsData.data.user_name
There’s also metadata attached to bits messages, the blob you get back looks roughly like this:
Note the message_id, message_type and version fields outside the actual data. Subscription and commerce messages have nothing like it, so I doubt adding a layer to it for consistency’s sake is worth the breaking change.
Message_id is the only true field that makes sense to keep really and I am not even sure how useful it truly is, as the parent object tells you the same info as the type (topic) and the version since it is the version you subscribed to (v1)
Those fields feel like they were revised when building subs and commerce, but no changes have been propagated back to Bits.