In the Beginningless Beginning, there was Ame no Minaka-nushi no Kami, the Ruling Spirit of the Center of Creation, and Absolutely Nothing Else At All.
Absolutely Nothing Else At All faced the outside of the Center of Creation, where Ame no Minakanushi no Kami dwelt, and spontaneously, simultaneously, reacted to the Divine Virtue by on the one hand expanding it to fill the Endless Emptiness and create Heaven, becoming Takamimusubi no Kami, the “Exalted Creator Spirit”; on the other, reflecting and compressing and digesting the Divine Virtue, forming the Earth and becoming Kamimusubi no Kami, the “Divine Creator Spirit”.
This was quite a while ago, obviously.
Ame No Minaka-nushi No Kami, Takamimusubi No Kami, and Kamimusubi No Kami are collectively known as the Musubi-Kami.
Shintō — the Way of the Kami — was originally known as “Musubi no Michi”, the Way of Musubi (産霊), so the term deserves a little unpacking.
The term “musu”, represented by the kanji 産, has an association with the concepts of giving birth to something, or producing something. An old Japanese poem refers to moss growing on a huge boulder over eight thousand human generations, even as the boulder is eventually reduced to pebbles, which are themselves completely hidden by the moss — the verb used to describe the moss growing is “musu”, apparently spontaneous, endlessly creative and transformative action.
The word “bi”, represented by the kanji 霊, has the sense of things of which nothing can be said but which inspire reverence, despite — perhaps because of — their essentially hidden nature. Just as ancient people revered the Sun, they also revered these things which they could sense, but not describe.
So, the Musubi-Kami are the spiritual beings who are the ultimate progenitors of everything which exists or is said to exist in Heaven and Earth, which is exalted and which inspires reverence, and of which little else may be said.
Most of Shintō mythology comes from the first volume of the Kojiki, the “Chronicle of Ancient Times”. The Kojiki and the Nihonshoki, compiled around the same general time, are the oldest existing Japanese histories, dating from the beginning of the Nara period, early in the 8th Century.
The Kojiki was compiled by order of the emperor Tenmu Ten-Nō, around the year 684. Prior to that time, there had been long-circulated histories among the various nobles families, notably works known as the Teiki and Kyūji. Since most of the transmission of these works was by oral recitation, a wide range of variations crept in over the years and became a matter of concern for the Emperor, who ordered the creation of an official version.
This task was given to Hieda no Are (who may or may not have been a woman). The Hieda family had functioned as specialists in oral history (and as oracular priestesses, probably related occupations) for many generations, performing a similar function in Japan as bards like Homer did in ancient Greece. It was said that Hieda no Are only had to hear a piece of literature recited a single time to be able to reproduce it perfectly from memory.
Hieda no Are traveled the country, hearing the differing versions of the nation’s history and harmonizing them into a single consistent chronicle.
Are’s work was interrupted for a time by the death of Tenmu Ten-Nō in 686, but continued on and off for the next quarter of a century. Finally, in 711, Genmei Ten-Nō ordered the scribe Ō no Yasumaru — written language was a relatively new thing in Japan, imported from China — to set down a text based on Are’s research, Are set to dictating and Yasumaru wrote, and the Kojiki was completed in 712.
The Kojiki is a work in three volumes: the first concerns the world of the Kami, and their creation of Heaven and Earth — “Earth” being “Japan”, for the most part — and all the things within them. The second and third volumes are concerned with the descent of the Imperial Family, beginning with the legendary Jinmu (“Spirit Warrior”) Ten-Nō (660 BCE?) and continuing through to the time of Suiko Ten-Nō (554-628).