Combine the oyster sauce, soy sauce, fish sauce and sugar together in a bowl.
In a wok or a skillet, heat the oil over medium heat. Add the onions and saute until soft and translucent, about 5 minutes.
Once the onions are soft and translucent, add the garlic and Thai chilies and stir until the garlic starts to brown.
Add about ¾ cup (180 ml) of the stock, the sauce mixture, and ground black or white pepper then stir to mix.
Add the bell pepper and cook for about a minute, then turn off the heat and stir in the basil just until wilted.
Taste the sauce, and if it is too salty, add the remaining stock or water to dilute.
Use right away, or allow to cool and keep in the fridge for at least a week.