# SDKs

The Amigo SDK provides a complete interface to interact with Amigo's API in Python and TypeScript. Our SDKs abstract the complexities of authentication, request formatting, response parsing, and error handling, letting developers focus on building AI-powered applications.

{% hint style="warning" %}
**Classic API only** - These SDKs wrap the Classic API at `api.amigo.ai`. The Platform API does not have official SDKs yet - use direct HTTP requests with Bearer token authentication. See [Platform API Authentication](https://docs.amigo.ai/developer-guide/platform-api/platform-api/authentication) for details.
{% endhint %}

## Available SDKs

### Python SDK

The official Python SDK for the Amigo API, supporting both synchronous and asynchronous operations.

| Property           | Value                                                                                |
| ------------------ | ------------------------------------------------------------------------------------ |
| **Package**        | `amigo_sdk`                                                                          |
| **Repository**     | [github.com/amigo-ai/amigo-python-sdk](https://github.com/amigo-ai/amigo-python-sdk) |
| **Registry**       | [PyPI](https://pypi.org/project/amigo_sdk/)                                          |
| **Python Version** | 3.11+                                                                                |

### TypeScript SDK

The official TypeScript/JavaScript SDK for the Amigo API, with full type safety and modern async/await patterns.

| Property            | Value                                                                                        |
| ------------------- | -------------------------------------------------------------------------------------------- |
| **Package**         | `@amigo-ai/sdk`                                                                              |
| **Repository**      | [github.com/amigo-ai/amigo-typescript-sdk](https://github.com/amigo-ai/amigo-typescript-sdk) |
| **Registry**        | [npm](https://www.npmjs.com/package/@amigo-ai/sdk)                                           |
| **Node.js Version** | 18+                                                                                          |

## Key Features

Both SDKs provide:

{% hint style="info" %}
**Auto-generated Types**\
Types are generated from the latest [Amigo OpenAPI schema](https://api.amigo.ai/v1/openapi.json), ensuring API compatibility.
{% endhint %}

* **Streaming Support** - Real-time conversation events with built-in NDJSON parsing
* **Error Handling** - Typed error handling for all API responses
* **Authentication** - Automated API key-based authentication and token management
* **Configuration** - Environment variable support with flexible configuration options
* **Resource Coverage** - Complete access to Amigo API resources (conversations, users, services, organizations)

## API Compatibility

{% hint style="warning" %}
**Version Compatibility**\
SDKs auto-generate types from the latest OpenAPI schema. Only the latest published SDK version is guaranteed to match the current API. Older versions may lack new endpoints or fields.
{% endhint %}

## Getting Started

{% tabs %}
{% tab title="Quick Start" %}

1. [**Installation**](https://docs.amigo.ai/developer-guide/classic-api/sdks/sdk-installation) - Set up the SDK in your project
2. [**Configuration**](https://docs.amigo.ai/developer-guide/classic-api/sdks/sdk-configuration) - Configure authentication and client options
3. [**Hello World**](https://docs.amigo.ai/developer-guide/classic-api/sdks/sdk-hello-world) - Create your first conversation
4. [**Error Handling**](https://docs.amigo.ai/developer-guide/classic-api/sdks/sdk-error-handling) - Handle errors and edge cases
   {% endtab %}

{% tab title="Advanced" %}

* [**Streaming Responses**](https://docs.amigo.ai/developer-guide/classic-api/core-api/conversations/conversations-interact) - Handle real-time events
* [**User Management**](https://docs.amigo.ai/developer-guide/classic-api/core-api/users) - Create and manage users
* [**Regional Endpoints**](https://docs.amigo.ai/developer-guide/getting-started/regions-and-endpoints) - Configure regional deployments
  {% endtab %}
  {% endtabs %}

## Production Examples

Explore these examples demonstrating production-ready patterns:

{% tabs %}
{% tab title="Python Examples" %}
**Repository**: [github.com/amigo-ai/amigo-python-sdk/examples](https://github.com/amigo-ai/amigo-python-sdk/tree/main/examples)

* Project structure best practices
* Environment configuration
* Error handling patterns
* Async/await implementations
  {% endtab %}

{% tab title="TypeScript Examples" %}
**Repository**: [github.com/amigo-ai/amigo-typescript-sdk/examples](https://github.com/amigo-ai/amigo-typescript-sdk/tree/main/examples)

* Type-safe implementations
* Modern async patterns
* Production error handling
* Real-world application contexts
  {% endtab %}
  {% endtabs %}

## Support & Resources

| Resource                  | Link                                                                     |
| ------------------------- | ------------------------------------------------------------------------ |
| **Python SDK Issues**     | [GitHub Issues](https://github.com/amigo-ai/amigo-python-sdk/issues)     |
| **TypeScript SDK Issues** | [GitHub Issues](https://github.com/amigo-ai/amigo-typescript-sdk/issues) |
| **Enterprise Support**    | Contact support through the Amigo dashboard                              |
| **API Reference**         | [OpenAPI Schema](https://api.amigo.ai/v1/openapi.json)                   |

## License

Both SDKs are licensed under the MIT License.
