Heat the vegetable oil in a large wok or deep skillet over medium heat. Add the chopped onion and sauté until translucent, about 3-4 minutes.
Stir in the minced garlic, grated ginger, and chopped red chilies. Cook for another 2 minutes until fragrant.
Add the crab pieces to the wok, stirring to coat them in the aromatics. Cook for about 5 minutes until the crab starts to turn red.
In a bowl, mix together the tomato ketchup, sweet chili sauce, soy sauce, oyster sauce, and sugar. Pour this mixture over the crab.
Add the chicken broth and bring the sauce to a simmer. Cover and cook for 10-15 minutes, allowing the crab to absorb the flavors.
Stir in the cornstarch mixture to thicken the sauce. Cook for an additional 2-3 minutes until the sauce is glossy and thickened.
Remove from heat and garnish with chopped green onions and fresh cilantro before serving.