Skip to content

Support Anthropic Beta Service Instrumentation #38

@adase11

Description

@adase11

The wrapped Anthropic client only supports logging the non-beta path for the Anthropic SDK.

InstrumentedAnthropicClient.invoke() only intercepts "messages()" - beta() falls through to the raw delegate

  if (methodName.equals("messages") && parameterTypes.length == 0) {
      return new InstrumentedMessageService(delegate.messages(), ...);
  }
  return super.invoke(proxy, method, args); // beta() goes here - no instrumentation

An example Anthropic SDK request:

anthropicClient.beta().messages().createStreaming(params);

It would be helpful to support the beta path as wel

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions