https://retellai.com/?utm_source=discord&utm_medium=seo logo
<@1145576664366055464> I'm experiencing authentica...
# ❓・ai-evy-support
j
@AI Evy I'm experiencing authentication issues when trying to integrate Retell's voice AI into my platform. When making API requests to create a Retell agent or start a call, I'm receiving "Cannot GET /v2/agents" and 404 errors. I've verified that: 1. The api.retellai.com domain resolves correctly 2. My curl test returns "Cannot GET /v2/agents" instead of a valid response 3. I'm using the authorization header with my API key: "Authorization: Bearer [my_key]" I'm trying to implement a feature where users can talk with an agent. Any guidance on what might be wrong with my API key or permissions would be greatly appreciated. Thank you!
a
Thanks for tagging me @josh_98013. I'll look through relevant sources and get back to you shortly.
### Answer I notice you're making direct API calls. For easier integration and to avoid common authentication issues, I recommend using one of Retell's official SDKs [(1) ]() : 1. For Node.js/TypeScript:
Copy code
bash
npm i retell-sdk
2. For Python:
Copy code
bash
pip install retell-sdk
After installation, initialize the client with your API key : Node.js/TypeScript:
Copy code
typescript
import Retell from 'retell-sdk';

const retellClient = new Retell({
  apiKey: "YOUR_API_KEY",
}) ;
Python:
Copy code
python
from retell import Retell

retell_client = Retell(
  api_key="YOUR_API_KEY"
)
The SDKs provide typed methods and a more structured approach to integrating with Retell, which can help reduce code complexity and avoid authentication issues . For security verification, make sure to check the X-Retell-Signature header when making requests - this value should be an encrypted request body using your secret key [(2) ]() . If you continue experiencing issues, please check out these resources: - [Node.js SDK Examples]() [(1) ]() - [Python SDK Examples]()
​ To learn more, see the sources I considered: [[1] SDKs](https://docs.retellai.com/get-started/sdk) [[2] Voice API: Integrate Phone AI Agents with Your System | Retell AI](https://www.retellai.com/blog/how-to-integrate-phone-ai-agents-with-your-existing-api-systems) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.