{% rich_text 'random' label='some random content', html="<p>Hi!</p>", export_to_template_context=True %}
This is an important concept, particularly in cases where modules might have more than one attribute you want to get data from like an img module with an src and alt_text attribute. That last part of the name target is going to be the attribute you want the data from. If you want the label make it label, if you want the src make it src, if you want the value you make it value. In this case it is html:
{% rich_text 'random' label='some random content', html="<p>Hi!</p>", export_to_template_context=True %}
This is an important concept, particularly in cases where modules might have more than one attribute you want to get data from like an img module with an src and alt_text attribute. That last part of the name target is going to be the attribute you want the data from. If you want the label make it label, if you want the src make it src, if you want the value you make it value. In this case it is html:
I don't have any practical experience playing with that, but the thing is the data from the module is exported to the template so I would assume that as long as the global module is on a page containing the module that you have export and whose data you are targeting then it should work. I would also assume that the module that is exported to the template should exist above any use of it's data tokens.
I don't think you can add editable fields to a global module though so I do not believe you could contain the exported module inside of the global module. It would be the equivilant of static text anyways.