Muhammad Shah of Brunei

Muhammad Shah (born Awang Alak Betatar; died c. 1402) established the Sultanate of Brunei and was its first sultan, from 1368 to his death in 1402. The genealogy of Muhammad Shah remains unclear. He converted to Islam in the 14th century and assumed the name Sultan Muhammad Shah. Subsequent sovereigns of Brunei, governed by a Muslim administration, were referred to as sultans.

Personal life
Awang Alak Betatar and his half-brother Awang Semaun were among the 14 siblings born to their father, Dewa Emas Kayangan, and a Murut woman from Limbang. Dewa Emas Kayangan embarked on a quest for a specific type of cattle, the tembadau, to fulfill his wife's desires while she was pregnant. Throughout his journey, he married women in four villages, fathered children, and ultimately had the 14 siblings mentioned. Upon finding the tembadau, Dewa Emas Kayangan chose to ascend to the celestial realms, where he was known as Batara Kala di Kayangan. Awang Alak Betatar was crowned despite not being the firstborn prince. Charming and attractive, he rose to become Brunei's first monarch.

Founding of Brunei
The current state of Brunei was formed by Muhammad Shah, with the help of his brothers. He ruled as Raja Awang Alak Betatar until the early 1360s, until his conversion to Islam. Before the Brunei River colony was established, Awang Alak Betatar established a new village in Negeri Garang in the current Temburong District. Following a period at Negeri Garang, Awang Alak Betatar then moved to Brunei on the waters around Kota Batu. The reason for the migration was because they felt the new place was more suitable as the centre of administration. The location of Kota Batu near a river enabled Awang Alak Betatar to control the rural areas and enlarge his political influence.

The Syair Awang Semaun explains the history of Brunei, which was ruled by Awang Alak Betatar and his siblings; Awang Semaun at Kota Batu; Pateh Mambang and Pateh Tuba at Luba: Pateh Sangkuna and Pateh Manggurun at Saba, Pateh Malakai at Bukit Panggal, Pateh Pahit at Labuhan Kapal, Damang (Damong) Sari at Bukit Salilah, Pateh Sindayung at Panchor Papan, Demang Lebar Daun, Hapu Awang, Pateh Berbai (also known as Sultan Ahmad of Brunei), and Pateh Laila Langgong.

Brunei's rise and expansion
At the beginning, Melanau and Brunei were both subjects of the Majapahit Empire. A number of regions, including "Kadangdangan, Landa Samedang, Tirem, Sedu, Barune(ng), Kalaka, Saludung, Solot, Pasir Barito, Sawaku, Tabulang, Tajung Kuteri, and Malano," were vassals of the Majapahit, according to the old Nagarakretagama record. As the Majapahit Empire collapsed, Brunei seized the chance to increase its power and set its sights on the Tutong River region. Pembakal Bangis, a Bruneian nobleman, was chosen by Awang Alak Betatar to make the request that Mawangga, the Tutong chief, show up at the capital. Mawangga responded, however, that he and his people were conquered slaves, ruled by the Melanau leader Basiung and his in-law Tugaw, who resided in Igan, and that they could not submit.

Mawangga told Pembakal Bangis that Tutong would surrender to the authority of the Brunei Raja if the great Melanau commander, Awang Alak Betatar, ordered his soldiers to proceed to Igan. Awang Alak Betatar's demand was communicated to Basiung, the chief of the Bruneian forces at Igan. However, Basiung was not pleased and was used to people approaching him. In response, Basiung suggested that Awang Alak Betatar pay him a visit instead, threatening to launch an Igan attack on Brunei if there was any delay. Bangis told Basiung nine days to make up his mind, but Basiung was unfazed and declared that he would make sure Awang Alak Betatar didn't hurt him if he showed up on time with presents. Awang Alak Betatar and his ministers, Awang Semaun, Awang Jeramabak, and Pateh Damang Sari, were offended by Basiung's reply and chose to attack Igan in order to establish their authority.

The first battleground between Brunei and foreign armies was the Sarawakian Igan Valley. The Igan River flowed through this valley and was located in the traditional lands of the Melanau-speaking people. There are two accounts of the fight: the first, more legendary, tells of a nine-month struggle between three Brunei heroes and Bilanapura, a genie that Jerambak finally defeated using a miraculous fish skin he stole from an ogre. According to the second, Awang Jerambak's Brunei men came up against Basiung and his 9,000-strong allied armies from Sambas, Matu, Sadung, and Sarikei. The Brunei army, aided by the Dayaks, overpowered Basiung's warriors despite their superior numbers; as a result, Igan was destroyed and war spoils were taken. Following this, Jerambak made Igan accept Awang Alak Betatar's dominance.

The Bruneian soldiers persisted in their conquests, subduing Igan's allies, such as Sarikei, Rajang, Sadung, Sarawak, Tanjung Datu, and Lingga, and stealing and capturing the traditionally Melanau regions of Oya, Matu, and Mukah. They penetrated all the way to Sambas, where they took control of Pontianak, Sanggau, and Sambas itself. They also expanded their dominion over Borneo to the south and southwest. They overcame Banjar (now Banjarmasin) on the east coast and took over parts of northern Borneo, albeit the latter took longer because of the dispersed towns. Awang Alak Betatar expanded the newly established Brunei territory by advancing his frontiers from the Tutong River to the Rejang river delta.

According to Chinese historical accounts, including "Nan Hai Zhi, Volume 7," Brunei ruled over nine regions in the 13th and 14th centuries, which is consistent with the Syair Awang Semaun. It describes how Awang Alak Betatar expanded his domain to include Sungai Igan and then took five more provinces from Johor on Borneo's west coast: Sarawak, Samarahan, Sadong, Mukah, and Kalaka. With the acquisition, Brunei's colonial territories became a total of 14, in line with reports that date back to the 10th century. Due to the influence of the Srivijaya, these provinces had slipped out of Brunei's authority, but in the middle of the 14th century, Awang Alak Betatar regained them, solidifying Brunei's historical geographical reach.

Brunei was still ruled by the Javanese, but according to "Ming Tai Zu Shi Lu, Volume 67," it confirmed its authority over 14 states. This figure is consistent with Brunei's oral traditions and corresponds with the country's 10th century geographical dominance, as documented in "Zhu Fan Zhi" (977). The myth, passed down orally, tells of a prince who, while searching for a missing spear, got married in each of the 14 states he went to, bearing sons who were subsequently made rulers of these communities. The Chinese accounts verify Brunei's historical authority over 14 territories, even with their mythological components.

Islamic conversion and land grants
As to the Salasilah Raja-Raja Brunei (Manuscript 9B), upon Sultan Muhammad Shah's ascension as the first Sultan of Brunei, he was bestowed with many lands by the Yang Di-Pertuan of Johor, including Kalaka, Saribas, Semarahan, Sarawak, and Mukah. Theorising that the Melanau people's resistance to Brunei rule could account for the difference within the battle accounts and the gift from the Sultan of Johor, Dzulfawati Haji Hassan published her paper "Hubungan Melanau-Brunei" for the 10th Anniversary of Universiti Brunei Darussalam in 1996. In defiance of Brunei's invasions and conquests, the Melanau sided with Johor and revolted. However, these states were eventually restored to Brunei after Sultan Muhammad Shah wed a princess of Johor.

Local customs, recorded in the Syair Awang Semaun and the Salasilah Raja-Raja Brunei, state that Awang Alak Betatar turned to Islam in order to marry Puteri Dayang Pingai, the daughter of the Sultan of Johor. While archeological data points to Brunei's emergence in the 10th century, some historians of Brunei have placed this event as early as 1368 (Jamil Al-Sufri 1997), which has come to be accepted as the official date of the sultanate's Islamic conversion, though there is still room for disagreement. Early on under Sultan Muhammad Shah's rule, Brunei was required to pay tribute to China as well as Java. This time frame matched the Ming Dynasty's ascent to power in 1368, following the fall of the Yuan Dynasty.

According to Jamil Al-Sufri, the Johor in the Salasilah Raja-Raja Brunei should be understood as Tumasik, or ancient Singapore, as Johor was not created until 1512. Pengiran Mohammad (1992), who seems to have known that Singapore was not a Muslim country, proposes that Melaka, whose kings converted to Islam in the early 15th century, should be considered as the correct interpretation. It is unclear whom Muhammad Shah married, but it is reported either as the daughter of Iskandar Shah, or the daughter of Sang Nila Utama, both of the House of Sang Sapurba.

Awang Alak Betatar's conversion of the Malay Hindu-Buddhist monarchy of Brunei to Islam transformed its religious landscape. However, because of the strong Hindu-Buddhist influence, Islam had not yet thoroughly permeated Bruneian society in the immediate wake of his conversion. According to Mahmud Saedon in 2003, Islamic missionary activities also hadn't established a solid foundation at that point. Despite this, evidence also suggests that the present-day region of Brunei was home to an Islamic presence before to the establishment of the Sultanate, as well as a pre-existing Muslim monarchy.

Muhammad Shah and Ming China
During the Ming Dynasty's rise in the 14th century, Ancient China actively sought to restore diplomatic relations and commerce with Southeast Asian kingdoms. Between 1370 and 1375, under the Hongwu Emperor, Chinese envoys were dispatched to several kingdoms in the South China Sea region, including Majapahit in Java, Suwarnabhumi, Pagaruyung, Malayapura in Sumatra, and notably Brunei. These efforts aimed to establish diplomatic ties and assert Chinese influence in the region, amidst ongoing Javanese dominance.

Shen-Chi and his aide Chang-Jhing-Chi went out in September 1370 to deliver a letter addressed to Brunei, also known as the state of Poni, on behalf of the Chinese emperor. On 18 November 1371, they landed in Java after leaving Quan-Chau. They learned that Muhammad Shah was the new name of the Poni kingdom shortly after they arrived in Java. The account makes special notice of the Sultan's demeanour, characterising him as exceedingly egotistical. Muhammad Shah showed opposition to Chinese domination by acting coldly toward the Chinese emissary. He provided a number of justifications for rejecting China's hegemony.

As per Brunei's oral traditions, the report recalls an invasion by the Sulu people. Sultan said, "Recently the state of Solo (Sulu) has invaded my country, my children and my possessions have all been confiscated." The Sultan opposed Chinese dominance in 1371, acting coldly with the Chinese ambassador and bringing up recent battles like the Sulu invasion and Majapahit's shielding might. Chinese records show that Awang Alak Betatar had already converted to Islam in 1371. The report from the Chinese ambassador makes clear that Brunei had to manage its contacts with China and Java even after the Sultan's conversion, even though it had become independent of Java. The Syair Awang Semaun, celebrating Brunei's strength and victories like repelling the Sulu invasion, contrasts with the more balanced narrative in the Salasilah Raja-Raja Brunei. This historical account acknowledges Brunei's earlier subordination to Java and its subsequent independence following its Islamic conversion.

Chinese records from the "Ming-shih" mention the Sultan of Brunei in 1370 as Ma-ho-mo-sa, interpreted by local historians as referring to Muhammad Shah, the first Islamic Sultan of Brunei, though some suggest it might read as Mahmud Shah or "Maha Moksha," a Buddhist name, reflecting earlier cultural influences. The 1371 mission to China resulted in two significant letters: the "Golden Letter," symbolising Brunei's submission to Chinese authority, and the "Perak Letter," detailing payments to the Hongwu Emperor. Both letters were brought in September 1371 by Zhang-Jing-Zhi, the Chinese official, and Ismail, the Sultan's envoy. One of the letters reads, "My country is a very small place ruled by She-po (Java), very much in need of attention from His Majesty."

Muhammad Shah's daughter, Princess Ratna Dewi, allegedly married a Chinese immigrant by the name of Ong Sum Ping who started a trading station at Mumiang on the Kinabatangan River. For this he was conferred the nobility title of Pengiran Maharaja Lela and elected Chief of Kinabatangan.

Legends
The Syair Awang Semaun, originally an oral tradition in Brunei, was first transcribed into written form in 1947 by Allen R. Maxwell, who released additional portions in 2005. It primarily recounts mythological tales from pre-Islamic Brunei, focusing on the reign of Awang Alak Betatar, possibly the kingdom's earliest documented monarch. Central to the narrative is Awang Semaun, a Bruneian Malay celebrated for his bravery and physical strength rather than his association with Awang Alak Betatar.

The early history of Brunei is complex, characterised by discrepancies between Chinese sources and local Bruneian accounts such as the Salasilah Raja-Raja Brunei. Chinese records mention figures like Raja Ma-na-je-chia-na (Maharaja Karna) and his son Hsia Wang (Raja Kecil), aided by Ismail and Mahmud, ruling Brunei until 1425. In contrast, the genealogy skips these figures, instead naming Sultan Ahmad (Pateh Berbai or Ong Sum Ping) after Muhammad Shah. This divergence underscores the uncertain early succession of Brunei's sultans and suggests the genealogy might incorporate distinct oral traditions. Spanish texts from the Boxer Codex (1590) mention Sultan Yusuf as Brunei's purported Islamic state founder, adding another layer to the historical discourse. The presence of Ismail in both Chinese accounts—first as Muhammad Shah's envoy to China in 1371 and later as Hsia Wang's grandfather's uncle in 1421—suggests a significant historical link between Chinese-documented Ma-na-je-chia-na and Brunei's sultanate.

The Chinese Emperor's 1405 coronation of Raja Ma-na-je-chia-na could reflect Awang Alak Betatar's uncertainty toward China, influenced by Javanese pressures during the 1371 envoy visit. This mirrors China's strategic approach, exemplified by its 1377 installation of a new ruler in the Suwarnabhumi Kingdom to counter Javanese influence. These intricate historical dynamics underscore Brunei's nuanced early history and ongoing scholarly inquiries into its royal succession and geopolitical influences.