Begin by slicing the onions thinly and placing them in a bowl of cold water. Let them soak while you prepare the batter — this helps to mellow their sharpness and enhances the final texture.
In a mixing bowl, sift together the gram flour and gluten-free baking powder. Stir in the chilli powder, turmeric, and a pinch of salt. Add the chopped green chilli for a subtle heat. Gradually pour in around 100ml of cold water, whisking until a thick, smooth batter forms. If it feels too dense, add a little extra water until the texture resembles a heavy pancake batter.
To prepare the raita, grate the peeled cucumber into a sieve placed over a bowl. Let it drain for a few minutes, then press firmly to remove any excess moisture. In a separate bowl, combine the yogurt, chopped mint, and a pinch of salt and pepper. Fold in the drained cucumber, then transfer the raita to a small serving dish. Chill until ready to serve.
Drain the onions thoroughly and fold them into the prepared batter, ensuring they are evenly coated. Heat about 5cm of vegetable oil in a deep pan or wok over medium heat. Avoid filling the pan more than one-third full to prevent spillage. Test the oil by dropping in a small bit of batter — it should sizzle, rise to the surface, and begin to turn golden.
Carefully drop heaped tablespoons of the onion mixture into the hot oil, cooking in batches to avoid overcrowding. Fry each batch for approximately 3 to 4 minutes, flipping halfway through, until golden brown and crisp on all sides. Remove the bhajis using a slotted spoon and place them on kitchen paper to drain. Sprinkle with a little extra salt while still hot. Keep warm until all are cooked.
Serve immediately with the cool, refreshing cucumber-mint raita on the side.