In a large bowl, whisk together the soy sauce, ketchup, brown sugar, pineapple juice, rice vinegar, vegetable oil, garlic, ginger, black pepper, and red pepper flakes (if using) until well combined.
Add the chicken thighs to the marinade, ensuring they are fully coated. Cover and refrigerate for at least 2 hours, or preferably overnight for maximum flavor.
Preheat your grill to medium-high heat. Remove the chicken from the marinade, reserving the marinade for basting.
Place the chicken skin-side down on the grill. Cook for about 6-7 minutes, then flip and brush with the reserved marinade. Continue grilling for another 6-7 minutes, or until the chicken reaches an internal temperature of 165°F.
Remove the chicken from the grill and let it rest for 5 minutes. Garnish with chopped green onions and sesame seeds before serving.