1. How do you get good at giving talks?
2. How do you generate opportunities to talk?
Most of the other comments are focused on the first (practice), but if the question is the second, it is really a question about marketing.
You have to become famous in a niche, perhaps write something you can be known for. Try to develop a platform, or else write for a well known brand.