Skip to main content
Helicone provides seamless integration with Anthropic Claude models, supporting all features including streaming, prompt caching, and tool use.

Integration Methods

Proxy Integration

Route requests through Helicone’s Anthropic proxy.

AI Gateway

Use Claude through the unified AI Gateway with OpenAI-compatible API.

Async Logging

Zero-latency logging using OpenLLMetry.

AWS Bedrock

Track Claude models on AWS Bedrock.

Quick Start

1

Get your API keys

You’ll need:
2

Update your base URL

Change the base URL to route requests through Helicone:
3

Make requests as usual

Use the Anthropic SDK normally:
4

View your logs

All requests are now logged to your Helicone dashboard.

Streaming Support

Helicone fully supports Anthropic streaming:

Prompt Caching

Helicone tracks Anthropic’s prompt caching, showing cache hits and cost savings:

Tool Use (Function Calling)

Track Claude’s tool use with full visibility:

Vision

Use Claude with images:

Session Tracking

Track multi-turn conversations:
Learn more about Session Tracking.

Custom Properties

Add custom metadata to track important context:

Using the AI Gateway

Access Claude through the AI Gateway with OpenAI-compatible API:
Learn more about the AI Gateway.

AWS Bedrock

Track Claude models on AWS Bedrock:

Response Caching

Reduce costs with Helicone’s response caching:
Note: This is separate from Anthropic’s prompt caching. Helicone caching caches entire responses. Learn more about Response Caching.

Zero-Latency Integration

For production applications, use async logging:
Learn more about Async Logging.

Best Practices

Never hardcode API keys:
Include session and user IDs:
Use Anthropic’s prompt caching for large contexts:
Track both input and output tokens, plus cache usage:

Troubleshooting

  1. Verify your Helicone API key is correct
  2. Check the Helicone-Auth header format: Bearer sk-helicone-...
  3. Ensure you’re using https://anthropic.helicone.ai
  4. Confirm your Anthropic API key is valid
  • Pass Anthropic API key as apiKey parameter
  • Pass Helicone API key in Helicone-Auth header
  • Format: Helicone-Auth: Bearer sk-helicone-...
  • Ensure you’re using the latest @anthropic-ai/sdk version
  • Check that your base URL is correct
  • Streaming works with both proxy and AI Gateway methods
  • Prompt caching only works with Claude 3.5 Sonnet and later
  • Cache blocks must be at least 1024 tokens
  • View cache metrics in the Helicone dashboard

Supported Models

Helicone supports all Anthropic models:
  • Claude 3.5 Sonnet (claude-3-5-sonnet-20240620)
  • Claude 3 Opus (claude-3-opus-20240229)
  • Claude 3 Sonnet (claude-3-sonnet-20240229)
  • Claude 3 Haiku (claude-3-haiku-20240307)
  • All future Claude models

Next Steps

AI Gateway

Use Claude with the unified AI Gateway

Session Tracking

Track multi-turn conversations

Async Logging

Zero-latency integration

Custom Properties

Add custom metadata