Run your first Tavily Search in 4 lines of code. Simply replace the API key in this snippet with your own.
Copy
Ask AI
from tavily import TavilyClienttavily_client = TavilyClient(api_key="tvly-YOUR_API_KEY")response = tavily_client.search("Who is Leo Messi?")print(response)
That’s all it takes to start using Tavily’s basic features!If you want to learn how to implement more complex workflows in Python, check out our intermediate-level Getting Started notebook.Or, dive deep into our API and read about the different parameters on our API Reference page, and learn how to integrate natively with one of our SDKs.