This page includes brief installation instructions and links to the open-source GitHub repositories for Anthropic's Client SDKs. For basic usage instructions, see the API reference For detailed usage instructions, refer to each SDK's GitHub repository.
Additional configuration is needed to use Anthropic's Client SDKs through a partner platform. If you are using Amazon Bedrock, see this guide; if you are using Google Cloud Vertex AI, see this guide; if you are using Microsoft Foundry, see this guide.
Requirements: Python 3.8+
Installation:
pip install anthropicTypeScript library GitHub repo
While this library is in TypeScript, it can also be used in JavaScript libraries.
Installation:
npm install @anthropic-ai/sdkRequirements: Java 8 or later
Installation:
Gradle:
implementation("com.anthropic:anthropic-java:2.10.0")Maven:
<dependency>
<groupId>com.anthropic</groupId>
<artifactId>anthropic-java</artifactId>
<version>2.10.0</version>
</dependency>Requirements: Go 1.22+
Installation:
go get -u 'github.com/anthropics/[email protected]'The C# SDK is currently in beta.
Requirements: .NET 8 or later
Installation:
dotnet add package AnthropicRequirements: Ruby 3.2.0 or later
Installation:
Add to your Gemfile:
gem "anthropic", "~> 1.13.0"Then run:
bundle installThe PHP SDK is currently in beta.
Requirements: PHP 8.1.0 or higher
Installation:
composer require "anthropic-ai/sdk 0.3.0"Every SDK has a beta namespace that is available for accessing new features that Anthropic releases in beta versions. Use this in conjunction with beta headers to access these features. Refer to each SDK's GitHub repository for specific usage examples.